{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/nautilinks-co/json-schema/nautilinks-co-create-webhook-response-schema.json",
  "title": "CreateWebhookResponse",
  "x-generated": "2026-11-19",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/nautilinks-co-openapi.json#/components/schemas/CreateWebhookResponse",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "ok",
    "id",
    "url",
    "events",
    "secret",
    "signing_key_derivation",
    "created_at"
  ],
  "properties": {
    "ok": {
      "type": "boolean",
      "const": true
    },
    "id": {
      "type": "string"
    },
    "url": {
      "type": "string",
      "format": "uri"
    },
    "events": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/WebhookEvent"
      }
    },
    "secret": {
      "type": "string",
      "description": "One-time secret; store it immediately."
    },
    "signing_key_derivation": {
      "type": "string",
      "const": "hex(sha256(secret))"
    },
    "created_at": {
      "type": "string"
    }
  },
  "$defs": {
    "WebhookEvent": {
      "type": "string",
      "enum": [
        "order.accepted",
        "order.published",
        "order.cancelled"
      ]
    }
  }
}