cognitive

package
v4.10.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 12, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Account

type Account struct {
	pulumi.CustomResourceState

	// The subdomain name used for token-based authentication. Changing this forces a new resource to be created.
	CustomSubdomainName pulumi.StringPtrOutput `pulumi:"customSubdomainName"`
	// The endpoint used to connect to the Cognitive Service Account.
	Endpoint pulumi.StringOutput `pulumi:"endpoint"`
	// Specifies the type of Cognitive Service Account that should be created. Possible values are `Academic`, `AnomalyDetector`, `Bing.Autosuggest`, `Bing.Autosuggest.v7`, `Bing.CustomSearch`, `Bing.Search`, `Bing.Search.v7`, `Bing.Speech`, `Bing.SpellCheck`, `Bing.SpellCheck.v7`, `CognitiveServices`, `ComputerVision`, `ContentModerator`, `CustomSpeech`, `CustomVision.Prediction`, `CustomVision.Training`, `Emotion`, `Face`,`FormRecognizer`, `ImmersiveReader`, `LUIS`, `LUIS.Authoring`, `Personalizer`, `QnAMaker`, `Recommendations`, `SpeakerRecognition`, `Speech`, `SpeechServices`, `SpeechTranslation`, `TextAnalytics`, `TextTranslation` and `WebLM`. Changing this forces a new resource to be created.
	Kind pulumi.StringOutput `pulumi:"kind"`
	// Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
	Location pulumi.StringOutput `pulumi:"location"`
	// Specifies the name of the Cognitive Service Account. Changing this forces a new resource to be created.
	Name pulumi.StringOutput `pulumi:"name"`
	// A `networkAcls` block as defined below.
	NetworkAcls AccountNetworkAclsPtrOutput `pulumi:"networkAcls"`
	// A primary access key which can be used to connect to the Cognitive Service Account.
	PrimaryAccessKey pulumi.StringOutput `pulumi:"primaryAccessKey"`
	// A URL to link a QnAMaker cognitive account to a QnA runtime.
	QnaRuntimeEndpoint pulumi.StringPtrOutput `pulumi:"qnaRuntimeEndpoint"`
	// The name of the resource group in which the Cognitive Service Account is created. Changing this forces a new resource to be created.
	ResourceGroupName pulumi.StringOutput `pulumi:"resourceGroupName"`
	// The secondary access key which can be used to connect to the Cognitive Service Account.
	SecondaryAccessKey pulumi.StringOutput `pulumi:"secondaryAccessKey"`
	// Specifies the SKU Name for this Cognitive Service Account. Possible values are `F0`, `F1`, `S`, `S0`, `S1`, `S2`, `S3`, `S4`, `S5`, `S6`, `P0`, `P1`, and `P2`.
	SkuName pulumi.StringOutput `pulumi:"skuName"`
	// A mapping of tags to assign to the resource.
	Tags pulumi.StringMapOutput `pulumi:"tags"`
}

## Import

Cognitive Service Accounts can be imported using the `resource id`, e.g.

```sh

$ pulumi import azure:cognitive/account:Account account1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.CognitiveServices/accounts/account1

```

func GetAccount

func GetAccount(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *AccountState, opts ...pulumi.ResourceOption) (*Account, error)

GetAccount gets an existing Account resource's state with the given name, ID, and optional state properties that are used to uniquely qualify the lookup (nil if not required).

func NewAccount

func NewAccount(ctx *pulumi.Context,
	name string, args *AccountArgs, opts ...pulumi.ResourceOption) (*Account, error)

NewAccount registers a new resource with the given unique name, arguments, and options.

func (*Account) ElementType

func (*Account) ElementType() reflect.Type

func (*Account) ToAccountOutput

func (i *Account) ToAccountOutput() AccountOutput

func (*Account) ToAccountOutputWithContext

func (i *Account) ToAccountOutputWithContext(ctx context.Context) AccountOutput

func (*Account) ToAccountPtrOutput

func (i *Account) ToAccountPtrOutput() AccountPtrOutput

func (*Account) ToAccountPtrOutputWithContext

func (i *Account) ToAccountPtrOutputWithContext(ctx context.Context) AccountPtrOutput

type AccountArgs

