azure.mgmt.cognitiveservices.models module

exception azure.mgmt.cognitiveservices.models.ErrorException(deserialize, response, *args)[source]

Bases: msrest.exceptions.HttpOperationError

Server responsed with exception of type: ‘Error’.

Parameters:
  • deserialize – A deserializer
  • response – Server response to be deserialized.
class azure.mgmt.cognitiveservices.models.CheckDomainAvailabilityParameter(*, subdomain_name: str, type: str, **kwargs)[source]

Bases: msrest.serialization.Model

Check Domain availability parameter.

All required parameters must be populated in order to send to Azure.

Parameters:
  • subdomain_name (str) – Required. The subdomain name to use.
  • type (str) – Required. The Type of the resource.
class azure.mgmt.cognitiveservices.models.CheckDomainAvailabilityResult(*, is_subdomain_available: bool = None, reason: str = None, subdomain_name: str = None, type: str = None, **kwargs)[source]

Bases: msrest.serialization.Model

Check Domain availability result.

Parameters:
  • is_subdomain_available (bool) – Indicates the given SKU is available or not.
  • reason (str) – Reason why the SKU is not available.
  • subdomain_name (str) – The subdomain name to use.
  • type (str) – The Type of the resource.
class azure.mgmt.cognitiveservices.models.CheckSkuAvailabilityParameter(*, skus, kind: str, type: str, **kwargs)[source]

Bases: msrest.serialization.Model

Check SKU availability parameter.

All required parameters must be populated in order to send to Azure.

Parameters:
  • skus (list[str]) – Required. The SKU of the resource.
  • kind (str) – Required. The Kind of the resource.
  • type (str) – Required. The Type of the resource.
class azure.mgmt.cognitiveservices.models.CheckSkuAvailabilityResult(*, kind: str = None, type: str = None, sku_name: str = None, sku_available: bool = None, reason: str = None, message: str = None, **kwargs)[source]

Bases: msrest.serialization.Model

Check SKU availability result.

Parameters:
  • kind (str) – The Kind of the resource.
  • type (str) – The Type of the resource.
  • sku_name (str) – The SKU of Cognitive Services account.
  • sku_available (bool) – Indicates the given SKU is available or not.
  • reason (str) – Reason why the SKU is not available.
  • message (str) – Additional error message.
class azure.mgmt.cognitiveservices.models.CheckSkuAvailabilityResultList(*, value=None, **kwargs)[source]

Bases: msrest.serialization.Model

Check SKU availability result list.

Parameters:value (list[CheckSkuAvailabilityResult]) – Check SKU availability result list.
class azure.mgmt.cognitiveservices.models.CognitiveServicesAccount(*, etag: str = None, kind: str = None, location: str = None, endpoint: str = None, internal_id: str = None, custom_sub_domain_name: str = None, network_acls=None, sku=None, tags=None, **kwargs)[source]

Bases: msrest.serialization.Model

Cognitive Services Account is an Azure resource representing the provisioned account, its type, location and SKU.

Variables are only populated by the server, and will be ignored when sending a request.

Parameters:
  • etag (str) – Entity Tag
  • kind (str) – Type of cognitive service account.
  • location (str) – The location of the resource
  • endpoint (str) – Endpoint of the created account.
  • internal_id (str) – The internal identifier.
  • custom_sub_domain_name (str) – Optional subdomain name used for token-based authentication.
  • network_acls (NetworkRuleSet) – A collection of rules governing the accessibility from specific network locations.
  • sku (Sku) – The SKU of Cognitive Services account.
  • tags (dict[str, str]) – Gets or sets a list of key value pairs that describe the resource. These tags can be used in viewing and grouping this resource (across resource groups). A maximum of 15 tags can be provided for a resource. Each tag must have a key no greater than 128 characters and value no greater than 256 characters.
Variables:
  • id (str) – The id of the created account
  • name (str) – The name of the created account
  • provisioning_state (str or ProvisioningState) – Gets the status of the cognitive services account at the time the operation was called. Possible values include: ‘Creating’, ‘ResolvingDNS’, ‘Moving’, ‘Deleting’, ‘Succeeded’, ‘Failed’
  • type (str) – Resource type
class azure.mgmt.cognitiveservices.models.CognitiveServicesAccountCreateParameters(*, sku, kind: str, location: str, properties, tags=None, **kwargs)[source]

