forked from Azure/azure-rest-api-specs
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Hub Generated] Review request for Microsoft.Communication to add ver…
…sion preview/2023-03-01-preview (Azure#22996) * Adds base for updating Microsoft.Communication from version preview/2021-10-01-preview to version 2023-03-01-preview * Updates readme * Updates API version in new specs and examples * Adding version 2023-03-01-preview changes. * Adding missing readme.md update * Addressing PR comments. * Updating to v5 common types * Incorporating comments from the stable version PR * Updating description for the provisioning state enum * Fixing model validation errors * Removing redundant systemData property. * Adding 201 response to indicate resource was create successfully
- Loading branch information
1 parent
69eba15
commit 7371f3a
Showing
35 changed files
with
3,412 additions
and
5 deletions.
There are no files selected for viewing
840 changes: 840 additions & 0 deletions
840
...rce-manager/Microsoft.Communication/preview/2023-03-01-preview/CommunicationServices.json
Large diffs are not rendered by default.
Oops, something went wrong.
732 changes: 732 additions & 0 deletions
732
...nication/resource-manager/Microsoft.Communication/preview/2023-03-01-preview/Domains.json
Large diffs are not rendered by default.
Oops, something went wrong.
502 changes: 502 additions & 0 deletions
502
...on/resource-manager/Microsoft.Communication/preview/2023-03-01-preview/EmailServices.json
Large diffs are not rendered by default.
Oops, something went wrong.
339 changes: 339 additions & 0 deletions
339
.../resource-manager/Microsoft.Communication/preview/2023-03-01-preview/SenderUsernames.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,339 @@ | ||
{ | ||
"swagger": "2.0", | ||
"info": { | ||
"title": "Azure Communication Services Management API", | ||
"version": "2023-03-01-preview", | ||
"description": "REST API for Email Services/Domains/SenderUsernames" | ||
}, | ||
"consumes": [ | ||
"application/json" | ||
], | ||
"produces": [ | ||
"application/json" | ||
], | ||
"host": "management.azure.com", | ||
"schemes": [ | ||
"https" | ||
], | ||
"securityDefinitions": { | ||
"azure_auth": { | ||
"type": "oauth2", | ||
"authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", | ||
"flow": "implicit", | ||
"description": "Azure Active Directory OAuth2 Flow", | ||
"scopes": { | ||
"user_impersonation": "impersonate your user account" | ||
} | ||
} | ||
}, | ||
"paths": { | ||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Communication/emailServices/{emailServiceName}/domains/{domainName}/senderUsernames": { | ||
"get": { | ||
"description": "List all valid sender usernames for a domains resource.", | ||
"operationId": "SenderUsernames_ListByDomains", | ||
"summary": "ListBy_Domains", | ||
"tags": [ | ||
"SenderUsernames" | ||
], | ||
"parameters": [ | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" | ||
}, | ||
{ | ||
"$ref": "EmailServices.json#/parameters/EmailServiceName" | ||
}, | ||
{ | ||
"$ref": "Domains.json#/parameters/DomainName" | ||
} | ||
], | ||
"responses": { | ||
"200": { | ||
"description": "Success. The response describe the Domains SenderUsername collection.", | ||
"schema": { | ||
"$ref": "#/definitions/SenderUsernameResourceCollection" | ||
} | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/definitions/ErrorResponse" | ||
} | ||
} | ||
}, | ||
"x-ms-pageable": { | ||
"nextLinkName": "nextLink" | ||
}, | ||
"produces": [ | ||
"application/json" | ||
], | ||
"x-ms-examples": { | ||
"Get SenderUsernames resource": { | ||
"$ref": "./examples/senderUsernames/listByDomain.json" | ||
} | ||
} | ||
} | ||
}, | ||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Communication/emailServices/{emailServiceName}/domains/{domainName}/senderUsernames/{senderUsername}": { | ||
"get": { | ||
"description": "Get a valid sender username for a domains resource.", | ||
"operationId": "SenderUsernames_Get", | ||
"summary": "Get", | ||
"tags": [ | ||
"SenderUsernames" | ||
], | ||
"parameters": [ | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" | ||
}, | ||
{ | ||
"$ref": "EmailServices.json#/parameters/EmailServiceName" | ||
}, | ||
{ | ||
"$ref": "Domains.json#/parameters/DomainName" | ||
}, | ||
{ | ||
"$ref": "#/parameters/SenderUsername" | ||
} | ||
], | ||
"responses": { | ||
"200": { | ||
"description": "Success. The response describe the corresponding SenderUsername resource.", | ||
"schema": { | ||
"$ref": "#/definitions/SenderUsernameResource" | ||
} | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/definitions/ErrorResponse" | ||
} | ||
} | ||
}, | ||
"produces": [ | ||
"application/json" | ||
], | ||
"x-ms-examples": { | ||
"Get SenderUsernames resource": { | ||
"$ref": "./examples/senderUsernames/get.json" | ||
} | ||
} | ||
}, | ||
"put": { | ||
"description": "Add a new SenderUsername resource under the parent Domains resource or update an existing SenderUsername resource.", | ||
"operationId": "SenderUsernames_CreateOrUpdate", | ||
"summary": "Create Or Update", | ||
"tags": [ | ||
"SenderUsernames" | ||
], | ||
"parameters": [ | ||
{ | ||
"name": "parameters", | ||
"in": "body", | ||
"description": "Parameters for the create or update operation", | ||
"required": true, | ||
"schema": { | ||
"$ref": "#/definitions/SenderUsernameResource" | ||
} | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" | ||
}, | ||
{ | ||
"$ref": "EmailServices.json#/parameters/EmailServiceName" | ||
}, | ||
{ | ||
"$ref": "Domains.json#/parameters/DomainName" | ||
}, | ||
{ | ||
"$ref": "#/parameters/SenderUsername" | ||
} | ||
], | ||
"consumes": [ | ||
"application/json" | ||
], | ||
"responses": { | ||
"200": { | ||
"description": "The update request was completed successfully", | ||
"schema": { | ||
"$ref": "#/definitions/SenderUsernameResource" | ||
} | ||
}, | ||
"201": { | ||
"description": "The create request was completed successfully", | ||
"schema": { | ||
"$ref": "#/definitions/SenderUsernameResource" | ||
} | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/definitions/ErrorResponse" | ||
} | ||
} | ||
}, | ||
"produces": [ | ||
"application/json" | ||
], | ||
"x-ms-examples": { | ||
"Create or update SenderUsernames resource": { | ||
"$ref": "./examples/senderUsernames/createOrUpdate.json" | ||
} | ||
} | ||
}, | ||
"delete": { | ||
"description": "Operation to delete a SenderUsernames resource.", | ||
"operationId": "SenderUsernames_Delete", | ||
"summary": "Delete", | ||
"tags": [ | ||
"SenderUsernames" | ||
], | ||
"parameters": [ | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" | ||
}, | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" | ||
}, | ||
{ | ||
"$ref": "EmailServices.json#/parameters/EmailServiceName" | ||
}, | ||
{ | ||
"$ref": "Domains.json#/parameters/DomainName" | ||
}, | ||
{ | ||
"$ref": "#/parameters/SenderUsername" | ||
} | ||
], | ||
"responses": { | ||
"200": { | ||
"description": "The delete operation was successful." | ||
}, | ||
"204": { | ||
"description": "The resource did not exist." | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/definitions/ErrorResponse" | ||
} | ||
} | ||
}, | ||
"x-ms-examples": { | ||
"Delete SenderUsernames resource": { | ||
"$ref": "./examples/senderUsernames/delete.json" | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"definitions": { | ||
"SenderUsernameResource": { | ||
"description": "A class representing a SenderUsername resource.", | ||
"type": "object", | ||
"allOf": [ | ||
{ | ||
"$ref": "../../../../../common-types/resource-management/v5/types.json#/definitions/ProxyResource" | ||
} | ||
], | ||
"properties": { | ||
"properties": { | ||
"$ref": "#/definitions/SenderUsernameProperties", | ||
"description": "The properties of a SenderUsername resource.", | ||
"x-ms-client-flatten": true | ||
} | ||
} | ||
}, | ||
"SenderUsernameResourceCollection": { | ||
"description": "A class representing a Domains SenderUsernames collection.", | ||
"type": "object", | ||
"properties": { | ||
"value": { | ||
"description": "List of SenderUsernames", | ||
"type": "array", | ||
"items": { | ||
"$ref": "#/definitions/SenderUsernameResource" | ||
} | ||
}, | ||
"nextLink": { | ||
"description": "The URL the client should use to fetch the next page (per server side paging).", | ||
"type": "string" | ||
} | ||
} | ||
}, | ||
"SenderUsernameProperties": { | ||
"description": "A class that describes the properties of a SenderUsername resource.", | ||
"type": "object", | ||
"required": [ | ||
"username" | ||
], | ||
"properties": { | ||
"dataLocation": { | ||
"description": "The location where the SenderUsername resource data is stored at rest.", | ||
"type": "string", | ||
"readOnly": true | ||
}, | ||
"username": { | ||
"description": "A sender senderUsername to be used when sending emails.", | ||
"type": "string" | ||
}, | ||
"displayName": { | ||
"description": "The display name for the senderUsername.", | ||
"type": "string" | ||
}, | ||
"provisioningState": { | ||
"description": "Provisioning state of the resource. Unknown is the default state for Communication Services.", | ||
"enum": [ | ||
"Unknown", | ||
"Succeeded", | ||
"Failed", | ||
"Canceled", | ||
"Running", | ||
"Creating", | ||
"Updating", | ||
"Deleting", | ||
"Moving" | ||
], | ||
"type": "string", | ||
"readOnly": true, | ||
"x-ms-enum": { | ||
"name": "ProvisioningState", | ||
"modelAsString": true | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"parameters": { | ||
"SenderUsername": { | ||
"name": "senderUsername", | ||
"in": "path", | ||
"description": "The valid sender Username.", | ||
"minLength": 1, | ||
"maxLength": 253, | ||
"required": true, | ||
"type": "string", | ||
"x-ms-parameter-location": "method" | ||
} | ||
} | ||
} |
19 changes: 19 additions & 0 deletions
19
...iew/2023-03-01-preview/examples/communicationServices/checkNameAvailabilityAvailable.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "11112222-3333-4444-5555-666677778888", | ||
"api-version": "2023-03-01-preview", | ||
"nameAvailabilityParameters": { | ||
"type": "Microsoft.Communication/CommunicationServices", | ||
"name": "MyCommunicationService" | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"nameAvailable": true, | ||
"reason": "NameAvailable", | ||
"message": "Requested name is available for the requested type" | ||
} | ||
} | ||
} | ||
} |
19 changes: 19 additions & 0 deletions
19
...w/2023-03-01-preview/examples/communicationServices/checkNameAvailabilityUnavailable.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "11112222-3333-4444-5555-666677778888", | ||
"api-version": "2023-03-01-preview", | ||
"nameAvailabilityParameters": { | ||
"type": "Microsoft.Communication/CommunicationServices", | ||
"name": "MyCommunicationService" | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"nameAvailable": false, | ||
"reason": "AlreadyExists", | ||
"message": "Requested name is unavailable for the requested type" | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.