Power Platform Unified API

Unified RESTful API surface for all Power Platform administrative capabilities including licensing, app management, environment management, and governance. Provides a single endpoint at api.powerplatform.com.

OpenAPI Specification

power-platform-api-openapi.json Raw ↑
{
  "openapi": "3.1.0",
  "info": {
    "title": "Microsoft Power Platform REST API",
    "description": "Unified RESTful API for Microsoft Power Platform administrative capabilities including environment management, application package management, flow run monitoring, and licensing governance. Provides a single endpoint at api.powerplatform.com for programmatic access to Power Platform resources across tenants and environments.",
    "version": "2022-03-01-preview",
    "contact": {
      "name": "Microsoft Power Platform Support",
      "url": "https://admin.powerplatform.microsoft.com/support"
    },
    "license": {
      "name": "Microsoft API Terms of Use",
      "url": "https://learn.microsoft.com/en-us/legal/microsoft-apis/terms-of-use"
    }
  },
  "servers": [
    {
      "url": "https://api.powerplatform.com",
      "description": "Power Platform Unified API endpoint"
    },
    {
      "url": "https://api.bap.microsoft.com",
      "description": "Business Application Platform (BAP) legacy endpoint for environment management"
    }
  ],
  "security": [
    {
      "oauth2": []
    },
    {
      "bearerAuth": []
    }
  ],
  "tags": [
    {
      "name": "Environments",
      "description": "Operations for listing, creating, and managing Power Platform environments. Environments are containers that store apps, flows, data, and other resources."
    },
    {
      "name": "Applications",
      "description": "Operations for managing application packages within Power Platform environments, including listing available packages, installing applications, and checking installation status."
    },
    {
      "name": "Flow Runs",
      "description": "Operations for monitoring and retrieving Power Automate flow run history within environments."
    },
    {
      "name": "Licensing",
      "description": "Operations for managing billing policies and licensing across the Power Platform tenant."
    }
  ],
  "paths": {
    "/providers/Microsoft.BusinessAppPlatform/scopes/admin/environments": {
      "get": {
        "operationId": "listEnvironments",
        "summary": "List Environments",
        "description": "Retrieves a list of all Power Platform environments for the tenant. The response includes environment properties such as display name, location, SKU type, provisioning state, capacity, linked Dataverse metadata, and runtime endpoints. Requires tenant admin or Power Platform admin permissions.",
        "tags": [
          "Environments"
        ],
        "parameters": [
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2020-10-01"
            },
            "description": "The API version to use for this request."
          },
          {
            "name": "$expand",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "examples": [
                "properties.capacity,properties.addons"
              ]
            },
            "description": "Comma-separated list of related properties to expand. Supported values include properties.capacity and properties.addons."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of environments for the tenant.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EnvironmentListResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized. The request requires valid authentication credentials."
          },
          "403": {
            "description": "Forbidden. The caller does not have sufficient permissions."
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      }
    },
    "/providers/Microsoft.BusinessAppPlatform/scopes/admin/environments/{environmentId}": {
      "get": {
        "operationId": "getEnvironment",
        "summary": "Get Environment",
        "description": "Retrieves details for a specific Power Platform environment by its identifier, including properties, capacity, linked Dataverse metadata, and runtime endpoints.",
        "tags": [
          "Environments"
        ],
        "parameters": [
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The unique identifier of the environment."
          },
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2020-10-01"
            },
            "description": "The API version to use for this request."
          },
          {
            "name": "$expand",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Comma-separated list of related properties to expand."
          }
        ],
        "responses": {
          "200": {
            "description": "The environment resource.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Environment"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized."
          },
          "403": {
            "description": "Forbidden."
          },
          "404": {
            "description": "Environment not found."
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      },
      "delete": {
        "operationId": "deleteEnvironment",
        "summary": "Delete Environment",
        "description": "Deletes a Power Platform environment. This action is irreversible and removes all apps, flows, and data within the environment.",
        "tags": [
          "Environments"
        ],
        "parameters": [
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The unique identifier of the environment to delete."
          },
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2020-10-01"
            },
            "description": "The API version to use for this request."
          }
        ],
        "responses": {
          "202": {
            "description": "Accepted. The environment deletion has been initiated."
          },
          "401": {
            "description": "Unauthorized."
          },
          "403": {
            "description": "Forbidden."
          },
          "404": {
            "description": "Environment not found."
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      }
    },
    "/appmanagement/environments/{environmentId}/applicationPackages": {
      "get": {
        "operationId": "getEnvironmentApplicationPackages",
        "summary": "Get Environment Application Packages",
        "description": "Retrieves the list of application packages available for installation in a specific Power Platform environment. Returns packages with their current installation status, version information, and metadata.",
        "tags": [
          "Applications"
        ],
        "parameters": [
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The unique identifier of the target environment."
          },
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2022-03-01-preview"
            },
            "description": "The API version to use for this request."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of application packages available in the environment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApplicationPackageListResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized."
          },
          "403": {
            "description": "Forbidden."
          },
          "404": {
            "description": "Environment not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      }
    },
    "/appmanagement/environments/{environmentId}/applicationPackages/{applicationPackageId}/install": {
      "post": {
        "operationId": "installApplicationPackage",
        "summary": "Install Application Package",
        "description": "Initiates the installation of a specific application package in the target Power Platform environment. Returns an operation ID that can be used to poll for installation status.",
        "tags": [
          "Applications"
        ],
        "parameters": [
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The unique identifier of the target environment."
          },
          {
            "name": "applicationPackageId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The unique identifier of the application package to install."
          },
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2022-03-01-preview"
            },
            "description": "The API version to use for this request."
          }
        ],
        "responses": {
          "202": {
            "description": "Accepted. The installation has been initiated. Use the returned operation ID to poll for status.",
            "headers": {
              "Location": {
                "description": "URL to poll for the operation status.",
                "schema": {
                  "type": "string",
                  "format": "uri"
                }
              },
              "Retry-After": {
                "description": "Suggested number of seconds to wait before polling for status.",
                "schema": {
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "description": "Bad request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized."
          },
          "403": {
            "description": "Forbidden."
          },
          "404": {
            "description": "Environment or application package not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      }
    },
    "/appmanagement/environments/{environmentId}/operations/{operationId}": {
      "get": {
        "operationId": "getApplicationPackageInstallStatus",
        "summary": "Get Application Package Install Status",
        "description": "Retrieves the polling status for a previously triggered application package installation. Use this operation to check whether an install has completed, is still in progress, or has failed.",
        "tags": [
          "Applications"
        ],
        "parameters": [
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The unique identifier of the target environment."
          },
          {
            "name": "operationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The unique identifier of the installation operation."
          },
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2022-03-01-preview"
            },
            "description": "The API version to use for this request."
          }
        ],
        "responses": {
          "200": {
            "description": "The operation status.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperationStatus"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized."
          },
          "403": {
            "description": "Forbidden."
          },
          "404": {
            "description": "Operation not found.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      }
    },
    "/appmanagement/applicationPackages": {
      "get": {
        "operationId": "getTenantApplicationPackages",
        "summary": "Get Tenant Application Packages",
        "description": "Lists the installable application packages available for the tenant. Returns Microsoft-provided application packages that can be deployed to environments.",
        "tags": [
          "Applications"
        ],
        "parameters": [
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2022-03-01-preview"
            },
            "description": "The API version to use for this request."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of application packages available for the tenant.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApplicationPackageListResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized."
          },
          "403": {
            "description": "Forbidden."
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      }
    },
    "/powerautomate/environments/{environmentId}/flowRuns": {
      "get": {
        "operationId": "listFlowRuns",
        "summary": "List Flow Runs",
        "description": "Retrieves flow runs by workflow ID for a specific Power Platform environment. Returns a list of flow run records including their status, start time, end time, and trigger information. The environment must have a Microsoft Dataverse database.",
        "tags": [
          "Flow Runs"
        ],
        "parameters": [
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The unique identifier of the environment."
          },
          {
            "name": "workflowId",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The workflow ID to retrieve flow runs for."
          },
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2022-03-01-preview"
            },
            "description": "The API version to use for this request."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of flow runs matching the workflow ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FlowRunListResponse"
                }
              }
            }
          },
          "204": {
            "description": "No content. No matching flow runs found."
          },
          "400": {
            "description": "Bad request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized."
          },
          "403": {
            "description": "Forbidden."
          },
          "404": {
            "description": "Not found. Environment does not have a Microsoft Dataverse database.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error."
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      }
    },
    "/licensing/billingPolicies": {
      "get": {
        "operationId": "listBillingPolicies",
        "summary": "List Billing Policies",
        "description": "Retrieves the list of billing policies configured for the tenant. Billing policies define the association between Azure subscriptions and Power Platform environments for pay-as-you-go billing.",
        "tags": [
          "Licensing"
        ],
        "parameters": [
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2022-03-01-preview"
            },
            "description": "The API version to use for this request."
          },
          {
            "name": "$top",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer"
            },
            "description": "The maximum number of billing policies to return."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of billing policies for the tenant.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BillingPolicyListResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad request."
          },
          "401": {
            "description": "Unauthorized."
          },
          "403": {
            "description": "Forbidden."
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      },
      "post": {
        "operationId": "createBillingPolicy",
        "summary": "Create Billing Policy",
        "description": "Creates a new billing policy that links a Power Platform environment to an Azure subscription for pay-as-you-go billing.",
        "tags": [
          "Licensing"
        ],
        "parameters": [
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2022-03-01-preview"
            },
            "description": "The API version to use for this request."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BillingPolicyCreateRequest"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The billing policy was created successfully.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BillingPolicy"
                }
              }
            }
          },
          "400": {
            "description": "Bad request."
          },
          "401": {
            "description": "Unauthorized."
          },
          "403": {
            "description": "Forbidden."
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      }
    },
    "/licensing/billingPolicies/{billingPolicyId}": {
      "get": {
        "operationId": "getBillingPolicy",
        "summary": "Get Billing Policy",
        "description": "Retrieves details for a specific billing policy by its identifier.",
        "tags": [
          "Licensing"
        ],
        "parameters": [
          {
            "name": "billingPolicyId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The unique identifier of the billing policy."
          },
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2022-03-01-preview"
            },
            "description": "The API version to use for this request."
          }
        ],
        "responses": {
          "200": {
            "description": "The billing policy resource.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BillingPolicy"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized."
          },
          "403": {
            "description": "Forbidden."
          },
          "404": {
            "description": "Billing policy not found."
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      },
      "patch": {
        "operationId": "updateBillingPolicy",
        "summary": "Update Billing Policy",
        "description": "Updates an existing billing policy with new values.",
        "tags": [
          "Licensing"
        ],
        "parameters": [
          {
            "name": "billingPolicyId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The unique identifier of the billing policy to update."
          },
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2022-03-01-preview"
            },
            "description": "The API version to use for this request."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BillingPolicyUpdateRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The billing policy was updated successfully.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BillingPolicy"
                }
              }
            }
          },
          "400": {
            "description": "Bad request."
          },
          "401": {
            "description": "Unauthorized."
          },
          "403": {
            "description": "Forbidden."
          },
          "404": {
            "description": "Billing policy not found."
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      },
      "delete": {
        "operationId": "deleteBillingPolicy",
        "summary": "Delete Billing Policy",
        "description": "Deletes a billing policy by its identifier.",
        "tags": [
          "Licensing"
        ],
        "parameters": [
          {
            "name": "billingPolicyId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            },
            "description": "The unique identifier of the billing policy to delete."
          },
          {
            "name": "api-version",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2022-03-01-preview"
            },
            "description": "The API version to use for this request."
          }
        ],
        "responses": {
          "204": {
            "description": "The billing policy was deleted successfully."
          },
          "401": {
            "description": "Unauthorized."
          },
          "403": {
            "description": "Forbidden."
          },
          "404": {
            "description": "Billing policy not found."
          }
        },
        "x-microcks-operation": {
          "delay": 0,
          "dispatcher": "FALLBACK"
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "oauth2": {
        "type": "oauth2",
        "description": "Microsoft Entra ID OAuth 2.0 authentication. Register your application and obtain tokens via the Microsoft identity platform.",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/v2.0/authorize",
            "tokenUrl": "https://login.microsoftonline.com/common/oauth2/v2.0/token",
            "scopes": {
              "https://api.powerplatform.com/.default": "Access Power Platform API resources"
            }
          },
          "clientCredentials": {
            "tokenUrl": "https://login.microsoftonline.com/{tenantId}/oauth2/v2.0/token",
            "scopes": {
              "https://api.powerplatform.com/.default": "Access Power Platform API resources as a service principal"
            }
          }
        }
      },
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT",
        "description": "Bearer token obtained from Microsoft Entra ID OAuth 2.0 flow."
      }
    },
    "schemas": {
      "EnvironmentListResponse": {
        "type": "object",
        "description": "Response containing a list of Power Platform environments.",
        "properties": {
          "value": {
            "type": "array",
            "description": "Array of environment resources.",
            "items": {
              "$ref": "#/components/schemas/Environment"
            },
            "example": []
          }
        }
      },
      "Environment": {
        "type": "object",
        "description": "A Power Platform environment resource. Environments are containers that store apps, flows, data, and other resources.",
        "properties": {
          "id": {
            "type": "string",
            "description": "The fully qualified resource ID of the environment.",
            "examples": [
              "/providers/Microsoft.BusinessAppPlatform/scopes/admin/environments/aaaabbbb-0000-cccc-1111-dddd2222eeee"
            ]
          },
          "type": {
            "type": "string",
            "description": "The resource type.",
            "examples": [
              "Microsoft.BusinessAppPlatform/scopes/environments"
            ]
          },
          "location": {
            "type": "string",
            "description": "The geographic location of the environment.",
            "examples": [
              "unitedstates",
              "europe",
              "asia"
            ]
          },
          "name": {
            "type": "string",
            "format": "uuid",
            "description": "The environment identifier (GUID).",
            "example": "Example Title"
          },
          "properties": {
            "$ref": "#/components/schemas/EnvironmentProperties"
          }
        }
      },
      "EnvironmentProperties": {
        "type": "object",
        "description": "Properties of a Power Platform environment.",
        "properties": {
          "azureRegion": {
            "type": "string",
            "description": "The Azure region where the environment is hosted.",
            "examples": [
              "westus",
              "northeurope",
              "eastasia"
            ]
          },
          "displayName": {
            "type": "string",
            "description": "The display name of the environment.",
            "examples": [
              "My Power Platform Environment"
            ]
          },
          "description": {
            "type": [
              "string",
              "null"
            ],
            "description": "A text description of the environment purpose.",
            "example": "A sample description."
          },
          "createdTime": {
            "type": "string",
            "format": "date-time",
            "description": "The timestamp when the environment was created.",
            "example": "2026-01-15T10:30:00Z"
          },
          "createdBy": {
            "$ref": "#/components/schemas/Principal"
          },
          "lastModifiedTime": {
            "type": "string",
            "format": "date-time",
            "description": "The timestamp of the last modification to the environment.",
            "example": "2026-01-15T10:30:00Z"
          },
          "provisioningState": {
            "type": "string",
            "description": "The current provisioning state of the environment.",
            "enum": [
              "Succeeded",
              "Failed",
              "InProgress",
              "Deleting"
            ],
            "example": "Succeeded"
          },
          "creationType": {
            "type": "string",
            "description": "How the environment was created.",
            "enum": [
              "User",
              "System",
              "Developer"
            ],
            "example": "User"
          },
          "environmentSku": {
            "type": "string",
            "description": "The SKU type of the environment.",
            "enum": [
              "Production",
              "Sandbox",
              "Trial",
              "Developer",
              "Default",
              "Teams"
            ],
            "example": "Production"
          },
          "isDefault": {
            "type": "boolean",
            "description": "Whether this is the default environment for the tenant.",
            "example": true
    

# --- truncated at 32 KB (56 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/power-platform/refs/heads/main/openapi/power-platform-api-openapi.json