openapi-directory
Version:
Building & bundling https://github.com/APIs-guru/openapi-directory for easy use from JS
1 lines • 53.4 kB
JSON
{"openapi":"3.0.0","info":{"description":"Use these REST APIs for performing operations on Subscription entity associated with your Azure API Management deployment. The Subscription entity represents the association between a user and a product in API Management. Products contain one or more APIs, and once a product is published, developers can subscribe to the product and begin to use the product’s APIs.","title":"ApiManagementClient","version":"2019-12-01-preview","x-apisguru-categories":["cloud"],"x-logo":{"url":"https://assets.onestore.ms/cdnfiles/onestorerolling-1606-01000/shell/v3/images/logo/microsoft.png"},"x-origin":[{"format":"swagger","url":"https://raw.githubusercontent.com/Azure/azure-rest-api-specs/master/specification/apimanagement/resource-manager/Microsoft.ApiManagement/preview/2019-12-01-preview/apimsubscriptions.json","version":"2.0"}],"x-preferred":true,"x-providerName":"azure.com","x-serviceName":"apimanagement-apimsubscriptions","x-tags":["Azure","Microsoft"]},"security":[{"azure_auth":["user_impersonation"]}],"paths":{"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/subscriptions":{"get":{"description":"Lists all subscriptions of the API Management service instance.","operationId":"Subscription_List","parameters":[{"description":"The name of the resource group.","in":"path","name":"resourceGroupName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string"},"examples":{"ApiManagementListSubscriptions":{"value":"rg1"}}},{"description":"The name of the API Management service.","in":"path","name":"serviceName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","minLength":1,"maxLength":50,"pattern":"^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$"},"examples":{"ApiManagementListSubscriptions":{"value":"apimService1"}}},{"description":"| Field | Usage | Supported operators | Supported functions |</br>|-------------|-------------|-------------|-------------|</br>| name | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith | </br>| displayName | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith | </br>| stateComment | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith | </br>| ownerId | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith | </br>| scope | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith | </br>| userId | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith | </br>| productId | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith | </br>| state | filter | eq | | </br>| user | expand | | | </br>","in":"query","name":"$filter","required":false,"schema":{"type":"string"}},{"description":"Number of records to return.","in":"query","name":"$top","required":false,"x-ms-parameter-location":"method","schema":{"type":"integer","format":"int32","minimum":1}},{"description":"Number of records to skip.","in":"query","name":"$skip","required":false,"x-ms-parameter-location":"method","schema":{"type":"integer","format":"int32","minimum":0}},{"description":"Version of the API to be used with the client request.","in":"query","name":"api-version","required":true,"schema":{"type":"string"},"examples":{"ApiManagementListSubscriptions":{"value":"2019-12-01-preview"}}},{"description":"Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.","in":"path","name":"subscriptionId","required":true,"schema":{"type":"string"},"examples":{"ApiManagementListSubscriptions":{"value":"subid"}}}],"responses":{"200":{"description":"A collection of the Subscription entities for the specified API Management service instance.","content":{"application/json":{"schema":{"description":"Paged Subscriptions list representation.","properties":{"nextLink":{"description":"Next page link if any.","type":"string"},"value":{"description":"Page values.","items":{"allOf":[{"description":"The Resource definition.","properties":{"id":{"description":"Resource ID.","readOnly":true,"type":"string"},"name":{"description":"Resource name.","readOnly":true,"type":"string"},"type":{"description":"Resource type for API Management resource.","readOnly":true,"type":"string"}},"x-ms-azure-resource":true}],"description":"Subscription details.","properties":{"properties":{"description":"Subscription details.","properties":{"allowTracing":{"description":"Determines whether tracing is enabled","type":"boolean","x-apim-code-nillable":true},"createdDate":{"description":"Subscription creation date. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","readOnly":true,"type":"string"},"displayName":{"description":"The name of the subscription, or null if the subscription has no name.","maxLength":100,"minLength":0,"type":"string"},"endDate":{"description":"Date when subscription was cancelled or expired. The setting is for audit purposes only and the subscription is not automatically cancelled. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"expirationDate":{"description":"Subscription expiration date. The setting is for audit purposes only and the subscription is not automatically expired. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"notificationDate":{"description":"Upcoming subscription expiration notification date. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"ownerId":{"description":"The user resource identifier of the subscription owner. The value is a valid relative URL in the format of /users/{userId} where {userId} is a user identifier.","type":"string"},"primaryKey":{"description":"Subscription primary key. This property will not be filled on 'GET' operations! Use '/listSecrets' POST request to get the value.","maxLength":256,"minLength":1,"type":"string","x-ms-secret":true},"scope":{"description":"Scope like /products/{productId} or /apis or /apis/{apiId}.","type":"string"},"secondaryKey":{"description":"Subscription secondary key. This property will not be filled on 'GET' operations! Use '/listSecrets' POST request to get the value.","maxLength":256,"minLength":1,"type":"string","x-ms-secret":true},"startDate":{"description":"Subscription activation date. The setting is for audit purposes only and the subscription is not automatically activated. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"state":{"description":"Subscription state. Possible states are * active – the subscription is active, * suspended – the subscription is blocked, and the subscriber cannot call any APIs of the product, * submitted – the subscription request has been made by the developer, but has not yet been approved or rejected, * rejected – the subscription request has been denied by an administrator, * cancelled – the subscription has been cancelled by the developer or administrator, * expired – the subscription reached its expiration date and was deactivated.","enum":["suspended","active","expired","submitted","rejected","cancelled"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"SubscriptionState"}},"stateComment":{"description":"Optional subscription comment added by an administrator.","type":"string"}},"required":["scope","state"]}}},"type":"array"}}},"examples":{"ApiManagementListSubscriptions":{"$ref":"#/components/examples/ApiManagementListSubscriptions"}}}}},"default":{"description":"Error response describing why the operation failed.","content":{"application/json":{"schema":{"description":"Error Response.","properties":{"error":{"description":"Error Body contract.","properties":{"code":{"description":"Service-defined error code. This code serves as a sub-status for the HTTP error code specified in the response.","type":"string"},"details":{"description":"The list of invalid fields send in request, in case of validation error.","items":{"description":"Error Field contract.","properties":{"code":{"description":"Property level error code.","type":"string"},"message":{"description":"Human-readable representation of property-level error.","type":"string"},"target":{"description":"Property name.","type":"string"}}},"type":"array"},"message":{"description":"Human-readable representation of the error.","type":"string"}}}}}}}}},"tags":["Subscription"],"x-ms-odata":"./definitions.json#/definitions/SubscriptionContract","x-ms-pageable":{"nextLinkName":"nextLink"}}},"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/subscriptions/{sid}":{"delete":{"description":"Deletes the specified subscription.","operationId":"Subscription_Delete","parameters":[{"description":"The name of the resource group.","in":"path","name":"resourceGroupName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string"},"examples":{"ApiManagementDeleteSubscription":{"value":"rg1"}}},{"description":"The name of the API Management service.","in":"path","name":"serviceName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","minLength":1,"maxLength":50,"pattern":"^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$"},"examples":{"ApiManagementDeleteSubscription":{"value":"apimService1"}}},{"description":"Subscription entity Identifier. The entity represents the association between a user and a product in API Management.","in":"path","name":"sid","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","maxLength":256,"pattern":"^[^*#&+:<>?]+$"},"examples":{"ApiManagementDeleteSubscription":{"value":"testsub"}}},{"description":"ETag of the Entity. ETag should match the current entity state from the header response of the GET request or it should be * for unconditional update.","in":"header","name":"If-Match","required":true,"x-ms-parameter-location":"method","schema":{"type":"string"},"examples":{"ApiManagementDeleteSubscription":{"value":"*"}}},{"description":"Version of the API to be used with the client request.","in":"query","name":"api-version","required":true,"schema":{"type":"string"},"examples":{"ApiManagementDeleteSubscription":{"value":"2019-12-01-preview"}}},{"description":"Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.","in":"path","name":"subscriptionId","required":true,"schema":{"type":"string"},"examples":{"ApiManagementDeleteSubscription":{"value":"subid"}}}],"responses":{"200":{"description":"The subscription details were successfully deleted."},"204":{"description":"The subscription details were successfully deleted."},"default":{"description":"Error response describing why the operation failed.","content":{"application/json":{"schema":{"description":"Error Response.","properties":{"error":{"description":"Error Body contract.","properties":{"code":{"description":"Service-defined error code. This code serves as a sub-status for the HTTP error code specified in the response.","type":"string"},"details":{"description":"The list of invalid fields send in request, in case of validation error.","items":{"description":"Error Field contract.","properties":{"code":{"description":"Property level error code.","type":"string"},"message":{"description":"Human-readable representation of property-level error.","type":"string"},"target":{"description":"Property name.","type":"string"}}},"type":"array"},"message":{"description":"Human-readable representation of the error.","type":"string"}}}}}}}}},"tags":["Subscription"]},"get":{"description":"Gets the specified Subscription entity.","operationId":"Subscription_Get","parameters":[{"description":"The name of the resource group.","in":"path","name":"resourceGroupName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string"},"examples":{"ApiManagementGetSubscription":{"value":"rg1"}}},{"description":"The name of the API Management service.","in":"path","name":"serviceName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","minLength":1,"maxLength":50,"pattern":"^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$"},"examples":{"ApiManagementGetSubscription":{"value":"apimService1"}}},{"description":"Subscription entity Identifier. The entity represents the association between a user and a product in API Management.","in":"path","name":"sid","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","maxLength":256,"pattern":"^[^*#&+:<>?]+$"},"examples":{"ApiManagementGetSubscription":{"value":"5931a769d8d14f0ad8ce13b8"}}},{"description":"Version of the API to be used with the client request.","in":"query","name":"api-version","required":true,"schema":{"type":"string"},"examples":{"ApiManagementGetSubscription":{"value":"2019-12-01-preview"}}},{"description":"Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.","in":"path","name":"subscriptionId","required":true,"schema":{"type":"string"},"examples":{"ApiManagementGetSubscription":{"value":"subid"}}}],"responses":{"200":{"description":"The response body contains the specified Subscription entity.","headers":{"ETag":{"description":"Current entity state version. Should be treated as opaque and used to make conditional HTTP requests.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"allOf":[{"description":"The Resource definition.","properties":{"id":{"description":"Resource ID.","readOnly":true,"type":"string"},"name":{"description":"Resource name.","readOnly":true,"type":"string"},"type":{"description":"Resource type for API Management resource.","readOnly":true,"type":"string"}},"x-ms-azure-resource":true}],"description":"Subscription details.","properties":{"properties":{"description":"Subscription details.","properties":{"allowTracing":{"description":"Determines whether tracing is enabled","type":"boolean","x-apim-code-nillable":true},"createdDate":{"description":"Subscription creation date. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","readOnly":true,"type":"string"},"displayName":{"description":"The name of the subscription, or null if the subscription has no name.","maxLength":100,"minLength":0,"type":"string"},"endDate":{"description":"Date when subscription was cancelled or expired. The setting is for audit purposes only and the subscription is not automatically cancelled. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"expirationDate":{"description":"Subscription expiration date. The setting is for audit purposes only and the subscription is not automatically expired. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"notificationDate":{"description":"Upcoming subscription expiration notification date. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"ownerId":{"description":"The user resource identifier of the subscription owner. The value is a valid relative URL in the format of /users/{userId} where {userId} is a user identifier.","type":"string"},"primaryKey":{"description":"Subscription primary key. This property will not be filled on 'GET' operations! Use '/listSecrets' POST request to get the value.","maxLength":256,"minLength":1,"type":"string","x-ms-secret":true},"scope":{"description":"Scope like /products/{productId} or /apis or /apis/{apiId}.","type":"string"},"secondaryKey":{"description":"Subscription secondary key. This property will not be filled on 'GET' operations! Use '/listSecrets' POST request to get the value.","maxLength":256,"minLength":1,"type":"string","x-ms-secret":true},"startDate":{"description":"Subscription activation date. The setting is for audit purposes only and the subscription is not automatically activated. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"state":{"description":"Subscription state. Possible states are * active – the subscription is active, * suspended – the subscription is blocked, and the subscriber cannot call any APIs of the product, * submitted – the subscription request has been made by the developer, but has not yet been approved or rejected, * rejected – the subscription request has been denied by an administrator, * cancelled – the subscription has been cancelled by the developer or administrator, * expired – the subscription reached its expiration date and was deactivated.","enum":["suspended","active","expired","submitted","rejected","cancelled"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"SubscriptionState"}},"stateComment":{"description":"Optional subscription comment added by an administrator.","type":"string"}},"required":["scope","state"]}}},"examples":{"ApiManagementGetSubscription":{"$ref":"#/components/examples/ApiManagementGetSubscription"}}}}},"default":{"description":"Error response describing why the operation failed.","content":{"application/json":{"schema":{"description":"Error Response.","properties":{"error":{"description":"Error Body contract.","properties":{"code":{"description":"Service-defined error code. This code serves as a sub-status for the HTTP error code specified in the response.","type":"string"},"details":{"description":"The list of invalid fields send in request, in case of validation error.","items":{"description":"Error Field contract.","properties":{"code":{"description":"Property level error code.","type":"string"},"message":{"description":"Human-readable representation of property-level error.","type":"string"},"target":{"description":"Property name.","type":"string"}}},"type":"array"},"message":{"description":"Human-readable representation of the error.","type":"string"}}}}}}}}},"tags":["Subscription"]},"head":{"description":"Gets the entity state (Etag) version of the apimanagement subscription specified by its identifier.","operationId":"Subscription_GetEntityTag","parameters":[{"description":"The name of the resource group.","in":"path","name":"resourceGroupName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string"},"examples":{"ApiManagementHeadSubscription":{"value":"rg1"}}},{"description":"The name of the API Management service.","in":"path","name":"serviceName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","minLength":1,"maxLength":50,"pattern":"^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$"},"examples":{"ApiManagementHeadSubscription":{"value":"apimService1"}}},{"description":"Subscription entity Identifier. The entity represents the association between a user and a product in API Management.","in":"path","name":"sid","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","maxLength":256,"pattern":"^[^*#&+:<>?]+$"},"examples":{"ApiManagementHeadSubscription":{"value":"5931a769d8d14f0ad8ce13b8"}}},{"description":"Version of the API to be used with the client request.","in":"query","name":"api-version","required":true,"schema":{"type":"string"},"examples":{"ApiManagementHeadSubscription":{"value":"2019-12-01-preview"}}},{"description":"Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.","in":"path","name":"subscriptionId","required":true,"schema":{"type":"string"},"examples":{"ApiManagementHeadSubscription":{"value":"subid"}}}],"responses":{"200":{"description":"Specified apimanagement subscription entity exists and current entity state version is present in the ETag header.","headers":{"ETag":{"description":"Current entity state version. Should be treated as opaque and used to make conditional HTTP requests.","schema":{"type":"string"}}}},"default":{"description":"Error response describing why the operation failed.","content":{"application/json":{"schema":{"description":"Error Response.","properties":{"error":{"description":"Error Body contract.","properties":{"code":{"description":"Service-defined error code. This code serves as a sub-status for the HTTP error code specified in the response.","type":"string"},"details":{"description":"The list of invalid fields send in request, in case of validation error.","items":{"description":"Error Field contract.","properties":{"code":{"description":"Property level error code.","type":"string"},"message":{"description":"Human-readable representation of property-level error.","type":"string"},"target":{"description":"Property name.","type":"string"}}},"type":"array"},"message":{"description":"Human-readable representation of the error.","type":"string"}}}}}}}}},"tags":["Subscription"]},"patch":{"description":"Updates the details of a subscription specified by its identifier.","operationId":"Subscription_Update","parameters":[{"description":"The name of the resource group.","in":"path","name":"resourceGroupName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string"},"examples":{"ApiManagementUpdateSubscription":{"value":"rg1"}}},{"description":"The name of the API Management service.","in":"path","name":"serviceName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","minLength":1,"maxLength":50,"pattern":"^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$"},"examples":{"ApiManagementUpdateSubscription":{"value":"apimService1"}}},{"description":"Subscription entity Identifier. The entity represents the association between a user and a product in API Management.","in":"path","name":"sid","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","maxLength":256,"pattern":"^[^*#&+:<>?]+$"},"examples":{"ApiManagementUpdateSubscription":{"value":"testsub"}}},{"description":"Notify change in Subscription State. \n - If false, do not send any email notification for change of state of subscription \n - If true, send email notification of change of state of subscription ","in":"query","name":"notify","required":false,"x-ms-parameter-location":"method","schema":{"type":"boolean"}},{"description":"ETag of the Entity. ETag should match the current entity state from the header response of the GET request or it should be * for unconditional update.","in":"header","name":"If-Match","required":true,"x-ms-parameter-location":"method","schema":{"type":"string"},"examples":{"ApiManagementUpdateSubscription":{"value":"*"}}},{"description":"Version of the API to be used with the client request.","in":"query","name":"api-version","required":true,"schema":{"type":"string"},"examples":{"ApiManagementUpdateSubscription":{"value":"2019-12-01-preview"}}},{"description":"Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.","in":"path","name":"subscriptionId","required":true,"schema":{"type":"string"},"examples":{"ApiManagementUpdateSubscription":{"value":"subid"}}}],"requestBody":{"content":{"application/json":{"schema":{"description":"Subscription update details.","properties":{"properties":{"description":"Parameters supplied to the Update subscription operation.","properties":{"allowTracing":{"description":"Determines whether tracing can be enabled","type":"boolean"},"displayName":{"description":"Subscription name.","type":"string"},"expirationDate":{"description":"Subscription expiration date. The setting is for audit purposes only and the subscription is not automatically expired. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.","format":"date-time","type":"string"},"ownerId":{"description":"User identifier path: /users/{userId}","type":"string"},"primaryKey":{"description":"Primary subscription key.","maxLength":256,"minLength":1,"type":"string"},"scope":{"description":"Scope like /products/{productId} or /apis or /apis/{apiId}","type":"string"},"secondaryKey":{"description":"Secondary subscription key.","maxLength":256,"minLength":1,"type":"string"},"state":{"description":"Subscription state. Possible states are * active – the subscription is active, * suspended – the subscription is blocked, and the subscriber cannot call any APIs of the product, * submitted – the subscription request has been made by the developer, but has not yet been approved or rejected, * rejected – the subscription request has been denied by an administrator, * cancelled – the subscription has been cancelled by the developer or administrator, * expired – the subscription reached its expiration date and was deactivated.","enum":["suspended","active","expired","submitted","rejected","cancelled"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"SubscriptionState"}},"stateComment":{"description":"Comments describing subscription state change by the administrator.","type":"string"}}}}}}},"description":"Update parameters.","required":true},"responses":{"204":{"description":"The subscription details were successfully updated."},"default":{"description":"Error response describing why the operation failed.","content":{"application/json":{"schema":{"description":"Error Response.","properties":{"error":{"description":"Error Body contract.","properties":{"code":{"description":"Service-defined error code. This code serves as a sub-status for the HTTP error code specified in the response.","type":"string"},"details":{"description":"The list of invalid fields send in request, in case of validation error.","items":{"description":"Error Field contract.","properties":{"code":{"description":"Property level error code.","type":"string"},"message":{"description":"Human-readable representation of property-level error.","type":"string"},"target":{"description":"Property name.","type":"string"}}},"type":"array"},"message":{"description":"Human-readable representation of the error.","type":"string"}}}}}}}}},"tags":["Subscription"]},"put":{"description":"Creates or updates the subscription of specified user to the specified product.","operationId":"Subscription_CreateOrUpdate","parameters":[{"description":"The name of the resource group.","in":"path","name":"resourceGroupName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string"},"examples":{"ApiManagementCreateSubscription":{"value":"rg1"}}},{"description":"The name of the API Management service.","in":"path","name":"serviceName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","minLength":1,"maxLength":50,"pattern":"^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$"},"examples":{"ApiManagementCreateSubscription":{"value":"apimService1"}}},{"description":"Subscription entity Identifier. The entity represents the association between a user and a product in API Management.","in":"path","name":"sid","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","maxLength":256,"pattern":"^[^*#&+:<>?]+$"},"examples":{"ApiManagementCreateSubscription":{"value":"testsub"}}},{"description":"Notify change in Subscription State. \n - If false, do not send any email notification for change of state of subscription \n - If true, send email notification of change of state of subscription ","in":"query","name":"notify","required":false,"x-ms-parameter-location":"method","schema":{"type":"boolean"}},{"description":"ETag of the Entity. Not required when creating an entity, but required when updating an entity.","in":"header","name":"If-Match","required":false,"x-ms-parameter-location":"method","schema":{"type":"string"}},{"description":"Version of the API to be used with the client request.","in":"query","name":"api-version","required":true,"schema":{"type":"string"},"examples":{"ApiManagementCreateSubscription":{"value":"2019-12-01-preview"}}},{"description":"Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.","in":"path","name":"subscriptionId","required":true,"schema":{"type":"string"},"examples":{"ApiManagementCreateSubscription":{"value":"subid"}}}],"requestBody":{"content":{"application/json":{"schema":{"description":"Subscription create details.","properties":{"properties":{"description":"Parameters supplied to the Create subscription operation.","properties":{"allowTracing":{"description":"Determines whether tracing can be enabled","type":"boolean"},"displayName":{"description":"Subscription name.","maxLength":100,"minLength":1,"type":"string"},"ownerId":{"description":"User (user id path) for whom subscription is being created in form /users/{userId}","type":"string"},"primaryKey":{"description":"Primary subscription key. If not specified during request key will be generated automatically.","maxLength":256,"minLength":1,"type":"string"},"scope":{"description":"Scope like /products/{productId} or /apis or /apis/{apiId}.","type":"string"},"secondaryKey":{"description":"Secondary subscription key. If not specified during request key will be generated automatically.","maxLength":256,"minLength":1,"type":"string"},"state":{"description":"Initial subscription state. If no value is specified, subscription is created with Submitted state. Possible states are * active – the subscription is active, * suspended – the subscription is blocked, and the subscriber cannot call any APIs of the product, * submitted – the subscription request has been made by the developer, but has not yet been approved or rejected, * rejected – the subscription request has been denied by an administrator, * cancelled – the subscription has been cancelled by the developer or administrator, * expired – the subscription reached its expiration date and was deactivated.","enum":["suspended","active","expired","submitted","rejected","cancelled"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"SubscriptionState"}}},"required":["scope","displayName"]}}}}},"description":"Create parameters.","required":true},"responses":{"200":{"description":"The user already subscribed to the product.","headers":{"ETag":{"description":"Current entity state version. Should be treated as opaque and used to make conditional HTTP requests.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"allOf":[{"description":"The Resource definition.","properties":{"id":{"description":"Resource ID.","readOnly":true,"type":"string"},"name":{"description":"Resource name.","readOnly":true,"type":"string"},"type":{"description":"Resource type for API Management resource.","readOnly":true,"type":"string"}},"x-ms-azure-resource":true}],"description":"Subscription details.","properties":{"properties":{"description":"Subscription details.","properties":{"allowTracing":{"description":"Determines whether tracing is enabled","type":"boolean","x-apim-code-nillable":true},"createdDate":{"description":"Subscription creation date. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","readOnly":true,"type":"string"},"displayName":{"description":"The name of the subscription, or null if the subscription has no name.","maxLength":100,"minLength":0,"type":"string"},"endDate":{"description":"Date when subscription was cancelled or expired. The setting is for audit purposes only and the subscription is not automatically cancelled. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"expirationDate":{"description":"Subscription expiration date. The setting is for audit purposes only and the subscription is not automatically expired. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"notificationDate":{"description":"Upcoming subscription expiration notification date. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"ownerId":{"description":"The user resource identifier of the subscription owner. The value is a valid relative URL in the format of /users/{userId} where {userId} is a user identifier.","type":"string"},"primaryKey":{"description":"Subscription primary key. This property will not be filled on 'GET' operations! Use '/listSecrets' POST request to get the value.","maxLength":256,"minLength":1,"type":"string","x-ms-secret":true},"scope":{"description":"Scope like /products/{productId} or /apis or /apis/{apiId}.","type":"string"},"secondaryKey":{"description":"Subscription secondary key. This property will not be filled on 'GET' operations! Use '/listSecrets' POST request to get the value.","maxLength":256,"minLength":1,"type":"string","x-ms-secret":true},"startDate":{"description":"Subscription activation date. The setting is for audit purposes only and the subscription is not automatically activated. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"state":{"description":"Subscription state. Possible states are * active – the subscription is active, * suspended – the subscription is blocked, and the subscriber cannot call any APIs of the product, * submitted – the subscription request has been made by the developer, but has not yet been approved or rejected, * rejected – the subscription request has been denied by an administrator, * cancelled – the subscription has been cancelled by the developer or administrator, * expired – the subscription reached its expiration date and was deactivated.","enum":["suspended","active","expired","submitted","rejected","cancelled"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"SubscriptionState"}},"stateComment":{"description":"Optional subscription comment added by an administrator.","type":"string"}},"required":["scope","state"]}}},"examples":{"ApiManagementCreateSubscription":{"$ref":"#/components/examples/ApiManagementCreateSubscription"}}}}},"201":{"description":"The user was successfully subscribed to the product.","headers":{"ETag":{"description":"Current entity state version. Should be treated as opaque and used to make conditional HTTP requests.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"allOf":[{"description":"The Resource definition.","properties":{"id":{"description":"Resource ID.","readOnly":true,"type":"string"},"name":{"description":"Resource name.","readOnly":true,"type":"string"},"type":{"description":"Resource type for API Management resource.","readOnly":true,"type":"string"}},"x-ms-azure-resource":true}],"description":"Subscription details.","properties":{"properties":{"description":"Subscription details.","properties":{"allowTracing":{"description":"Determines whether tracing is enabled","type":"boolean","x-apim-code-nillable":true},"createdDate":{"description":"Subscription creation date. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","readOnly":true,"type":"string"},"displayName":{"description":"The name of the subscription, or null if the subscription has no name.","maxLength":100,"minLength":0,"type":"string"},"endDate":{"description":"Date when subscription was cancelled or expired. The setting is for audit purposes only and the subscription is not automatically cancelled. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"expirationDate":{"description":"Subscription expiration date. The setting is for audit purposes only and the subscription is not automatically expired. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"notificationDate":{"description":"Upcoming subscription expiration notification date. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"ownerId":{"description":"The user resource identifier of the subscription owner. The value is a valid relative URL in the format of /users/{userId} where {userId} is a user identifier.","type":"string"},"primaryKey":{"description":"Subscription primary key. This property will not be filled on 'GET' operations! Use '/listSecrets' POST request to get the value.","maxLength":256,"minLength":1,"type":"string","x-ms-secret":true},"scope":{"description":"Scope like /products/{productId} or /apis or /apis/{apiId}.","type":"string"},"secondaryKey":{"description":"Subscription secondary key. This property will not be filled on 'GET' operations! Use '/listSecrets' POST request to get the value.","maxLength":256,"minLength":1,"type":"string","x-ms-secret":true},"startDate":{"description":"Subscription activation date. The setting is for audit purposes only and the subscription is not automatically activated. The subscription lifecycle can be managed by using the `state` property. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.\n","format":"date-time","type":"string"},"state":{"description":"Subscription state. Possible states are * active – the subscription is active, * suspended – the subscription is blocked, and the subscriber cannot call any APIs of the product, * submitted – the subscription request has been made by the developer, but has not yet been approved or rejected, * rejected – the subscription request has been denied by an administrator, * cancelled – the subscription has been cancelled by the developer or administrator, * expired – the subscription reached its expiration date and was deactivated.","enum":["suspended","active","expired","submitted","rejected","cancelled"],"type":"string","x-ms-enum":{"modelAsString":false,"name":"SubscriptionState"}},"stateComment":{"description":"Optional subscription comment added by an administrator.","type":"string"}},"required":["scope","state"]}}},"examples":{"ApiManagementCreateSubscription":{"$ref":"#/components/examples/ApiManagementCreateSubscription"}}}}},"default":{"description":"Error response describing why the operation failed.","content":{"application/json":{"schema":{"description":"Error Response.","properties":{"error":{"description":"Error Body contract.","properties":{"code":{"description":"Service-defined error code. This code serves as a sub-status for the HTTP error code specified in the response.","type":"string"},"details":{"description":"The list of invalid fields send in request, in case of validation error.","items":{"description":"Error Field contract.","properties":{"code":{"description":"Property level error code.","type":"string"},"message":{"description":"Human-readable representation of property-level error.","type":"string"},"target":{"description":"Property name.","type":"string"}}},"type":"array"},"message":{"description":"Human-readable representation of the error.","type":"string"}}}}}}}}},"tags":["Subscription"]}},"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/subscriptions/{sid}/listSecrets":{"post":{"description":"Gets the subscription keys.","operationId":"Subscription_ListSecrets","parameters":[{"description":"The name of the resource group.","in":"path","name":"resourceGroupName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string"},"examples":{"ApiManagementListSecretsSubscription":{"value":"rg1"}}},{"description":"The name of the API Management service.","in":"path","name":"serviceName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","minLength":1,"maxLength":50,"pattern":"^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$"},"examples":{"ApiManagementListSecretsSubscription":{"value":"apimService1"}}},{"description":"Subscription entity Identifier. The entity represents the association between a user and a product in API Management.","in":"path","name":"sid","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","maxLength":256,"pattern":"^[^*#&+:<>?]+$"},"examples":{"ApiManagementListSecretsSubscription":{"value":"5931a769d8d14f0ad8ce13b8"}}},{"description":"Version of the API to be used with the client request.","in":"query","name":"api-version","required":true,"schema":{"type":"string"},"examples":{"ApiManagementListSecretsSubscription":{"value":"2019-12-01-preview"}}},{"description":"Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.","in":"path","name":"subscriptionId","required":true,"schema":{"type":"string"},"examples":{"ApiManagementListSecretsSubscription":{"value":"subid"}}}],"responses":{"200":{"description":"The response body contains subscription keys.","content":{"application/json":{"schema":{"description":"Subscription keys.","properties":{"primaryKey":{"description":"Subscription primary key.","maxLength":256,"minLength":1,"type":"string"},"secondaryKey":{"description":"Subscription secondary key.","maxLength":256,"minLength":1,"type":"string"}}},"examples":{"ApiManagementListSecretsSubscription":{"$ref":"#/components/examples/ApiManagementListSecretsSubscription"}}}}},"default":{"description":"Error response describing why the operation failed.","content":{"application/json":{"schema":{"description":"Error Response.","properties":{"error":{"description":"Error Body contract.","properties":{"code":{"description":"Service-defined error code. This code serves as a sub-status for the HTTP error code specified in the response.","type":"string"},"details":{"description":"The list of invalid fields send in request, in case of validation error.","items":{"description":"Error Field contract.","properties":{"code":{"description":"Property level error code.","type":"string"},"message":{"description":"Human-readable representation of property-level error.","type":"string"},"target":{"description":"Property name.","type":"string"}}},"type":"array"},"message":{"description":"Human-readable representation of the error.","type":"string"}}}}}}}}},"tags":["Subscription"]}},"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/subscriptions/{sid}/regeneratePrimaryKey":{"post":{"description":"Regenerates primary key of existing subscription of the API Management service instance.","operationId":"Subscription_RegeneratePrimaryKey","parameters":[{"description":"The name of the resource group.","in":"path","name":"resourceGroupName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string"},"examples":{"ApiManagementSubscriptionRegeneratePrimaryKey":{"value":"rg1"}}},{"description":"The name of the API Management service.","in":"path","name":"serviceName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","minLength":1,"maxLength":50,"pattern":"^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$"},"examples":{"ApiManagementSubscriptionRegeneratePrimaryKey":{"value":"apimService1"}}},{"description":"Subscription entity Identifier. The entity represents the association between a user and a product in API Management.","in":"path","name":"sid","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","maxLength":256,"pattern":"^[^*#&+:<>?]+$"},"examples":{"ApiManagementSubscriptionRegeneratePrimaryKey":{"value":"testsub"}}},{"description":"Version of the API to be used with the client request.","in":"query","name":"api-version","required":true,"schema":{"type":"string"},"examples":{"ApiManagementSubscriptionRegeneratePrimaryKey":{"value":"2019-12-01-preview"}}},{"description":"Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.","in":"path","name":"subscriptionId","required":true,"schema":{"type":"string"},"examples":{"ApiManagementSubscriptionRegeneratePrimaryKey":{"value":"subid"}}}],"responses":{"204":{"description":"The primary key was successfully regenerated."},"default":{"description":"Error response describing why the operation failed.","content":{"application/json":{"schema":{"description":"Error Response.","properties":{"error":{"description":"Error Body contract.","properties":{"code":{"description":"Service-defined error code. This code serves as a sub-status for the HTTP error code specified in the response.","type":"string"},"details":{"description":"The list of invalid fields send in request, in case of validation error.","items":{"description":"Error Field contract.","properties":{"code":{"description":"Property level error code.","type":"string"},"message":{"description":"Human-readable representation of property-level error.","type":"string"},"target":{"description":"Property name.","type":"string"}}},"type":"array"},"message":{"description":"Human-readable representation of the error.","type":"string"}}}}}}}}},"tags":["Subscription"]}},"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/subscriptions/{sid}/regenerateSecondaryKey":{"post":{"description":"Regenerates secondary key of existing subscription of the API Management service instance.","operationId":"Subscription_RegenerateSecondaryKey","parameters":[{"description":"The name of the resource group.","in":"path","name":"resourceGroupName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string"},"examples":{"ApiManagementSubscriptionRegenerateSecondaryKey":{"value":"rg1"}}},{"description":"The name of the API Management service.","in":"path","name":"serviceName","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","minLength":1,"maxLength":50,"pattern":"^[a-zA-Z](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?$"},"examples":{"ApiManagementSubscriptionRegenerateSecondaryKey":{"value":"apimService1"}}},{"description":"Subscription entity Identifier. The entity represents the association between a user and a product in API Management.","in":"path","name":"sid","required":true,"x-ms-parameter-location":"method","schema":{"type":"string","maxLength":256,"pattern":"^[^*#&+:<>?]+$"},"examples":{"ApiManagementSubscriptionRegenerateSecondaryKey":{"value":"testsub"}}},{"description":"Version of the API to be used with the client request.","in":"query","name":"api-version","required":true,"schema":{"type":"string"},"examples":{"ApiManagementSubscriptionRegenerateSecondaryKey":{"value":"2019-12-01-preview"}}},{"description":"Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.","in":"path","name":"subscriptionId","required":true,"schema":{"type":"string"},"examples":{"ApiManagementSubscriptionRegenerateSecondaryKey":{"value":"subid"}}}],"responses":{"204":{"description":"The secondary key was successfully regenerated."},"default":{"description":"Error response describing why the operation failed.","content":{"application/json":{"schema":{"description":"Error Response.","properties":{"error":{"description":"Error Body contract.","properties":{"code":{"description":"Service-defined error code. This code serves as a sub-status for the HTTP error code specified in the response.","type":"string"},"details":{"description":"The list of invalid fields send in request, in case of validation error.","items":{"description":"Error Field contract.","properties":{"code":{"description":"Property level error code.","type":"string"},"message":{"description":"Human-readable representation of property-level error.","type":"string"},"target":{"description":"Property name.","type":"string"}}},"type":"array"},"message":{"description":"Human-readable representation of the error.","type":"string"}}}}}}}}},"tags":["Subscription"]}}},"servers":[{"url":"https://management.azure.com"}],"components":{"examples":{"ApiManagementListSubscriptions":{"value":{"nextLink":"","value":[{"id":"/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.ApiManagement/service/apimService1/subscriptions/5600b59475ff190048070001","name":"5600b59475ff190048070001","properties":{"createdDate":"2015-09-22T01:57:40.3Z","ownerId":"/subscriptions/subid/resourceGroups/rg1/p