tenant_configuration
Creates, updates, deletes, gets or lists a tenant_configuration resource.
Overview
| Name | tenant_configuration |
| Type | Resource |
| Id | azure.api_management.tenant_configuration |
Fields
The following fields are returned by SELECT queries:
- get_sync_state
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
branch | string | The name of Git branch. |
commitId | string | The latest commit Id. |
configurationChangeDate | string (date-time) | The date of the latest configuration change. The date conforms to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the ISO 8601 standard. |
isExport | boolean | value indicating if last sync was save (true) or deploy (false) operation. |
isGitEnabled | boolean | value indicating whether Git configuration access is enabled. |
isSynced | boolean | value indicating if last synchronization was later than the configuration change. |
lastOperationId | string | Most recent tenant configuration operation identifier. |
syncDate | string (date-time) | The date of the latest synchronization. The date conforms to the following format: yyyy-MM-ddTHH:mm:ssZ as specified by the ISO 8601 standard. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_sync_state | select | resource_group_name, service_name, configuration_name, subscription_id | Gets the status of the most recent synchronization between the configuration database and the Git repository. | |
deploy | exec | resource_group_name, service_name, configuration_name, subscription_id | This operation applies changes from the specified Git branch to the configuration database. This is a long running operation and could take several minutes to complete. | |
save | exec | resource_group_name, service_name, configuration_name, subscription_id | This operation creates a commit with the current configuration snapshot to the specified branch in the repository. This is a long running operation and could take several minutes to complete. | |
validate | exec | resource_group_name, service_name, configuration_name, subscription_id | This operation validates the changes in the specified Git branch. This is a long running operation and could take several minutes to complete. |
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.
| Name | Datatype | Description |
|---|---|---|
configuration_name | 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. "configuration" Required. |
resource_group_name | string | The name of the resource group. The name is case insensitive. Required. |
service_name | string | The name of the API Management service. Required. |
subscription_id | string |
SELECT examples
- get_sync_state
Gets the status of the most recent synchronization between the configuration database and the Git repository.
SELECT
id,
name,
branch,
commitId,
configurationChangeDate,
isExport,
isGitEnabled,
isSynced,
lastOperationId,
syncDate,
systemData,
type
FROM azure.api_management.tenant_configuration
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND service_name = '{{ service_name }}' -- required
AND configuration_name = '{{ configuration_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Lifecycle Methods
- deploy
- save
- validate
This operation applies changes from the specified Git branch to the configuration database. This is a long running operation and could take several minutes to complete.
EXEC azure.api_management.tenant_configuration.deploy
@resource_group_name='{{ resource_group_name }}' --required,
@service_name='{{ service_name }}' --required,
@configuration_name='{{ configuration_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"properties": "{{ properties }}"
}'
;
This operation creates a commit with the current configuration snapshot to the specified branch in the repository. This is a long running operation and could take several minutes to complete.
EXEC azure.api_management.tenant_configuration.save
@resource_group_name='{{ resource_group_name }}' --required,
@service_name='{{ service_name }}' --required,
@configuration_name='{{ configuration_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"properties": "{{ properties }}"
}'
;
This operation validates the changes in the specified Git branch. This is a long running operation and could take several minutes to complete.
EXEC azure.api_management.tenant_configuration.validate
@resource_group_name='{{ resource_group_name }}' --required,
@service_name='{{ service_name }}' --required,
@configuration_name='{{ configuration_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"properties": "{{ properties }}"
}'
;