com.pulumi.azurenative.insights.WorkbookTemplate Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of azure-native Show documentation
Show all versions of azure-native Show documentation
A native Pulumi package for creating and managing Azure resources.
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package com.pulumi.azurenative.insights;
import com.pulumi.azurenative.Utilities;
import com.pulumi.azurenative.insights.WorkbookTemplateArgs;
import com.pulumi.azurenative.insights.outputs.WorkbookTemplateGalleryResponse;
import com.pulumi.azurenative.insights.outputs.WorkbookTemplateLocalizedGalleryResponse;
import com.pulumi.core.Alias;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import java.lang.Integer;
import java.lang.Object;
import java.lang.String;
import java.util.List;
import java.util.Map;
import java.util.Optional;
import javax.annotation.Nullable;
/**
* An Application Insights workbook template definition.
* Azure REST API version: 2020-11-20. Prior API version in Azure Native 1.x: 2019-10-17-preview.
*
* ## Example Usage
* ### WorkbookTemplateAdd
*
*
* {@code
* package generated_program;
*
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.azurenative.insights.WorkbookTemplate;
* import com.pulumi.azurenative.insights.WorkbookTemplateArgs;
* import com.pulumi.azurenative.insights.inputs.WorkbookTemplateGalleryArgs;
* import java.util.List;
* import java.util.ArrayList;
* import java.util.Map;
* import java.io.File;
* import java.nio.file.Files;
* import java.nio.file.Paths;
*
* public class App {
* public static void main(String[] args) {
* Pulumi.run(App::stack);
* }
*
* public static void stack(Context ctx) {
* var workbookTemplate = new WorkbookTemplate("workbookTemplate", WorkbookTemplateArgs.builder()
* .author("Contoso")
* .galleries(WorkbookTemplateGalleryArgs.builder()
* .category("Failures")
* .name("Simple Template")
* .order(100)
* .resourceType("microsoft.insights/components")
* .type("tsg")
* .build())
* .location("west us")
* .priority(1)
* .resourceGroupName("my-resource-group")
* .resourceName("testtemplate2")
* .templateData(Map.ofEntries(
* Map.entry("$schema", "https://github.com/Microsoft/Application-Insights-Workbooks/blob/master/schema/workbook.json"),
* Map.entry("items",
* Map.ofEntries(
* Map.entry("content", Map.of("json", """
* ## New workbook
* ---
*
* Welcome to your new workbook. This area will display text formatted as markdown.
*
*
* We've included a basic analytics query to get you started. Use the `Edit` button below each section to configure it or add more sections. """)),
* Map.entry("name", "text - 2"),
* Map.entry("type", 1)
* ),
* Map.ofEntries(
* Map.entry("content", Map.ofEntries(
* Map.entry("exportToExcelOptions", "visible"),
* Map.entry("query", """
* union withsource=TableName *
* | summarize Count=count() by TableName
* | render barchart """),
* Map.entry("queryType", 0),
* Map.entry("resourceType", "microsoft.operationalinsights/workspaces"),
* Map.entry("size", 1),
* Map.entry("version", "KqlItem/1.0")
* )),
* Map.entry("name", "query - 2"),
* Map.entry("type", 3)
* )),
* Map.entry("styleSettings", ),
* Map.entry("version", "Notebook/1.0")
* ))
* .build());
*
* }
* }
*
* }
*
*
* ## Import
*
* An existing resource can be imported using its type token, name, and identifier, e.g.
*
* ```sh
* $ pulumi import azure-native:insights:WorkbookTemplate testtemplate2 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/workbooktemplates/{resourceName}
* ```
*
*/
@ResourceType(type="azure-native:insights:WorkbookTemplate")
public class WorkbookTemplate extends com.pulumi.resources.CustomResource {
/**
* Information about the author of the workbook template.
*
*/
@Export(name="author", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> author;
/**
* @return Information about the author of the workbook template.
*
*/
public Output> author() {
return Codegen.optional(this.author);
}
/**
* Workbook galleries supported by the template.
*
*/
@Export(name="galleries", refs={List.class,WorkbookTemplateGalleryResponse.class}, tree="[0,1]")
private Output> galleries;
/**
* @return Workbook galleries supported by the template.
*
*/
public Output> galleries() {
return this.galleries;
}
/**
* Key value pair of localized gallery. Each key is the locale code of languages supported by the Azure portal.
*
*/
@Export(name="localized", refs={Map.class,String.class,List.class,WorkbookTemplateLocalizedGalleryResponse.class}, tree="[0,1,[2,3]]")
private Output* @Nullable */ Map>> localized;
/**
* @return Key value pair of localized gallery. Each key is the locale code of languages supported by the Azure portal.
*
*/
public Output>>> localized() {
return Codegen.optional(this.localized);
}
/**
* Resource location
*
*/
@Export(name="location", refs={String.class}, tree="[0]")
private Output location;
/**
* @return Resource location
*
*/
public Output location() {
return this.location;
}
/**
* Azure resource name.
*
*/
@Export(name="name", refs={String.class}, tree="[0]")
private Output name;
/**
* @return Azure resource name.
*
*/
public Output name() {
return this.name;
}
/**
* Priority of the template. Determines which template to open when a workbook gallery is opened in viewer mode.
*
*/
@Export(name="priority", refs={Integer.class}, tree="[0]")
private Output* @Nullable */ Integer> priority;
/**
* @return Priority of the template. Determines which template to open when a workbook gallery is opened in viewer mode.
*
*/
public Output> priority() {
return Codegen.optional(this.priority);
}
/**
* Resource tags
*
*/
@Export(name="tags", refs={Map.class,String.class}, tree="[0,1,1]")
private Output* @Nullable */ Map> tags;
/**
* @return Resource tags
*
*/
public Output>> tags() {
return Codegen.optional(this.tags);
}
/**
* Valid JSON object containing workbook template payload.
*
*/
@Export(name="templateData", refs={Object.class}, tree="[0]")
private Output
© 2015 - 2024 Weber Informatics LLC | Privacy Policy