Media Service - Check Name Availability
Checks whether the Media Service resource name is available. The name must be globally unique.
POST https://management.azure.com/subscriptions/{subscriptionId}/providers/Microsoft.Media/CheckNameAvailability?api-version={api-version}
URI Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
|
resourceGroupName
|
path | True |
|
Name of the resource group within the Azure subscription. |
|
mediaServiceName
|
path | True |
|
Name of the Media Service.
Regex pattern: |
|
subscriptionId
|
path | True |
|
The unique identifier for a Microsoft Azure subscription. |
|
api-version
|
query | True |
|
Version of the API to be used with the client request. The current version is 2015-10-01. |
Request Body
| Name | Required | Type | Description |
|---|---|---|---|
| name | True |
|
The name of the resource. A name must be globally unique. Regex pattern: |
| type | True |
|
The type of the resource - mediaservices. |
Responses
| Name | Type | Description |
|---|---|---|
| 200 OK |
Success. Returns details about whether a Media Service resource name is available. |
|
| Other Status Codes |
CheckNameAvailability of a Media Service failed. |
Examples
MediaServiceCheckNameAvailability
Sample Request
POST https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Media/CheckNameAvailability?api-version=2015-10-01
{
"name": "contosomedia",
"type": "mediaservices"
}
Sample Response
{
"nameAvailable": true,
"reason": "None",
"message": ""
}
Definitions
| ApiError | |
| CheckNameAvailabilityOutput |
| Name | Type | Description |
|---|---|---|
| code |
|
Error code. |
| message |
|
Error message. |
| Name | Type | Description |
|---|---|---|
| message |
|
Specifies the detailed reason if the name is not available. |
| nameAvailable |
|
Specifies if the name is available. |
| reason |
|
Specifies the reason if the name is not available. |