{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/frihet-io/json-schema/frihet-io-resend-inbound-payload-schema.json",
  "title": "ResendInboundPayload",
  "description": "Payload sent by Resend for inbound email routing.",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/frihet-io-webhooks-api-openapi.yml#/components/schemas/ResendInboundPayload",
  "type": "object",
  "properties": {
    "to": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Recipient email addresses. Should include receipts@<slug>.frihet.io"
    },
    "from": {
      "type": "string",
      "description": "Sender email address"
    },
    "subject": {
      "type": "string",
      "description": "Email subject line"
    },
    "text": {
      "type": "string",
      "description": "Plain text body"
    },
    "html": {
      "type": "string",
      "description": "HTML body"
    },
    "attachments": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "filename": {
            "type": "string",
            "description": "Original filename of the attachment"
          },
          "content": {
            "type": "string",
            "description": "Base64-encoded file content"
          },
          "content_type": {
            "type": "string",
            "description": "MIME type of the attachment"
          }
        }
      }
    }
  }
}