type AccountArgs struct {
	// The subdomain name used for token-based authentication. Changing this forces a new resource to be created.
	CustomSubdomainName pulumi.StringPtrInput
	// Specifies the type of Cognitive Service Account that should be created. Possible values are `Academic`, `AnomalyDetector`, `Bing.Autosuggest`, `Bing.Autosuggest.v7`, `Bing.CustomSearch`, `Bing.Search`, `Bing.Search.v7`, `Bing.Speech`, `Bing.SpellCheck`, `Bing.SpellCheck.v7`, `CognitiveServices`, `ComputerVision`, `ContentModerator`, `CustomSpeech`, `CustomVision.Prediction`, `CustomVision.Training`, `Emotion`, `Face`,`FormRecognizer`, `ImmersiveReader`, `LUIS`, `LUIS.Authoring`, `Personalizer`, `QnAMaker`, `Recommendations`, `SpeakerRecognition`, `Speech`, `SpeechServices`, `SpeechTranslation`, `TextAnalytics`, `TextTranslation` and `WebLM`. Changing this forces a new resource to be created.
	Kind pulumi.StringInput
	// Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
	Location pulumi.StringPtrInput
	// Specifies the name of the Cognitive Service Account. Changing this forces a new resource to be created.
	Name pulumi.StringPtrInput
	// A `networkAcls` block as defined below.
	NetworkAcls AccountNetworkAclsPtrInput
	// A URL to link a QnAMaker cognitive account to a QnA runtime.
	QnaRuntimeEndpoint pulumi.StringPtrInput
	// The name of the resource group in which the Cognitive Service Account is created. Changing this forces a new resource to be created.
	ResourceGroupName pulumi.StringInput
	// Specifies the SKU Name for this Cognitive Service Account. Possible values are `F0`, `F1`, `S`, `S0`, `S1`, `S2`, `S3`, `S4`, `S5`, `S6`, `P0`, `P1`, and `P2`.
	SkuName pulumi.StringInput
	// A mapping of tags to assign to the resource.
	Tags pulumi.StringMapInput
}

The set of arguments for constructing a Account resource.

func (AccountArgs) ElementType

func (AccountArgs) ElementType() reflect.Type

type AccountArray

type AccountArray []AccountInput

func (AccountArray) ElementType

func (AccountArray) ElementType() reflect.Type

func (AccountArray) ToAccountArrayOutput

func (i AccountArray) ToAccountArrayOutput() AccountArrayOutput

func (AccountArray) ToAccountArrayOutputWithContext

func (i AccountArray) ToAccountArrayOutputWithContext(ctx context.Context) AccountArrayOutput

type AccountArrayInput

type AccountArrayInput interface {
	pulumi.Input

	ToAccountArrayOutput() AccountArrayOutput
	ToAccountArrayOutputWithContext(context.Context) AccountArrayOutput
}

AccountArrayInput is an input type that accepts AccountArray and AccountArrayOutput values. You can construct a concrete instance of `AccountArrayInput` via:

AccountArray{ AccountArgs{...} }

type AccountArrayOutput

type AccountArrayOutput struct{ *pulumi.OutputState }

func (AccountArrayOutput) ElementType

func (AccountArrayOutput) ElementType() reflect.Type

func (AccountArrayOutput) Index

func (AccountArrayOutput) ToAccountArrayOutput

func (o AccountArrayOutput) ToAccountArrayOutput() AccountArrayOutput

func (AccountArrayOutput) ToAccountArrayOutputWithContext

func (o AccountArrayOutput) ToAccountArrayOutputWithContext(ctx context.Context) AccountArrayOutput

type AccountInput

type AccountInput interface {
	pulumi.Input

	ToAccountOutput() AccountOutput
	ToAccountOutputWithContext(ctx context.Context) AccountOutput
}

type AccountMap

type AccountMap map[string]AccountInput

func (AccountMap) ElementType

func (AccountMap) ElementType() reflect.Type

func (AccountMap) ToAccountMapOutput

func (i AccountMap) ToAccountMapOutput() AccountMapOutput

func (AccountMap) ToAccountMapOutputWithContext

func (i AccountMap) ToAccountMapOutputWithContext(ctx context.Context) AccountMapOutput

type AccountMapInput

type AccountMapInput interface {
	pulumi.Input

	ToAccountMapOutput() AccountMapOutput
	ToAccountMapOutputWithContext(context.Context) AccountMapOutput
}

AccountMapInput is an input type that accepts AccountMap and AccountMapOutput values. You can construct a concrete instance of `AccountMapInput` via:

AccountMap{ "key": AccountArgs{...} }

type AccountMapOutput

type AccountMapOutput struct{ *pulumi.OutputState }