Bases: msrest.serialization.Model

The parameters to provide for the account.

All required parameters must be populated in order to send to Azure.

Parameters:
  • sku (Sku) – Required. Required. Gets or sets the SKU of the resource.
  • kind (str) – Required. Required. Gets or sets the Kind of the resource.
  • location (str) – Required. Required. Gets or sets the location of the resource. This will be one of the supported and registered Azure Geo Regions (e.g. West US, East US, Southeast Asia, etc.). The geo region of a resource cannot be changed once it is created, but if an identical geo region is specified on update the request will succeed.
  • tags (dict[str, str]) – Gets or sets a list of key value pairs that describe the resource. These tags can be used in viewing and grouping this resource (across resource groups). A maximum of 15 tags can be provided for a resource. Each tag must have a key no greater than 128 characters and value no greater than 256 characters.
  • properties (object) – Required. Must exist in the request. Must be an empty object. Must not be null.
class azure.mgmt.cognitiveservices.models.CognitiveServicesAccountEnumerateSkusResult(**kwargs)[source]

Bases: msrest.serialization.Model

The list of cognitive services accounts operation response.

Variables are only populated by the server, and will be ignored when sending a request.

Variables:value (list[CognitiveServicesResourceAndSku]) – Gets the list of Cognitive Services accounts and their properties.
class azure.mgmt.cognitiveservices.models.CognitiveServicesAccountKeys(*, key1: str = None, key2: str = None, **kwargs)[source]

Bases: msrest.serialization.Model

The access keys for the cognitive services account.

Parameters:
  • key1 (str) – Gets the value of key 1.
  • key2 (str) – Gets the value of key 2.
class azure.mgmt.cognitiveservices.models.CognitiveServicesAccountUpdateParameters(*, sku=None, tags=None, properties=None, **kwargs)[source]

Bases: msrest.serialization.Model

The parameters to provide for the account.

Parameters:
  • sku (Sku) – Gets or sets the SKU of the resource.
  • tags (dict[str, str]) – Gets or sets a list of key value pairs that describe the resource. These tags can be used in viewing and grouping this resource (across resource groups). A maximum of 15 tags can be provided for a resource. Each tag must have a key no greater than 128 characters and value no greater than 256 characters.
  • properties (object) – Additional properties for Account. Only provided fields will be updated.
class azure.mgmt.cognitiveservices.models.CognitiveServicesResourceAndSku(*, resource_type: str = None, sku=None, **kwargs)[source]

Bases: msrest.serialization.Model

Cognitive Services resource type and SKU.

Parameters:
  • resource_type (str) – Resource Namespace and Type
  • sku (Sku) – The SKU of Cognitive Services account.
class azure.mgmt.cognitiveservices.models.Error(*, error=None, **kwargs)[source]

Bases: msrest.serialization.Model

Cognitive Services error object.

Parameters:error (ErrorBody) – The error body.
class azure.mgmt.cognitiveservices.models.ErrorBody(*, code: str, message: str, **kwargs)[source]

Bases: msrest.serialization.Model

Cognitive Services error body.

All required parameters must be populated in order to send to Azure.

Parameters:
  • code (str) – Required. error code
  • message (str) – Required. error message
class azure.mgmt.cognitiveservices.models.IpRule(*, value: str, **kwargs)[source]

Bases: msrest.serialization.Model

A rule governing the accessibility from a specific ip address or ip range.

All required parameters must be populated in order to send to Azure.

Parameters:value (str) – Required. An IPv4 address range in CIDR notation, such as ‘124.56.78.91’ (simple IP address) or ‘124.56.78.0/24’ (all addresses that start with 124.56.78).
class azure.mgmt.cognitiveservices.models.MetricName(**kwargs)[source]

Bases: msrest.serialization.Model

A metric name.

Variables are only populated by the server, and will be ignored when sending a request.

Variables:
  • value (str) – The name of the metric.
  • localized_value (str) – The friendly name of the metric.
class azure.mgmt.cognitiveservices.models.NetworkRuleSet(*, bypass=None, default_action=None, ip_rules=None, virtual_network_rules=None, **kwargs)[source]

Bases: msrest.serialization.Model

A set of rules governing the network accessibility.

