---
title: "POST /subscriptions/{subscriptionId}/providers/Microsoft.StorageSync/locations/{locationName}/checkNameAvailability"
method: POST
path: "/subscriptions/{subscriptionId}/providers/Microsoft.StorageSync/locations/{locationName}/checkNameAvailability"
tags: ["StorageSyncService"]
---

# POST /subscriptions/{subscriptionId}/providers/Microsoft.StorageSync/locations/{locationName}/checkNameAvailability

`POST /subscriptions/{subscriptionId}/providers/Microsoft.StorageSync/locations/{locationName}/checkNameAvailability`

Check the give namespace name availability.

## Path parameters

- `locationName` string, required

## Parameters

- `../../../../../common-types/resource-management/v1/types.json#/components/parameters/ApiVersionParameter` — unresolved $ref
- `../../../../../common-types/resource-management/v1/types.json#/components/parameters/SubscriptionIdParameter` — unresolved $ref

## Request body

- CheckNameAvailabilityParameters — Parameters for a check name availability request.
  - `name` string, required — The name to check for availability
  - `type` 'Microsoft.StorageSync/storageSyncServices', required — The resource type. Must be set to Microsoft.StorageSync/storageSyncServices

## Response `200`

check availability returned successfully.

- CheckNameAvailabilityResult — The CheckNameAvailability operation response.
  - `nameAvailable` boolean — Gets a boolean value that indicates whether the name is available for you to use. If true, the name is available. If false, the name has already been taken or invalid and cannot be used.
  - `reason` 'Invalid' | 'AlreadyExists' — Gets the reason that a Storage Sync Service name could not be used. The Reason element is only returned if NameAvailable is false.
  - `message` string — Gets an error message explaining the Reason value in more detail.

---

[API](https://skmtc.dev/azure/apis/microsoft-storage-sync.md) · [All operations](https://skmtc.dev/azure/apis/microsoft-storage-sync/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/azure/microsoft-storage-sync/revisions/2de2d4c41058/schema)
