SubscriptionClient
All resource groups and resources exist within subscriptions
COMMUNITYBEARER0 INSTALLS
OpenAPI Specificationv3.0
{
"swagger": "2.0",
"schemes": [
"https"
],
"host": "management.azure.com",
"info": {
"description": "All resource groups and resources exist within subscriptions. These operation enable you get information about your subscriptions and tenants. A tenant is a dedicated instance of Azure Active Directory (Azure AD) for your organization.",
"title": "SubscriptionClient",
"version": "2019-06-01",
"x-apisguru-categories": [
"cloud"
],
"x-logo": {
"url": "https://api.apis.guru/v2/cache/logo/https_assets.onestore.ms_cdnfiles_onestorerolling-1606-01000_shell_v3_images_logo_microsoft.png"
},
"x-origin": [
{
"format": "swagger",
"url": "https://raw.githubusercontent.com/Azure/azure-rest-api-specs/master/specification/resources/resource-manager/Microsoft.Resources/stable/2019-06-01/subscriptions.json",
"version": "2.0"
}
],
"x-preferred": true,
"x-providerName": "azure.com",
"x-serviceName": "resources-subscriptions",
"x-tags": [
"Azure",
"Microsoft"
]
},
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"securityDefinitions": {
"azure_auth": {
"authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize",
"description": "Azure Active Directory OAuth2 Flow",
"flow": "implicit",
"scopes": {
"user_impersonation": "impersonate your user account"
},
"type": "oauth2"
}
},
"security": [
{
"azure_auth": [
"user_impersonation"
]
}
],
"parameters": {
"ApiVersionParameter": {
"description": "The API version to use for the operation.",
"in": "query",
"name": "api-version",
"required": true,
"type": "string",
"x-ms-parameter-location": "client"
},
"SubscriptionIdParameter": {
"description": "The ID of the target subscription.",
"in": "path",
"name": "subscriptionId",
"required": true,
"type": "string",
"x-ms-parameter-location": "method"
}
},
"paths": {
"/providers/Microsoft.Resources/operations": {
"get": {
"description": "Lists all of the available Microsoft.Resources REST API operations.",
"operationId": "Operations_List",
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
}
],
"responses": {
"200": {
"description": "OK. The request has succeeded.",
"schema": {
"$ref": "#/definitions/OperationListResult"
}
}
},
"tags": [
"Operations"
],
"x-ms-pageable": {
"nextLinkName": "nextLink"
}
}
},
"/subscriptions": {
"get": {
"description": "Gets all subscriptions for a tenant.",
"operationId": "Subscriptions_List",
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
}
],
"responses": {
"200": {
"description": "OK - Returns an array of subscriptions.",
"schema": {
"$ref": "#/definitions/SubscriptionListResult"
}
}
},
"tags": [
"Subscriptions"
],
"x-ms-examples": {
"Get all subscriptions.": {
"parameters": {
"api-version": "2019-06-01"
},
"responses": {
"200": {
"body": {
"nextLink": "...",
"value": [
{
"authorizationSource": "RoleBased",
"displayName": "Example Subscription",
"id": "/subscriptions/291bba3f-e0a5-47bc-a099-3bdcb2a50a05",
"managedByTenants": [
{
"tenantId": "8f70baf1-1f6e-46a2-a1ff-238dac1ebfb7"
}
],
"state": "Enabled",
"subscriptionId": "291bba3f-e0a5-47bc-a099-3bdcb2a50a05",
"subscriptionPolicies": {
"locationPlacementId": "Internal_2014-09-01",
"quotaId": "Internal_2014-09-01",
"spendingLimit": "Off"
},
"tenantId": "31c75423-32d6-4322-88b7-c478bdde4858"
},
{
"authorizationSource": "RoleBased",
"displayName": "Example Subscription2",
"id": "/subscriptions/72ac930a-f34e-42d8-b06d-dc2a9e12ed71",
"managedByTenants": [
{
"tenantId": "8f70baf1-1f6e-46a2-a1ff-238dac1ebfb7"
},
{
"tenantId": "f7fb6af2-321d-47c8-9c0f-b0239eaad39a"
}
],
"state": "Enabled",
"subscriptionId": "72ac930a-f34e-42d8-b06d-dc2a9e12ed71",
"subscriptionPolicies": {
"locationPlacementId": "Internal_2014-09-01",
"quotaId": "Internal_2014-09-01",
"spendingLimit": "Off"
},
"tenantId": "2a0ff0de-96b2-4859-bb7c-a430d07a3e0c"
}
]
}
}
}
}
},
"x-ms-pageable": {
"nextLinkName": "nextLink"
}
}
},
"/subscriptions/{subscriptionId}": {
"get": {
"description": "Gets details about a specified subscription.",
"operationId": "Subscriptions_Get",
"parameters": [
{
"$ref": "#/parameters/SubscriptionIdParameter"
},
{
"$ref": "#/parameters/ApiVersionParameter"
}
],
"responses": {
"200": {
"description": "OK - Returns information about the subscription.",
"schema": {
"$ref": "#/definitions/Subscription"
}
}
},
"tags": [
"Subscriptions"
],
"x-ms-examples": {
"Get a single subscription.": {
"parameters": {
"api-version": "2019-06-01",
"subscriptionId": "291bba3f-e0a5-47bc-a099-3bdcb2a50a05"
},
"responses": {
"200": {
"body": {
"authorizationSource": "Bypassed",
"displayName": "Example Subscription",
"id": "/subscriptions/291bba3f-e0a5-47bc-a099-3bdcb2a50a05",
"managedByTenants": [
{
"tenantId": "8f70baf1-1f6e-46a2-a1ff-238dac1ebfb7"
}
],
"state": "Enabled",
"subscriptionId": "291bba3f-e0a5-47bc-a099-3bdcb2a50a05",
"subscriptionPolicies": {
"locationPlacementId": "Internal_2014-09-01",
"quotaId": "Internal_2014-09-01",
"spendingLimit": "Off"
},
"tenantId": "31c75423-32d6-4322-88b7-c478bdde4858"
}
}
}
}
}
}
},
"/subscriptions/{subscriptionId}/locations": {
"get": {
"description": "This operation provides all the locations that are available for resource providers; however, each resource provider may support a subset of this list.",
"operationId": "Subscriptions_ListLocations",
"parameters": [
{
"$ref": "#/parameters/SubscriptionIdParameter"
},
{
"$ref": "#/parameters/ApiVersionParameter"
}
],
"responses": {
"200": {
"description": "OK - Returns an array of locations.",
"schema": {
"$ref": "#/definitions/LocationListResult"
}
}
},
"summary": "Gets all available geo-locations.",
"tags": [
"Subscriptions"
],
"x-ms-pageable": {
"nextLinkName": null
}
}
},
"/tenants": {
"get": {
"description": "Gets the tenants for your account.",
"operationId": "Tenants_List",
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
}
],
"responses": {
"200": {
"description": "OK - Returns an array of tenants.",
"schema": {
"$ref": "#/definitions/TenantListResult"
}
}
},
"tags": [
"Tenants"
],
"x-ms-pageable": {
"nextLinkName": "nextLink"
}
}
}
},
"definitions": {
"Location": {
"description": "Location information.",
"properties": {
"displayName": {
"description": "The display name of the location.",
"readOnly": true,
"type": "string"
},
"id": {
"description": "The fully qualified ID of the location. For example, /subscriptions/00000000-0000-0000-0000-000000000000/locations/westus.",
"readOnly": true,
"type": "string"
},
"latitude": {
"description": "The latitude of the location.",
"readOnly": true,
"type": "string"
},
"longitude": {
"description": "The longitude of the location.",
"readOnly": true,
"type": "string"
},
"name": {
"description": "The location name.",
"readOnly": true,
"type": "string"
},
"subscriptionId": {
"description": "The subscription ID.",
"readOnly": true,
"type": "string"
}
}
},
"LocationListResult": {
"description": "Location list operation response.",
"properties": {
"value": {
"description": "An array of locations.",
"items": {
"$ref": "#/definitions/Location"
},
"type": "array"
}
}
},
"ManagedByTenant": {
"description": "Information about a tenant managing the subscription.",
"properties": {
"tenantId": {
"description": "The tenant ID of the managing tenant. This is a GUID.",
"readOnly": true,
"type": "string"
}
}
},
"Operation": {
"description": "Microsoft.Resources operation",
"properties": {
"display": {
"description": "The object that represents the operation.",
"properties": {
"description": {
"description": "Description of the operation.",
"type": "string"
},
"operation": {
"description": "Operation type: Read, write, delete, etc.",
"type": "string"
},
"provider": {
"description": "Service provider: Microsoft.Resources",
"type": "string"
},
"resource": {
"description": "Resource on which the operation is performed: Profile, endpoint, etc.",
"type": "string"
}
}
},
"name": {
"description": "Operation name: {provider}/{resource}/{operation}",
"type": "string"
}
},
"type": "object"
},
"OperationListResult": {
"description": "Result of the request to list Microsoft.Resources operations. It contains a list of operations and a URL link to get the next set of results.",
"properties": {
"nextLink": {
"description": "URL to get the next set of operation list results if there are any.",
"type": "string"
},
"value": {
"description": "List of Microsoft.Resources operations.",
"items": {
"$ref": "#/definitions/Operation"
},
"type": "array"
}
}
},
"Subscription": {
"description": "Subscription information.",
"properties": {
"authorizationSource": {
"description": "The authorization source of the request. Valid values are one or more combinations of Legacy, RoleBased, Bypassed, Direct and Management. For example, 'Legacy, RoleBased'.",
"type": "string"
},
"displayName": {
"description": "The subscription display name.",
"readOnly": true,
"type": "string"
},
"id": {
"description": "The fully qualified ID for the subscription. For example, /subscriptions/00000000-0000-0000-0000-000000000000.",
"readOnly": true,
"type": "string"
},
"managedByTenants": {
"description": "An array containing the tenants managing the subscription.",
"items": {
"$ref": "#/definitions/ManagedByTenant"
},
"type": "array"
},
"state": {
"description": "The subscription state. Possible values are Enabled, Warned, PastDue, Disabled, and Deleted.",
"enum": [
"Enabled",
"Warned",
"PastDue",
"Disabled",
"Deleted"
],
"readOnly": true,
"type": "string",
"x-ms-enum": {
"modelAsString": false,
"name": "SubscriptionState"
}
},
"subscriptionId": {
"description": "The subscription ID.",
"readOnly": true,
"type": "string"
},
"subscriptionPolicies": {
"$ref": "#/definitions/SubscriptionPolicies",
"description": "The subscription policies."
},
"tenantId": {
"description": "The subscription tenant ID.",
"readOnly": true,
"type": "string"
}
}
},
"SubscriptionListResult": {
"description": "Subscription list operation response.",
"properties": {
"nextLink": {
"description": "The URL to get the next set of results.",
"type": "string"
},
"value": {
"description": "An array of subscriptions.",
"items": {
"$ref": "#/definitions/Subscription"
},
"type": "array"
}
},
"required": [
"nextLink"
]
},
"SubscriptionPolicies": {
"description": "Subscription policies.",
"properties": {
"locationPlacementId": {
"description": "The subscription location placement ID. The ID indicates which regions are visible for a subscription. For example, a subscription with a location placement Id of Public_2014-09-01 has access to Azure public regions.",
"readOnly": true,
"type": "string"
},
"quotaId": {
"description": "The subscription quota ID.",
"readOnly": true,
"type": "string"
},
"spendingLimit": {
"description": "The subscription spending limit.",
"enum": [
"On",
"Off",
"CurrentPeriodOff"
],
"readOnly": true,
"type": "string",
"x-ms-enum": {
"modelAsString": false,
"name": "spendingLimit"
}
}
}
},
"TenantIdDescription": {
"description": "Tenant Id information.",
"properties": {
"id": {
"description": "The fully qualified ID of the tenant. For example, /tenants/00000000-0000-0000-0000-000000000000.",
"readOnly": true,
"type": "string"
},
"tenantId": {
"description": "The tenant ID. For example, 00000000-0000-0000-0000-000000000000.",
"readOnly": true,
"type": "string"
}
}
},
"TenantListResult": {
"description": "Tenant Ids information.",
"properties": {
"nextLink": {
"description": "The URL to use for getting the next set of results.",
"type": "string"
},
"value": {
"description": "An array of tenants.",
"items": {
"$ref": "#/definitions/TenantIdDescription"
},
"type": "array"
}
},
"required": [
"nextLink"
]
}
}
}