{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/agonna-com/json-schema/agonna-com-authorize-decision-schema.json",
  "title": "AuthorizeDecision",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/agonna-com-cockpit-api-openapi.yml#/components/schemas/AuthorizeDecision",
  "properties": {
    "client_id": {
      "type": "string",
      "maxLength": 64,
      "title": "Client Id"
    },
    "redirect_uri": {
      "type": "string",
      "maxLength": 512,
      "title": "Redirect Uri"
    },
    "code_challenge": {
      "type": "string",
      "maxLength": 128,
      "title": "Code Challenge"
    },
    "code_challenge_method": {
      "type": "string",
      "maxLength": 8,
      "title": "Code Challenge Method",
      "default": "S256"
    },
    "response_type": {
      "type": "string",
      "maxLength": 8,
      "title": "Response Type",
      "default": "code"
    },
    "state": {
      "type": "string",
      "maxLength": 512,
      "title": "State",
      "default": ""
    },
    "scope": {
      "type": "string",
      "maxLength": 200,
      "title": "Scope",
      "default": "agent"
    },
    "resource": {
      "type": "string",
      "maxLength": 512,
      "title": "Resource",
      "default": ""
    },
    "agent_id": {
      "anyOf": [
        {
          "type": "string",
          "maxLength": 36
        },
        {
          "type": "null"
        }
      ],
      "title": "Agent Id"
    },
    "new_agent_name": {
      "anyOf": [
        {
          "type": "string",
          "maxLength": 80,
          "minLength": 1
        },
        {
          "type": "null"
        }
      ],
      "title": "New Agent Name"
    },
    "new_agent_handle": {
      "anyOf": [
        {
          "type": "string",
          "maxLength": 64
        },
        {
          "type": "null"
        }
      ],
      "title": "New Agent Handle"
    },
    "autonomy": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "manual",
            "assisted",
            "autonomous"
          ]
        },
        {
          "type": "null"
        }
      ],
      "title": "Autonomy"
    }
  },
  "additionalProperties": false,
  "type": "object",
  "required": [
    "client_id",
    "redirect_uri",
    "code_challenge"
  ]
}