{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/postzen-dev/json-schema/postzen-dev-inbox-message-send-request-schema.json",
  "title": "InboxMessageSendRequest",
  "description": "Exactly one of `message` or `attachmentUrl` is required. Meta’s Send API carries one payload per call, so the two cannot be combined — send two messages instead.",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/postzen-dev-inbox-api-openapi.yml#/components/schemas/InboxMessageSendRequest",
  "type": "object",
  "required": [
    "accountId"
  ],
  "properties": {
    "accountId": {
      "type": "string",
      "description": "PostZen account id that owns the conversation."
    },
    "message": {
      "type": "string",
      "description": "Message text. Cannot be combined with `attachmentUrl`: Meta accepts one payload per call, so a request carrying both is rejected with a 400 rather than silently sending half of it."
    },
    "attachmentUrl": {
      "type": "string",
      "format": "uri",
      "description": "Publicly fetchable http(s) URL. Meta downloads it itself, so it must be reachable without credentials — `POST /v1/media/upload-direct` returns a URL that qualifies."
    },
    "attachmentType": {
      "type": "string",
      "enum": [
        "image",
        "video",
        "audio",
        "file"
      ],
      "description": "Required whenever `attachmentUrl` is set."
    }
  }
}