{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "#/components/schemas/PermissionScope",
  "title": "PermissionScope",
  "type": "object",
  "description": "Defines an OAuth 2.0 delegated permission scope exposed by a web API application",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "Unique identifier for the scope",
      "example": "abc123"
    },
    "value": {
      "type": "string",
      "description": "The value that identifies the scope in OAuth 2.0 authorization requests",
      "example": "example_value"
    },
    "type": {
      "type": "string",
      "description": "Whether the scope can be consented to by a user or requires admin consent",
      "enum": [
        "User",
        "Admin"
      ],
      "example": "User"
    },
    "adminConsentDisplayName": {
      "type": "string",
      "description": "Display name shown on the admin consent experience",
      "example": "example_value"
    },
    "adminConsentDescription": {
      "type": "string",
      "description": "Description shown on the admin consent experience",
      "example": "example_value"
    },
    "userConsentDisplayName": {
      "type": [
        "string",
        "null"
      ],
      "description": "Display name shown on the user consent experience",
      "example": "example_value"
    },
    "userConsentDescription": {
      "type": [
        "string",
        "null"
      ],
      "description": "Description shown on the user consent experience",
      "example": "example_value"
    },
    "isEnabled": {
      "type": "boolean",
      "description": "Whether the scope is enabled and can be requested",
      "example": true
    }
  }
}