Subscription interface

Interface representing a Subscription.

Methods

createOrUpdate(string, string, string, SubscriptionCreateParameters, SubscriptionCreateOrUpdateOptionalParams)

Creates or updates the subscription of specified user to the specified product.

delete(string, string, string, string, SubscriptionDeleteOptionalParams)

Deletes the specified subscription.

get(string, string, string, SubscriptionGetOptionalParams)

Gets the specified Subscription entity.

getEntityTag(string, string, string, SubscriptionGetEntityTagOptionalParams)

Gets the entity state (Etag) version of the apimanagement subscription specified by its identifier.

list(string, string, SubscriptionListOptionalParams)

Lists all subscriptions of the API Management service instance.

listSecrets(string, string, string, SubscriptionListSecretsOptionalParams)

Gets the specified Subscription keys.

regeneratePrimaryKey(string, string, string, SubscriptionRegeneratePrimaryKeyOptionalParams)

Regenerates primary key of existing subscription of the API Management service instance.

regenerateSecondaryKey(string, string, string, SubscriptionRegenerateSecondaryKeyOptionalParams)

Regenerates secondary key of existing subscription of the API Management service instance.

update(string, string, string, string, SubscriptionUpdateParameters, SubscriptionUpdateOptionalParams)

Updates the details of a subscription specified by its identifier.

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.

options
SubscriptionCreateOrUpdateOptionalParams

The options parameters.

Returns

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

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.

options
SubscriptionGetEntityTagOptionalParams

The options parameters.

Returns

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.

options
SubscriptionListSecretsOptionalParams

The options parameters.

Returns

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.

options
SubscriptionRegeneratePrimaryKeyOptionalParams

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.

options
SubscriptionRegenerateSecondaryKeyOptionalParams

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