![JAR search and dependency download from the Maven repository](/logo.png)
com.pulumi.azurenative.apimanagement.kotlin.WorkspaceApiArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-azure-native-kotlin Show documentation
Show all versions of pulumi-azure-native-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.azurenative.apimanagement.kotlin
import com.pulumi.azurenative.apimanagement.WorkspaceApiArgs.builder
import com.pulumi.azurenative.apimanagement.kotlin.enums.ApiType
import com.pulumi.azurenative.apimanagement.kotlin.enums.ContentFormat
import com.pulumi.azurenative.apimanagement.kotlin.enums.Protocol
import com.pulumi.azurenative.apimanagement.kotlin.enums.SoapApiType
import com.pulumi.azurenative.apimanagement.kotlin.enums.TranslateRequiredQueryParametersConduct
import com.pulumi.azurenative.apimanagement.kotlin.inputs.ApiContactInformationArgs
import com.pulumi.azurenative.apimanagement.kotlin.inputs.ApiContactInformationArgsBuilder
import com.pulumi.azurenative.apimanagement.kotlin.inputs.ApiCreateOrUpdatePropertiesWsdlSelectorArgs
import com.pulumi.azurenative.apimanagement.kotlin.inputs.ApiCreateOrUpdatePropertiesWsdlSelectorArgsBuilder
import com.pulumi.azurenative.apimanagement.kotlin.inputs.ApiLicenseInformationArgs
import com.pulumi.azurenative.apimanagement.kotlin.inputs.ApiLicenseInformationArgsBuilder
import com.pulumi.azurenative.apimanagement.kotlin.inputs.ApiVersionSetContractDetailsArgs
import com.pulumi.azurenative.apimanagement.kotlin.inputs.ApiVersionSetContractDetailsArgsBuilder
import com.pulumi.azurenative.apimanagement.kotlin.inputs.AuthenticationSettingsContractArgs
import com.pulumi.azurenative.apimanagement.kotlin.inputs.AuthenticationSettingsContractArgsBuilder
import com.pulumi.azurenative.apimanagement.kotlin.inputs.SubscriptionKeyParameterNamesContractArgs
import com.pulumi.azurenative.apimanagement.kotlin.inputs.SubscriptionKeyParameterNamesContractArgsBuilder
import com.pulumi.core.Either
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName
/**
* API details.
* Azure REST API version: 2022-09-01-preview.
* Other available API versions: 2023-03-01-preview, 2023-05-01-preview, 2023-09-01-preview, 2024-05-01.
* ## Example Usage
* ### ApiManagementCreateWorkspaceApi
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using AzureNative = Pulumi.AzureNative;
* return await Deployment.RunAsync(() =>
* {
* var workspaceApi = new AzureNative.ApiManagement.WorkspaceApi("workspaceApi", new()
* {
* ApiId = "tempgroup",
* AuthenticationSettings = new AzureNative.ApiManagement.Inputs.AuthenticationSettingsContractArgs
* {
* OAuth2 = new AzureNative.ApiManagement.Inputs.OAuth2AuthenticationSettingsContractArgs
* {
* AuthorizationServerId = "authorizationServerId2283",
* Scope = "oauth2scope2580",
* },
* },
* Description = "apidescription5200",
* DisplayName = "apiname1463",
* Path = "newapiPath",
* Protocols = new[]
* {
* AzureNative.ApiManagement.Protocol.Https,
* AzureNative.ApiManagement.Protocol.Http,
* },
* ResourceGroupName = "rg1",
* ServiceName = "apimService1",
* ServiceUrl = "http://newechoapi.cloudapp.net/api",
* SubscriptionKeyParameterNames = new AzureNative.ApiManagement.Inputs.SubscriptionKeyParameterNamesContractArgs
* {
* Header = "header4520",
* Query = "query3037",
* },
* WorkspaceId = "wks1",
* });
* });
* ```
* ```go
* 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.NewWorkspaceApi(ctx, "workspaceApi", &apimanagement.WorkspaceApiArgs{
* ApiId: pulumi.String("tempgroup"),
* AuthenticationSettings: &apimanagement.AuthenticationSettingsContractArgs{
* OAuth2: &apimanagement.OAuth2AuthenticationSettingsContractArgs{
* AuthorizationServerId: pulumi.String("authorizationServerId2283"),
* Scope: pulumi.String("oauth2scope2580"),
* },
* },
* Description: pulumi.String("apidescription5200"),
* DisplayName: pulumi.String("apiname1463"),
* Path: pulumi.String("newapiPath"),
* Protocols: pulumi.StringArray{
* pulumi.String(apimanagement.ProtocolHttps),
* pulumi.String(apimanagement.ProtocolHttp),
* },
* ResourceGroupName: pulumi.String("rg1"),
* ServiceName: pulumi.String("apimService1"),
* ServiceUrl: pulumi.String("http://newechoapi.cloudapp.net/api"),
* SubscriptionKeyParameterNames: &apimanagement.SubscriptionKeyParameterNamesContractArgs{
* Header: pulumi.String("header4520"),
* Query: pulumi.String("query3037"),
* },
* WorkspaceId: pulumi.String("wks1"),
* })
* if err != nil {
* return err
* }
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.azurenative.apimanagement.WorkspaceApi;
* import com.pulumi.azurenative.apimanagement.WorkspaceApiArgs;
* import com.pulumi.azurenative.apimanagement.inputs.AuthenticationSettingsContractArgs;
* import com.pulumi.azurenative.apimanagement.inputs.OAuth2AuthenticationSettingsContractArgs;
* import com.pulumi.azurenative.apimanagement.inputs.SubscriptionKeyParameterNamesContractArgs;
* 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 workspaceApi = new WorkspaceApi("workspaceApi", WorkspaceApiArgs.builder()
* .apiId("tempgroup")
* .authenticationSettings(AuthenticationSettingsContractArgs.builder()
* .oAuth2(OAuth2AuthenticationSettingsContractArgs.builder()
* .authorizationServerId("authorizationServerId2283")
* .scope("oauth2scope2580")
* .build())
* .build())
* .description("apidescription5200")
* .displayName("apiname1463")
* .path("newapiPath")
* .protocols(
* "https",
* "http")
* .resourceGroupName("rg1")
* .serviceName("apimService1")
* .serviceUrl("http://newechoapi.cloudapp.net/api")
* .subscriptionKeyParameterNames(SubscriptionKeyParameterNamesContractArgs.builder()
* .header("header4520")
* .query("query3037")
* .build())
* .workspaceId("wks1")
* .build());
* }
* }
* ```
* ## Import
* An existing resource can be imported using its type token, name, and identifier, e.g.
* ```sh
* $ pulumi import azure-native:apimanagement:WorkspaceApi apiid9419 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/workspaces/{workspaceId}/apis/{apiId}
* ```
* @property apiId API revision identifier. Must be unique in the current API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number.
* @property apiRevision Describes the revision of the API. If no value is provided, default revision 1 is created
* @property apiRevisionDescription Description of the API Revision.
* @property apiType Type of API.
* @property apiVersion Indicates the version identifier of the API if the API is versioned
* @property apiVersionDescription Description of the API Version.
* @property apiVersionSet Version set details
* @property apiVersionSetId A resource identifier for the related ApiVersionSet.
* @property authenticationSettings Collection of authentication settings included into this API.
* @property contact Contact information for the API.
* @property description Description of the API. May include HTML formatting tags.
* @property displayName API name. Must be 1 to 300 characters long.
* @property format Format of the Content in which the API is getting imported.
* @property isCurrent Indicates if API revision is current api revision.
* @property license License information for the API.
* @property path Relative URL uniquely identifying this API and all of its resource paths within the API Management service instance. It is appended to the API endpoint base URL specified during the service instance creation to form a public URL for this API.
* @property protocols Describes on which protocols the operations in this API can be invoked.
* @property resourceGroupName The name of the resource group. The name is case insensitive.
* @property serviceName The name of the API Management service.
* @property serviceUrl Absolute URL of the backend service implementing this API. Cannot be more than 2000 characters long.
* @property soapApiType Type of API to create.
* * `http` creates a REST API
* * `soap` creates a SOAP pass-through API
* * `websocket` creates websocket API
* * `graphql` creates GraphQL API.
* @property sourceApiId API identifier of the source API.
* @property subscriptionKeyParameterNames Protocols over which API is made available.
* @property subscriptionRequired Specifies whether an API or Product subscription is required for accessing the API.
* @property termsOfServiceUrl A URL to the Terms of Service for the API. MUST be in the format of a URL.
* @property translateRequiredQueryParametersConduct Strategy of translating required query parameters to template ones. By default has value 'template'. Possible values: 'template', 'query'
* @property value Content value when Importing an API.
* @property workspaceId Workspace identifier. Must be unique in the current API Management service instance.
* @property wsdlSelector Criteria to limit import of WSDL to a subset of the document.
*/
public data class WorkspaceApiArgs(
public val apiId: Output? = null,
public val apiRevision: Output? = null,
public val apiRevisionDescription: Output? = null,
public val apiType: Output>? = null,
public val apiVersion: Output? = null,
public val apiVersionDescription: Output? = null,
public val apiVersionSet: Output? = null,
public val apiVersionSetId: Output? = null,
public val authenticationSettings: Output? = null,
public val contact: Output? = null,
public val description: Output? = null,
public val displayName: Output? = null,
public val format: Output>? = null,
public val isCurrent: Output? = null,
public val license: Output? = null,
public val path: Output? = null,
public val protocols: Output>>? = null,
public val resourceGroupName: Output? = null,
public val serviceName: Output? = null,
public val serviceUrl: Output? = null,
public val soapApiType: Output>? = null,
public val sourceApiId: Output? = null,
public val subscriptionKeyParameterNames: Output? =
null,
public val subscriptionRequired: Output? = null,
public val termsOfServiceUrl: Output? = null,
public val translateRequiredQueryParametersConduct: Output>? = null,
public val `value`: Output? = null,
public val workspaceId: Output? = null,
public val wsdlSelector: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.azurenative.apimanagement.WorkspaceApiArgs =
com.pulumi.azurenative.apimanagement.WorkspaceApiArgs.builder()
.apiId(apiId?.applyValue({ args0 -> args0 }))
.apiRevision(apiRevision?.applyValue({ args0 -> args0 }))
.apiRevisionDescription(apiRevisionDescription?.applyValue({ args0 -> args0 }))
.apiType(
apiType?.applyValue({ args0 ->
args0.transform({ args0 -> args0 }, { args0 ->
args0.let({ args0 -> args0.toJava() })
})
}),
)
.apiVersion(apiVersion?.applyValue({ args0 -> args0 }))
.apiVersionDescription(apiVersionDescription?.applyValue({ args0 -> args0 }))
.apiVersionSet(apiVersionSet?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.apiVersionSetId(apiVersionSetId?.applyValue({ args0 -> args0 }))
.authenticationSettings(
authenticationSettings?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.contact(contact?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.description(description?.applyValue({ args0 -> args0 }))
.displayName(displayName?.applyValue({ args0 -> args0 }))
.format(
format?.applyValue({ args0 ->
args0.transform({ args0 -> args0 }, { args0 ->
args0.let({ args0 -> args0.toJava() })
})
}),
)
.isCurrent(isCurrent?.applyValue({ args0 -> args0 }))
.license(license?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.path(path?.applyValue({ args0 -> args0 }))
.protocols(
protocols?.applyValue({ args0 ->
args0.map({ args0 ->
args0.transform(
{ args0 -> args0 },
{ args0 -> args0.let({ args0 -> args0.toJava() }) },
)
})
}),
)
.resourceGroupName(resourceGroupName?.applyValue({ args0 -> args0 }))
.serviceName(serviceName?.applyValue({ args0 -> args0 }))
.serviceUrl(serviceUrl?.applyValue({ args0 -> args0 }))
.soapApiType(
soapApiType?.applyValue({ args0 ->
args0.transform({ args0 -> args0 }, { args0 ->
args0.let({ args0 -> args0.toJava() })
})
}),
)
.sourceApiId(sourceApiId?.applyValue({ args0 -> args0 }))
.subscriptionKeyParameterNames(
subscriptionKeyParameterNames?.applyValue({ args0 ->
args0.let({ args0 -> args0.toJava() })
}),
)
.subscriptionRequired(subscriptionRequired?.applyValue({ args0 -> args0 }))
.termsOfServiceUrl(termsOfServiceUrl?.applyValue({ args0 -> args0 }))
.translateRequiredQueryParametersConduct(
translateRequiredQueryParametersConduct?.applyValue({ args0 ->
args0.transform({ args0 -> args0 }, { args0 -> args0.let({ args0 -> args0.toJava() }) })
}),
)
.`value`(`value`?.applyValue({ args0 -> args0 }))
.workspaceId(workspaceId?.applyValue({ args0 -> args0 }))
.wsdlSelector(wsdlSelector?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) })).build()
}
/**
* Builder for [WorkspaceApiArgs].
*/
@PulumiTagMarker
public class WorkspaceApiArgsBuilder internal constructor() {
private var apiId: Output? = null
private var apiRevision: Output? = null
private var apiRevisionDescription: Output? = null
private var apiType: Output>? = null
private var apiVersion: Output? = null
private var apiVersionDescription: Output? = null
private var apiVersionSet: Output? = null
private var apiVersionSetId: Output? = null
private var authenticationSettings: Output? = null
private var contact: Output? = null
private var description: Output? = null
private var displayName: Output? = null
private var format: Output>? = null
private var isCurrent: Output? = null
private var license: Output? = null
private var path: Output? = null
private var protocols: Output>>? = null
private var resourceGroupName: Output? = null
private var serviceName: Output? = null
private var serviceUrl: Output? = null
private var soapApiType: Output>? = null
private var sourceApiId: Output? = null
private var subscriptionKeyParameterNames: Output? =
null
private var subscriptionRequired: Output? = null
private var termsOfServiceUrl: Output? = null
private var translateRequiredQueryParametersConduct:
Output>? = null
private var `value`: Output? = null
private var workspaceId: Output? = null
private var wsdlSelector: Output? = null
/**
* @param value API revision identifier. Must be unique in the current API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number.
*/
@JvmName("xbyjundidxdvhakp")
public suspend fun apiId(`value`: Output) {
this.apiId = value
}
/**
* @param value Describes the revision of the API. If no value is provided, default revision 1 is created
*/
@JvmName("nnnhxsdkwbtcolvf")
public suspend fun apiRevision(`value`: Output) {
this.apiRevision = value
}
/**
* @param value Description of the API Revision.
*/
@JvmName("fqubhioklpoaqqiv")
public suspend fun apiRevisionDescription(`value`: Output) {
this.apiRevisionDescription = value
}
/**
* @param value Type of API.
*/
@JvmName("aerkcaiuyedwsxay")
public suspend fun apiType(`value`: Output>) {
this.apiType = value
}
/**
* @param value Indicates the version identifier of the API if the API is versioned
*/
@JvmName("xtgfcpswhfcjeobn")
public suspend fun apiVersion(`value`: Output) {
this.apiVersion = value
}
/**
* @param value Description of the API Version.
*/
@JvmName("cvrelfeatiyouduv")
public suspend fun apiVersionDescription(`value`: Output) {
this.apiVersionDescription = value
}
/**
* @param value Version set details
*/
@JvmName("hgucomldljhuxaff")
public suspend fun apiVersionSet(`value`: Output) {
this.apiVersionSet = value
}
/**
* @param value A resource identifier for the related ApiVersionSet.
*/
@JvmName("sbhdtpgcsnonaimr")
public suspend fun apiVersionSetId(`value`: Output) {
this.apiVersionSetId = value
}
/**
* @param value Collection of authentication settings included into this API.
*/
@JvmName("kesmpvnetcbjechf")
public suspend fun authenticationSettings(`value`: Output) {
this.authenticationSettings = value
}
/**
* @param value Contact information for the API.
*/
@JvmName("sywcfxokshgohcbi")
public suspend fun contact(`value`: Output) {
this.contact = value
}
/**
* @param value Description of the API. May include HTML formatting tags.
*/
@JvmName("eoxvoheaweifstxb")
public suspend fun description(`value`: Output) {
this.description = value
}
/**
* @param value API name. Must be 1 to 300 characters long.
*/
@JvmName("wcawdqnmmjcamcyp")
public suspend fun displayName(`value`: Output) {
this.displayName = value
}
/**
* @param value Format of the Content in which the API is getting imported.
*/
@JvmName("qjiguwgckpmlpepa")
public suspend fun format(`value`: Output>) {
this.format = value
}
/**
* @param value Indicates if API revision is current api revision.
*/
@JvmName("tsgbrmuwhyrgqmsy")
public suspend fun isCurrent(`value`: Output) {
this.isCurrent = value
}
/**
* @param value License information for the API.
*/
@JvmName("visihbvwphgfhvcg")
public suspend fun license(`value`: Output) {
this.license = value
}
/**
* @param value Relative URL uniquely identifying this API and all of its resource paths within the API Management service instance. It is appended to the API endpoint base URL specified during the service instance creation to form a public URL for this API.
*/
@JvmName("dlnufnwujorvagbm")
public suspend fun path(`value`: Output) {
this.path = value
}
/**
* @param value Describes on which protocols the operations in this API can be invoked.
*/
@JvmName("cpghxeqktqbxepuj")
public suspend fun protocols(`value`: Output>>) {
this.protocols = value
}
@JvmName("oujpjrvoatffwxxl")
public suspend fun protocols(vararg values: Output>) {
this.protocols = Output.all(values.asList())
}
/**
* @param values Describes on which protocols the operations in this API can be invoked.
*/
@JvmName("bgstrplpsklknbbj")
public suspend fun protocols(values: List
© 2015 - 2025 Weber Informatics LLC | Privacy Policy