Parameters:
  • bypass (str or NetworkRuleBypassOptions) – Tells what traffic can bypass network rules. This can be ‘AzureServices’ or ‘None’. If not specified the default is ‘AzureServices’. Possible values include: ‘AzureServices’, ‘None’
  • default_action (str or NetworkRuleAction) – The default action when no rule from ipRules and from virtualNetworkRules match. This is only used after the bypass property has been evaluated. Possible values include: ‘Allow’, ‘Deny’
  • ip_rules (list[IpRule]) – The list of IP address rules.
  • virtual_network_rules (list[VirtualNetworkRule]) – The list of virtual network rules.
class azure.mgmt.cognitiveservices.models.OperationDisplayInfo(*, description: str = None, operation: str = None, provider: str = None, resource: str = None, **kwargs)[source]

Bases: msrest.serialization.Model

The operation supported by Cognitive Services.

Parameters:
  • description (str) – The description of the operation.
  • operation (str) – The action that users can perform, based on their permission level.
  • provider (str) – Service provider: Microsoft Cognitive Services.
  • resource (str) – Resource on which the operation is performed.
class azure.mgmt.cognitiveservices.models.OperationEntity(*, name: str = None, display=None, origin: str = None, properties=None, **kwargs)[source]

Bases: msrest.serialization.Model

The operation supported by Cognitive Services.

Parameters:
  • name (str) – Operation name: {provider}/{resource}/{operation}.
  • display (OperationDisplayInfo) – The operation supported by Cognitive Services.
  • origin (str) – The origin of the operation.
  • properties (object) – Additional properties.
class azure.mgmt.cognitiveservices.models.RegenerateKeyParameters(*, key_name, **kwargs)[source]

Bases: msrest.serialization.Model

Regenerate key parameters.

All required parameters must be populated in order to send to Azure.

Parameters:key_name (str or KeyName) – Required. key name to generate (Key1|Key2). Possible values include: ‘Key1’, ‘Key2’
class azure.mgmt.cognitiveservices.models.ResourceSku(**kwargs)[source]

Bases: msrest.serialization.Model

Describes an available Cognitive Services SKU.

Variables are only populated by the server, and will be ignored when sending a request.

Variables:
  • resource_type (str) – The type of resource the SKU applies to.
  • name (str) – The name of SKU.
  • tier (str) – Specifies the tier of Cognitive Services account.
  • kind (str) – The Kind of resources that are supported in this SKU.
  • locations (list[str]) – The set of locations that the SKU is available.
  • restrictions (list[ResourceSkuRestrictions]) – The restrictions because of which SKU cannot be used. This is empty if there are no restrictions.
class azure.mgmt.cognitiveservices.models.ResourceSkuRestrictionInfo(**kwargs)[source]

Bases: msrest.serialization.Model

ResourceSkuRestrictionInfo.

Variables are only populated by the server, and will be ignored when sending a request.

Variables:
  • locations (list[str]) – Locations where the SKU is restricted
  • zones (list[str]) – List of availability zones where the SKU is restricted.
class azure.mgmt.cognitiveservices.models.ResourceSkuRestrictions(**kwargs)[source]

Bases: msrest.serialization.Model

Describes restrictions of a SKU.

Variables are only populated by the server, and will be ignored when sending a request.

Variables:
  • type (str or ResourceSkuRestrictionsType) – The type of restrictions. Possible values include: ‘Location’, ‘Zone’
  • values (list[str]) – The value of restrictions. If the restriction type is set to location. This would be different locations where the SKU is restricted.
  • restriction_info (ResourceSkuRestrictionInfo) – The information about the restriction where the SKU cannot be used.
  • reason_code (str or ResourceSkuRestrictionsReasonCode) – The reason for restriction. Possible values include: ‘QuotaId’, ‘NotAvailableForSubscription’
class azure.mgmt.cognitiveservices.models.Sku(*, name: str, **kwargs)[source]

Bases: msrest.serialization.Model

The SKU of the cognitive services account.

Variables are only populated by the server, and will be ignored when sending a request.

All required parameters must be populated in order to send to Azure.

Parameters:name (str) – Required. Gets or sets the sku name. Required for account creation, optional for update.
Variables:tier (str or SkuTier) – Gets the sku tier. This is based on the SKU name. Possible values include: ‘Free’, ‘Standard’, ‘Premium’
class azure.mgmt.cognitiveservices.models.Usage(*, unit=None, status=None, **kwargs)[source]

Bases: msrest.serialization.Model

The usage data for a usage request.