func (AccountMapOutput) ElementType

func (AccountMapOutput) ElementType() reflect.Type

func (AccountMapOutput) MapIndex

func (AccountMapOutput) ToAccountMapOutput

func (o AccountMapOutput) ToAccountMapOutput() AccountMapOutput

func (AccountMapOutput) ToAccountMapOutputWithContext

func (o AccountMapOutput) ToAccountMapOutputWithContext(ctx context.Context) AccountMapOutput

type AccountNetworkAcls

type AccountNetworkAcls struct {
	// The Default Action to use when no rules match from `ipRules` / `virtualNetworkSubnetIds`. Possible values are `Allow` and `Deny`.
	DefaultAction string `pulumi:"defaultAction"`
	// One or more IP Addresses, or CIDR Blocks which should be able to access the Cognitive Account.
	IpRules []string `pulumi:"ipRules"`
	// One or more Subnet ID's which should be able to access this Cognitive Account.
	VirtualNetworkSubnetIds []string `pulumi:"virtualNetworkSubnetIds"`
}

type AccountNetworkAclsArgs

type AccountNetworkAclsArgs struct {
	// The Default Action to use when no rules match from `ipRules` / `virtualNetworkSubnetIds`. Possible values are `Allow` and `Deny`.
	DefaultAction pulumi.StringInput `pulumi:"defaultAction"`
	// One or more IP Addresses, or CIDR Blocks which should be able to access the Cognitive Account.
	IpRules pulumi.StringArrayInput `pulumi:"ipRules"`
	// One or more Subnet ID's which should be able to access this Cognitive Account.
	VirtualNetworkSubnetIds pulumi.StringArrayInput `pulumi:"virtualNetworkSubnetIds"`
}

func (AccountNetworkAclsArgs) ElementType

func (AccountNetworkAclsArgs) ElementType() reflect.Type

func (AccountNetworkAclsArgs) ToAccountNetworkAclsOutput

func (i AccountNetworkAclsArgs) ToAccountNetworkAclsOutput() AccountNetworkAclsOutput

func (AccountNetworkAclsArgs) ToAccountNetworkAclsOutputWithContext

func (i AccountNetworkAclsArgs) ToAccountNetworkAclsOutputWithContext(ctx context.Context) AccountNetworkAclsOutput

func (AccountNetworkAclsArgs) ToAccountNetworkAclsPtrOutput

func (i AccountNetworkAclsArgs) ToAccountNetworkAclsPtrOutput() AccountNetworkAclsPtrOutput

func (AccountNetworkAclsArgs) ToAccountNetworkAclsPtrOutputWithContext

func (i AccountNetworkAclsArgs) ToAccountNetworkAclsPtrOutputWithContext(ctx context.Context) AccountNetworkAclsPtrOutput

type AccountNetworkAclsInput

type AccountNetworkAclsInput interface {
	pulumi.Input

	ToAccountNetworkAclsOutput() AccountNetworkAclsOutput
	ToAccountNetworkAclsOutputWithContext(context.Context) AccountNetworkAclsOutput
}

AccountNetworkAclsInput is an input type that accepts AccountNetworkAclsArgs and AccountNetworkAclsOutput values. You can construct a concrete instance of `AccountNetworkAclsInput` via:

AccountNetworkAclsArgs{...}

type AccountNetworkAclsOutput

type AccountNetworkAclsOutput struct{ *pulumi.OutputState }

func (AccountNetworkAclsOutput) DefaultAction

func (o AccountNetworkAclsOutput) DefaultAction() pulumi.StringOutput

The Default Action to use when no rules match from `ipRules` / `virtualNetworkSubnetIds`. Possible values are `Allow` and `Deny`.

func (AccountNetworkAclsOutput) ElementType

func (AccountNetworkAclsOutput) ElementType() reflect.Type

func (AccountNetworkAclsOutput) IpRules

One or more IP Addresses, or CIDR Blocks which should be able to access the Cognitive Account.

func (AccountNetworkAclsOutput) ToAccountNetworkAclsOutput

func (o AccountNetworkAclsOutput) ToAccountNetworkAclsOutput() AccountNetworkAclsOutput

func (AccountNetworkAclsOutput) ToAccountNetworkAclsOutputWithContext

func (o AccountNetworkAclsOutput) ToAccountNetworkAclsOutputWithContext(ctx context.Context) AccountNetworkAclsOutput

func (AccountNetworkAclsOutput) ToAccountNetworkAclsPtrOutput

