Subscription interface
Interface representing a Subscription.
Methods
Method Details
createOrUpdate(string, string, string, SubscriptionCreateParameters, SubscriptionCreateOrUpdateOptionalParams)
Creates or updates the subscription of specified user to the specified product.
function createOrUpdate(resourceGroupName: string, serviceName: string, sid: string, parameters: SubscriptionCreateParameters, options?: SubscriptionCreateOrUpdateOptionalParams): Promise<SubscriptionCreateOrUpdateResponse>
Parameters
- resourceGroupName
-
string
The name of the resource group. The name is case insensitive.
- serviceName
-
string
The name of the API Management service.
- sid
-
string
Subscription entity Identifier. The entity represents the association between a user and a product in API Management.
- parameters
- SubscriptionCreateParameters
Create parameters.
The options parameters.
Returns
Promise<SubscriptionCreateOrUpdateResponse>
delete(string, string, string, string, SubscriptionDeleteOptionalParams)
Deletes the specified subscription.
function delete(resourceGroupName: string, serviceName: string, sid: string, ifMatch: string, options?: SubscriptionDeleteOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group. The name is case insensitive.
- serviceName
-
string
The name of the API Management service.
- sid
-
string
Subscription entity Identifier. The entity represents the association between a user and a product in API Management.
- ifMatch
-
string
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.
- options
- SubscriptionDeleteOptionalParams
The options parameters.
Returns
Promise<void>
get(string, string, string, SubscriptionGetOptionalParams)
Gets the specified Subscription entity.
function get(resourceGroupName: string, serviceName: string, sid: string, options?: SubscriptionGetOptionalParams): Promise<SubscriptionGetResponse>
Parameters
- resourceGroupName
-
string
The name of the resource group. The name is case insensitive.
- serviceName
-
string
The name of the API Management service.
- sid
-
string
Subscription entity Identifier. The entity represents the association between a user and a product in API Management.
- options
- SubscriptionGetOptionalParams
The options parameters.
Returns
Promise<SubscriptionGetResponse>
getEntityTag(string, string, string, SubscriptionGetEntityTagOptionalParams)
Gets the entity state (Etag) version of the apimanagement subscription specified by its identifier.
function getEntityTag(resourceGroupName: string, serviceName: string, sid: string, options?: SubscriptionGetEntityTagOptionalParams): Promise<SubscriptionGetEntityTagHeaders>
Parameters
- resourceGroupName
-
string
The name of the resource group. The name is case insensitive.
- serviceName
-
string
The name of the API Management service.
- sid
-
string
Subscription entity Identifier. The entity represents the association between a user and a product in API Management.
The options parameters.
Returns
Promise<SubscriptionGetEntityTagHeaders>
list(string, string, SubscriptionListOptionalParams)
Lists all subscriptions of the API Management service instance.
function list(resourceGroupName: string, serviceName: string, options?: SubscriptionListOptionalParams): PagedAsyncIterableIterator<SubscriptionContract, SubscriptionContract[], PageSettings>
Parameters
- resourceGroupName
-
string
The name of the resource group. The name is case insensitive.
- serviceName
-
string
The name of the API Management service.
- options
- SubscriptionListOptionalParams
The options parameters.
Returns
listSecrets(string, string, string, SubscriptionListSecretsOptionalParams)
Gets the specified Subscription keys.
function listSecrets(resourceGroupName: string, serviceName: string, sid: string, options?: SubscriptionListSecretsOptionalParams): Promise<SubscriptionListSecretsResponse>
Parameters
- resourceGroupName
-
string
The name of the resource group. The name is case insensitive.
- serviceName
-
string
The name of the API Management service.
- sid
-
string
Subscription entity Identifier. The entity represents the association between a user and a product in API Management.
The options parameters.
Returns
Promise<SubscriptionListSecretsResponse>
regeneratePrimaryKey(string, string, string, SubscriptionRegeneratePrimaryKeyOptionalParams)
Regenerates primary key of existing subscription of the API Management service instance.
function regeneratePrimaryKey(resourceGroupName: string, serviceName: string, sid: string, options?: SubscriptionRegeneratePrimaryKeyOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group. The name is case insensitive.
- serviceName
-
string
The name of the API Management service.
- sid
-
string
Subscription entity Identifier. The entity represents the association between a user and a product in API Management.
The options parameters.
Returns
Promise<void>
regenerateSecondaryKey(string, string, string, SubscriptionRegenerateSecondaryKeyOptionalParams)
Regenerates secondary key of existing subscription of the API Management service instance.
function regenerateSecondaryKey(resourceGroupName: string, serviceName: string, sid: string, options?: SubscriptionRegenerateSecondaryKeyOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group. The name is case insensitive.
- serviceName
-
string
The name of the API Management service.
- sid
-
string
Subscription entity Identifier. The entity represents the association between a user and a product in API Management.
The options parameters.
Returns
Promise<void>
update(string, string, string, string, SubscriptionUpdateParameters, SubscriptionUpdateOptionalParams)
Updates the details of a subscription specified by its identifier.
function update(resourceGroupName: string, serviceName: string, sid: string, ifMatch: string, parameters: SubscriptionUpdateParameters, options?: SubscriptionUpdateOptionalParams): Promise<SubscriptionUpdateResponse>
Parameters
- resourceGroupName
-
string
The name of the resource group. The name is case insensitive.
- serviceName
-
string
The name of the API Management service.
- sid
-
string
Subscription entity Identifier. The entity represents the association between a user and a product in API Management.
- ifMatch
-
string
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.
- parameters
- SubscriptionUpdateParameters
Update parameters.
- options
- SubscriptionUpdateOptionalParams
The options parameters.
Returns
Promise<SubscriptionUpdateResponse>