Microsoft Azure Subscriptions API

Manage Azure subscriptions

OpenAPI Specification

azure-subscriptions-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: Microsoft Azure Management Resource Groups Subscriptions API
  description: Core Microsoft Azure Resource Manager REST API for subscription, resource group, and resource management across all Azure services.
  version: '2022-09-01'
  x-generated-from: documentation
servers:
- url: https://management.azure.com
  description: Azure Resource Manager
security:
- azure_auth:
  - user_impersonation
tags:
- name: Subscriptions
  description: Manage Azure subscriptions
paths:
  /subscriptions:
    get:
      operationId: Subscriptions_List
      summary: Microsoft Azure Azure Management List Subscriptions
      description: Gets all subscriptions for a tenant.
      tags:
      - Subscriptions
      parameters:
      - name: api-version
        in: query
        required: true
        schema:
          type: string
        example: '2022-09-01'
      responses:
        '200':
          description: List of subscriptions
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SubscriptionListResult'
              examples:
                Subscriptions_List200Example:
                  summary: Default Subscriptions_List 200 response
                  x-microcks-default: true
                  value:
                    id: example-id
                    name: example
                    provisioningState: Succeeded
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /subscriptions/{subscriptionId}:
    get:
      operationId: Subscriptions_Get
      summary: Microsoft Azure Azure Management Get Subscription Details
      description: Gets details about a specified subscription.
      tags:
      - Subscriptions
      parameters:
      - name: subscriptionId
        in: path
        required: true
        schema:
          type: string
        example: 00000000-0000-0000-0000-000000000000
      - name: api-version
        in: query
        required: true
        schema:
          type: string
        example: '2022-09-01'
      responses:
        '200':
          description: Subscription details
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Subscription'
              examples:
                Subscriptions_Get200Example:
                  summary: Default Subscriptions_Get 200 response
                  x-microcks-default: true
                  value:
                    id: example-id
                    name: example
                    provisioningState: Succeeded
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
components:
  schemas:
    SubscriptionListResult:
      type: object
      properties:
        value:
          type: array
          items:
            $ref: '#/components/schemas/Subscription'
        nextLink:
          type: string
    Subscription:
      type: object
      description: Subscription information.
      properties:
        id:
          type: string
          readOnly: true
        subscriptionId:
          type: string
          readOnly: true
        displayName:
          type: string
        state:
          type: string
          enum:
          - Enabled
          - Disabled
          - Deleted
          - PastDue
          - Warned
        subscriptionPolicies:
          type: object
          properties:
            locationPlacementId:
              type: string
            quotaId:
              type: string
            spendingLimit:
              type: string
              enum:
              - true
              - false
              - CurrentPeriodOff
        authorizationSource:
          type: string
        managedByTenants:
          type: array
          items:
            type: object
            properties:
              tenantId:
                type: string
  securitySchemes:
    azure_auth:
      type: oauth2
      flows:
        implicit:
          authorizationUrl: https://login.microsoftonline.com/common/oauth2/authorize
          scopes:
            user_impersonation: Impersonate your user account