func (o AccountNetworkAclsOutput) ToAccountNetworkAclsPtrOutput() AccountNetworkAclsPtrOutput

func (AccountNetworkAclsOutput) ToAccountNetworkAclsPtrOutputWithContext

func (o AccountNetworkAclsOutput) ToAccountNetworkAclsPtrOutputWithContext(ctx context.Context) AccountNetworkAclsPtrOutput

func (AccountNetworkAclsOutput) VirtualNetworkSubnetIds

func (o AccountNetworkAclsOutput) VirtualNetworkSubnetIds() pulumi.StringArrayOutput

One or more Subnet ID's which should be able to access this Cognitive Account.

type AccountNetworkAclsPtrInput

type AccountNetworkAclsPtrInput interface {
	pulumi.Input

	ToAccountNetworkAclsPtrOutput() AccountNetworkAclsPtrOutput
	ToAccountNetworkAclsPtrOutputWithContext(context.Context) AccountNetworkAclsPtrOutput
}

AccountNetworkAclsPtrInput is an input type that accepts AccountNetworkAclsArgs, AccountNetworkAclsPtr and AccountNetworkAclsPtrOutput values. You can construct a concrete instance of `AccountNetworkAclsPtrInput` via:

        AccountNetworkAclsArgs{...}

or:

        nil

type AccountNetworkAclsPtrOutput

type AccountNetworkAclsPtrOutput struct{ *pulumi.OutputState }

func (AccountNetworkAclsPtrOutput) DefaultAction

The Default Action to use when no rules match from `ipRules` / `virtualNetworkSubnetIds`. Possible values are `Allow` and `Deny`.

func (AccountNetworkAclsPtrOutput) Elem

func (AccountNetworkAclsPtrOutput) ElementType

func (AccountNetworkAclsPtrOutput) IpRules

One or more IP Addresses, or CIDR Blocks which should be able to access the Cognitive Account.

func (AccountNetworkAclsPtrOutput) ToAccountNetworkAclsPtrOutput

func (o AccountNetworkAclsPtrOutput) ToAccountNetworkAclsPtrOutput() AccountNetworkAclsPtrOutput

func (AccountNetworkAclsPtrOutput) ToAccountNetworkAclsPtrOutputWithContext

func (o AccountNetworkAclsPtrOutput) ToAccountNetworkAclsPtrOutputWithContext(ctx context.Context) AccountNetworkAclsPtrOutput

func (AccountNetworkAclsPtrOutput) VirtualNetworkSubnetIds

func (o AccountNetworkAclsPtrOutput) VirtualNetworkSubnetIds() pulumi.StringArrayOutput

One or more Subnet ID's which should be able to access this Cognitive Account.

type AccountOutput

type AccountOutput struct {
	*pulumi.OutputState
}

func (AccountOutput) ElementType

func (AccountOutput) ElementType() reflect.Type

func (AccountOutput) ToAccountOutput

func (o AccountOutput) ToAccountOutput() AccountOutput

func (AccountOutput) ToAccountOutputWithContext

func (o AccountOutput) ToAccountOutputWithContext(ctx context.Context) AccountOutput

func (AccountOutput) ToAccountPtrOutput

func (o AccountOutput) ToAccountPtrOutput() AccountPtrOutput

func (AccountOutput) ToAccountPtrOutputWithContext

func (o AccountOutput) ToAccountPtrOutputWithContext(ctx context.Context) AccountPtrOutput

type AccountPtrInput

type AccountPtrInput interface {
	pulumi.Input

	ToAccountPtrOutput() AccountPtrOutput
	ToAccountPtrOutputWithContext(ctx context.Context) AccountPtrOutput
}

type AccountPtrOutput

type AccountPtrOutput struct {
	*pulumi.OutputState
}

func (AccountPtrOutput) ElementType

func (AccountPtrOutput) ElementType() reflect.Type

func (AccountPtrOutput) ToAccountPtrOutput

func (o AccountPtrOutput) ToAccountPtrOutput() AccountPtrOutput

func (AccountPtrOutput) ToAccountPtrOutputWithContext

func (o AccountPtrOutput) ToAccountPtrOutputWithContext(ctx context.Context) AccountPtrOutput

type AccountState

