EnvironmentArgs

data class EnvironmentArgs(val customProperties: Output<Any>? = null, val description: Output<String>? = null, val environmentName: Output<String>? = null, val kind: Output<Either<String, EnvironmentKind>>? = null, val onboarding: Output<OnboardingArgs>? = null, val resourceGroupName: Output<String>? = null, val server: Output<EnvironmentServerArgs>? = null, val serviceName: Output<String>? = null, val title: Output<String>? = null, val workspaceName: Output<String>? = null) : ConvertibleToJava<EnvironmentArgs>

Environment entity. Uses Azure REST API version 2024-03-15-preview. In version 2.x of the Azure Native provider, it used API version 2024-03-01. Other available API versions: 2024-03-01, 2024-06-01-preview. These can be accessed by generating a local SDK package using the CLI command pulumi package add azure-native apicenter [ApiVersion]. See the ../../../version-guide/#accessing-any-api-version-via-local-packages for details.

Example Usage

Environments_CreateOrUpdate

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var environment = new AzureNative.ApiCenter.Environment("environment", new()
{
Description = "The primary Azure API Management service for the European division of Contoso.",
EnvironmentName = "public",
Kind = AzureNative.ApiCenter.EnvironmentKind.Production,
Onboarding = new AzureNative.ApiCenter.Inputs.OnboardingArgs
{
DeveloperPortalUri = new[]
{
"https://developer.contoso.com",
},
Instructions = "Sign in or sign up in the specified developer portal to request API access. You must complete the internal privacy training for your account to be approved.",
},
ResourceGroupName = "contoso-resources",
Server = new AzureNative.ApiCenter.Inputs.EnvironmentServerArgs
{
ManagementPortalUri = new[]
{
"https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contoso-resources/providers/Microsoft.ApiManagement/service/contoso",
},
Type = AzureNative.ApiCenter.EnvironmentServerType.Azure_API_Management,
},
ServiceName = "contoso",
Title = "Contoso Europe Azure API Management",
WorkspaceName = "default",
});
});
package main
import (
apicenter "github.com/pulumi/pulumi-azure-native-sdk/apicenter/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := apicenter.NewEnvironment(ctx, "environment", &apicenter.EnvironmentArgs{
Description: pulumi.String("The primary Azure API Management service for the European division of Contoso."),
EnvironmentName: pulumi.String("public"),
Kind: pulumi.String(apicenter.EnvironmentKindProduction),
Onboarding: &apicenter.OnboardingArgs{
DeveloperPortalUri: pulumi.StringArray{
pulumi.String("https://developer.contoso.com"),
},
Instructions: pulumi.String("Sign in or sign up in the specified developer portal to request API access. You must complete the internal privacy training for your account to be approved."),
},
ResourceGroupName: pulumi.String("contoso-resources"),
Server: &apicenter.EnvironmentServerArgs{
ManagementPortalUri: pulumi.StringArray{
pulumi.String("https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contoso-resources/providers/Microsoft.ApiManagement/service/contoso"),
},
Type: pulumi.String(apicenter.EnvironmentServerType_Azure_API_Management),
},
ServiceName: pulumi.String("contoso"),
Title: pulumi.String("Contoso Europe Azure API Management"),
WorkspaceName: pulumi.String("default"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.apicenter.Environment;
import com.pulumi.azurenative.apicenter.EnvironmentArgs;
import com.pulumi.azurenative.apicenter.inputs.OnboardingArgs;
import com.pulumi.azurenative.apicenter.inputs.EnvironmentServerArgs;
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 environment = new Environment("environment", EnvironmentArgs.builder()
.description("The primary Azure API Management service for the European division of Contoso.")
.environmentName("public")
.kind("production")
.onboarding(OnboardingArgs.builder()
.developerPortalUri("https://developer.contoso.com")
.instructions("Sign in or sign up in the specified developer portal to request API access. You must complete the internal privacy training for your account to be approved.")
.build())
.resourceGroupName("contoso-resources")
.server(EnvironmentServerArgs.builder()
.managementPortalUri("https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contoso-resources/providers/Microsoft.ApiManagement/service/contoso")
.type("Azure API Management")
.build())
.serviceName("contoso")
.title("Contoso Europe Azure API Management")
.workspaceName("default")
.build());
}
}

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-native:apicenter:Environment public /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiCenter/services/{serviceName}/workspaces/{workspaceName}/environments/{environmentName}

Constructors

Link copied to clipboard
constructor(customProperties: Output<Any>? = null, description: Output<String>? = null, environmentName: Output<String>? = null, kind: Output<Either<String, EnvironmentKind>>? = null, onboarding: Output<OnboardingArgs>? = null, resourceGroupName: Output<String>? = null, server: Output<EnvironmentServerArgs>? = null, serviceName: Output<String>? = null, title: Output<String>? = null, workspaceName: Output<String>? = null)

Properties

Link copied to clipboard
val customProperties: Output<Any>? = null

The custom metadata defined for API catalog entities.

Link copied to clipboard
val description: Output<String>? = null

The environment description.

Link copied to clipboard
val environmentName: Output<String>? = null

The name of the environment.

Link copied to clipboard
val kind: Output<Either<String, EnvironmentKind>>? = null

Environment kind.

Link copied to clipboard
val onboarding: Output<OnboardingArgs>? = null

Environment onboarding information

Link copied to clipboard
val resourceGroupName: Output<String>? = null

The name of the resource group. The name is case insensitive.

Link copied to clipboard
val server: Output<EnvironmentServerArgs>? = null

Server information of the environment.

Link copied to clipboard
val serviceName: Output<String>? = null

The name of Azure API Center service.

Link copied to clipboard
val title: Output<String>? = null

Environment title.

Link copied to clipboard
val workspaceName: Output<String>? = null

The name of the workspace.

Functions

Link copied to clipboard
open override fun toJava(): EnvironmentArgs