Variables are only populated by the server, and will be ignored when sending a request.

Parameters:
  • unit (str or UnitType) – The unit of the metric. Possible values include: ‘Count’, ‘Bytes’, ‘Seconds’, ‘Percent’, ‘CountPerSecond’, ‘BytesPerSecond’, ‘Milliseconds’
  • status (str or QuotaUsageStatus) – Cognitive Services account quota usage status. Possible values include: ‘Included’, ‘Blocked’, ‘InOverage’, ‘Unknown’
Variables:
  • name (MetricName) – The name information for the metric.
  • quota_period (str) – The quota period used to summarize the usage values.
  • limit (float) – Maximum value for this metric.
  • current_value (float) – Current value for this metric.
  • next_reset_time (str) – Next reset time for current quota.
class azure.mgmt.cognitiveservices.models.UsagesResult(**kwargs)[source]

Bases: msrest.serialization.Model

The response to a list usage request.

Variables are only populated by the server, and will be ignored when sending a request.

Variables:value (list[Usage]) – The list of usages for Cognitive Service account.
class azure.mgmt.cognitiveservices.models.VirtualNetworkRule(*, id: str, state: str = None, ignore_missing_vnet_service_endpoint: bool = None, **kwargs)[source]

Bases: msrest.serialization.Model

A rule governing the accessibility from a specific virtual network.

All required parameters must be populated in order to send to Azure.

Parameters:
  • id (str) – Required. Full resource id of a vnet subnet, such as ‘/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/subnet1’.
  • state (str) – Gets the state of virtual network rule.
  • ignore_missing_vnet_service_endpoint (bool) – Ignore missing vnet service endpoint or not.
class azure.mgmt.cognitiveservices.models.CognitiveServicesAccountPaged(*args, **kwargs)[source]

Bases: msrest.paging.Paged

A paging container for iterating over a list of CognitiveServicesAccount object

class azure.mgmt.cognitiveservices.models.ResourceSkuPaged(*args, **kwargs)[source]

Bases: msrest.paging.Paged

A paging container for iterating over a list of ResourceSku object

class azure.mgmt.cognitiveservices.models.OperationEntityPaged(*args, **kwargs)[source]

Bases: msrest.paging.Paged

A paging container for iterating over a list of OperationEntity object

class azure.mgmt.cognitiveservices.models.SkuTier[source]

Bases: str, enum.Enum

An enumeration.

free = 'Free'
premium = 'Premium'
standard = 'Standard'
class azure.mgmt.cognitiveservices.models.ProvisioningState[source]

Bases: str, enum.Enum

An enumeration.

creating = 'Creating'
deleting = 'Deleting'
failed = 'Failed'
moving = 'Moving'
resolving_dns = 'ResolvingDNS'
succeeded = 'Succeeded'
class azure.mgmt.cognitiveservices.models.NetworkRuleBypassOptions[source]

Bases: str, enum.Enum

An enumeration.

azure_services = 'AzureServices'
none = 'None'
class azure.mgmt.cognitiveservices.models.NetworkRuleAction[source]

Bases: str, enum.Enum

An enumeration.

allow = 'Allow'
deny = 'Deny'
class azure.mgmt.cognitiveservices.models.KeyName[source]

Bases: str, enum.Enum

An enumeration.

key1 = 'Key1'
key2 = 'Key2'
class azure.mgmt.cognitiveservices.models.UnitType[source]

Bases: str, enum.Enum

An enumeration.

bytes = 'Bytes'
bytes_per_second = 'BytesPerSecond'
count = 'Count'
count_per_second = 'CountPerSecond'
milliseconds = 'Milliseconds'
percent = 'Percent'
seconds = 'Seconds'
class azure.mgmt.cognitiveservices.models.QuotaUsageStatus[source]

Bases: str, enum.Enum

An enumeration.

blocked = 'Blocked'
in_overage = 'InOverage'
included = 'Included'
unknown = 'Unknown'
class azure.mgmt.cognitiveservices.models.ResourceSkuRestrictionsType[source]

Bases: str, enum.Enum

An enumeration.

location = 'Location'
zone = 'Zone'
class azure.mgmt.cognitiveservices.models.ResourceSkuRestrictionsReasonCode[source]

Bases: str, enum.Enum

An enumeration.

not_available_for_subscription = 'NotAvailableForSubscription'
quota_id = 'QuotaId'