type AccountState struct {
	// The subdomain name used for token-based authentication. Changing this forces a new resource to be created.
	CustomSubdomainName pulumi.StringPtrInput
	// The endpoint used to connect to the Cognitive Service Account.
	Endpoint pulumi.StringPtrInput
	// Specifies the type of Cognitive Service Account that should be created. Possible values are `Academic`, `AnomalyDetector`, `Bing.Autosuggest`, `Bing.Autosuggest.v7`, `Bing.CustomSearch`, `Bing.Search`, `Bing.Search.v7`, `Bing.Speech`, `Bing.SpellCheck`, `Bing.SpellCheck.v7`, `CognitiveServices`, `ComputerVision`, `ContentModerator`, `CustomSpeech`, `CustomVision.Prediction`, `CustomVision.Training`, `Emotion`, `Face`,`FormRecognizer`, `ImmersiveReader`, `LUIS`, `LUIS.Authoring`, `Personalizer`, `QnAMaker`, `Recommendations`, `SpeakerRecognition`, `Speech`, `SpeechServices`, `SpeechTranslation`, `TextAnalytics`, `TextTranslation` and `WebLM`. Changing this forces a new resource to be created.
	Kind pulumi.StringPtrInput
	// Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
	Location pulumi.StringPtrInput
	// Specifies the name of the Cognitive Service Account. Changing this forces a new resource to be created.
	Name pulumi.StringPtrInput
	// A `networkAcls` block as defined below.
	NetworkAcls AccountNetworkAclsPtrInput
	// A primary access key which can be used to connect to the Cognitive Service Account.
	PrimaryAccessKey pulumi.StringPtrInput
	// A URL to link a QnAMaker cognitive account to a QnA runtime.
	QnaRuntimeEndpoint pulumi.StringPtrInput
	// The name of the resource group in which the Cognitive Service Account is created. Changing this forces a new resource to be created.
	ResourceGroupName pulumi.StringPtrInput
	// The secondary access key which can be used to connect to the Cognitive Service Account.
	SecondaryAccessKey pulumi.StringPtrInput
	// Specifies the SKU Name for this Cognitive Service Account. Possible values are `F0`, `F1`, `S`, `S0`, `S1`, `S2`, `S3`, `S4`, `S5`, `S6`, `P0`, `P1`, and `P2`.
	SkuName pulumi.StringPtrInput
	// A mapping of tags to assign to the resource.
	Tags pulumi.StringMapInput
}

func (AccountState) ElementType

func (AccountState) ElementType() reflect.Type

type LookupAccountArgs

type LookupAccountArgs struct {
	// Specifies the name of the Cognitive Services Account.
	Name string `pulumi:"name"`
	// Specifies the name of the resource group where the Cognitive Services Account resides.
	ResourceGroupName string `pulumi:"resourceGroupName"`
}

A collection of arguments for invoking getAccount.

type LookupAccountResult

type LookupAccountResult struct {
	// The endpoint of the Cognitive Services Account
	Endpoint string `pulumi:"endpoint"`
	// The provider-assigned unique ID for this managed resource.
	Id string `pulumi:"id"`
	// The kind of the Cognitive Services Account
	Kind string `pulumi:"kind"`
	// The Azure location where the Cognitive Services Account exists
	Location string `pulumi:"location"`
	Name     string `pulumi:"name"`
	// The primary access key of the Cognitive Services Account
	PrimaryAccessKey string `pulumi:"primaryAccessKey"`
	// If `kind` is `QnAMaker` the link to the QNA runtime.
	QnaRuntimeEndpoint string `pulumi:"qnaRuntimeEndpoint"`
	ResourceGroupName  string `pulumi:"resourceGroupName"`
	// The secondary access key of the Cognitive Services Account
	SecondaryAccessKey string `pulumi:"secondaryAccessKey"`
	// The sku name of the Cognitive Services Account
	SkuName string `pulumi:"skuName"`
	// A mapping of tags to assigned to the resource.
	Tags map[string]string `pulumi:"tags"`
}

A collection of values returned by getAccount.

func LookupAccount

func LookupAccount(ctx *pulumi.Context, args *LookupAccountArgs, opts ...pulumi.InvokeOption) (*LookupAccountResult, error)

Use this data source to access information about an existing Cognitive Services Account.

## Example Usage

```go package main

import (

"github.com/pulumi/pulumi-azure/sdk/v4/go/azure/cognitive"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"

)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		test, err := cognitive.LookupAccount(ctx, &cognitive.LookupAccountArgs{
			Name:              "example-account",
			ResourceGroupName: "cognitive_account_rg",
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("primaryAccessKey", test.PrimaryAccessKey)
		return nil
	})
}

```

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL