Skip to content

Instantly share code, notes, and snippets.

@justinyoo
Created June 20, 2016 03:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save justinyoo/40ee3814886b33504cef9230c5230ce5 to your computer and use it in GitHub Desktop.
Save justinyoo/40ee3814886b33504cef9230c5230ce5 to your computer and use it in GitHub Desktop.
Application Insights WebTests SDK
public class WebTestResource : GenericResource
{
private const string ResourceType = "Microsoft.Insights/webtests";
private const string ApiVersion = "2015-05-01";
public WebTestResource(string name, string url, ResourceBaseExtended insights)
{
var syntheticMonitorId = $"{name}-{insights.Name}";
this.ResourceIdentity = new ResourceIdentity($"{syntheticMonitorId}", ResourceType, ApiVersion);
this.Location = insights.Location;
this.Tags.Add($"hidden-link:{insights.Id}", "Resource");
}
...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment