Content Item Args
data class ContentItemArgs(val contentItemId: Output<String>? = null, val contentTypeId: Output<String>? = null, val properties: Output<Any>? = null, val resourceGroupName: Output<String>? = null, val serviceName: Output<String>? = null) : ConvertibleToJava<ContentItemArgs>
Content type contract details. Uses Azure REST API version 2022-08-01. In version 1.x of the Azure Native provider, it used API version 2020-12-01. Other available API versions: 2022-09-01-preview, 2023-03-01-preview, 2023-05-01-preview, 2023-09-01-preview, 2024-05-01, 2024-06-01-preview.
Example Usage
ApiManagementCreateContentTypeContentItem
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var contentItem = new AzureNative.ApiManagement.ContentItem("contentItem", new()
{
ContentItemId = "4e3cf6a5-574a-ba08-1f23-2e7a38faa6d8",
ContentTypeId = "page",
Properties = new Dictionary<string, object?>
{
["en_us"] = new Dictionary<string, object?>
{
["description"] = "Short story about the company.",
["documentId"] = "contentTypes/document/contentItems/4e3cf6a5-574a-ba08-1f23-2e7a38faa6d8",
["keywords"] = "company, about",
["permalink"] = "/about",
["title"] = "About",
},
},
ResourceGroupName = "rg1",
ServiceName = "apimService1",
});
});
Content copied to clipboard
package main
import (
apimanagement "github.com/pulumi/pulumi-azure-native-sdk/apimanagement/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := apimanagement.NewContentItem(ctx, "contentItem", &apimanagement.ContentItemArgs{
ContentItemId: pulumi.String("4e3cf6a5-574a-ba08-1f23-2e7a38faa6d8"),
ContentTypeId: pulumi.String("page"),
Properties: pulumi.Any(map[string]interface{}{
"en_us": map[string]interface{}{
"description": "Short story about the company.",
"documentId": "contentTypes/document/contentItems/4e3cf6a5-574a-ba08-1f23-2e7a38faa6d8",
"keywords": "company, about",
"permalink": "/about",
"title": "About",
},
}),
ResourceGroupName: pulumi.String("rg1"),
ServiceName: pulumi.String("apimService1"),
})
if err != nil {
return err
}
return nil
})
}
Content copied to clipboard
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.apimanagement.ContentItem;
import com.pulumi.azurenative.apimanagement.ContentItemArgs;
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 contentItem = new ContentItem("contentItem", ContentItemArgs.builder()
.contentItemId("4e3cf6a5-574a-ba08-1f23-2e7a38faa6d8")
.contentTypeId("page")
.properties(Map.of("en_us", Map.ofEntries(
Map.entry("description", "Short story about the company."),
Map.entry("documentId", "contentTypes/document/contentItems/4e3cf6a5-574a-ba08-1f23-2e7a38faa6d8"),
Map.entry("keywords", "company, about"),
Map.entry("permalink", "/about"),
Map.entry("title", "About")
)))
.resourceGroupName("rg1")
.serviceName("apimService1")
.build());
}
}
Content copied to clipboard
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:apimanagement:ContentItem 4e3cf6a5-574a-ba08-1f23-2e7a38faa6d8 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/contentTypes/{contentTypeId}/contentItems/{contentItemId}
Content copied to clipboard
Constructors
Properties
Link copied to clipboard
Content item identifier.
Link copied to clipboard
Content type identifier.
Link copied to clipboard
Properties of the content item.
Link copied to clipboard
The name of the resource group. The name is case insensitive.
Link copied to clipboard
The name of the API Management service.