{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/granite-md/json-schema/granite-md-webhook-create-schema.json",
  "title": "WebhookCreate",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/granite-md-openapi.yaml#/components/schemas/WebhookCreate",
  "type": "object",
  "required": [
    "events"
  ],
  "properties": {
    "kind": {
      "$ref": "#/$defs/IntegrationKind"
    },
    "url": {
      "type": "string",
      "maxLength": 2000,
      "description": "Automation tools: the https URL that starts the workflow (a catch hook), for\ntriggers. Chat apps need none.\n"
    },
    "bot_token": {
      "type": "string",
      "maxLength": 100,
      "description": "`telegram`: the bot's token from @BotFather."
    },
    "chat_id": {
      "type": "string",
      "maxLength": 40,
      "description": "`telegram`: the chat, group, or channel (`-100…` or `@name`) the bot posts to."
    },
    "actions": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/IntegrationAction"
      }
    },
    "folder": {
      "type": "string",
      "maxLength": 200
    },
    "signing_secret": {
      "type": "string",
      "maxLength": 200,
      "description": "`slack`: the app's signing secret (Basic Information); notetakers: the webhook's signing secret."
    },
    "public_key": {
      "type": "string",
      "maxLength": 200,
      "description": "`discord`: the application's public key (hex)."
    },
    "application_id": {
      "type": "string",
      "maxLength": 40,
      "description": "`discord`: the application ID; with `bot_token`, Granite registers the slash commands."
    },
    "inbound_token": {
      "type": "string",
      "maxLength": 200,
      "description": "`teams`: the outgoing webhook's security token; `mattermost`, `rocket_chat`, `zulip`: the webhook's token; `fireflies`, `granola`, `meetgeek`: the API key meetings are fetched with."
    },
    "description": {
      "type": "string",
      "maxLength": 200
    },
    "events": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/WebhookEventType"
      }
    }
  },
  "$defs": {
    "IntegrationAction": {
      "type": "string",
      "description": "What an integration may do: `capture` (plain messages to the inbox note), `create`,\n`append`, `daily` (today's daily note), `search`, `list` (a folder), `read`, `update`\n(replace the text), `move` and `delete` (a note or a whole folder), and `meeting`\n(notetakers only: save each finished meeting as a note).\n",
      "enum": [
        "capture",
        "create",
        "append",
        "daily",
        "search",
        "list",
        "read",
        "update",
        "move",
        "delete",
        "meeting"
      ]
    },
    "IntegrationKind": {
      "type": "string",
      "description": "The connected service. `webhook` is a custom endpoint. AI meeting notetakers\n(`read_ai`, `fathom`, `fireflies`, `tldv`, `otter`, `granola`, `circleback`, `avoma`,\n`meetgeek`) send finished meetings. `google_chat`, `webex`, and `ntfy` could only notify\nand can no longer be added.\n",
      "enum": [
        "slack",
        "teams",
        "mattermost",
        "discord",
        "telegram",
        "rocket_chat",
        "zulip",
        "shortcuts",
        "n8n",
        "pipedream",
        "zapier",
        "make",
        "ifttt",
        "activepieces",
        "power_automate",
        "webhook",
        "read_ai",
        "fathom",
        "fireflies",
        "tldv",
        "otter",
        "granola",
        "circleback",
        "avoma",
        "meetgeek",
        "google_chat",
        "webex",
        "ntfy"
      ]
    },
    "WebhookEventType": {
      "type": "string",
      "enum": [
        "*",
        "note.*",
        "member.*",
        "note.created",
        "note.updated",
        "note.moved",
        "note.deleted",
        "vault.shared",
        "member.added",
        "member.removed",
        "member.role_changed"
      ]
    }
  }
}