Skip to main content

authorization_server

Creates, updates, deletes, gets or lists an authorization_server resource.

Overview

Nameauthorization_server
TypeResource
Idazure.api_management.authorization_server

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringFully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}.
namestringThe name of the resource.
authorizationEndpointstringOAuth authorization endpoint. See http://tools.ietf.org/html/rfc6749#section-3.2 _. Required.
authorizationMethodsarrayHTTP verbs supported by the authorization endpoint. GET must be always present. POST is optional.
bearerTokenSendingMethodsarraySpecifies the mechanism by which access token is passed to the API.
clientAuthenticationMethodarrayMethod of authentication supported by the token endpoint of this authorization server. Possible values are Basic and/or Body. When Body is specified, client credentials and other parameters are passed within the request body in the application/x-www-form-urlencoded format.
clientIdstringClient or app id registered with this authorization server. Required.
clientRegistrationEndpointstringOptional reference to a page where client or app registration for this authorization server is performed. Contains absolute URL to entity being referenced. Required.
clientSecretstringClient or app secret registered with this authorization server. This property will not be filled on 'GET' operations! Use '/listSecrets' POST request to get the value.
defaultScopestringAccess token scope that is going to be requested by default. Can be overridden at the API level. Should be provided in the form of a string containing space-delimited values.
descriptionstringDescription of the authorization server. Can contain HTML formatting tags.
displayNamestringUser-friendly authorization server name. Required.
grantTypesarrayForm of an authorization grant, which the client uses to request the access token. Required.
resourceOwnerPasswordstringCan be optionally specified when resource owner password grant type is supported by this authorization server. Default resource owner password.
resourceOwnerUsernamestringCan be optionally specified when resource owner password grant type is supported by this authorization server. Default resource owner username.
supportStatebooleanIf true, authorization server will include state parameter from the authorization request to its response. Client may use state parameter to raise protocol security.
systemDataobjectAzure Resource Manager metadata containing createdBy and modifiedBy information.
tokenBodyParametersarrayAdditional parameters required by the token endpoint of this authorization server represented as an array of JSON objects with name and value string properties, i.e. {"name" : "name value", "value": "a value"}.
tokenEndpointstringOAuth token endpoint. Contains absolute URI to entity being referenced.
typestringThe type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts".
useInApiDocumentationbooleanIf true, the authorization server will be used in the API documentation in the developer portal. False by default if no value is provided.
useInTestConsolebooleanIf true, the authorization server may be used in the developer portal test console. True by default if no value is provided.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_group_name, service_name, authsid, subscription_idGets the details of the authorization server specified by its identifier.
list_by_serviceselectresource_group_name, service_name, subscription_id$filter, $top, $skipLists a collection of authorization servers defined within a service instance.
create_or_updateinsertresource_group_name, service_name, authsid, subscription_idCreates new authorization server or updates an existing authorization server.
updateupdateresource_group_name, service_name, authsid, subscription_idUpdates the details of the authorization server specified by its identifier.
create_or_updatereplaceresource_group_name, service_name, authsid, subscription_idCreates new authorization server or updates an existing authorization server.
deletedeleteresource_group_name, service_name, authsid, subscription_idDeletes specific authorization server instance.
get_entity_tagexecresource_group_name, service_name, authsid, subscription_idGets the entity state (Etag) version of the authorizationServer specified by its identifier.
list_secretsexecresource_group_name, service_name, authsid, subscription_idGets the client secret details of the authorization server.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
authsidstringIdentifier of the authorization server. Required.
resource_group_namestringThe name of the resource group. The name is case insensitive. Required.
service_namestringThe name of the API Management service. Required.
subscription_idstring
$filterstring| Field | Usage | Supported operators | Supported functions ||-------------|-------------|-------------|-------------|| name | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith || displayName | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith |. Default value is None.
$skipintegerNumber of records to skip. Default value is None.
$topintegerNumber of records to return. Default value is None.

SELECT examples

Gets the details of the authorization server specified by its identifier.

SELECT
id,
name,
authorizationEndpoint,
authorizationMethods,
bearerTokenSendingMethods,
clientAuthenticationMethod,
clientId,
clientRegistrationEndpoint,
clientSecret,
defaultScope,
description,
displayName,
grantTypes,
resourceOwnerPassword,
resourceOwnerUsername,
supportState,
systemData,
tokenBodyParameters,
tokenEndpoint,
type,
useInApiDocumentation,
useInTestConsole
FROM azure.api_management.authorization_server
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND service_name = '{{ service_name }}' -- required
AND authsid = '{{ authsid }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;

INSERT examples

Creates new authorization server or updates an existing authorization server.

INSERT INTO azure.api_management.authorization_server (
properties,
resource_group_name,
service_name,
authsid,
subscription_id
)
SELECT
'{{ properties }}',
'{{ resource_group_name }}',
'{{ service_name }}',
'{{ authsid }}',
'{{ subscription_id }}'
RETURNING
id,
name,
properties,
systemData,
type
;

UPDATE examples

Updates the details of the authorization server specified by its identifier.

UPDATE azure.api_management.authorization_server
SET
properties = '{{ properties }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND service_name = '{{ service_name }}' --required
AND authsid = '{{ authsid }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
properties,
systemData,
type;

REPLACE examples

Creates new authorization server or updates an existing authorization server.

REPLACE azure.api_management.authorization_server
SET
properties = '{{ properties }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND service_name = '{{ service_name }}' --required
AND authsid = '{{ authsid }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
properties,
systemData,
type;

DELETE examples

Deletes specific authorization server instance.

DELETE FROM azure.api_management.authorization_server
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND service_name = '{{ service_name }}' --required
AND authsid = '{{ authsid }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;

Lifecycle Methods

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

EXEC azure.api_management.authorization_server.get_entity_tag 
@resource_group_name='{{ resource_group_name }}' --required,
@service_name='{{ service_name }}' --required,
@authsid='{{ authsid }}' --required,
@subscription_id='{{ subscription_id }}' --required
;