Share via


WorkspaceApiPolicy interface

Interface representing a WorkspaceApiPolicy.

Methods

createOrUpdate(string, string, string, string, string, PolicyContract, WorkspaceApiPolicyCreateOrUpdateOptionalParams)

Creates or updates policy configuration for the API.

delete(string, string, string, string, string, string, WorkspaceApiPolicyDeleteOptionalParams)

Deletes the policy configuration at the Api.

get(string, string, string, string, string, WorkspaceApiPolicyGetOptionalParams)

Get the policy configuration at the API level.

getEntityTag(string, string, string, string, string, WorkspaceApiPolicyGetEntityTagOptionalParams)

Gets the entity state (Etag) version of the API policy specified by its identifier.

listByApi(string, string, string, string, WorkspaceApiPolicyListByApiOptionalParams)

Get the policy configuration at the API level.

Method Details

createOrUpdate(string, string, string, string, string, PolicyContract, WorkspaceApiPolicyCreateOrUpdateOptionalParams)

Creates or updates policy configuration for the API.

function createOrUpdate(resourceGroupName: string, serviceName: string, workspaceId: string, apiId: string, policyId: string, parameters: PolicyContract, options?: WorkspaceApiPolicyCreateOrUpdateOptionalParams): Promise<WorkspaceApiPolicyCreateOrUpdateResponse>

Parameters

resourceGroupName

string

The name of the resource group. The name is case insensitive.

serviceName

string

The name of the API Management service.

workspaceId

string

Workspace identifier. Must be unique in the current API Management service instance.

apiId

string

API revision identifier. Must be unique in the current API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number.

policyId

string

The identifier of the Policy.

parameters
PolicyContract

The policy contents to apply.

options
WorkspaceApiPolicyCreateOrUpdateOptionalParams

The options parameters.

Returns

delete(string, string, string, string, string, string, WorkspaceApiPolicyDeleteOptionalParams)

Deletes the policy configuration at the Api.

function delete(resourceGroupName: string, serviceName: string, workspaceId: string, apiId: string, policyId: string, ifMatch: string, options?: WorkspaceApiPolicyDeleteOptionalParams): 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.

workspaceId

string

Workspace identifier. Must be unique in the current API Management service instance.

apiId

string

API revision identifier. Must be unique in the current API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number.

policyId

string

The identifier of the Policy.

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
WorkspaceApiPolicyDeleteOptionalParams

The options parameters.

Returns

Promise<void>

get(string, string, string, string, string, WorkspaceApiPolicyGetOptionalParams)

Get the policy configuration at the API level.

function get(resourceGroupName: string, serviceName: string, workspaceId: string, apiId: string, policyId: string, options?: WorkspaceApiPolicyGetOptionalParams): Promise<WorkspaceApiPolicyGetResponse>

Parameters

resourceGroupName

string

The name of the resource group. The name is case insensitive.

serviceName

string

The name of the API Management service.

workspaceId

string

Workspace identifier. Must be unique in the current API Management service instance.

apiId

string

API revision identifier. Must be unique in the current API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number.

policyId

string

The identifier of the Policy.

options
WorkspaceApiPolicyGetOptionalParams

The options parameters.

Returns

getEntityTag(string, string, string, string, string, WorkspaceApiPolicyGetEntityTagOptionalParams)

Gets the entity state (Etag) version of the API policy specified by its identifier.

function getEntityTag(resourceGroupName: string, serviceName: string, workspaceId: string, apiId: string, policyId: string, options?: WorkspaceApiPolicyGetEntityTagOptionalParams): Promise<WorkspaceApiPolicyGetEntityTagHeaders>

Parameters

resourceGroupName

string

The name of the resource group. The name is case insensitive.

serviceName

string

The name of the API Management service.

workspaceId

string

Workspace identifier. Must be unique in the current API Management service instance.

apiId

string

API revision identifier. Must be unique in the current API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number.

policyId

string

The identifier of the Policy.

options
WorkspaceApiPolicyGetEntityTagOptionalParams

The options parameters.

Returns

listByApi(string, string, string, string, WorkspaceApiPolicyListByApiOptionalParams)

Get the policy configuration at the API level.

function listByApi(resourceGroupName: string, serviceName: string, workspaceId: string, apiId: string, options?: WorkspaceApiPolicyListByApiOptionalParams): PagedAsyncIterableIterator<PolicyContract, PolicyContract[], PageSettings>

Parameters

resourceGroupName

string

The name of the resource group. The name is case insensitive.

serviceName

string

The name of the API Management service.

workspaceId

string

Workspace identifier. Must be unique in the current API Management service instance.

apiId

string

API revision identifier. Must be unique in the current API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number.

options
WorkspaceApiPolicyListByApiOptionalParams

The options parameters.

Returns