{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/scale-ai/json-schema/scale-ai-create-webhook-trigger-response-schema.json",
  "title": "CreateWebhookTriggerResponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/scale-ai-agent-apikeys-api-openapi.yml#/components/schemas/CreateWebhookTriggerResponse",
  "properties": {
    "key_id": {
      "type": "string",
      "title": "Key Id",
      "description": "The created agent API key id."
    },
    "agent_name": {
      "type": "string",
      "title": "Agent Name",
      "description": "The agent the webhook drives."
    },
    "source": {
      "$ref": "#/$defs/AgentAPIKeyType",
      "description": "Webhook source (github or slack)."
    },
    "name": {
      "type": "string",
      "title": "Name",
      "description": "Signature-lookup key (repo full_name / api_app_id)."
    },
    "secret": {
      "type": "string",
      "title": "Secret",
      "description": "The signing secret — shown once; paste into the source's webhook config."
    },
    "webhook_path": {
      "type": "string",
      "title": "Webhook Path",
      "description": "The forward path to POST webhooks to."
    },
    "webhook_url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Webhook Url",
      "description": "Full webhook URL to paste into the source (None if no base URL configured)."
    }
  },
  "type": "object",
  "required": [
    "key_id",
    "agent_name",
    "source",
    "name",
    "secret",
    "webhook_path"
  ],
  "$defs": {
    "AgentAPIKeyType": {
      "type": "string",
      "enum": [
        "internal",
        "external",
        "github",
        "slack"
      ],
      "title": "AgentAPIKeyType"
    }
  }
}