{
  "components": {
    "schemas": {
      "eventoutbox.Attempt": {
        "properties": {
          "attempt": {
            "format": "int64",
            "type": "integer"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "durationMs": {
            "format": "int64",
            "type": "integer"
          },
          "error": {
            "type": "string"
          },
          "httpStatus": {
            "format": "int64",
            "type": "integer"
          },
          "replay": {
            "format": "int64",
            "type": "integer"
          },
          "responseBody": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "eventoutbox.Delivery": {
        "properties": {
          "attempts": {
            "format": "int64",
            "type": "integer"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "error": {
            "type": "string"
          },
          "eventId": {
            "type": "string"
          },
          "httpStatus": {
            "format": "int64",
            "type": "integer"
          },
          "id": {
            "type": "string"
          },
          "nextAttemptAt": {
            "format": "date-time",
            "type": "string"
          },
          "payload": {
            "allOf": [
              {
                "$ref": "#/components/schemas/eventoutbox.Envelope"
              }
            ],
            "description": "Immutable event body returned by delivery detail; omitted from the paginated list. Replay preserves this body and event ID."
          },
          "replayCount": {
            "format": "int64",
            "type": "integer"
          },
          "status": {
            "type": "string"
          },
          "type": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "eventoutbox.DeliveryPage": {
        "properties": {
          "deliveries": {
            "items": {
              "$ref": "#/components/schemas/eventoutbox.Delivery"
            },
            "type": "array"
          },
          "page": {
            "format": "int64",
            "type": "integer"
          },
          "pageSize": {
            "format": "int64",
            "type": "integer"
          },
          "total": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "eventoutbox.Envelope": {
        "properties": {
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "data": {
            "additionalProperties": {},
            "description": "Event-specific fields. Mail events include messageUuid; additional fields depend on event type. Verify the signature over raw bytes before parsing.",
            "type": "object"
          },
          "id": {
            "format": "uuid",
            "type": "string"
          },
          "type": {
            "enum": [
              "email.received",
              "email.sent",
              "email.delivered",
              "email.failed",
              "email.unknown",
              "email.bounced",
              "email.complained",
              "webhook.test"
            ],
            "type": "string"
          },
          "version": {
            "enum": [
              "1"
            ],
            "type": "string"
          }
        },
        "type": "object"
      },
      "eventoutbox.Result": {
        "properties": {
          "deliveryId": {
            "type": "string"
          },
          "error": {
            "type": "string"
          },
          "eventId": {
            "type": "string"
          },
          "httpStatus": {
            "format": "int64",
            "type": "integer"
          },
          "status": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "handler.ProvisionRequest": {
        "properties": {
          "accessKeyId": {
            "type": "string"
          },
          "region": {
            "type": "string"
          },
          "secretAccessKey": {
            "type": "string",
            "writeOnly": true
          }
        },
        "required": [
          "region",
          "accessKeyId",
          "secretAccessKey"
        ],
        "type": "object"
      },
      "handler.ValidateCredentialsRequest": {
        "properties": {
          "accessKeyId": {
            "type": "string"
          },
          "region": {
            "type": "string"
          },
          "secretAccessKey": {
            "type": "string",
            "writeOnly": true
          }
        },
        "required": [
          "region",
          "accessKeyId",
          "secretAccessKey"
        ],
        "type": "object"
      },
      "model.AddContactsToListRequest": {
        "properties": {
          "contactIds": {
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "required": [
          "contactIds"
        ],
        "type": "object"
      },
      "model.ApiKeyResponse": {
        "properties": {
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "expiresAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "key": {
            "description": "Only shown on creation",
            "type": "string"
          },
          "keyPrefix": {
            "type": "string"
          },
          "lastUsedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "name": {
            "type": "string"
          },
          "permissions": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "rateLimit": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.AttachmentDTO": {
        "properties": {
          "blobId": {
            "type": "string"
          },
          "cid": {
            "type": "string"
          },
          "content": {
            "type": "string"
          },
          "disposition": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "size": {
            "format": "int64",
            "type": "integer"
          },
          "type": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.AuthResponse": {
        "properties": {
          "token": {
            "type": "string"
          },
          "user": {
            "allOf": [
              {
                "$ref": "#/components/schemas/model.User"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "model.Automation": {
        "properties": {
          "completedCount": {
            "format": "int64",
            "type": "integer"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "enrolledCount": {
            "format": "int64",
            "type": "integer"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "inProgressCount": {
            "format": "int64",
            "type": "integer"
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "status": {
            "description": "draft, active, paused",
            "type": "string"
          },
          "triggerConfig": {
            "additionalProperties": {},
            "type": "object"
          },
          "triggerType": {
            "description": "contact.created, contact.subscribed, tag.added, etc.",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "uuid": {
            "type": "string"
          },
          "workflow": {
            "allOf": [
              {
                "$ref": "#/components/schemas/model.Workflow"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "model.AutomationListResult": {
        "properties": {
          "automations": {
            "items": {
              "$ref": "#/components/schemas/model.AutomationSummary"
            },
            "type": "array"
          },
          "page": {
            "format": "int64",
            "type": "integer"
          },
          "pageSize": {
            "format": "int64",
            "type": "integer"
          },
          "total": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "model.AutomationStats": {
        "properties": {
          "automationUuid": {
            "type": "string"
          },
          "completed": {
            "format": "int64",
            "type": "integer"
          },
          "completionRate": {
            "type": "number"
          },
          "enrolled": {
            "format": "int64",
            "type": "integer"
          },
          "errors": {
            "format": "int64",
            "type": "integer"
          },
          "inProgress": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "model.AutomationSummary": {
        "properties": {
          "completedCount": {
            "format": "int64",
            "type": "integer"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "enrolledCount": {
            "format": "int64",
            "type": "integer"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "inProgressCount": {
            "format": "int64",
            "type": "integer"
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "status": {
            "type": "string"
          },
          "triggerConfig": {
            "additionalProperties": {},
            "type": "object"
          },
          "triggerType": {
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.BatchEmailResult": {
        "properties": {
          "error": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "index": {
            "format": "int64",
            "type": "integer"
          },
          "messageId": {
            "type": "string"
          },
          "status": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.BatchSendRequest": {
        "properties": {
          "emails": {
            "items": {
              "$ref": "#/components/schemas/model.SendEmailRequest"
            },
            "maxItems": 100,
            "minItems": 1,
            "type": "array"
          }
        },
        "required": [
          "emails"
        ],
        "type": "object"
      },
      "model.BatchSendResponse": {
        "properties": {
          "results": {
            "items": {
              "$ref": "#/components/schemas/model.BatchEmailResult"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "model.Campaign": {
        "properties": {
          "abTestSettings": {},
          "bounceCount": {
            "format": "int64",
            "type": "integer"
          },
          "clickCount": {
            "format": "int64",
            "type": "integer"
          },
          "complaintCount": {
            "format": "int64",
            "type": "integer"
          },
          "completedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "deliveredCount": {
            "format": "int64",
            "type": "integer"
          },
          "fromEmail": {
            "type": "string"
          },
          "fromName": {
            "type": "string"
          },
          "htmlContent": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "isAbTest": {
            "type": "boolean"
          },
          "listId": {
            "format": "int64",
            "type": "integer"
          },
          "listName": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "openCount": {
            "format": "int64",
            "type": "integer"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "replyTo": {
            "type": "string"
          },
          "scheduledAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "sentCount": {
            "format": "int64",
            "type": "integer"
          },
          "startedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "status": {
            "description": "draft, scheduled, sending, sent, paused, cancelled",
            "type": "string"
          },
          "subject": {
            "type": "string"
          },
          "templateId": {
            "allOf": [
              {
                "format": "int64",
                "type": "integer"
              }
            ],
            "nullable": true
          },
          "textContent": {
            "type": "string"
          },
          "totalRecipients": {
            "format": "int64",
            "type": "integer"
          },
          "unsubscribeCount": {
            "format": "int64",
            "type": "integer"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.CampaignListResponse": {
        "properties": {
          "campaigns": {
            "items": {
              "$ref": "#/components/schemas/model.Campaign"
            },
            "type": "array"
          },
          "page": {
            "format": "int64",
            "type": "integer"
          },
          "pageSize": {
            "format": "int64",
            "type": "integer"
          },
          "total": {
            "format": "int64",
            "type": "integer"
          },
          "totalPages": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "model.CampaignStatsResponse": {
        "properties": {
          "bounceRate": {
            "type": "number"
          },
          "campaign": {
            "allOf": [
              {
                "$ref": "#/components/schemas/model.Campaign"
              }
            ],
            "nullable": true
          },
          "clickRate": {
            "type": "number"
          },
          "clicksByLink": {
            "additionalProperties": {
              "format": "int64",
              "type": "integer"
            },
            "type": "object"
          },
          "complaintRate": {
            "type": "number"
          },
          "openRate": {
            "type": "number"
          },
          "opensByHour": {
            "additionalProperties": {
              "format": "int64",
              "type": "integer"
            },
            "type": "object"
          },
          "unsubscribeRate": {
            "type": "number"
          }
        },
        "type": "object"
      },
      "model.ComposeEmailRequest": {
        "anyOf": [
          {
            "properties": {
              "to": {
                "minItems": 1,
                "type": "array"
              }
            },
            "required": [
              "to"
            ]
          },
          {
            "properties": {
              "cc": {
                "minItems": 1,
                "type": "array"
              }
            },
            "required": [
              "cc"
            ]
          },
          {
            "properties": {
              "bcc": {
                "minItems": 1,
                "type": "array"
              }
            },
            "required": [
              "bcc"
            ]
          }
        ],
        "description": "At least one recipient across to/cc/bcc; SES accepts at most 50 combined. The rendered subject is limited to 1000 bytes and combined text/HTML body to 2 MiB. Limits are bytes, not Unicode character counts.",
        "properties": {
          "attachments": {
            "items": {
              "$ref": "#/components/schemas/model.AttachmentDTO"
            },
            "maxItems": 50,
            "type": "array"
          },
          "bcc": {
            "items": {
              "$ref": "#/components/schemas/model.EmailAddressDTO"
            },
            "type": "array"
          },
          "cc": {
            "items": {
              "$ref": "#/components/schemas/model.EmailAddressDTO"
            },
            "type": "array"
          },
          "draftId": {
            "type": "string"
          },
          "draftVersion": {
            "format": "int64",
            "type": "integer"
          },
          "fromEmail": {
            "type": "string"
          },
          "htmlBody": {
            "type": "string"
          },
          "identityId": {
            "format": "int64",
            "type": "integer"
          },
          "inReplyTo": {
            "type": "string"
          },
          "references": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "replyTo": {
            "items": {
              "$ref": "#/components/schemas/model.EmailAddressDTO"
            },
            "type": "array"
          },
          "subject": {
            "type": "string"
          },
          "textBody": {
            "type": "string"
          },
          "to": {
            "items": {
              "$ref": "#/components/schemas/model.EmailAddressDTO"
            },
            "type": "array"
          }
        },
        "required": [
          "identityId",
          "subject"
        ],
        "type": "object"
      },
      "model.Contact": {
        "properties": {
          "attributes": {
            "additionalProperties": {},
            "type": "object"
          },
          "consentIp": {
            "type": "string"
          },
          "consentSource": {
            "type": "string"
          },
          "consentTimestamp": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "engagementScore": {
            "type": "number"
          },
          "firstName": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "lastEngagedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "lastName": {
            "type": "string"
          },
          "lists": {
            "items": {
              "$ref": "#/components/schemas/model.ListMembership"
            },
            "type": "array"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "status": {
            "description": "active, unsubscribed, bounced, complained",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.ContactListResponse": {
        "properties": {
          "contacts": {
            "items": {
              "$ref": "#/components/schemas/model.Contact"
            },
            "type": "array"
          },
          "page": {
            "format": "int64",
            "type": "integer"
          },
          "pageSize": {
            "format": "int64",
            "type": "integer"
          },
          "total": {
            "format": "int64",
            "type": "integer"
          },
          "totalPages": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "model.CreateApiKeyRequest": {
        "properties": {
          "expiresAt": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "description": "Optional future RFC3339 expiry. Null means no expiry.",
            "nullable": true
          },
          "name": {
            "minLength": 2,
            "type": "string"
          },
          "permissions": {
            "items": {
              "enum": [
                "contacts:manage",
                "domains:manage",
                "domains:read",
                "email:manage",
                "email:read",
                "email:send",
                "identities:manage",
                "identities:read",
                "templates:manage",
                "templates:read",
                "webhooks:manage"
              ],
              "type": "string"
            },
            "minItems": 1,
            "type": "array",
            "uniqueItems": true
          },
          "rateLimit": {
            "default": 100,
            "description": "Requests per minute. Omit or use 0 for 100; otherwise 1–10000.",
            "format": "int64",
            "maximum": 10000,
            "minimum": 0,
            "type": "integer"
          }
        },
        "required": [
          "name",
          "permissions"
        ],
        "type": "object"
      },
      "model.CreateAutomationRequest": {
        "properties": {
          "description": {
            "type": "string"
          },
          "name": {
            "minLength": 2,
            "type": "string"
          },
          "triggerConfig": {
            "additionalProperties": {},
            "type": "object"
          },
          "triggerType": {
            "type": "string"
          },
          "workflow": {
            "allOf": [
              {
                "$ref": "#/components/schemas/model.Workflow"
              }
            ],
            "nullable": true
          }
        },
        "required": [
          "name",
          "triggerType"
        ],
        "type": "object"
      },
      "model.CreateCampaignRequest": {
        "properties": {
          "fromEmail": {
            "format": "email",
            "type": "string"
          },
          "fromName": {
            "type": "string"
          },
          "htmlContent": {
            "type": "string"
          },
          "listId": {
            "format": "int64",
            "type": "integer"
          },
          "name": {
            "minLength": 2,
            "type": "string"
          },
          "replyTo": {
            "type": "string"
          },
          "subject": {
            "type": "string"
          },
          "templateId": {
            "allOf": [
              {
                "format": "int64",
                "type": "integer"
              }
            ],
            "nullable": true
          },
          "textContent": {
            "type": "string"
          }
        },
        "required": [
          "name",
          "subject",
          "fromName",
          "fromEmail",
          "listId"
        ],
        "type": "object"
      },
      "model.CreateContactRequest": {
        "properties": {
          "attributes": {
            "additionalProperties": {},
            "type": "object"
          },
          "consentSource": {
            "type": "string"
          },
          "email": {
            "format": "email",
            "type": "string"
          },
          "firstName": {
            "type": "string"
          },
          "lastName": {
            "type": "string"
          },
          "listIds": {
            "items": {
              "format": "int64",
              "type": "integer"
            },
            "type": "array"
          },
          "skipConfirmation": {
            "description": "For double opt-in",
            "type": "boolean"
          }
        },
        "required": [
          "email"
        ],
        "type": "object"
      },
      "model.CreateDomainRequest": {
        "properties": {
          "name": {
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "model.CreateIdentityRequest": {
        "properties": {
          "displayName": {
            "type": "string"
          },
          "domainId": {
            "description": "UUID of an active domain owned by the caller's organization; SES verification is required in SES mode.",
            "format": "uuid",
            "type": "string"
          },
          "email": {
            "description": "Complete address on that domain; arbitrary external domains are rejected.",
            "format": "email",
            "type": "string"
          },
          "isCatchAll": {
            "description": "Only one catch-all per domain allowed",
            "type": "boolean"
          },
          "isDefault": {
            "type": "boolean"
          },
          "password": {
            "description": "Required with at least 8 characters for legacy non-SES identities; SES addresses do not require one.",
            "type": "string",
            "writeOnly": true
          },
          "quotaBytes": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "domainId",
          "email"
        ],
        "type": "object"
      },
      "model.CreateListRequest": {
        "properties": {
          "description": {
            "type": "string"
          },
          "name": {
            "minLength": 2,
            "type": "string"
          },
          "segmentRules": {},
          "type": {
            "default": "static",
            "description": "static, dynamic",
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "model.CreateTemplateRequest": {
        "properties": {
          "description": {
            "type": "string"
          },
          "html": {
            "type": "string"
          },
          "name": {
            "minLength": 2,
            "type": "string"
          },
          "subject": {
            "type": "string"
          },
          "text": {
            "type": "string"
          }
        },
        "required": [
          "name",
          "subject",
          "html"
        ],
        "type": "object"
      },
      "model.CreateWebhookRequest": {
        "properties": {
          "events": {
            "description": "Use canonical dotted event names. Legacy aliases remain accepted; webhook.test is emitted only by the test endpoint.",
            "items": {
              "enum": [
                "email.received",
                "email.sent",
                "email.delivered",
                "email.failed",
                "email.unknown",
                "email.bounced",
                "email.complained",
                "email_received",
                "email_sent",
                "email_delivered",
                "email_failed",
                "email_unknown",
                "email_bounced",
                "email_complained",
                "bounce_received",
                "complaint_received"
              ],
              "type": "string"
            },
            "type": "array"
          },
          "name": {
            "minLength": 2,
            "type": "string"
          },
          "url": {
            "description": "Public HTTPS only, at most 2048 bytes; redirects and private/reserved destinations are rejected.",
            "format": "uri",
            "type": "string"
          }
        },
        "required": [
          "name",
          "url",
          "events"
        ],
        "type": "object"
      },
      "model.DeleteEmailRequest": {
        "properties": {
          "emailIds": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "permanent": {
            "type": "boolean"
          }
        },
        "required": [
          "emailIds"
        ],
        "type": "object"
      },
      "model.DeliveryEvent": {
        "properties": {
          "details": {
            "type": "string"
          },
          "emailId": {
            "format": "int64",
            "type": "integer"
          },
          "eventType": {
            "description": "queued, sent, delivered, opened, clicked, bounced, complained",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "ipAddress": {
            "type": "string"
          },
          "timestamp": {
            "format": "date-time",
            "type": "string"
          },
          "userAgent": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.Domain": {
        "properties": {
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "dkimPublicKey": {
            "type": "string"
          },
          "dkimSelector": {
            "type": "string"
          },
          "dkimVerified": {
            "type": "boolean"
          },
          "dmarcVerified": {
            "type": "boolean"
          },
          "emailProvider": {
            "description": "ses, smtp",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "mxVerified": {
            "type": "boolean"
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "receivingEnabled": {
            "type": "boolean"
          },
          "receivingRuleName": {
            "type": "string"
          },
          "receivingRuleSetName": {
            "type": "string"
          },
          "receivingS3Bucket": {
            "type": "string"
          },
          "receivingSetupAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "receivingSnsTopicArn": {
            "type": "string"
          },
          "sesDkimTokens": {
            "description": "SES Easy DKIM tokens",
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "sesIdentityArn": {
            "description": "SES identity ARN",
            "type": "string"
          },
          "sesVerified": {
            "description": "SES domain verification status",
            "type": "boolean"
          },
          "spfVerified": {
            "type": "boolean"
          },
          "status": {
            "description": "pending, active, suspended",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "uuid": {
            "type": "string"
          },
          "verificationToken": {
            "type": "string"
          },
          "verifiedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "model.DomainDNSRecord": {
        "properties": {
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "domainId": {
            "format": "int64",
            "type": "integer"
          },
          "hostname": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "priority": {
            "allOf": [
              {
                "format": "int64",
                "type": "integer"
              }
            ],
            "nullable": true
          },
          "recordType": {
            "description": "MX, TXT, CNAME",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "value": {
            "type": "string"
          },
          "verified": {
            "type": "boolean"
          },
          "verifiedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "model.EmailAddressDTO": {
        "properties": {
          "email": {
            "format": "email",
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        },
        "required": [
          "email"
        ],
        "type": "object"
      },
      "model.EmailAttachment": {
        "properties": {
          "checksum": {
            "type": "string"
          },
          "contentId": {
            "type": "string"
          },
          "contentType": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "downloadUrl": {
            "type": "string"
          },
          "filename": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "isInline": {
            "type": "boolean"
          },
          "receivedEmailId": {
            "format": "int64",
            "type": "integer"
          },
          "s3Bucket": {
            "type": "string"
          },
          "s3Key": {
            "type": "string"
          },
          "sizeBytes": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.EmailLabel": {
        "properties": {
          "color": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.EmailTemplate": {
        "properties": {
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "htmlBody": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "isActive": {
            "type": "boolean"
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "subject": {
            "type": "string"
          },
          "textBody": {
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "uuid": {
            "type": "string"
          },
          "variables": {
            "description": "List of variable names",
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "model.ExportContactsRequest": {
        "properties": {
          "format": {
            "description": "csv, json",
            "type": "string"
          },
          "listIds": {
            "items": {
              "format": "int64",
              "type": "integer"
            },
            "type": "array"
          },
          "status": {
            "description": "active, unsubscribed, etc.",
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "model.FilterCondition": {
        "properties": {
          "field": {
            "description": "from, to, subject, body, hasAttachment",
            "type": "string"
          },
          "operator": {
            "description": "contains, equals, startsWith, endsWith, regex",
            "type": "string"
          },
          "value": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.FlagEmailRequest": {
        "properties": {
          "emailIds": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "flagged": {
            "type": "boolean"
          }
        },
        "required": [
          "emailIds"
        ],
        "type": "object"
      },
      "model.GetEmailStatusResponse": {
        "properties": {
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "deliveredAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "events": {
            "items": {
              "$ref": "#/components/schemas/model.DeliveryEvent"
            },
            "type": "array"
          },
          "from": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "messageId": {
            "type": "string"
          },
          "sentAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "status": {
            "type": "string"
          },
          "subject": {
            "type": "string"
          },
          "to": {
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "model.Identity": {
        "properties": {
          "canReceive": {
            "type": "boolean"
          },
          "canSend": {
            "type": "boolean"
          },
          "color": {
            "description": "Hex color for UI display",
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "displayName": {
            "type": "string"
          },
          "domainId": {
            "format": "int64",
            "type": "integer"
          },
          "email": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "isCatchAll": {
            "type": "boolean"
          },
          "isDefault": {
            "type": "boolean"
          },
          "quotaBytes": {
            "format": "int64",
            "type": "integer"
          },
          "stalwartAcctId": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "usedBytes": {
            "format": "int64",
            "type": "integer"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.ImportContactRow": {
        "properties": {
          "attributes": {
            "additionalProperties": {},
            "type": "object"
          },
          "email": {
            "format": "email",
            "type": "string"
          },
          "firstName": {
            "type": "string"
          },
          "lastName": {
            "type": "string"
          }
        },
        "required": [
          "email"
        ],
        "type": "object"
      },
      "model.ImportContactsRequest": {
        "properties": {
          "consentSource": {
            "type": "string"
          },
          "contacts": {
            "items": {
              "$ref": "#/components/schemas/model.ImportContactRow"
            },
            "type": "array"
          },
          "listIds": {
            "items": {
              "format": "int64",
              "type": "integer"
            },
            "type": "array"
          },
          "skipConfirmation": {
            "type": "boolean"
          },
          "updateExisting": {
            "type": "boolean"
          }
        },
        "required": [
          "contacts"
        ],
        "type": "object"
      },
      "model.ImportContactsResponse": {
        "properties": {
          "errors": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "imported": {
            "format": "int64",
            "type": "integer"
          },
          "skipped": {
            "format": "int64",
            "type": "integer"
          },
          "updated": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "model.ImportContactsToListRequest": {
        "properties": {
          "consentSource": {
            "type": "string"
          },
          "contacts": {
            "items": {
              "$ref": "#/components/schemas/model.ImportContactRow"
            },
            "type": "array"
          },
          "updateExisting": {
            "type": "boolean"
          }
        },
        "required": [
          "contacts"
        ],
        "type": "object"
      },
      "model.ImportContactsToListResponse": {
        "properties": {
          "errors": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "imported": {
            "format": "int64",
            "type": "integer"
          },
          "skipped": {
            "format": "int64",
            "type": "integer"
          },
          "updated": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "model.InboxCountsResponse": {
        "properties": {
          "dmarcReports": {
            "description": "Messages in the dedicated DMARC Reports folder.",
            "format": "int64",
            "minimum": 0,
            "type": "integer"
          },
          "dmarcReportsUnread": {
            "description": "Unread messages in the dedicated DMARC Reports folder.",
            "format": "int64",
            "minimum": 0,
            "type": "integer"
          },
          "drafts": {
            "format": "int64",
            "type": "integer"
          },
          "inbox": {
            "format": "int64",
            "type": "integer"
          },
          "inboxUnread": {
            "description": "Unread messages in the main Inbox only.",
            "format": "int64",
            "minimum": 0,
            "type": "integer"
          },
          "labels": {
            "additionalProperties": {
              "format": "int64",
              "type": "integer"
            },
            "type": "object"
          },
          "sent": {
            "format": "int64",
            "type": "integer"
          },
          "spam": {
            "format": "int64",
            "type": "integer"
          },
          "starred": {
            "format": "int64",
            "type": "integer"
          },
          "trash": {
            "format": "int64",
            "type": "integer"
          },
          "unread": {
            "description": "Global unread total excluding Trash; includes Spam and unread DMARC reports.",
            "format": "int64",
            "minimum": 0,
            "type": "integer"
          }
        },
        "type": "object"
      },
      "model.InboxFilter": {
        "properties": {
          "actionArchive": {
            "type": "boolean"
          },
          "actionFolder": {
            "description": "An explicit destination overrides automatic DMARC organization. Empty leaves the selected folder unchanged.",
            "enum": [
              "",
              "inbox",
              "archive",
              "spam",
              "trash",
              "dmarc-reports"
            ],
            "type": "string"
          },
          "actionForward": {
            "type": "string"
          },
          "actionLabels": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "actionMarkRead": {
            "type": "boolean"
          },
          "actionStar": {
            "type": "boolean"
          },
          "actionTrash": {
            "type": "boolean"
          },
          "active": {
            "type": "boolean"
          },
          "conditionLogic": {
            "description": "all, any",
            "type": "string"
          },
          "conditions": {
            "items": {
              "$ref": "#/components/schemas/model.FilterCondition"
            },
            "type": "array"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "identityId": {
            "allOf": [
              {
                "format": "int64",
                "type": "integer"
              }
            ],
            "nullable": true
          },
          "lastMatchedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "matchCount": {
            "format": "int64",
            "type": "integer"
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "priority": {
            "format": "int64",
            "type": "integer"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.InboxListResponse": {
        "properties": {
          "emails": {
            "items": {
              "$ref": "#/components/schemas/model.ReceivedEmail"
            },
            "type": "array"
          },
          "page": {
            "format": "int64",
            "type": "integer"
          },
          "pageSize": {
            "format": "int64",
            "type": "integer"
          },
          "total": {
            "format": "int64",
            "type": "integer"
          },
          "totalPages": {
            "format": "int64",
            "type": "integer"
          },
          "unread": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "model.LabelEmailsRequest": {
        "properties": {
          "addLabels": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "emailUuids": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "removeLabels": {
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "required": [
          "emailUuids"
        ],
        "type": "object"
      },
      "model.List": {
        "properties": {
          "contactCount": {
            "format": "int64",
            "type": "integer"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "segmentRules": {},
          "type": {
            "description": "static, dynamic",
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.ListMembership": {
        "properties": {
          "joinedAt": {
            "format": "date-time",
            "type": "string"
          },
          "listId": {
            "format": "int64",
            "type": "integer"
          },
          "listName": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.LoginRequest": {
        "properties": {
          "email": {
            "format": "email",
            "type": "string"
          },
          "password": {
            "type": "string"
          }
        },
        "required": [
          "email",
          "password"
        ],
        "type": "object"
      },
      "model.LoginResponse": {
        "properties": {
          "challengeToken": {
            "type": "string"
          },
          "requiresTwoFactor": {
            "type": "boolean"
          },
          "token": {
            "type": "string"
          },
          "user": {
            "allOf": [
              {
                "$ref": "#/components/schemas/model.User"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "model.ManualAddContactToListRequest": {
        "properties": {
          "attributes": {
            "additionalProperties": {},
            "type": "object"
          },
          "email": {
            "format": "email",
            "type": "string"
          },
          "firstName": {
            "type": "string"
          },
          "lastName": {
            "type": "string"
          }
        },
        "required": [
          "email"
        ],
        "type": "object"
      },
      "model.MarkEmailsRequest": {
        "properties": {
          "emailUuids": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "isRead": {
            "type": "boolean"
          }
        },
        "required": [
          "emailUuids"
        ],
        "type": "object"
      },
      "model.MarkReadRequest": {
        "properties": {
          "emailIds": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "read": {
            "type": "boolean"
          }
        },
        "required": [
          "emailIds"
        ],
        "type": "object"
      },
      "model.MoveEmailRequest": {
        "properties": {
          "emailIds": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "targetMailboxId": {
            "type": "string"
          }
        },
        "required": [
          "emailIds",
          "targetMailboxId"
        ],
        "type": "object"
      },
      "model.MoveEmailsRequest": {
        "properties": {
          "emailUuids": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "folder": {
            "description": "A manual move is retained; automatic classification is not repeated.",
            "enum": [
              "inbox",
              "archive",
              "spam",
              "trash",
              "dmarc-reports"
            ],
            "type": "string"
          }
        },
        "required": [
          "emailUuids",
          "folder"
        ],
        "type": "object"
      },
      "model.PreviewTemplateRequest": {
        "properties": {
          "variables": {
            "additionalProperties": {
              "type": "string"
            },
            "type": "object"
          }
        },
        "type": "object"
      },
      "model.PreviewTemplateResponse": {
        "properties": {
          "html": {
            "type": "string"
          },
          "subject": {
            "type": "string"
          },
          "text": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.ReceivedEmail": {
        "properties": {
          "attachments": {
            "items": {
              "$ref": "#/components/schemas/model.EmailAttachment"
            },
            "type": "array"
          },
          "bccEmails": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "ccEmails": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "direction": {
            "type": "string"
          },
          "dkimVerdict": {
            "type": "string"
          },
          "dmarcVerdict": {
            "type": "string"
          },
          "domainId": {
            "format": "int64",
            "type": "integer"
          },
          "draftVersion": {
            "format": "int64",
            "type": "integer"
          },
          "envelopeRecipients": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "folder": {
            "type": "string"
          },
          "fromEmail": {
            "type": "string"
          },
          "fromName": {
            "type": "string"
          },
          "hasAttachments": {
            "type": "boolean"
          },
          "htmlBody": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "identityColor": {
            "type": "string"
          },
          "identityDisplayName": {
            "type": "string"
          },
          "identityEmail": {
            "type": "string"
          },
          "identityId": {
            "format": "int64",
            "type": "integer"
          },
          "inReplyTo": {
            "type": "string"
          },
          "isArchived": {
            "type": "boolean"
          },
          "isRead": {
            "type": "boolean"
          },
          "isSpam": {
            "type": "boolean"
          },
          "isStarred": {
            "type": "boolean"
          },
          "isTrashed": {
            "type": "boolean"
          },
          "labels": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "messageId": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "rawS3Bucket": {
            "type": "string"
          },
          "rawS3Key": {
            "type": "string"
          },
          "readAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "receivedAt": {
            "format": "date-time",
            "type": "string"
          },
          "references": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "replyTo": {
            "type": "string"
          },
          "sendError": {
            "type": "string"
          },
          "sendStatus": {
            "type": "string"
          },
          "sentAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "sesMessageId": {
            "type": "string"
          },
          "sizeBytes": {
            "format": "int64",
            "type": "integer"
          },
          "snippet": {
            "type": "string"
          },
          "snsNotificationId": {
            "type": "string"
          },
          "spamScore": {
            "allOf": [
              {
                "type": "number"
              }
            ],
            "nullable": true
          },
          "spamVerdict": {
            "type": "string"
          },
          "spfVerdict": {
            "type": "string"
          },
          "subject": {
            "type": "string"
          },
          "textBody": {
            "type": "string"
          },
          "threadId": {
            "type": "string"
          },
          "toEmails": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "trashedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "uuid": {
            "type": "string"
          },
          "virusVerdict": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.RegisterRequest": {
        "properties": {
          "email": {
            "format": "email",
            "type": "string"
          },
          "name": {
            "minLength": 2,
            "type": "string"
          },
          "orgName": {
            "type": "string"
          },
          "password": {
            "minLength": 8,
            "type": "string"
          }
        },
        "required": [
          "email",
          "password",
          "name"
        ],
        "type": "object"
      },
      "model.RemoveContactsFromListRequest": {
        "properties": {
          "contactIds": {
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "required": [
          "contactIds"
        ],
        "type": "object"
      },
      "model.RotateSecretResponse": {
        "properties": {
          "secret": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.SaveDraftRequest": {
        "properties": {
          "attachments": {
            "items": {
              "$ref": "#/components/schemas/model.AttachmentDTO"
            },
            "type": "array"
          },
          "bcc": {
            "items": {
              "$ref": "#/components/schemas/model.EmailAddressDTO"
            },
            "type": "array"
          },
          "cc": {
            "items": {
              "$ref": "#/components/schemas/model.EmailAddressDTO"
            },
            "type": "array"
          },
          "fromEmail": {
            "type": "string"
          },
          "htmlBody": {
            "type": "string"
          },
          "identityId": {
            "format": "int64",
            "type": "integer"
          },
          "inReplyTo": {
            "type": "string"
          },
          "references": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "replyTo": {
            "items": {
              "$ref": "#/components/schemas/model.EmailAddressDTO"
            },
            "type": "array"
          },
          "subject": {
            "type": "string"
          },
          "textBody": {
            "type": "string"
          },
          "to": {
            "items": {
              "$ref": "#/components/schemas/model.EmailAddressDTO"
            },
            "type": "array"
          },
          "version": {
            "format": "int64",
            "type": "integer"
          }
        },
        "required": [
          "identityId"
        ],
        "type": "object"
      },
      "model.ScheduleCampaignRequest": {
        "properties": {
          "scheduledAt": {
            "description": "RFC3339 timestamp",
            "type": "string"
          },
          "timezone": {
            "default": "UTC",
            "type": "string"
          }
        },
        "required": [
          "scheduledAt"
        ],
        "type": "object"
      },
      "model.SendEmailRequest": {
        "anyOf": [
          {
            "properties": {
              "to": {
                "minItems": 1,
                "type": "array"
              }
            },
            "required": [
              "to"
            ]
          },
          {
            "properties": {
              "cc": {
                "minItems": 1,
                "type": "array"
              }
            },
            "required": [
              "cc"
            ]
          },
          {
            "properties": {
              "bcc": {
                "minItems": 1,
                "type": "array"
              }
            },
            "required": [
              "bcc"
            ]
          }
        ],
        "description": "At least one recipient across to/cc/bcc; SES accepts at most 50 combined. The rendered subject is limited to 1000 bytes and combined text/HTML body to 2 MiB. Limits are bytes, not Unicode character counts. Supply text, html, templateId or attachments. Single-send requests also require a header or body idempotency key.",
        "properties": {
          "attachments": {
            "items": {
              "$ref": "#/components/schemas/model.AttachmentDTO"
            },
            "maxItems": 50,
            "type": "array"
          },
          "bcc": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "cc": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "from": {
            "format": "email",
            "type": "string"
          },
          "html": {
            "type": "string"
          },
          "idempotencyKey": {
            "description": "Alternative to the single-send Idempotency-Key header; both must agree when supplied. At least one form is mandatory.",
            "maxLength": 128,
            "minLength": 8,
            "type": "string"
          },
          "metadata": {
            "additionalProperties": {
              "type": "string"
            },
            "type": "object"
          },
          "replyTo": {
            "type": "string"
          },
          "scheduledFor": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "description": "RFC3339 timestamp",
            "nullable": true
          },
          "subject": {
            "type": "string"
          },
          "tags": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "templateId": {
            "type": "string"
          },
          "text": {
            "type": "string"
          },
          "to": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "variables": {
            "additionalProperties": {
              "type": "string"
            },
            "type": "object"
          }
        },
        "required": [
          "from",
          "subject"
        ],
        "type": "object"
      },
      "model.SendEmailResponse": {
        "properties": {
          "acceptedAt": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "messageId": {
            "type": "string"
          },
          "status": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.SetupReceivingResponse": {
        "properties": {
          "requiredDns": {
            "items": {
              "$ref": "#/components/schemas/model.DomainDNSRecord"
            },
            "type": "array"
          },
          "ruleName": {
            "type": "string"
          },
          "ruleSetName": {
            "type": "string"
          },
          "s3Bucket": {
            "type": "string"
          },
          "snsTopicArn": {
            "type": "string"
          },
          "success": {
            "type": "boolean"
          },
          "webhookUrl": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.StarEmailsRequest": {
        "properties": {
          "emailUuids": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "isStarred": {
            "type": "boolean"
          }
        },
        "required": [
          "emailUuids"
        ],
        "type": "object"
      },
      "model.TrashEmailsRequest": {
        "properties": {
          "emailUuids": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "permanent": {
            "description": "If true, delete permanently",
            "type": "boolean"
          }
        },
        "required": [
          "emailUuids"
        ],
        "type": "object"
      },
      "model.UpdateAutomationRequest": {
        "properties": {
          "description": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "name": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "triggerConfig": {
            "additionalProperties": {},
            "type": "object"
          },
          "triggerType": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "workflow": {
            "allOf": [
              {
                "$ref": "#/components/schemas/model.Workflow"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "model.UpdateCampaignRequest": {
        "properties": {
          "fromEmail": {
            "type": "string"
          },
          "fromName": {
            "type": "string"
          },
          "htmlContent": {
            "type": "string"
          },
          "listId": {
            "allOf": [
              {
                "format": "int64",
                "type": "integer"
              }
            ],
            "nullable": true
          },
          "name": {
            "type": "string"
          },
          "replyTo": {
            "type": "string"
          },
          "subject": {
            "type": "string"
          },
          "templateId": {
            "allOf": [
              {
                "format": "int64",
                "type": "integer"
              }
            ],
            "nullable": true
          },
          "textContent": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.UpdateContactRequest": {
        "properties": {
          "attributes": {
            "additionalProperties": {},
            "type": "object"
          },
          "email": {
            "type": "string"
          },
          "firstName": {
            "type": "string"
          },
          "lastName": {
            "type": "string"
          },
          "status": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.UpdateIdentityRequest": {
        "properties": {
          "color": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "displayName": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "isCatchAll": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "isDefault": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "model.UpdateLabelRequest": {
        "properties": {
          "color": {
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.UpdateListRequest": {
        "properties": {
          "description": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "segmentRules": {}
        },
        "type": "object"
      },
      "model.UpdateTemplateRequest": {
        "properties": {
          "description": {
            "type": "string"
          },
          "html": {
            "type": "string"
          },
          "isActive": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "name": {
            "type": "string"
          },
          "subject": {
            "type": "string"
          },
          "text": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.UpdateWebhookRequest": {
        "properties": {
          "active": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "events": {
            "description": "Use canonical dotted event names. Legacy aliases remain accepted; webhook.test is emitted only by the test endpoint.",
            "items": {
              "enum": [
                "email.received",
                "email.sent",
                "email.delivered",
                "email.failed",
                "email.unknown",
                "email.bounced",
                "email.complained",
                "email_received",
                "email_sent",
                "email_delivered",
                "email_failed",
                "email_unknown",
                "email_bounced",
                "email_complained",
                "bounce_received",
                "complaint_received"
              ],
              "type": "string"
            },
            "type": "array"
          },
          "name": {
            "type": "string"
          },
          "url": {
            "description": "Public HTTPS only, at most 2048 bytes; redirects and private/reserved destinations are rejected.",
            "format": "uri",
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.User": {
        "properties": {
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "emailVerified": {
            "type": "boolean"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "lastLoginAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "role": {
            "description": "owner, admin, member",
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.WebhookCallResponse": {
        "properties": {
          "attempts": {
            "format": "int64",
            "type": "integer"
          },
          "completedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "error": {
            "type": "string"
          },
          "eventType": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "payload": {
            "additionalProperties": {},
            "type": "object"
          },
          "responseBody": {
            "type": "string"
          },
          "responseStatus": {
            "format": "int64",
            "type": "integer"
          },
          "responseTimeMs": {
            "format": "int64",
            "type": "integer"
          },
          "status": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.WebhookResponse": {
        "properties": {
          "active": {
            "type": "boolean"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "events": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "failureCount": {
            "format": "int64",
            "type": "integer"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "lastFailureAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "lastSuccessAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "lastTriggeredAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "name": {
            "type": "string"
          },
          "secret": {
            "description": "Only returned on creation",
            "type": "string"
          },
          "successCount": {
            "format": "int64",
            "type": "integer"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "url": {
            "type": "string"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.Workflow": {
        "properties": {
          "edges": {
            "items": {
              "$ref": "#/components/schemas/model.WorkflowEdge"
            },
            "type": "array"
          },
          "nodes": {
            "items": {
              "$ref": "#/components/schemas/model.WorkflowNode"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "model.WorkflowEdge": {
        "properties": {
          "id": {
            "type": "string"
          },
          "label": {
            "type": "string"
          },
          "source": {
            "type": "string"
          },
          "sourceHandle": {
            "type": "string"
          },
          "target": {
            "type": "string"
          },
          "targetHandle": {
            "type": "string"
          },
          "type": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.WorkflowNode": {
        "properties": {
          "data": {
            "$ref": "#/components/schemas/model.WorkflowNodeData"
          },
          "id": {
            "type": "string"
          },
          "position": {
            "$ref": "#/components/schemas/model.WorkflowPosition"
          },
          "type": {
            "description": "trigger, email, delay, condition, action",
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.WorkflowNodeData": {
        "properties": {
          "config": {
            "additionalProperties": {},
            "type": "object"
          },
          "label": {
            "type": "string"
          },
          "type": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "model.WorkflowPosition": {
        "properties": {
          "x": {
            "type": "number"
          },
          "y": {
            "type": "number"
          }
        },
        "type": "object"
      },
      "provider.CloudflareZone": {
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "status": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "provider.DMARCInspection": {
        "properties": {
          "canCreate": {
            "type": "boolean"
          },
          "checkedAt": {
            "format": "date-time",
            "type": "string"
          },
          "hostname": {
            "type": "string"
          },
          "policy": {
            "type": "string"
          },
          "policyHostname": {
            "type": "string"
          },
          "reason": {
            "type": "string"
          },
          "status": {
            "description": "Published DNS inspection state. Check canCreate/verified and reason; a suggested value is not proof it is configured.",
            "type": "string"
          },
          "suggestedValue": {
            "type": "string"
          },
          "value": {
            "type": "string"
          },
          "verified": {
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "service.AddMemberInput": {
        "properties": {
          "canManage": {
            "type": "boolean"
          },
          "canRead": {
            "type": "boolean"
          },
          "canSend": {
            "type": "boolean"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.Alert": {
        "properties": {
          "acknowledged": {
            "type": "boolean"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "data": {},
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "message": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "severity": {
            "description": "info, warning, critical",
            "type": "string"
          },
          "title": {
            "type": "string"
          },
          "type": {
            "description": "blacklist, bounce_rate, complaint_rate, quota, warmup",
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.AttachmentRef": {
        "properties": {
          "blobId": {
            "type": "string"
          },
          "cid": {
            "description": "Content-ID for inline",
            "type": "string"
          },
          "content": {
            "description": "Base64 for a newly attached file",
            "type": "string"
          },
          "disposition": {
            "description": "attachment or inline",
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "size": {
            "format": "int64",
            "type": "integer"
          },
          "type": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.AuditLog": {
        "properties": {
          "action": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "ipAddress": {
            "type": "string"
          },
          "newValues": {
            "additionalProperties": {},
            "type": "object"
          },
          "oldValues": {
            "additionalProperties": {},
            "type": "object"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "requestId": {
            "type": "string"
          },
          "resource": {
            "type": "string"
          },
          "resourceId": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "userAgent": {
            "type": "string"
          },
          "userId": {
            "allOf": [
              {
                "format": "int64",
                "type": "integer"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "service.AuthenticationOptions": {
        "properties": {
          "allowCredentials": {
            "items": {
              "$ref": "#/components/schemas/service.CredentialDescriptor"
            },
            "type": "array"
          },
          "challenge": {
            "type": "string"
          },
          "rpId": {
            "type": "string"
          },
          "timeout": {
            "format": "int64",
            "type": "integer"
          },
          "userVerification": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.AuthenticationResponse": {
        "properties": {
          "authenticatorData": {
            "type": "string"
          },
          "clientDataJSON": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "rawId": {
            "type": "string"
          },
          "signature": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "userHandle": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.AuthenticationStatus": {
        "properties": {
          "dkimConfigured": {
            "format": "int64",
            "type": "integer"
          },
          "dmarcConfigured": {
            "format": "int64",
            "type": "integer"
          },
          "domains": {
            "items": {
              "$ref": "#/components/schemas/service.DomainAuthStatus"
            },
            "type": "array"
          },
          "spfConfigured": {
            "format": "int64",
            "type": "integer"
          },
          "totalDomains": {
            "format": "int64",
            "type": "integer"
          },
          "verifiedDomains": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.AuthenticatorSelection": {
        "properties": {
          "authenticatorAttachment": {
            "type": "string"
          },
          "residentKey": {
            "type": "string"
          },
          "userVerification": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.AutoReply": {
        "properties": {
          "active": {
            "type": "boolean"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "endDate": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "excludePatterns": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "htmlContent": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "identityIds": {
            "items": {
              "format": "int64",
              "type": "integer"
            },
            "type": "array"
          },
          "lastRepliedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "replyCount": {
            "format": "int64",
            "type": "integer"
          },
          "replyOnce": {
            "type": "boolean"
          },
          "replyToAll": {
            "type": "boolean"
          },
          "startDate": {
            "format": "date-time",
            "type": "string"
          },
          "subject": {
            "type": "string"
          },
          "textContent": {
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.BlacklistCheckResponse": {
        "properties": {
          "checkedAt": {
            "format": "date-time",
            "type": "string"
          },
          "ipAddress": {
            "type": "string"
          },
          "listedCount": {
            "format": "int64",
            "type": "integer"
          },
          "results": {
            "items": {
              "$ref": "#/components/schemas/service.BlacklistResult"
            },
            "type": "array"
          },
          "totalChecked": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.BlacklistResult": {
        "properties": {
          "checkedAt": {
            "format": "date-time",
            "type": "string"
          },
          "delistUrl": {
            "type": "string"
          },
          "listed": {
            "type": "boolean"
          },
          "rbl": {
            "type": "string"
          },
          "reason": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.ComposeEmail": {
        "properties": {
          "attachments": {
            "items": {
              "$ref": "#/components/schemas/service.AttachmentRef"
            },
            "type": "array"
          },
          "bcc": {
            "items": {
              "$ref": "#/components/schemas/service.EmailAddress"
            },
            "type": "array"
          },
          "cc": {
            "items": {
              "$ref": "#/components/schemas/service.EmailAddress"
            },
            "type": "array"
          },
          "draftId": {
            "type": "string"
          },
          "draftVersion": {
            "format": "int64",
            "type": "integer"
          },
          "from": {
            "$ref": "#/components/schemas/service.EmailAddress"
          },
          "htmlBody": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "identityId": {
            "format": "int64",
            "type": "integer"
          },
          "inReplyTo": {
            "type": "string"
          },
          "isDraft": {
            "type": "boolean"
          },
          "references": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "replyTo": {
            "items": {
              "$ref": "#/components/schemas/service.EmailAddress"
            },
            "type": "array"
          },
          "subject": {
            "type": "string"
          },
          "textBody": {
            "type": "string"
          },
          "to": {
            "items": {
              "$ref": "#/components/schemas/service.EmailAddress"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "service.ConsentRecord": {
        "properties": {
          "action": {
            "description": "subscribe, unsubscribe, resubscribe, consent_given",
            "type": "string"
          },
          "contactId": {
            "format": "int64",
            "type": "integer"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "details": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "ipAddress": {
            "type": "string"
          },
          "listId": {
            "allOf": [
              {
                "format": "int64",
                "type": "integer"
              }
            ],
            "nullable": true
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "source": {
            "description": "api, form, import, one-click, preference-center",
            "type": "string"
          },
          "userAgent": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.CreateAutoReplyInput": {
        "properties": {
          "active": {
            "type": "boolean"
          },
          "endDate": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "excludePatterns": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "htmlContent": {
            "type": "string"
          },
          "identityIds": {
            "items": {
              "format": "int64",
              "type": "integer"
            },
            "type": "array"
          },
          "name": {
            "type": "string"
          },
          "replyOnce": {
            "type": "boolean"
          },
          "replyToAll": {
            "type": "boolean"
          },
          "startDate": {
            "format": "date-time",
            "type": "string"
          },
          "subject": {
            "type": "string"
          },
          "textContent": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.CreateEmailForwardInput": {
        "properties": {
          "forwardTo": {
            "type": "string"
          },
          "identityId": {
            "format": "int64",
            "type": "integer"
          },
          "keepCopy": {
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "service.CreateEmailRuleInput": {
        "properties": {
          "actions": {
            "items": {
              "$ref": "#/components/schemas/service.RuleAction"
            },
            "type": "array"
          },
          "active": {
            "type": "boolean"
          },
          "conditionLogic": {
            "type": "string"
          },
          "conditions": {
            "items": {
              "$ref": "#/components/schemas/service.RuleCondition"
            },
            "type": "array"
          },
          "description": {
            "type": "string"
          },
          "identityIds": {
            "items": {
              "format": "int64",
              "type": "integer"
            },
            "type": "array"
          },
          "name": {
            "type": "string"
          },
          "priority": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.CreatePushSubscriptionInput": {
        "properties": {
          "authKey": {
            "type": "string"
          },
          "deviceName": {
            "type": "string"
          },
          "endpoint": {
            "type": "string"
          },
          "p256dhKey": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.CreateSharedMailboxInput": {
        "properties": {
          "description": {
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.CreateSieveScriptInput": {
        "properties": {
          "active": {
            "type": "boolean"
          },
          "name": {
            "type": "string"
          },
          "script": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.CreateWebhookTriggerInput": {
        "properties": {
          "active": {
            "type": "boolean"
          },
          "description": {
            "type": "string"
          },
          "filters": {
            "additionalProperties": {},
            "type": "object"
          },
          "name": {
            "type": "string"
          },
          "triggerType": {
            "description": "Use a canonical dotted event name. Legacy underscored aliases are accepted; webhook.test is emitted only by the test endpoint.",
            "enum": [
              "email.received",
              "email.sent",
              "email.delivered",
              "email.failed",
              "email.unknown",
              "email.bounced",
              "email.complained",
              "email_received",
              "email_sent",
              "email_delivered",
              "email_failed",
              "email_unknown",
              "email_bounced",
              "email_complained",
              "bounce_received",
              "complaint_received"
            ],
            "type": "string"
          },
          "webhookUrl": {
            "description": "Public HTTPS only, at most 2048 bytes; no credentials/fragments/private or reserved destinations. Redirects are rejected.",
            "format": "uri",
            "type": "string"
          }
        },
        "required": [
          "name",
          "triggerType",
          "webhookUrl"
        ],
        "type": "object"
      },
      "service.CredentialDescriptor": {
        "properties": {
          "id": {
            "type": "string"
          },
          "transports": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "type": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.DomainAuthStatus": {
        "properties": {
          "dkimVerified": {
            "type": "boolean"
          },
          "dmarcVerified": {
            "type": "boolean"
          },
          "domain": {
            "type": "string"
          },
          "sesVerified": {
            "type": "boolean"
          },
          "spfVerified": {
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "service.DomainMetrics": {
        "properties": {
          "bounceRate": {
            "type": "number"
          },
          "bounced": {
            "format": "int64",
            "type": "integer"
          },
          "complaintRate": {
            "type": "number"
          },
          "complaints": {
            "format": "int64",
            "type": "integer"
          },
          "delivered": {
            "format": "int64",
            "type": "integer"
          },
          "deliveryRate": {
            "type": "number"
          },
          "domain": {
            "type": "string"
          },
          "sent": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.DraftResult": {
        "properties": {
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "identityId": {
            "format": "int64",
            "type": "integer"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "version": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.EmailAddress": {
        "properties": {
          "email": {
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.EmailForTestInput": {
        "properties": {
          "body": {
            "type": "string"
          },
          "from": {
            "type": "string"
          },
          "headers": {
            "additionalProperties": {
              "type": "string"
            },
            "type": "object"
          },
          "subject": {
            "type": "string"
          },
          "to": {
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "service.EmailForward": {
        "properties": {
          "active": {
            "type": "boolean"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "forwardCount": {
            "format": "int64",
            "type": "integer"
          },
          "forwardTo": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "identityId": {
            "format": "int64",
            "type": "integer"
          },
          "keepCopy": {
            "type": "boolean"
          },
          "lastForwardedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          },
          "verified": {
            "type": "boolean"
          },
          "verifiedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "service.EmailHealthSummary": {
        "properties": {
          "authStatus": {
            "$ref": "#/components/schemas/service.AuthenticationStatus"
          },
          "healthScore": {
            "format": "int64",
            "type": "integer"
          },
          "healthStatus": {
            "description": "excellent, good, warning, critical",
            "type": "string"
          },
          "receivingMetrics": {
            "$ref": "#/components/schemas/service.ReceivingMetrics"
          },
          "sendingMetrics": {
            "$ref": "#/components/schemas/service.ReputationMetrics"
          },
          "sesLimits": {
            "allOf": [
              {
                "$ref": "#/components/schemas/service.SESAccountLimits"
              }
            ],
            "nullable": true
          },
          "warnings": {
            "items": {
              "$ref": "#/components/schemas/service.HealthWarning"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "service.EmailRule": {
        "properties": {
          "actions": {
            "items": {
              "$ref": "#/components/schemas/service.RuleAction"
            },
            "type": "array"
          },
          "active": {
            "type": "boolean"
          },
          "conditionLogic": {
            "description": "\"all\" or \"any\"",
            "type": "string"
          },
          "conditions": {
            "items": {
              "$ref": "#/components/schemas/service.RuleCondition"
            },
            "type": "array"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "identityIds": {
            "items": {
              "format": "int64",
              "type": "integer"
            },
            "type": "array"
          },
          "lastMatchedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "matchCount": {
            "format": "int64",
            "type": "integer"
          },
          "migrationWarning": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "priority": {
            "format": "int64",
            "type": "integer"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.HealthWarning": {
        "properties": {
          "action": {
            "type": "string"
          },
          "message": {
            "type": "string"
          },
          "severity": {
            "description": "info, warning, critical",
            "type": "string"
          },
          "title": {
            "type": "string"
          },
          "type": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.InboxFilterTestInput": {
        "properties": {
          "body": {
            "type": "string"
          },
          "from": {
            "type": "string"
          },
          "hasAttachments": {
            "type": "boolean"
          },
          "subject": {
            "type": "string"
          },
          "to": {
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "service.ListInfo": {
        "properties": {
          "description": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "name": {
            "type": "string"
          },
          "subscribed": {
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "service.MailboxChange": {
        "properties": {
          "changedAt": {
            "format": "date-time",
            "type": "string"
          },
          "cursor": {
            "type": "string"
          },
          "domainId": {
            "format": "int64",
            "type": "integer"
          },
          "identityId": {
            "format": "int64",
            "type": "integer"
          },
          "messageUuid": {
            "type": "string"
          },
          "operation": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.MailboxChanges": {
        "properties": {
          "changes": {
            "items": {
              "$ref": "#/components/schemas/service.MailboxChange"
            },
            "type": "array"
          },
          "hasMore": {
            "type": "boolean"
          },
          "nextCursor": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.OAuthConnection": {
        "properties": {
          "avatarUrl": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "name": {
            "type": "string"
          },
          "provider": {
            "type": "string"
          },
          "providerUserId": {
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.PreferenceData": {
        "properties": {
          "allLists": {
            "items": {
              "$ref": "#/components/schemas/service.ListInfo"
            },
            "type": "array"
          },
          "contactId": {
            "format": "int64",
            "type": "integer"
          },
          "email": {
            "type": "string"
          },
          "subscribedLists": {
            "items": {
              "format": "int64",
              "type": "integer"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "service.ProvisionedResources": {
        "properties": {
          "lambdaFunctionArn": {
            "type": "string"
          },
          "lambdaRoleArn": {
            "type": "string"
          },
          "receiptRuleSetName": {
            "type": "string"
          },
          "region": {
            "type": "string"
          },
          "s3BucketArn": {
            "type": "string"
          },
          "s3BucketName": {
            "type": "string"
          },
          "snsTopicArn": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.PubKeyCredParam": {
        "properties": {
          "alg": {
            "format": "int64",
            "type": "integer"
          },
          "type": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.PushSubscription": {
        "properties": {
          "active": {
            "type": "boolean"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "deviceName": {
            "type": "string"
          },
          "endpoint": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "lastUsedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "notifyCampaign": {
            "type": "boolean"
          },
          "notifyMentions": {
            "type": "boolean"
          },
          "notifyNewEmail": {
            "type": "boolean"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.QuotaStatus": {
        "properties": {
          "dailyLimit": {
            "format": "int64",
            "type": "integer"
          },
          "dailyPercentage": {
            "type": "number"
          },
          "dailyRemaining": {
            "format": "int64",
            "type": "integer"
          },
          "dailyUsed": {
            "format": "int64",
            "type": "integer"
          },
          "monthlyLimit": {
            "format": "int64",
            "type": "integer"
          },
          "monthlyPercentage": {
            "type": "number"
          },
          "monthlyRemaining": {
            "format": "int64",
            "type": "integer"
          },
          "monthlyUsed": {
            "format": "int64",
            "type": "integer"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.RPEntity": {
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.ReceivingMetrics": {
        "properties": {
          "byIdentity": {
            "additionalProperties": {
              "format": "int64",
              "type": "integer"
            },
            "type": "object"
          },
          "readRate": {
            "type": "number"
          },
          "spamRate": {
            "type": "number"
          },
          "totalRead": {
            "format": "int64",
            "type": "integer"
          },
          "totalReceived": {
            "format": "int64",
            "type": "integer"
          },
          "totalSpam": {
            "format": "int64",
            "type": "integer"
          },
          "totalVirus": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.RegistrationOptions": {
        "properties": {
          "attestation": {
            "type": "string"
          },
          "authenticatorSelection": {
            "$ref": "#/components/schemas/service.AuthenticatorSelection"
          },
          "challenge": {
            "type": "string"
          },
          "excludeCredentials": {
            "items": {
              "$ref": "#/components/schemas/service.CredentialDescriptor"
            },
            "type": "array"
          },
          "pubKeyCredParams": {
            "items": {
              "$ref": "#/components/schemas/service.PubKeyCredParam"
            },
            "type": "array"
          },
          "rp": {
            "$ref": "#/components/schemas/service.RPEntity"
          },
          "timeout": {
            "format": "int64",
            "type": "integer"
          },
          "user": {
            "$ref": "#/components/schemas/service.UserEntity"
          }
        },
        "type": "object"
      },
      "service.RegistrationResponse": {
        "properties": {
          "attestationObject": {
            "type": "string"
          },
          "clientDataJSON": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "rawId": {
            "type": "string"
          },
          "transports": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "type": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.ReputationMetrics": {
        "properties": {
          "bounceRate": {
            "type": "number"
          },
          "byDomain": {
            "additionalProperties": {
              "$ref": "#/components/schemas/service.DomainMetrics"
            },
            "type": "object"
          },
          "complaintRate": {
            "type": "number"
          },
          "deliveryRate": {
            "type": "number"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "period": {
            "type": "string"
          },
          "score": {
            "format": "int64",
            "type": "integer"
          },
          "spamRate": {
            "type": "number"
          },
          "totalBounced": {
            "format": "int64",
            "type": "integer"
          },
          "totalComplaints": {
            "format": "int64",
            "type": "integer"
          },
          "totalDelivered": {
            "format": "int64",
            "type": "integer"
          },
          "totalFailed": {
            "format": "int64",
            "type": "integer"
          },
          "totalReceived": {
            "format": "int64",
            "type": "integer"
          },
          "totalSent": {
            "format": "int64",
            "type": "integer"
          },
          "totalSpam": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.RuleAction": {
        "properties": {
          "type": {
            "description": "move_to_folder, add_label, mark_read, mark_starred, forward, delete, auto_reply, stop_processing",
            "type": "string"
          },
          "value": {
            "description": "Folder name, label name, forward address, etc.",
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.RuleCondition": {
        "properties": {
          "caseSensitive": {
            "type": "boolean"
          },
          "field": {
            "description": "from, to, subject, body, header",
            "type": "string"
          },
          "headerName": {
            "description": "Only for field=\"header\"",
            "type": "string"
          },
          "operator": {
            "description": "contains, equals, matches, starts_with, ends_with, not_contains, not_equals",
            "type": "string"
          },
          "value": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.SESAccountLimits": {
        "properties": {
          "max24HourSend": {
            "type": "number"
          },
          "maxSendRate": {
            "type": "number"
          },
          "remaining24Hour": {
            "type": "number"
          },
          "sandboxMode": {
            "type": "boolean"
          },
          "sendingEnabled": {
            "type": "boolean"
          },
          "sentLast24Hours": {
            "type": "number"
          },
          "usagePercentage": {
            "type": "number"
          }
        },
        "type": "object"
      },
      "service.SendEmailResult": {
        "properties": {
          "emailId": {
            "type": "string"
          },
          "messageId": {
            "type": "string"
          },
          "sendError": {
            "type": "string"
          },
          "sentAt": {
            "format": "date-time",
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "threadId": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.SendingReadiness": {
        "properties": {
          "checkedAt": {
            "format": "date-time",
            "type": "string"
          },
          "domainUuid": {
            "type": "string"
          },
          "feedbackConfigured": {
            "type": "boolean"
          },
          "feedbackReady": {
            "type": "boolean"
          },
          "reason": {
            "type": "string"
          },
          "storageReady": {
            "type": "boolean"
          },
          "subscriptionStatus": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.SharedMailbox": {
        "properties": {
          "autoReplyEnabled": {
            "type": "boolean"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "memberCount": {
            "format": "int64",
            "type": "integer"
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.SharedMailboxMember": {
        "properties": {
          "canManage": {
            "type": "boolean"
          },
          "canRead": {
            "type": "boolean"
          },
          "canSend": {
            "type": "boolean"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "sharedMailboxId": {
            "format": "int64",
            "type": "integer"
          },
          "userEmail": {
            "type": "string"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "userName": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.SieveScript": {
        "properties": {
          "active": {
            "type": "boolean"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "isDefault": {
            "type": "boolean"
          },
          "isValid": {
            "type": "boolean"
          },
          "lastError": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "script": {
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.TenantBranding": {
        "properties": {
          "accentColor": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "customDomain": {
            "type": "string"
          },
          "customDomainVerified": {
            "type": "boolean"
          },
          "emailFooterHtml": {
            "type": "string"
          },
          "emailHeaderHtml": {
            "type": "string"
          },
          "faviconUrl": {
            "type": "string"
          },
          "hidePoweredBy": {
            "type": "boolean"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "logoLightUrl": {
            "type": "string"
          },
          "logoUrl": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "primaryColor": {
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.TwoFactorSetup": {
        "properties": {
          "manualCode": {
            "type": "string"
          },
          "qrCodeUrl": {
            "type": "string"
          },
          "secret": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.UnifiedEmail": {
        "properties": {
          "blobId": {
            "type": "string"
          },
          "cc": {
            "items": {
              "$ref": "#/components/schemas/service.EmailAddress"
            },
            "type": "array"
          },
          "domainColor": {
            "type": "string"
          },
          "domainId": {
            "format": "int64",
            "type": "integer"
          },
          "domainName": {
            "type": "string"
          },
          "from": {
            "items": {
              "$ref": "#/components/schemas/service.EmailAddress"
            },
            "type": "array"
          },
          "hasAttachment": {
            "type": "boolean"
          },
          "id": {
            "type": "string"
          },
          "identityEmail": {
            "type": "string"
          },
          "identityId": {
            "format": "int64",
            "type": "integer"
          },
          "identityUuid": {
            "type": "string"
          },
          "isDraft": {
            "type": "boolean"
          },
          "isFlagged": {
            "type": "boolean"
          },
          "isRead": {
            "type": "boolean"
          },
          "keywords": {
            "additionalProperties": {
              "type": "boolean"
            },
            "type": "object"
          },
          "mailboxIds": {
            "additionalProperties": {
              "type": "boolean"
            },
            "type": "object"
          },
          "preview": {
            "type": "string"
          },
          "receivedAt": {
            "format": "date-time",
            "type": "string"
          },
          "size": {
            "format": "int64",
            "type": "integer"
          },
          "subject": {
            "type": "string"
          },
          "threadCount": {
            "format": "int64",
            "type": "integer"
          },
          "threadId": {
            "type": "string"
          },
          "to": {
            "items": {
              "$ref": "#/components/schemas/service.EmailAddress"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "service.UnifiedInboxResponse": {
        "properties": {
          "emails": {
            "items": {
              "$ref": "#/components/schemas/service.UnifiedEmail"
            },
            "type": "array"
          },
          "hasMore": {
            "type": "boolean"
          },
          "page": {
            "format": "int64",
            "type": "integer"
          },
          "pageSize": {
            "format": "int64",
            "type": "integer"
          },
          "total": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.UnifiedMailbox": {
        "properties": {
          "domainId": {
            "format": "int64",
            "type": "integer"
          },
          "domainName": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "identityEmail": {
            "type": "string"
          },
          "identityId": {
            "format": "int64",
            "type": "integer"
          },
          "identityUuid": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "parentId": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "role": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "sortOrder": {
            "format": "int64",
            "type": "integer"
          },
          "totalEmails": {
            "format": "int64",
            "type": "integer"
          },
          "totalThreads": {
            "format": "int64",
            "type": "integer"
          },
          "unreadEmails": {
            "format": "int64",
            "type": "integer"
          },
          "unreadThreads": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.UpdateAutoReplyInput": {
        "properties": {
          "active": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "endDate": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "excludePatterns": {
            "allOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              }
            ],
            "nullable": true
          },
          "htmlContent": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "identityIds": {
            "allOf": [
              {
                "items": {
                  "format": "int64",
                  "type": "integer"
                },
                "type": "array"
              }
            ],
            "nullable": true
          },
          "name": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "replyOnce": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "replyToAll": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "startDate": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "subject": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "textContent": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "service.UpdateBrandingInput": {
        "properties": {
          "accentColor": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "customDomain": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "emailFooterHtml": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "emailHeaderHtml": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "faviconUrl": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "hidePoweredBy": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "logoLightUrl": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "logoUrl": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "primaryColor": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "service.UpdateEmailRuleInput": {
        "properties": {
          "actions": {
            "allOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/service.RuleAction"
                },
                "type": "array"
              }
            ],
            "nullable": true
          },
          "active": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "conditionLogic": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "conditions": {
            "allOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/service.RuleCondition"
                },
                "type": "array"
              }
            ],
            "nullable": true
          },
          "description": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "identityIds": {
            "allOf": [
              {
                "items": {
                  "format": "int64",
                  "type": "integer"
                },
                "type": "array"
              }
            ],
            "nullable": true
          },
          "name": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "priority": {
            "allOf": [
              {
                "format": "int64",
                "type": "integer"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "service.UpdateSettingsRequest": {
        "properties": {
          "autoAdvance": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "autoOrganizeDmarcReports": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "description": "Optional. Omit to preserve the current setting; false opts out for future arrivals without moving existing mail.",
            "nullable": true
          },
          "blacklistAlerts": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "bounceRateWarnings": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "browserNotifications": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "campaignReports": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "conversationView": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "density": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "displayName": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "inboxLayout": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "newEmailNotifications": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "quotaWarnings": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "showSnippets": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          },
          "theme": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "weeklyDigest": {
            "allOf": [
              {
                "type": "boolean"
              }
            ],
            "nullable": true
          }
        },
        "type": "object"
      },
      "service.UserEntity": {
        "properties": {
          "displayName": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.UserSession": {
        "properties": {
          "active": {
            "type": "boolean"
          },
          "browser": {
            "type": "string"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "deviceName": {
            "type": "string"
          },
          "deviceType": {
            "type": "string"
          },
          "expiresAt": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "ipAddress": {
            "type": "string"
          },
          "isCurrent": {
            "description": "Indicates if this is the current session",
            "type": "boolean"
          },
          "lastSeenAt": {
            "format": "date-time",
            "type": "string"
          },
          "location": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "os": {
            "type": "string"
          },
          "revokedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.UserSettings": {
        "properties": {
          "autoAdvance": {
            "type": "boolean"
          },
          "autoOrganizeDmarcReports": {
            "default": true,
            "description": "Automatically file qualifying authenticated aggregate reports for this user. Does not configure DNS or receiving.",
            "type": "boolean"
          },
          "blacklistAlerts": {
            "type": "boolean"
          },
          "bounceRateWarnings": {
            "type": "boolean"
          },
          "browserNotifications": {
            "type": "boolean"
          },
          "campaignReports": {
            "type": "boolean"
          },
          "conversationView": {
            "type": "boolean"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "density": {
            "type": "string"
          },
          "displayName": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "inboxLayout": {
            "type": "string"
          },
          "newEmailNotifications": {
            "type": "boolean"
          },
          "quotaWarnings": {
            "type": "boolean"
          },
          "showSnippets": {
            "type": "boolean"
          },
          "theme": {
            "type": "string"
          },
          "twoFactorEnabled": {
            "type": "boolean"
          },
          "twoFactorMethod": {
            "allOf": [
              {
                "type": "string"
              }
            ],
            "nullable": true
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "weeklyDigest": {
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "service.WarmupSchedule": {
        "properties": {
          "days": {
            "description": "Daily limits for each day",
            "items": {
              "format": "int64",
              "type": "integer"
            },
            "type": "array"
          },
          "description": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "totalDays": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.WarmupStatus": {
        "properties": {
          "completedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "currentDay": {
            "format": "int64",
            "type": "integer"
          },
          "dailyLimit": {
            "format": "int64",
            "type": "integer"
          },
          "ipAddress": {
            "type": "string"
          },
          "pauseReason": {
            "type": "string"
          },
          "scheduleName": {
            "type": "string"
          },
          "sentToday": {
            "format": "int64",
            "type": "integer"
          },
          "startedAt": {
            "format": "date-time",
            "type": "string"
          },
          "status": {
            "description": "active, paused, completed",
            "type": "string"
          },
          "totalSent": {
            "format": "int64",
            "type": "integer"
          }
        },
        "type": "object"
      },
      "service.WebAuthnCredential": {
        "properties": {
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "credentialId": {
            "description": "Base64 encoded",
            "type": "string"
          },
          "deviceType": {
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "lastUsedAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "name": {
            "type": "string"
          },
          "transports": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "service.WebhookTrigger": {
        "properties": {
          "active": {
            "type": "boolean"
          },
          "createdAt": {
            "format": "date-time",
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "filters": {
            "additionalProperties": {},
            "type": "object"
          },
          "id": {
            "format": "int64",
            "type": "integer"
          },
          "lastTriggeredAt": {
            "allOf": [
              {
                "format": "date-time",
                "type": "string"
              }
            ],
            "nullable": true
          },
          "name": {
            "type": "string"
          },
          "orgId": {
            "format": "int64",
            "type": "integer"
          },
          "secret": {
            "type": "string"
          },
          "triggerCount": {
            "format": "int64",
            "type": "integer"
          },
          "triggerType": {
            "type": "string"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string"
          },
          "userId": {
            "format": "int64",
            "type": "integer"
          },
          "uuid": {
            "type": "string"
          },
          "webhookUrl": {
            "type": "string"
          }
        },
        "type": "object"
      }
    },
    "securitySchemes": {
      "bearerAuth": {
        "description": "Scoped Mailat API key or active human session JWT.",
        "scheme": "bearer",
        "type": "http"
      }
    }
  },
  "info": {
    "description": "Self-hosted SES email automation. API keys use Authorization: Bearer ue_… and explicit per-operation scopes. Human-only administration is marked. Inbox detail is non-mutating. Webhooks use version 1 events and HMAC-SHA256 over timestamp + '.' + raw body. Cursor retention is 90 days.",
    "title": "Mailat API",
    "version": "2026-10-04"
  },
  "openapi": "3.0.3",
  "paths": {
    "/api/v1/api-keys": {
      "get": {
        "description": "ListAPIKeys returns all API keys for the organization\nGET /api/v1/api-keys",
        "operationId": "get_api_v1_api_keys",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/model.ApiKeyResponse"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListAPIKeys",
        "tags": [
          "api-keys"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "post": {
        "description": "CreateAPIKey generates a new API key\nPOST /api/v1/api-keys",
        "operationId": "post_api_v1_api_keys",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.CreateApiKeyRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.ApiKeyResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "CreateAPIKey",
        "tags": [
          "api-keys"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/api-keys/{uuid}": {
      "delete": {
        "description": "DeleteAPIKey revokes an API key\nDELETE /api/v1/api-keys/:uuid",
        "operationId": "delete_api_v1_api_keys_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteAPIKey",
        "tags": [
          "api-keys"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/2fa/challenge": {
      "post": {
        "description": "CompleteChallenge accepts a one-use password/OAuth challenge, never an API key.",
        "operationId": "post_api_v1_auth_2fa_challenge",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "challengeToken": {
                    "type": "string"
                  },
                  "code": {
                    "type": "string"
                  }
                },
                "required": [
                  "challengeToken",
                  "code"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.LoginResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "CompleteChallenge",
        "tags": [
          "auth"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/2fa/disable": {
      "post": {
        "description": "Disable2FA disables 2FA for the user\nPOST /api/v1/security/2fa/disable",
        "operationId": "post_api_v1_auth_2fa_disable",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "code": {
                    "type": "string"
                  },
                  "password": {
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Disable2FA",
        "tags": [
          "auth"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/2fa/enable": {
      "post": {
        "description": "Setup2FA starts the 2FA setup process\nPOST /api/v1/security/2fa/setup",
        "operationId": "post_api_v1_auth_2fa_enable",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.TwoFactorSetup"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Setup2FA",
        "tags": [
          "auth"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/2fa/verify": {
      "post": {
        "description": "Verify2FA verifies a TOTP code and enables 2FA\nPOST /api/v1/security/2fa/verify",
        "operationId": "post_api_v1_auth_2fa_verify",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "code": {
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "backupCodes": {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Verify2FA",
        "tags": [
          "auth"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/change-password": {
      "post": {
        "description": "ChangePassword changes the user's password\nPOST /api/v1/auth/change-password",
        "operationId": "post_api_v1_auth_change_password",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "currentPassword": {
                    "type": "string"
                  },
                  "newPassword": {
                    "minLength": 8,
                    "type": "string"
                  }
                },
                "required": [
                  "currentPassword",
                  "newPassword"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ChangePassword",
        "tags": [
          "auth"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/login": {
      "post": {
        "description": "Login authenticates a user\nPOST /api/v1/auth/login",
        "operationId": "post_api_v1_auth_login",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.LoginRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.LoginResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "Login",
        "tags": [
          "auth"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/logout": {
      "post": {
        "description": "Logout",
        "operationId": "post_api_v1_auth_logout",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Logout",
        "tags": [
          "auth"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/me": {
      "get": {
        "description": "Me returns the current user's profile\nGET /api/v1/auth/me",
        "operationId": "get_api_v1_auth_me",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.User"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Me",
        "tags": [
          "auth"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/register": {
      "post": {
        "description": "Register creates a new user and organization\nPOST /api/v1/auth/register",
        "operationId": "post_api_v1_auth_register",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.RegisterRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.AuthResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "Register",
        "tags": [
          "auth"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/register-status": {
      "get": {
        "description": "RegisterStatus checks if registration is open\nGET /api/v1/auth/register-status",
        "operationId": "get_api_v1_auth_register_status",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "open": {
                          "type": "boolean"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "RegisterStatus",
        "tags": [
          "auth"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/sessions": {
      "get": {
        "description": "ListSessions returns all active sessions for the current user\nGET /api/v1/security/sessions",
        "operationId": "get_api_v1_auth_sessions",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "sessions": {
                          "items": {
                            "allOf": [
                              {
                                "$ref": "#/components/schemas/service.UserSession"
                              }
                            ],
                            "nullable": true
                          },
                          "type": "array"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListSessions",
        "tags": [
          "auth"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/sessions/revoke-all": {
      "post": {
        "description": "RevokeAllSessions revokes all sessions except the current one\nPOST /api/v1/security/sessions/revoke-all",
        "operationId": "post_api_v1_auth_sessions_revoke_all",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "revokedCount": {
                          "format": "int64",
                          "type": "integer"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "RevokeAllSessions",
        "tags": [
          "auth"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/sessions/{uuid}": {
      "delete": {
        "description": "RevokeSession revokes a specific session\nDELETE /api/v1/security/sessions/:uuid",
        "operationId": "delete_api_v1_auth_sessions_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "RevokeSession",
        "tags": [
          "auth"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auth/stream-token": {
      "post": {
        "description": "StreamToken",
        "operationId": "post_api_v1_auth_stream_token",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "expiresAt": {
                          "format": "date-time",
                          "type": "string"
                        },
                        "token": {
                          "type": "string"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "StreamToken",
        "tags": [
          "auth"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/auto-replies": {
      "get": {
        "description": "ListAutoReplies lists all auto-replies for the user\nGET /api/v1/auto-replies",
        "operationId": "get_api_v1_auto_replies",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/service.AutoReply"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListAutoReplies",
        "tags": [
          "auto-replies"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      },
      "post": {
        "description": "CreateAutoReply creates a new auto-reply\nPOST /api/v1/auto-replies",
        "operationId": "post_api_v1_auto_replies",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.CreateAutoReplyInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.AutoReply"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "CreateAutoReply",
        "tags": [
          "auto-replies"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      }
    },
    "/api/v1/auto-replies/{id}": {
      "delete": {
        "description": "DeleteAutoReply deletes an auto-reply\nDELETE /api/v1/auto-replies/:id",
        "operationId": "delete_api_v1_auto_replies_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteAutoReply",
        "tags": [
          "auto-replies"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      },
      "get": {
        "description": "GetAutoReply gets an auto-reply by ID\nGET /api/v1/auto-replies/:id",
        "operationId": "get_api_v1_auto_replies_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.AutoReply"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetAutoReply",
        "tags": [
          "auto-replies"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      },
      "put": {
        "description": "UpdateAutoReply updates an auto-reply\nPUT /api/v1/auto-replies/:id",
        "operationId": "put_api_v1_auto_replies_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.UpdateAutoReplyInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.AutoReply"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UpdateAutoReply",
        "tags": [
          "auto-replies"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      }
    },
    "/api/v1/automations": {
      "get": {
        "description": "List retrieves automations with pagination\nGET /api/v1/automations",
        "operationId": "get_api_v1_automations",
        "parameters": [
          {
            "in": "query",
            "name": "page",
            "schema": {
              "default": 1,
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "pageSize",
            "schema": {
              "default": 20,
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "status",
            "schema": {
              "default": "",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.AutomationListResult"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "List",
        "tags": [
          "automations"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "post": {
        "description": "Create creates a new automation\nPOST /api/v1/automations",
        "operationId": "post_api_v1_automations",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.CreateAutomationRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Automation"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Create",
        "tags": [
          "automations"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/automations/{uuid}": {
      "delete": {
        "description": "Delete deletes an automation\nDELETE /api/v1/automations/:uuid",
        "operationId": "delete_api_v1_automations_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Delete",
        "tags": [
          "automations"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "get": {
        "description": "Get retrieves an automation by UUID\nGET /api/v1/automations/:uuid",
        "operationId": "get_api_v1_automations_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Automation"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Get",
        "tags": [
          "automations"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "put": {
        "description": "Update updates an automation\nPUT /api/v1/automations/:uuid",
        "operationId": "put_api_v1_automations_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.UpdateAutomationRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Automation"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Update",
        "tags": [
          "automations"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/automations/{uuid}/activate": {
      "post": {
        "description": "Activate activates an automation\nPOST /api/v1/automations/:uuid/activate",
        "operationId": "post_api_v1_automations_uuid_activate",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Automation"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Activate",
        "tags": [
          "automations"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/automations/{uuid}/enroll": {
      "post": {
        "description": "EnrollContact enrolls a contact in an automation\nPOST /api/v1/automations/:uuid/enroll",
        "operationId": "post_api_v1_automations_uuid_enroll",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "contactUuid": {
                    "type": "string"
                  }
                },
                "required": [
                  "contactUuid"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "EnrollContact",
        "tags": [
          "automations"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/automations/{uuid}/pause": {
      "post": {
        "description": "Pause pauses an automation\nPOST /api/v1/automations/:uuid/pause",
        "operationId": "post_api_v1_automations_uuid_pause",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Automation"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Pause",
        "tags": [
          "automations"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/automations/{uuid}/stats": {
      "get": {
        "description": "GetStats retrieves automation statistics\nGET /api/v1/automations/:uuid/stats",
        "operationId": "get_api_v1_automations_uuid_stats",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.AutomationStats"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetStats",
        "tags": [
          "automations"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/branding": {
      "get": {
        "description": "GetBranding gets organization branding\nGET /api/v1/branding",
        "operationId": "get_api_v1_branding",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.TenantBranding"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetBranding",
        "tags": [
          "branding"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "put": {
        "description": "UpdateBranding updates organization branding\nPUT /api/v1/branding",
        "operationId": "put_api_v1_branding",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.UpdateBrandingInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.TenantBranding"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UpdateBranding",
        "tags": [
          "branding"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/branding/css": {
      "get": {
        "description": "GetBrandingCSS returns CSS variables for branding\nGET /api/v1/branding/css",
        "operationId": "get_api_v1_branding_css",
        "responses": {
          "200": {
            "content": {
              "text/css": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "description": "Brand CSS variables"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetBrandingCSS",
        "tags": [
          "branding"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/branding/verify-domain": {
      "post": {
        "description": "VerifyCustomDomain initiates custom domain verification\nPOST /api/v1/branding/verify-domain",
        "operationId": "post_api_v1_branding_verify_domain",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "instructions": {
                          "type": "string"
                        },
                        "verificationToken": {
                          "type": "string"
                        },
                        "verified": {
                          "type": "boolean"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "VerifyCustomDomain",
        "tags": [
          "branding"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/campaigns": {
      "get": {
        "description": "List retrieves campaigns with pagination\nGET /api/v1/campaigns",
        "operationId": "get_api_v1_campaigns",
        "parameters": [
          {
            "in": "query",
            "name": "page",
            "schema": {
              "default": 1,
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "pageSize",
            "schema": {
              "default": 20,
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "status",
            "schema": {
              "default": "",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.CampaignListResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "List",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "post": {
        "description": "Create creates a new campaign\nPOST /api/v1/campaigns",
        "operationId": "post_api_v1_campaigns",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.CreateCampaignRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Campaign"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Create",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/campaigns/{uuid}": {
      "delete": {
        "description": "Delete deletes a campaign\nDELETE /api/v1/campaigns/:uuid",
        "operationId": "delete_api_v1_campaigns_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Delete",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "get": {
        "description": "Get retrieves a campaign by UUID\nGET /api/v1/campaigns/:uuid",
        "operationId": "get_api_v1_campaigns_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Campaign"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Get",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "put": {
        "description": "Update updates a campaign\nPUT /api/v1/campaigns/:uuid",
        "operationId": "put_api_v1_campaigns_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.UpdateCampaignRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Campaign"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Update",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/campaigns/{uuid}/cancel": {
      "post": {
        "description": "Cancel cancels a campaign\nPOST /api/v1/campaigns/:uuid/cancel",
        "operationId": "post_api_v1_campaigns_uuid_cancel",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Campaign"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Cancel",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/campaigns/{uuid}/pause": {
      "post": {
        "description": "Pause pauses a sending campaign\nPOST /api/v1/campaigns/:uuid/pause",
        "operationId": "post_api_v1_campaigns_uuid_pause",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Campaign"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Pause",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/campaigns/{uuid}/preview": {
      "post": {
        "description": "Preview renders a campaign preview\nPOST /api/v1/campaigns/:uuid/preview",
        "operationId": "post_api_v1_campaigns_uuid_preview",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "additionalProperties": {
                        "type": "string"
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Preview",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/campaigns/{uuid}/resume": {
      "post": {
        "description": "Resume resumes a paused campaign\nPOST /api/v1/campaigns/:uuid/resume",
        "operationId": "post_api_v1_campaigns_uuid_resume",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Campaign"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Resume",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/campaigns/{uuid}/schedule": {
      "post": {
        "description": "Schedule schedules a campaign for future sending\nPOST /api/v1/campaigns/:uuid/schedule",
        "operationId": "post_api_v1_campaigns_uuid_schedule",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.ScheduleCampaignRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Campaign"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Schedule",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/campaigns/{uuid}/send": {
      "post": {
        "description": "SendNow starts sending a campaign immediately\nPOST /api/v1/campaigns/:uuid/send",
        "operationId": "post_api_v1_campaigns_uuid_send",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Campaign"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SendNow",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/campaigns/{uuid}/stats": {
      "get": {
        "description": "GetStats retrieves campaign statistics\nGET /api/v1/campaigns/:uuid/stats",
        "operationId": "get_api_v1_campaigns_uuid_stats",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.CampaignStatsResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetStats",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/campaigns/{uuid}/test": {
      "post": {
        "description": "SendTest sends a test email for a campaign\nPOST /api/v1/campaigns/:uuid/test",
        "operationId": "post_api_v1_campaigns_uuid_test",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "email": {
                    "format": "email",
                    "type": "string"
                  }
                },
                "required": [
                  "email"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SendTest",
        "tags": [
          "campaigns"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/compose/attachments": {
      "post": {
        "description": "UploadAttachment uploads an attachment\nPOST /api/v1/compose/attachments",
        "operationId": "post_api_v1_compose_attachments",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "properties": {
                  "file": {
                    "format": "binary",
                    "type": "string"
                  },
                  "identityId": {
                    "type": "integer"
                  }
                },
                "required": [
                  "identityId",
                  "file"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.AttachmentRef"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UploadAttachment",
        "tags": [
          "compose"
        ],
        "x-api-key-scope": "email:send",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "Primary SES compose workflow. Reply/forward contexts use public SES mailbox UUIDs; draft and attachment operations use owned records. In legacy non-SES configurations, sending can fall back to JMAP."
      }
    },
    "/api/v1/compose/drafts": {
      "post": {
        "description": "SaveDraft saves an email as a draft\nPOST /api/v1/compose/drafts",
        "operationId": "post_api_v1_compose_drafts",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "identityId": 1,
                "subject": "Draft",
                "textBody": "In progress",
                "to": [
                  {
                    "email": "recipient@example.net"
                  }
                ]
              },
              "schema": {
                "$ref": "#/components/schemas/model.SaveDraftRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.DraftResult"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SaveDraft",
        "tags": [
          "compose"
        ],
        "x-api-key-scope": "email:send",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "Primary SES compose workflow. Reply/forward contexts use public SES mailbox UUIDs; draft and attachment operations use owned records. In legacy non-SES configurations, sending can fall back to JMAP."
      }
    },
    "/api/v1/compose/drafts/{id}": {
      "delete": {
        "description": "DeleteDraft deletes a draft\nDELETE /api/v1/compose/drafts/:id",
        "operationId": "delete_api_v1_compose_drafts_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteDraft",
        "tags": [
          "compose"
        ],
        "x-api-key-scope": "email:send",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "Primary SES compose workflow. Reply/forward contexts use public SES mailbox UUIDs; draft and attachment operations use owned records. In legacy non-SES configurations, sending can fall back to JMAP."
      },
      "put": {
        "description": "UpdateDraft updates an existing draft\nPUT /api/v1/compose/drafts/:id",
        "operationId": "put_api_v1_compose_drafts_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "identityId": 1,
                "subject": "Updated draft",
                "textBody": "In progress",
                "version": 1
              },
              "schema": {
                "$ref": "#/components/schemas/model.SaveDraftRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.DraftResult"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UpdateDraft",
        "tags": [
          "compose"
        ],
        "x-api-key-scope": "email:send",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "Primary SES compose workflow. Reply/forward contexts use public SES mailbox UUIDs; draft and attachment operations use owned records. In legacy non-SES configurations, sending can fall back to JMAP."
      }
    },
    "/api/v1/compose/forward/{id}": {
      "get": {
        "description": "Get a context using the public SES mailbox message UUID as id. Map returned from.email to compose/send's fromEmail, and retain identityId, recipients, subject, bodies, inReplyTo, references and authorized attachments; do not post the context unchanged. Forward context includes authenticated attachment blob references. replyAll=true is supported on reply.",
        "operationId": "get_api_v1_compose_forward_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.ComposeEmail"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetForwardContext",
        "tags": [
          "compose"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "Primary SES compose workflow. Reply/forward contexts use public SES mailbox UUIDs; draft and attachment operations use owned records. In legacy non-SES configurations, sending can fall back to JMAP."
      }
    },
    "/api/v1/compose/reply/{id}": {
      "get": {
        "description": "Get a context using the public SES mailbox message UUID as id. Map returned from.email to compose/send's fromEmail, and retain identityId, recipients, subject, bodies, inReplyTo, references and authorized attachments; do not post the context unchanged. Forward context includes authenticated attachment blob references. replyAll=true is supported on reply.",
        "operationId": "get_api_v1_compose_reply_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "replyAll",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.ComposeEmail"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetReplyContext",
        "tags": [
          "compose"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "Primary SES compose workflow. Reply/forward contexts use public SES mailbox UUIDs; draft and attachment operations use owned records. In legacy non-SES configurations, sending can fall back to JMAP."
      }
    },
    "/api/v1/compose/send": {
      "post": {
        "description": "SendEmail sends a new email\nPOST /api/v1/compose/send",
        "operationId": "post_api_v1_compose_send",
        "parameters": [
          {
            "description": "Persist one key per logical submission. Reuse it with the identical request on retries; changed content returns 409. Single-email sends accept either this header or JSON idempotencyKey; both must agree when supplied together. Batch and compose require this header.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": true,
            "schema": {
              "maxLength": 128,
              "minLength": 8,
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "identityId": 1,
                "inReplyTo": "<original@example.net>",
                "references": [
                  "<original@example.net>"
                ],
                "subject": "Re: Hello",
                "textBody": "Thank you",
                "to": [
                  {
                    "email": "recipient@example.net"
                  }
                ]
              },
              "schema": {
                "$ref": "#/components/schemas/model.ComposeEmailRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.SendEmailResult"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SendEmail",
        "tags": [
          "compose"
        ],
        "x-api-key-scope": "email:send",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "Primary SES compose workflow. Reply/forward contexts use public SES mailbox UUIDs; draft and attachment operations use owned records. In legacy non-SES configurations, sending can fall back to JMAP."
      }
    },
    "/api/v1/confirm/{token}": {
      "get": {
        "description": "ConfirmDoubleOptIn handles double opt-in confirmation\nGET /api/v1/confirm/:token",
        "operationId": "get_api_v1_confirm_token",
        "parameters": [
          {
            "in": "path",
            "name": "token",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "ConfirmDoubleOptIn",
        "tags": [
          "confirm"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/contacts": {
      "get": {
        "description": "ListContacts retrieves contacts with pagination\nGET /api/v1/contacts",
        "operationId": "get_api_v1_contacts",
        "parameters": [
          {
            "in": "query",
            "name": "listIds",
            "schema": {
              "items": {
                "format": "int64",
                "type": "integer"
              },
              "type": "array"
            }
          },
          {
            "in": "query",
            "name": "page",
            "schema": {
              "default": 1,
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "pageSize",
            "schema": {
              "default": 50,
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "sortBy",
            "schema": {
              "default": "createdAt",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "sortOrder",
            "schema": {
              "default": "desc",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "status",
            "schema": {
              "items": {
                "type": "string"
              },
              "type": "array"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.ContactListResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "List",
        "tags": [
          "contacts"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "post": {
        "description": "CreateContact creates a new contact\nPOST /api/v1/contacts",
        "operationId": "post_api_v1_contacts",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.CreateContactRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Contact"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Create",
        "tags": [
          "contacts"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/contacts/export": {
      "post": {
        "description": "ExportContacts exports contacts as JSON\nPOST /api/v1/contacts/export",
        "operationId": "post_api_v1_contacts_export",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.ExportContactsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "$ref": "#/components/schemas/model.Contact"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Export",
        "tags": [
          "contacts"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/contacts/import": {
      "post": {
        "description": "ImportContacts bulk imports contacts\nPOST /api/v1/contacts/import",
        "operationId": "post_api_v1_contacts_import",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.ImportContactsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.ImportContactsResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Import",
        "tags": [
          "contacts"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/contacts/unsubscribe": {
      "post": {
        "description": "Unsubscribe marks a contact as unsubscribed\nPOST /api/v1/contacts/unsubscribe",
        "operationId": "post_api_v1_contacts_unsubscribe",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "email": {
                    "format": "email",
                    "type": "string"
                  }
                },
                "required": [
                  "email"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Unsubscribe",
        "tags": [
          "contacts"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/contacts/{uuid}": {
      "delete": {
        "description": "DeleteContact deletes a contact\nDELETE /api/v1/contacts/:uuid",
        "operationId": "delete_api_v1_contacts_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Delete",
        "tags": [
          "contacts"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "get": {
        "description": "GetContact retrieves a contact by UUID\nGET /api/v1/contacts/:uuid",
        "operationId": "get_api_v1_contacts_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Contact"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Get",
        "tags": [
          "contacts"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "put": {
        "description": "UpdateContact updates a contact\nPUT /api/v1/contacts/:uuid",
        "operationId": "put_api_v1_contacts_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.UpdateContactRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Contact"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Update",
        "tags": [
          "contacts"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/contacts/{uuid}/consent-audit": {
      "get": {
        "description": "GetConsentAuditTrail retrieves consent audit trail for a contact\nGET /api/v1/contacts/:uuid/consent-audit",
        "operationId": "get_api_v1_contacts_uuid_consent_audit",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "$ref": "#/components/schemas/service.ConsentRecord"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetConsentAuditTrail",
        "tags": [
          "contacts"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/contacts/{uuid}/export": {
      "get": {
        "description": "ExportContactData exports all data for a contact (GDPR)\nGET /api/v1/contacts/:uuid/export",
        "operationId": "get_api_v1_contacts_uuid_export",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "additionalProperties": {},
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ExportContactData",
        "tags": [
          "contacts"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/contacts/{uuid}/gdpr": {
      "delete": {
        "description": "DeleteContactData deletes all data for a contact (GDPR)\nDELETE /api/v1/contacts/:uuid/gdpr",
        "operationId": "delete_api_v1_contacts_uuid_gdpr",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteContactData",
        "tags": [
          "contacts"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/domains": {
      "get": {
        "description": "List returns all domains for the organization\nGET /api/v1/domains",
        "operationId": "get_api_v1_domains",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "properties": {
                          "createdAt": {
                            "format": "date-time",
                            "type": "string"
                          },
                          "dkimPublicKey": {
                            "type": "string"
                          },
                          "dkimSelector": {
                            "type": "string"
                          },
                          "dkimVerified": {
                            "type": "boolean"
                          },
                          "dmarcVerified": {
                            "type": "boolean"
                          },
                          "dnsRecords": {
                            "items": {
                              "allOf": [
                                {
                                  "$ref": "#/components/schemas/model.DomainDNSRecord"
                                }
                              ],
                              "nullable": true
                            },
                            "type": "array"
                          },
                          "emailProvider": {
                            "type": "string"
                          },
                          "id": {
                            "format": "int64",
                            "type": "integer"
                          },
                          "mxVerified": {
                            "type": "boolean"
                          },
                          "name": {
                            "type": "string"
                          },
                          "orgId": {
                            "format": "int64",
                            "type": "integer"
                          },
                          "receivingEnabled": {
                            "type": "boolean"
                          },
                          "sesVerified": {
                            "type": "boolean"
                          },
                          "spfVerified": {
                            "type": "boolean"
                          },
                          "status": {
                            "type": "string"
                          },
                          "updatedAt": {
                            "format": "date-time",
                            "type": "string"
                          },
                          "uuid": {
                            "type": "string"
                          },
                          "verificationToken": {
                            "type": "string"
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "List",
        "tags": [
          "domains"
        ],
        "x-api-key-scope": "domains:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "post": {
        "description": "Create adds a new domain\nPOST /api/v1/domains",
        "operationId": "post_api_v1_domains",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "name": "example.com"
              },
              "schema": {
                "$ref": "#/components/schemas/model.CreateDomainRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "dnsRecords": {
                          "items": {
                            "allOf": [
                              {
                                "$ref": "#/components/schemas/model.DomainDNSRecord"
                              }
                            ],
                            "nullable": true
                          },
                          "type": "array"
                        },
                        "domain": {
                          "allOf": [
                            {
                              "$ref": "#/components/schemas/model.Domain"
                            }
                          ],
                          "nullable": true
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Create",
        "tags": [
          "domains"
        ],
        "x-api-key-scope": "domains:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/domains/cloudflare/zones": {
      "post": {
        "description": "GetCloudflareZones lists Cloudflare zones for the API token\nPOST /api/v1/domains/cloudflare/zones",
        "operationId": "post_api_v1_domains_cloudflare_zones",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "apiToken": {
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "$ref": "#/components/schemas/provider.CloudflareZone"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetCloudflareZones",
        "tags": [
          "domains"
        ],
        "x-api-key-scope": "domains:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/domains/{uuid}": {
      "delete": {
        "description": "Delete removes a domain\nDELETE /api/v1/domains/:uuid",
        "operationId": "delete_api_v1_domains_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Delete",
        "tags": [
          "domains"
        ],
        "x-api-key-scope": "domains:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "get": {
        "description": "Get returns a single domain with DNS records\nGET /api/v1/domains/:uuid",
        "operationId": "get_api_v1_domains_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "dnsRecords": {
                          "items": {
                            "allOf": [
                              {
                                "$ref": "#/components/schemas/model.DomainDNSRecord"
                              }
                            ],
                            "nullable": true
                          },
                          "type": "array"
                        },
                        "domain": {
                          "allOf": [
                            {
                              "$ref": "#/components/schemas/model.Domain"
                            }
                          ],
                          "nullable": true
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Get",
        "tags": [
          "domains"
        ],
        "x-api-key-scope": "domains:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/domains/{uuid}/dmarc": {
      "get": {
        "description": "DMARC inspects the current policy without changing DNS or database state.\nGET /api/v1/domains/:uuid/dmarc",
        "operationId": "get_api_v1_domains_uuid_dmarc",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "$ref": "#/components/schemas/provider.DMARCInspection"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DMARC",
        "tags": [
          "domains"
        ],
        "x-api-key-scope": "domains:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/domains/{uuid}/dns/cloudflare": {
      "post": {
        "description": "AddDNSToCloudflare adds required DNS records to Cloudflare\nPOST /api/v1/domains/:uuid/dns/cloudflare",
        "operationId": "post_api_v1_domains_uuid_dns_cloudflare",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "apiToken": {
                    "type": "string"
                  },
                  "zoneId": {
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "results": {
                          "items": {
                            "additionalProperties": {},
                            "type": "object"
                          },
                          "type": "array"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "AddDNSToCloudflare",
        "tags": [
          "domains"
        ],
        "x-api-key-scope": "domains:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/domains/{uuid}/sending-status": {
      "get": {
        "description": "Separate attachment storage and outbound SES feedback readiness. Setup does not enable receiving or change MX. Inspect storageReady, feedbackConfigured, subscriptionStatus, feedbackReady and reason even for HTTP 200: an existing foreign SES topic is preserved and reported as a conflict. SNS confirmation can remain pending.",
        "operationId": "get_api_v1_domains_uuid_sending_status",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.SendingReadiness"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SendingStatus",
        "tags": [
          "domains"
        ],
        "x-api-key-scope": "domains:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/domains/{uuid}/ses-status": {
      "get": {
        "description": "CheckSESStatus checks the SES verification status\nGET /api/v1/domains/:uuid/ses-status",
        "operationId": "get_api_v1_domains_uuid_ses_status",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "domain": {
                          "allOf": [
                            {
                              "$ref": "#/components/schemas/model.Domain"
                            }
                          ],
                          "nullable": true
                        },
                        "sesStatus": {
                          "additionalProperties": {},
                          "type": "object"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "CheckSESStatus",
        "tags": [
          "domains"
        ],
        "x-api-key-scope": "domains:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/domains/{uuid}/ses-verify": {
      "post": {
        "description": "InitiateSES registers domain with AWS SES and returns DKIM records\nPOST /api/v1/domains/:uuid/ses-verify",
        "operationId": "post_api_v1_domains_uuid_ses_verify",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "dnsRecords": {
                          "items": {
                            "allOf": [
                              {
                                "$ref": "#/components/schemas/model.DomainDNSRecord"
                              }
                            ],
                            "nullable": true
                          },
                          "type": "array"
                        },
                        "domain": {
                          "allOf": [
                            {
                              "$ref": "#/components/schemas/model.Domain"
                            }
                          ],
                          "nullable": true
                        },
                        "sesRecords": {
                          "items": {
                            "additionalProperties": {
                              "type": "string"
                            },
                            "type": "object"
                          },
                          "type": "array"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "InitiateSES",
        "tags": [
          "domains"
        ],
        "x-api-key-scope": "domains:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/domains/{uuid}/setup-sending": {
      "post": {
        "description": "Separate attachment storage and outbound SES feedback readiness. Setup does not enable receiving or change MX. Inspect storageReady, feedbackConfigured, subscriptionStatus, feedbackReady and reason even for HTTP 200: an existing foreign SES topic is preserved and reported as a conflict. SNS confirmation can remain pending.",
        "operationId": "post_api_v1_domains_uuid_setup_sending",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.SendingReadiness"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SetupSending",
        "tags": [
          "domains"
        ],
        "x-api-key-scope": "domains:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/domains/{uuid}/verify": {
      "post": {
        "description": "Verify checks DNS records and updates verification status\nPOST /api/v1/domains/:uuid/verify",
        "operationId": "post_api_v1_domains_uuid_verify",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "dnsRecords": {
                          "items": {
                            "allOf": [
                              {
                                "$ref": "#/components/schemas/model.DomainDNSRecord"
                              }
                            ],
                            "nullable": true
                          },
                          "type": "array"
                        },
                        "domain": {
                          "allOf": [
                            {
                              "$ref": "#/components/schemas/model.Domain"
                            }
                          ],
                          "nullable": true
                        },
                        "verificationResults": {
                          "additionalProperties": {
                            "type": "boolean"
                          },
                          "type": "object"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Verify",
        "tags": [
          "domains"
        ],
        "x-api-key-scope": "domains:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/emails": {
      "post": {
        "description": "SendEmail sends a single transactional email\nPOST /api/v1/emails Requires a verified owned sender and stable Idempotency-Key. Base64 attachments preserve name, type (MIME), disposition and cid. Same key+content retries return the original result; changed payload is 409. A batch holds one content-bound key for the whole ordered request plus per-item keys. Inspect each item's success/error; retry the identical batch for incomplete items. queued/pending is not provider acceptance. sent is SES acceptance; delivered is destination-server acceptance. unknown needs investigation and must not be blindly retried with a new key.",
        "operationId": "post_api_v1_emails",
        "parameters": [
          {
            "description": "Persist one key per logical submission. Reuse it with the identical request on retries; changed content returns 409. Single-email sends accept either this header or JSON idempotencyKey; both must agree when supplied together. Batch and compose require this header.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "maxLength": 128,
              "minLength": 8,
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "attachments": [
                  {
                    "content": "SGVsbG8=",
                    "name": "hello.txt",
                    "type": "text/plain"
                  }
                ],
                "from": "hello@example.com",
                "subject": "Welcome",
                "text": "Hello from Mailat",
                "to": [
                  "recipient@example.net"
                ]
              },
              "schema": {
                "$ref": "#/components/schemas/model.SendEmailRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.SendEmailResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SendEmail",
        "tags": [
          "emails"
        ],
        "x-api-key-scope": "email:send",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/emails/batch": {
      "post": {
        "description": "BatchSendEmail sends multiple emails in batch\nPOST /api/v1/emails/batch Requires a verified owned sender and stable Idempotency-Key. Base64 attachments preserve name, type (MIME), disposition and cid. Same key+content retries return the original result; changed payload is 409. A batch holds one content-bound key for the whole ordered request plus per-item keys. Inspect each item's success/error; retry the identical batch for incomplete items. queued/pending is not provider acceptance. sent is SES acceptance; delivered is destination-server acceptance. unknown needs investigation and must not be blindly retried with a new key.",
        "operationId": "post_api_v1_emails_batch",
        "parameters": [
          {
            "description": "Persist one key per logical submission. Reuse it with the identical request on retries; changed content returns 409. Single-email sends accept either this header or JSON idempotencyKey; both must agree when supplied together. Batch and compose require this header.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": true,
            "schema": {
              "maxLength": 128,
              "minLength": 8,
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "emails": [
                  {
                    "from": "hello@example.com",
                    "idempotencyKey": "workflow-job-42-item-1",
                    "subject": "Welcome",
                    "text": "Hello",
                    "to": [
                      "recipient@example.net"
                    ]
                  }
                ]
              },
              "schema": {
                "$ref": "#/components/schemas/model.BatchSendRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.BatchSendResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "BatchSendEmail",
        "tags": [
          "emails"
        ],
        "x-api-key-scope": "email:send",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/emails/{id}": {
      "delete": {
        "description": "CancelEmail cancels a scheduled email\nDELETE /api/v1/emails/:id",
        "operationId": "delete_api_v1_emails_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "CancelEmail",
        "tags": [
          "emails"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "get": {
        "description": "GetEmailStatus retrieves the status of a sent email\nGET /api/v1/emails/:id",
        "operationId": "get_api_v1_emails_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.GetEmailStatusResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetEmailStatus",
        "tags": [
          "emails"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/forwards": {
      "get": {
        "description": "ListEmailForwards lists all email forwards for the user\nGET /api/v1/forwards",
        "operationId": "get_api_v1_forwards",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/service.EmailForward"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListEmailForwards",
        "tags": [
          "forwards"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      },
      "post": {
        "description": "CreateEmailForward creates a new email forward\nPOST /api/v1/forwards",
        "operationId": "post_api_v1_forwards",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.CreateEmailForwardInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.EmailForward"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "CreateEmailForward",
        "tags": [
          "forwards"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      }
    },
    "/api/v1/forwards/{id}": {
      "delete": {
        "description": "DeleteEmailForward deletes an email forward\nDELETE /api/v1/forwards/:id",
        "operationId": "delete_api_v1_forwards_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteEmailForward",
        "tags": [
          "forwards"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      }
    },
    "/api/v1/forwards/{id}/verify": {
      "post": {
        "description": "VerifyEmailForward verifies an email forward\nPOST /api/v1/forwards/:id/verify",
        "operationId": "post_api_v1_forwards_id_verify",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "token": {
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "VerifyEmailForward",
        "tags": [
          "forwards"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      }
    },
    "/api/v1/health": {
      "get": {
        "description": "Health returns the API health status\nGET /api/v1/health",
        "operationId": "get_api_v1_health",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "checks": {
                          "additionalProperties": {
                            "type": "string"
                          },
                          "type": "object"
                        },
                        "status": {
                          "enum": [
                            "healthy",
                            "unhealthy"
                          ],
                          "type": "string"
                        },
                        "timestamp": {
                          "format": "date-time",
                          "type": "string"
                        },
                        "version": {
                          "type": "string"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "checks": {
                          "additionalProperties": {
                            "type": "string"
                          },
                          "type": "object"
                        },
                        "status": {
                          "enum": [
                            "healthy",
                            "unhealthy"
                          ],
                          "type": "string"
                        },
                        "timestamp": {
                          "format": "date-time",
                          "type": "string"
                        },
                        "version": {
                          "type": "string"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "A database or Redis health check failed; code remains 0 and data.status is unhealthy."
          }
        },
        "security": [],
        "summary": "Health",
        "tags": [
          "health"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/health/alerts": {
      "get": {
        "description": "GetAlerts returns system alerts\nGET /api/v1/health/alerts",
        "operationId": "get_api_v1_health_alerts",
        "parameters": [
          {
            "in": "query",
            "name": "unacknowledged",
            "schema": {
              "default": false,
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "$ref": "#/components/schemas/service.Alert"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetAlerts",
        "tags": [
          "health"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/health/alerts/{id}/acknowledge": {
      "post": {
        "description": "AcknowledgeAlert acknowledges an alert\nPOST /api/v1/health/alerts/:id/acknowledge",
        "operationId": "post_api_v1_health_alerts_id_acknowledge",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "AcknowledgeAlert",
        "tags": [
          "health"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/health/blacklist-check": {
      "post": {
        "description": "CheckBlacklists checks if an IP is listed on blacklists\nPOST /api/v1/health/blacklist-check\nIf ipAddress is not provided, auto-detects the server's public IP",
        "operationId": "post_api_v1_health_blacklist_check",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "ipAddress": {
                    "description": "Optional - will auto-detect if not provided",
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.BlacklistCheckResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "CheckBlacklists",
        "tags": [
          "health"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/health/logs": {
      "get": {
        "description": "GetDeliveryLogs returns delivery logs\nGET /api/v1/health/logs",
        "operationId": "get_api_v1_health_logs",
        "parameters": [
          {
            "in": "query",
            "name": "emailId",
            "schema": {
              "default": 0,
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "page",
            "schema": {
              "default": 1,
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "pageSize",
            "schema": {
              "default": 50,
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "status",
            "schema": {
              "default": "",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "additionalProperties": {},
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetDeliveryLogs",
        "tags": [
          "health"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/health/quota": {
      "get": {
        "description": "GetQuotaStatus returns quota usage\nGET /api/v1/health/quota",
        "operationId": "get_api_v1_health_quota",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.QuotaStatus"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetQuotaStatus",
        "tags": [
          "health"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/health/reputation": {
      "get": {
        "description": "GetReputationMetrics retrieves sender reputation metrics\nGET /api/v1/health/reputation",
        "operationId": "get_api_v1_health_reputation",
        "parameters": [
          {
            "in": "query",
            "name": "period",
            "schema": {
              "default": "30days",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.ReputationMetrics"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetReputationMetrics",
        "tags": [
          "health"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/health/ses-limits": {
      "get": {
        "description": "GetSESLimits retrieves AWS SES account limits\nGET /api/v1/health/ses-limits",
        "operationId": "get_api_v1_health_ses_limits",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.SESAccountLimits"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetSESLimits",
        "tags": [
          "health"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/health/summary": {
      "get": {
        "description": "GetEmailHealthSummary retrieves comprehensive email health metrics\nGET /api/v1/health/summary",
        "operationId": "get_api_v1_health_summary",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.EmailHealthSummary"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetEmailHealthSummary",
        "tags": [
          "health"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/health/warmup": {
      "post": {
        "description": "StartWarmup starts IP warmup\nPOST /api/v1/health/warmup",
        "operationId": "post_api_v1_health_warmup",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "ipAddress": {
                    "type": "string"
                  },
                  "scheduleName": {
                    "default": "conservative",
                    "type": "string"
                  }
                },
                "required": [
                  "ipAddress"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.WarmupStatus"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "StartWarmup",
        "tags": [
          "health"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/health/warmup/schedules": {
      "get": {
        "description": "GetWarmupSchedules returns available warmup schedules\nGET /api/v1/health/warmup/schedules",
        "operationId": "get_api_v1_health_warmup_schedules",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "$ref": "#/components/schemas/service.WarmupSchedule"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetWarmupSchedules",
        "tags": [
          "health"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/health/warmup/{ip}": {
      "get": {
        "description": "GetWarmupStatus returns current warmup status\nGET /api/v1/health/warmup/:ip",
        "operationId": "get_api_v1_health_warmup_ip",
        "parameters": [
          {
            "in": "path",
            "name": "ip",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.WarmupStatus"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetWarmupStatus",
        "tags": [
          "health"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/identities": {
      "get": {
        "description": "List returns all identities for the user\nGET /api/v1/identities",
        "operationId": "get_api_v1_identities",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/model.Identity"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "List",
        "tags": [
          "identities"
        ],
        "x-api-key-scope": "identities:read",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Owned sender identities support SES. Legacy identities with a Stalwart account can also synchronize password/deletion changes to Stalwart; SES identities do not require a separate mailbox server."
      },
      "post": {
        "description": "Create adds a new identity/mailbox\nPOST /api/v1/identities",
        "operationId": "post_api_v1_identities",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "displayName": "Example",
                "domainId": "00000000-0000-4000-8000-000000000001",
                "email": "hello@example.com"
              },
              "schema": {
                "$ref": "#/components/schemas/model.CreateIdentityRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Identity"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Create",
        "tags": [
          "identities"
        ],
        "x-api-key-scope": "identities:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Owned sender identities support SES. Legacy identities with a Stalwart account can also synchronize password/deletion changes to Stalwart; SES identities do not require a separate mailbox server."
      }
    },
    "/api/v1/identities/{uuid}": {
      "delete": {
        "description": "Delete removes an identity\nDELETE /api/v1/identities/:uuid",
        "operationId": "delete_api_v1_identities_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Delete",
        "tags": [
          "identities"
        ],
        "x-api-key-scope": "identities:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Owned sender identities support SES. Legacy identities with a Stalwart account can also synchronize password/deletion changes to Stalwart; SES identities do not require a separate mailbox server."
      },
      "get": {
        "description": "Get returns a single identity\nGET /api/v1/identities/:uuid",
        "operationId": "get_api_v1_identities_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Identity"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Get",
        "tags": [
          "identities"
        ],
        "x-api-key-scope": "identities:read",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Owned sender identities support SES. Legacy identities with a Stalwart account can also synchronize password/deletion changes to Stalwart; SES identities do not require a separate mailbox server."
      },
      "put": {
        "description": "Update",
        "operationId": "put_api_v1_identities_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.UpdateIdentityRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Identity"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Update",
        "tags": [
          "identities"
        ],
        "x-api-key-scope": "identities:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Owned sender identities support SES. Legacy identities with a Stalwart account can also synchronize password/deletion changes to Stalwart; SES identities do not require a separate mailbox server."
      }
    },
    "/api/v1/identities/{uuid}/catch-all": {
      "post": {
        "description": "Update",
        "operationId": "post_api_v1_identities_uuid_catch_all",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.UpdateIdentityRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Identity"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Update",
        "tags": [
          "identities"
        ],
        "x-api-key-scope": "identities:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Owned sender identities support SES. Legacy identities with a Stalwart account can also synchronize password/deletion changes to Stalwart; SES identities do not require a separate mailbox server."
      }
    },
    "/api/v1/identities/{uuid}/password": {
      "put": {
        "description": "UpdatePassword changes the identity password\nPUT /api/v1/identities/:uuid/password",
        "operationId": "put_api_v1_identities_uuid_password",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "password": {
                    "minLength": 8,
                    "type": "string"
                  }
                },
                "required": [
                  "password"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UpdatePassword",
        "tags": [
          "identities"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Owned sender identities support SES. Legacy identities with a Stalwart account can also synchronize password/deletion changes to Stalwart; SES identities do not require a separate mailbox server."
      }
    },
    "/api/v1/inbox": {
      "get": {
        "description": "GetInbox returns unified inbox with emails from all identities\nGET /api/v1/inbox",
        "operationId": "get_api_v1_inbox",
        "parameters": [
          {
            "in": "query",
            "name": "flagged",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "in": "query",
            "name": "identityId",
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "mailboxId",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "page",
            "schema": {
              "default": 1,
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "pageSize",
            "schema": {
              "default": 50,
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "search",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "unread",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.UnifiedInboxResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetInbox",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "jmap",
        "x-mailat-backend-note": "Legacy mailbox operation requiring configured Stalwart/JMAP accounts. This is not the SES received-mail API; use /inbox/received and /inbox/changes for SES automation."
      }
    },
    "/api/v1/inbox/changes": {
      "get": {
        "description": "Read changes after a commit-ordered cursor. Start with cursor=now before an initial inbox snapshot, then replay changes after that cursor. Deduplicate by cursor and messageUuid. Deleted messages remain as tombstones. A cursor older than 90 days returns 410; resynchronize. limit is 1–500.",
        "operationId": "get_api_v1_inbox_changes",
        "parameters": [
          {
            "in": "query",
            "name": "cursor",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "limit",
            "schema": {
              "default": 100,
              "maximum": 500,
              "minimum": 1,
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.MailboxChanges"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Changes",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/delete": {
      "post": {
        "description": "DeleteEmails deletes or moves emails to trash\nPOST /api/v1/inbox/delete",
        "operationId": "post_api_v1_inbox_delete",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.DeleteEmailRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteEmails",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "jmap",
        "x-mailat-backend-note": "Legacy mailbox operation requiring configured Stalwart/JMAP accounts. This is not the SES received-mail API; use /inbox/received and /inbox/changes for SES automation."
      }
    },
    "/api/v1/inbox/emails/{id}": {
      "get": {
        "description": "GetEmail returns a single email by ID\nGET /api/v1/inbox/emails/:id",
        "operationId": "get_api_v1_inbox_emails_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.UnifiedEmail"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetEmail",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "jmap",
        "x-mailat-backend-note": "Legacy mailbox operation requiring configured Stalwart/JMAP accounts. This is not the SES received-mail API; use /inbox/received and /inbox/changes for SES automation."
      }
    },
    "/api/v1/inbox/filters": {
      "get": {
        "description": "ListFilters Explicit user filter destinations override the automatic DMARC report folder. actionFolder accepts dmarc-reports; label-only and mark-read filters retain the automatically selected folder. Spam and virus decisions are preserved.",
        "operationId": "get_api_v1_inbox_filters",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "$ref": "#/components/schemas/model.InboxFilter"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListFilters",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "post": {
        "description": "SaveFilter Explicit user filter destinations override the automatic DMARC report folder. actionFolder accepts dmarc-reports; label-only and mark-read filters retain the automatically selected folder. Spam and virus decisions are preserved.",
        "operationId": "post_api_v1_inbox_filters",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "actionFolder": "archive",
                "active": true,
                "conditionLogic": "all",
                "conditions": [
                  {
                    "field": "subject",
                    "operator": "contains",
                    "value": "invoice"
                  }
                ],
                "name": "Invoice mail"
              },
              "schema": {
                "properties": {
                  "actionArchive": {
                    "type": "boolean"
                  },
                  "actionFolder": {
                    "description": "An explicit destination overrides automatic DMARC organization. Empty leaves the selected folder unchanged.",
                    "enum": [
                      "",
                      "inbox",
                      "archive",
                      "spam",
                      "trash",
                      "dmarc-reports"
                    ],
                    "type": "string"
                  },
                  "actionForward": {
                    "type": "string"
                  },
                  "actionLabels": {
                    "items": {
                      "type": "string"
                    },
                    "type": "array"
                  },
                  "actionMarkRead": {
                    "type": "boolean"
                  },
                  "actionStar": {
                    "type": "boolean"
                  },
                  "actionTrash": {
                    "type": "boolean"
                  },
                  "active": {
                    "type": "boolean"
                  },
                  "conditionLogic": {
                    "description": "all, any",
                    "type": "string"
                  },
                  "conditions": {
                    "items": {
                      "$ref": "#/components/schemas/model.FilterCondition"
                    },
                    "type": "array"
                  },
                  "identityId": {
                    "allOf": [
                      {
                        "format": "int64",
                        "type": "integer"
                      }
                    ],
                    "nullable": true
                  },
                  "name": {
                    "type": "string"
                  },
                  "priority": {
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.InboxFilter"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SaveFilter",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/filters/{uuid}": {
      "delete": {
        "description": "DeleteFilter Explicit user filter destinations override the automatic DMARC report folder. actionFolder accepts dmarc-reports; label-only and mark-read filters retain the automatically selected folder. Spam and virus decisions are preserved.",
        "operationId": "delete_api_v1_inbox_filters_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteFilter",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "get": {
        "description": "GetFilter Explicit user filter destinations override the automatic DMARC report folder. actionFolder accepts dmarc-reports; label-only and mark-read filters retain the automatically selected folder. Spam and virus decisions are preserved.",
        "operationId": "get_api_v1_inbox_filters_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.InboxFilter"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetFilter",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "put": {
        "description": "SaveFilter Explicit user filter destinations override the automatic DMARC report folder. actionFolder accepts dmarc-reports; label-only and mark-read filters retain the automatically selected folder. Spam and virus decisions are preserved.",
        "operationId": "put_api_v1_inbox_filters_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "actionFolder": "archive",
                "active": true,
                "conditionLogic": "all",
                "conditions": [
                  {
                    "field": "subject",
                    "operator": "contains",
                    "value": "invoice"
                  }
                ],
                "name": "Invoice mail"
              },
              "schema": {
                "properties": {
                  "actionArchive": {
                    "type": "boolean"
                  },
                  "actionFolder": {
                    "description": "An explicit destination overrides automatic DMARC organization. Empty leaves the selected folder unchanged.",
                    "enum": [
                      "",
                      "inbox",
                      "archive",
                      "spam",
                      "trash",
                      "dmarc-reports"
                    ],
                    "type": "string"
                  },
                  "actionForward": {
                    "type": "string"
                  },
                  "actionLabels": {
                    "items": {
                      "type": "string"
                    },
                    "type": "array"
                  },
                  "actionMarkRead": {
                    "type": "boolean"
                  },
                  "actionStar": {
                    "type": "boolean"
                  },
                  "actionTrash": {
                    "type": "boolean"
                  },
                  "active": {
                    "type": "boolean"
                  },
                  "conditionLogic": {
                    "description": "all, any",
                    "type": "string"
                  },
                  "conditions": {
                    "items": {
                      "$ref": "#/components/schemas/model.FilterCondition"
                    },
                    "type": "array"
                  },
                  "identityId": {
                    "allOf": [
                      {
                        "format": "int64",
                        "type": "integer"
                      }
                    ],
                    "nullable": true
                  },
                  "name": {
                    "type": "string"
                  },
                  "priority": {
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.InboxFilter"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SaveFilter",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/filters/{uuid}/test": {
      "post": {
        "description": "TestFilter Explicit user filter destinations override the automatic DMARC report folder. actionFolder accepts dmarc-reports; label-only and mark-read filters retain the automatically selected folder. Spam and virus decisions are preserved.",
        "operationId": "post_api_v1_inbox_filters_uuid_test",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "body": "Invoice details",
                "from": "sender@example.net",
                "hasAttachments": false,
                "subject": "Invoice 42",
                "to": [
                  "hello@example.com"
                ]
              },
              "schema": {
                "$ref": "#/components/schemas/service.InboxFilterTestInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "actions": {
                          "properties": {
                            "archive": {
                              "type": "boolean"
                            },
                            "folder": {
                              "type": "string"
                            },
                            "labels": {
                              "items": {
                                "type": "string"
                              },
                              "type": "array"
                            },
                            "markRead": {
                              "type": "boolean"
                            },
                            "star": {
                              "type": "boolean"
                            },
                            "trash": {
                              "type": "boolean"
                            }
                          },
                          "type": "object"
                        },
                        "active": {
                          "type": "boolean"
                        },
                        "matches": {
                          "type": "boolean"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "TestFilter",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/labels": {
      "get": {
        "description": "ListLabels",
        "operationId": "get_api_v1_inbox_labels",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "$ref": "#/components/schemas/model.EmailLabel"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListLabels",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "post": {
        "description": "SaveLabel",
        "operationId": "post_api_v1_inbox_labels",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "color": "#2563eb",
                "name": "Invoices"
              },
              "schema": {
                "$ref": "#/components/schemas/model.UpdateLabelRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.EmailLabel"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SaveLabel",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/labels/{uuid}": {
      "delete": {
        "description": "DeleteLabel",
        "operationId": "delete_api_v1_inbox_labels_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteLabel",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "put": {
        "description": "SaveLabel",
        "operationId": "put_api_v1_inbox_labels_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "color": "#16a34a",
                "name": "Paid"
              },
              "schema": {
                "$ref": "#/components/schemas/model.UpdateLabelRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.EmailLabel"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SaveLabel",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/mailboxes": {
      "get": {
        "description": "GetMailboxes returns all mailboxes across all user's identities\nGET /api/v1/inbox/mailboxes",
        "operationId": "get_api_v1_inbox_mailboxes",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "$ref": "#/components/schemas/service.UnifiedMailbox"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetMailboxes",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "jmap",
        "x-mailat-backend-note": "Legacy mailbox operation requiring configured Stalwart/JMAP accounts. This is not the SES received-mail API; use /inbox/received and /inbox/changes for SES automation."
      }
    },
    "/api/v1/inbox/mark-read": {
      "post": {
        "description": "MarkRead marks emails as read or unread\nPOST /api/v1/inbox/mark-read",
        "operationId": "post_api_v1_inbox_mark_read",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.MarkReadRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "MarkRead",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "jmap",
        "x-mailat-backend-note": "Legacy mailbox operation requiring configured Stalwart/JMAP accounts. This is not the SES received-mail API; use /inbox/received and /inbox/changes for SES automation."
      }
    },
    "/api/v1/inbox/move": {
      "post": {
        "description": "MoveEmails moves emails to a different mailbox\nPOST /api/v1/inbox/move",
        "operationId": "post_api_v1_inbox_move",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.MoveEmailRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "MoveEmails",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "jmap",
        "x-mailat-backend-note": "Legacy mailbox operation requiring configured Stalwart/JMAP accounts. This is not the SES received-mail API; use /inbox/received and /inbox/changes for SES automation."
      }
    },
    "/api/v1/inbox/received": {
      "get": {
        "description": "ListEmails returns a paginated list of received emails\nGET /api/v1/inbox/received\nIf identityId is 0 or omitted, returns emails from all user's identities (unified inbox) The built-in dmarc-reports folder holds authenticated aggregate reports; all includes those messages. Search, pagination and identity/domain filters work normally. Reading does not change unread state.",
        "operationId": "get_api_v1_inbox_received",
        "parameters": [
          {
            "in": "query",
            "name": "dateFrom",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "dateTo",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "domainId",
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "folder",
            "schema": {
              "default": "inbox",
              "description": "Built-in folder or virtual view. all includes DMARC reports.",
              "enum": [
                "inbox",
                "dmarc-reports",
                "sent",
                "drafts",
                "outbox",
                "spam",
                "trash",
                "starred",
                "archive",
                "all"
              ],
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "hasAttachments",
            "schema": {
              "allOf": [
                {
                  "type": "boolean"
                }
              ],
              "nullable": true
            }
          },
          {
            "in": "query",
            "name": "identityId",
            "schema": {
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "isRead",
            "schema": {
              "allOf": [
                {
                  "type": "boolean"
                }
              ],
              "nullable": true
            }
          },
          {
            "in": "query",
            "name": "isStarred",
            "schema": {
              "allOf": [
                {
                  "type": "boolean"
                }
              ],
              "nullable": true
            }
          },
          {
            "in": "query",
            "name": "labels",
            "schema": {
              "items": {
                "type": "string"
              },
              "type": "array"
            }
          },
          {
            "in": "query",
            "name": "page",
            "schema": {
              "default": 1,
              "description": "One-based page. Values below 1 use 1.",
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "pageSize",
            "schema": {
              "default": 50,
              "description": "Values below 1 use 50; values above 100 are capped to 100.",
              "format": "int64",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "search",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "sender",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "sortBy",
            "schema": {
              "default": "receivedAt",
              "description": "subject, from_email or size_bytes; other values use received_at.",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "sortOrder",
            "schema": {
              "default": "desc",
              "description": "asc selects ascending order; other values use descending order.",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.InboxListResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListEmails",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/received/counts": {
      "get": {
        "description": "Counts for the caller's owned mailbox. inboxUnread is the main Inbox unread badge; dmarcReports and dmarcReportsUnread count the dedicated folder. unread retains its global non-trash meaning and includes unread reports.",
        "operationId": "get_api_v1_inbox_received_counts",
        "parameters": [
          {
            "description": "Omit or use zero for the unified mailbox; otherwise count an owned identity.",
            "in": "query",
            "name": "identityId",
            "required": false,
            "schema": {
              "minimum": 0,
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.InboxCountsResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetCounts",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/received/labels": {
      "post": {
        "description": "LabelEmails",
        "operationId": "post_api_v1_inbox_received_labels",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "addLabels": [
                  "Invoices"
                ],
                "emailUuids": [
                  "00000000-0000-4000-8000-000000000001"
                ],
                "removeLabels": []
              },
              "schema": {
                "$ref": "#/components/schemas/model.LabelEmailsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "LabelEmails",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/received/mark": {
      "post": {
        "description": "MarkEmails marks emails as read or unread\nPOST /api/v1/inbox/received/mark",
        "operationId": "post_api_v1_inbox_received_mark",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "emailUuids": [
                  "00000000-0000-4000-8000-000000000001"
                ],
                "isRead": true
              },
              "schema": {
                "$ref": "#/components/schemas/model.MarkEmailsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "MarkEmails",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/received/move": {
      "post": {
        "description": "Move owned messages to inbox, archive, spam, trash or dmarc-reports. The report folder is not archived, spam or trash. A manual move back to Inbox is not undone by recurring classification.",
        "operationId": "post_api_v1_inbox_received_move",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "emailUuids": [
                  "00000000-0000-4000-8000-000000000001"
                ],
                "folder": "dmarc-reports"
              },
              "schema": {
                "$ref": "#/components/schemas/model.MoveEmailsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "MoveEmails",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/received/star": {
      "post": {
        "description": "StarEmails stars or unstars emails\nPOST /api/v1/inbox/received/star",
        "operationId": "post_api_v1_inbox_received_star",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "emailUuids": [
                  "00000000-0000-4000-8000-000000000001"
                ],
                "isStarred": true
              },
              "schema": {
                "$ref": "#/components/schemas/model.StarEmailsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "StarEmails",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/received/trash": {
      "post": {
        "description": "TrashEmails moves emails to trash or permanently deletes\nPOST /api/v1/inbox/received/trash",
        "operationId": "post_api_v1_inbox_received_trash",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "emailUuids": [
                  "00000000-0000-4000-8000-000000000001"
                ],
                "permanent": false
              },
              "schema": {
                "$ref": "#/components/schemas/model.TrashEmailsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "TrashEmails",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/received/{uuid}": {
      "get": {
        "description": "Read an owned message and authenticated attachment URLs without changing unread state. Use POST /inbox/received/mark explicitly.",
        "operationId": "get_api_v1_inbox_received_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.ReceivedEmail"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetEmail",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/received/{uuid}/attachments/{attachmentUuid}": {
      "get": {
        "description": "DownloadAttachment returns private bytes only after checking message ownership.",
        "operationId": "get_api_v1_inbox_received_uuid_attachments_attachmentUuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "attachmentUuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/octet-stream": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              }
            },
            "description": "Private attachment bytes",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DownloadAttachment",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/search": {
      "get": {
        "description": "Search searches emails using full-text search\nGET /api/v1/inbox/search",
        "operationId": "get_api_v1_inbox_search",
        "parameters": [
          {
            "in": "query",
            "name": "page",
            "schema": {
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "pageSize",
            "schema": {
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "q",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.UnifiedInboxResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Search",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "jmap",
        "x-mailat-backend-note": "Legacy mailbox operation requiring configured Stalwart/JMAP accounts. This is not the SES received-mail API; use /inbox/received and /inbox/changes for SES automation."
      }
    },
    "/api/v1/inbox/setup": {
      "post": {
        "description": "SetupReceiving sets up email receiving for a domain\nPOST /api/v1/inbox/setup",
        "operationId": "post_api_v1_inbox_setup",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "domainId": 1
              },
              "schema": {
                "properties": {
                  "domainId": {
                    "format": "int64",
                    "type": "integer"
                  }
                },
                "required": [
                  "domainId"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.SetupReceivingResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SetupReceiving",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "domains:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/inbox/threads/{id}": {
      "get": {
        "description": "GetThread returns all emails in a thread\nGET /api/v1/inbox/threads/:id",
        "operationId": "get_api_v1_inbox_threads_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "$ref": "#/components/schemas/service.UnifiedEmail"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetThread",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "jmap",
        "x-mailat-backend-note": "Legacy mailbox operation requiring configured Stalwart/JMAP accounts. This is not the SES received-mail API; use /inbox/received and /inbox/changes for SES automation."
      }
    },
    "/api/v1/inbox/toggle-flag": {
      "post": {
        "description": "ToggleFlag toggles the flagged status of emails\nPOST /api/v1/inbox/toggle-flag",
        "operationId": "post_api_v1_inbox_toggle_flag",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.FlagEmailRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ToggleFlag",
        "tags": [
          "inbox"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "jmap",
        "x-mailat-backend-note": "Legacy mailbox operation requiring configured Stalwart/JMAP accounts. This is not the SES received-mail API; use /inbox/received and /inbox/changes for SES automation."
      }
    },
    "/api/v1/labels": {
      "get": {
        "description": "ListLabels",
        "operationId": "get_api_v1_labels",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "$ref": "#/components/schemas/model.EmailLabel"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListLabels",
        "tags": [
          "labels"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "post": {
        "description": "SaveLabel",
        "operationId": "post_api_v1_labels",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "color": "#2563eb",
                "name": "Invoices"
              },
              "schema": {
                "$ref": "#/components/schemas/model.UpdateLabelRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.EmailLabel"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SaveLabel",
        "tags": [
          "labels"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/labels/{uuid}": {
      "delete": {
        "description": "DeleteLabel",
        "operationId": "delete_api_v1_labels_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteLabel",
        "tags": [
          "labels"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "put": {
        "description": "SaveLabel",
        "operationId": "put_api_v1_labels_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "color": "#16a34a",
                "name": "Paid"
              },
              "schema": {
                "$ref": "#/components/schemas/model.UpdateLabelRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.EmailLabel"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SaveLabel",
        "tags": [
          "labels"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/lists": {
      "get": {
        "description": "ListLists retrieves all lists\nGET /api/v1/lists",
        "operationId": "get_api_v1_lists",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "$ref": "#/components/schemas/model.List"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "List",
        "tags": [
          "lists"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "post": {
        "description": "CreateList creates a new contact list\nPOST /api/v1/lists",
        "operationId": "post_api_v1_lists",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.CreateListRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.List"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Create",
        "tags": [
          "lists"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/lists/{uuid}": {
      "delete": {
        "description": "DeleteList deletes a list\nDELETE /api/v1/lists/:uuid",
        "operationId": "delete_api_v1_lists_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Delete",
        "tags": [
          "lists"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "get": {
        "description": "GetList retrieves a list by UUID\nGET /api/v1/lists/:uuid",
        "operationId": "get_api_v1_lists_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.List"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Get",
        "tags": [
          "lists"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "put": {
        "description": "UpdateList updates a list\nPUT /api/v1/lists/:uuid",
        "operationId": "put_api_v1_lists_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.UpdateListRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.List"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Update",
        "tags": [
          "lists"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/lists/{uuid}/contacts": {
      "delete": {
        "description": "RemoveContacts removes contacts from a list\nDELETE /api/v1/lists/:uuid/contacts",
        "operationId": "delete_api_v1_lists_uuid_contacts",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.RemoveContactsFromListRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "RemoveContacts",
        "tags": [
          "lists"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "get": {
        "description": "GetListContacts retrieves contacts in a list\nGET /api/v1/lists/:uuid/contacts",
        "operationId": "get_api_v1_lists_uuid_contacts",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "page",
            "schema": {
              "default": 1,
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "pageSize",
            "schema": {
              "default": 50,
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.ContactListResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetListContacts",
        "tags": [
          "lists"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "post": {
        "description": "AddContacts adds contacts to a list\nPOST /api/v1/lists/:uuid/contacts",
        "operationId": "post_api_v1_lists_uuid_contacts",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.AddContactsToListRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "AddContacts",
        "tags": [
          "lists"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/lists/{uuid}/contacts/import": {
      "post": {
        "description": "ImportContactsToList imports contacts directly to a list\nPOST /api/v1/lists/:uuid/contacts/import",
        "operationId": "post_api_v1_lists_uuid_contacts_import",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.ImportContactsToListRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.ImportContactsToListResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ImportContactsToList",
        "tags": [
          "lists"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/lists/{uuid}/contacts/manual": {
      "post": {
        "description": "ManualAddContactToList creates a contact and adds it to a list\nPOST /api/v1/lists/:uuid/contacts/manual",
        "operationId": "post_api_v1_lists_uuid_contacts_manual",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.ManualAddContactToListRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.Contact"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ManualAddContactToList",
        "tags": [
          "lists"
        ],
        "x-api-key-scope": "contacts:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/oauth/connections": {
      "get": {
        "description": "GetConnections returns all OAuth connections for the current user\nGET /api/v1/oauth/connections",
        "operationId": "get_api_v1_oauth_connections",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/service.OAuthConnection"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetConnections",
        "tags": [
          "oauth"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/oauth/providers": {
      "get": {
        "description": "GetProviders returns the list of configured OAuth providers\nGET /api/v1/oauth/providers",
        "operationId": "get_api_v1_oauth_providers",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "providers": {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "GetProviders",
        "tags": [
          "oauth"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/oauth/{provider}": {
      "delete": {
        "description": "DisconnectProvider removes an OAuth connection\nDELETE /api/v1/oauth/:provider",
        "operationId": "delete_api_v1_oauth_provider",
        "parameters": [
          {
            "in": "path",
            "name": "provider",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "DisconnectProvider",
        "tags": [
          "oauth"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "get": {
        "description": "InitiateOAuth starts the OAuth flow for a provider\nGET /api/v1/oauth/:provider",
        "operationId": "get_api_v1_oauth_provider",
        "parameters": [
          {
            "in": "path",
            "name": "provider",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "302": {
            "description": "Redirect to the configured destination",
            "headers": {
              "Location": {
                "schema": {
                  "format": "uri-reference",
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "InitiateOAuth",
        "tags": [
          "oauth"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/oauth/{provider}/callback": {
      "get": {
        "description": "HandleCallback handles the OAuth callback from a provider\nGET /api/v1/oauth/:provider/callback",
        "operationId": "get_api_v1_oauth_provider_callback",
        "parameters": [
          {
            "in": "path",
            "name": "provider",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "code",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "error",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "error_description",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "state",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "302": {
            "description": "Redirect to the configured destination",
            "headers": {
              "Location": {
                "schema": {
                  "format": "uri-reference",
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "HandleCallback",
        "tags": [
          "oauth"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/oauth/{provider}/connect": {
      "post": {
        "description": "ConnectProvider connects an OAuth provider to an existing user account\nPOST /api/v1/oauth/:provider/connect",
        "operationId": "post_api_v1_oauth_provider_connect",
        "parameters": [
          {
            "in": "path",
            "name": "provider",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "authUrl": {
                          "type": "string"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ConnectProvider",
        "tags": [
          "oauth"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/preferences/{token}": {
      "get": {
        "description": "GetPreferences returns preference center data\nGET /api/v1/preferences/:token",
        "operationId": "get_api_v1_preferences_token",
        "parameters": [
          {
            "in": "path",
            "name": "token",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.PreferenceData"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "GetPreferences",
        "tags": [
          "preferences"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "put": {
        "description": "UpdatePreferences updates subscriber preferences\nPUT /api/v1/preferences/:token",
        "operationId": "put_api_v1_preferences_token",
        "parameters": [
          {
            "in": "path",
            "name": "token",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "listIds": {
                    "items": {
                      "format": "int64",
                      "type": "integer"
                    },
                    "type": "array"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "UpdatePreferences",
        "tags": [
          "preferences"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/push/subscribe": {
      "post": {
        "description": "SubscribePush subscribes to push notifications\nPOST /api/v1/push/subscribe",
        "operationId": "post_api_v1_push_subscribe",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.CreatePushSubscriptionInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.PushSubscription"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "SubscribePush",
        "tags": [
          "push"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/push/subscriptions": {
      "get": {
        "description": "ListPushSubscriptions lists push subscriptions\nGET /api/v1/push/subscriptions",
        "operationId": "get_api_v1_push_subscriptions",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/service.PushSubscription"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListPushSubscriptions",
        "tags": [
          "push"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/push/subscriptions/{uuid}/preferences": {
      "put": {
        "description": "UpdatePushPreferences updates push notification preferences\nPUT /api/v1/push/subscriptions/:uuid/preferences",
        "operationId": "put_api_v1_push_subscriptions_uuid_preferences",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "notifyCampaign": {
                    "allOf": [
                      {
                        "type": "boolean"
                      }
                    ],
                    "nullable": true
                  },
                  "notifyMentions": {
                    "allOf": [
                      {
                        "type": "boolean"
                      }
                    ],
                    "nullable": true
                  },
                  "notifyNewEmail": {
                    "allOf": [
                      {
                        "type": "boolean"
                      }
                    ],
                    "nullable": true
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UpdatePushPreferences",
        "tags": [
          "push"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/push/unsubscribe": {
      "post": {
        "description": "UnsubscribePush unsubscribes from push notifications\nPOST /api/v1/push/unsubscribe",
        "operationId": "post_api_v1_push_unsubscribe",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "endpoint": {
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UnsubscribePush",
        "tags": [
          "push"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/push/vapid-key": {
      "get": {
        "description": "GetVAPIDKey returns the VAPID public key\nGET /api/v1/push/vapid-key",
        "operationId": "get_api_v1_push_vapid_key",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "publicKey": {
                          "type": "string"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetVAPIDKey",
        "tags": [
          "push"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/ready": {
      "get": {
        "description": "Ready returns whether the API is ready to serve requests\nGET /api/v1/ready",
        "operationId": "get_api_v1_ready",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "ready": {
                          "type": "boolean"
                        },
                        "timestamp": {
                          "format": "date-time",
                          "type": "string"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "Ready",
        "tags": [
          "ready"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/rules": {
      "get": {
        "deprecated": true,
        "description": "ListRules lists all email rules for the user\nGET /api/v1/rules Compatibility API synchronized with SES inbox filters. Prefer /inbox/filters. Unsupported legacy actions are rejected; migrated incompatible rules are disabled with migrationWarning.",
        "operationId": "get_api_v1_rules",
        "parameters": [
          {
            "in": "query",
            "name": "active",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/service.EmailRule"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListRules",
        "tags": [
          "rules"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "post": {
        "deprecated": true,
        "description": "CreateRule creates a new email rule\nPOST /api/v1/rules Compatibility API synchronized with SES inbox filters. Prefer /inbox/filters. Unsupported legacy actions are rejected; migrated incompatible rules are disabled with migrationWarning.",
        "operationId": "post_api_v1_rules",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.CreateEmailRuleInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.EmailRule"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "CreateRule",
        "tags": [
          "rules"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/rules/reorder": {
      "post": {
        "deprecated": true,
        "description": "ReorderRules updates the priority order of rules\nPOST /api/v1/rules/reorder Compatibility API synchronized with SES inbox filters. Prefer /inbox/filters. Unsupported legacy actions are rejected; migrated incompatible rules are disabled with migrationWarning.",
        "operationId": "post_api_v1_rules_reorder",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "ruleIds": {
                    "items": {
                      "format": "int64",
                      "type": "integer"
                    },
                    "type": "array"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ReorderRules",
        "tags": [
          "rules"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/rules/{id}": {
      "delete": {
        "deprecated": true,
        "description": "DeleteRule deletes an email rule\nDELETE /api/v1/rules/:id Compatibility API synchronized with SES inbox filters. Prefer /inbox/filters. Unsupported legacy actions are rejected; migrated incompatible rules are disabled with migrationWarning.",
        "operationId": "delete_api_v1_rules_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteRule",
        "tags": [
          "rules"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "get": {
        "deprecated": true,
        "description": "GetRule gets an email rule by ID\nGET /api/v1/rules/:id Compatibility API synchronized with SES inbox filters. Prefer /inbox/filters. Unsupported legacy actions are rejected; migrated incompatible rules are disabled with migrationWarning.",
        "operationId": "get_api_v1_rules_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.EmailRule"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetRule",
        "tags": [
          "rules"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      },
      "put": {
        "deprecated": true,
        "description": "UpdateRule updates an email rule\nPUT /api/v1/rules/:id Compatibility API synchronized with SES inbox filters. Prefer /inbox/filters. Unsupported legacy actions are rejected; migrated incompatible rules are disabled with migrationWarning.",
        "operationId": "put_api_v1_rules_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.UpdateEmailRuleInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.EmailRule"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UpdateRule",
        "tags": [
          "rules"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/rules/{id}/test": {
      "post": {
        "deprecated": true,
        "description": "TestRule tests a rule against a sample email\nPOST /api/v1/rules/:id/test Compatibility API synchronized with SES inbox filters. Prefer /inbox/filters. Unsupported legacy actions are rejected; migrated incompatible rules are disabled with migrationWarning.",
        "operationId": "post_api_v1_rules_id_test",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.EmailForTestInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "actions": {
                          "items": {
                            "$ref": "#/components/schemas/service.RuleAction"
                          },
                          "type": "array"
                        },
                        "matches": {
                          "type": "boolean"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "TestRule",
        "tags": [
          "rules"
        ],
        "x-api-key-scope": "email:manage",
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/security/2fa/backup-codes": {
      "post": {
        "description": "RegenerateBackupCodes generates new backup codes\nPOST /api/v1/security/2fa/backup-codes",
        "operationId": "post_api_v1_security_2fa_backup_codes",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "code": {
                    "type": "string"
                  },
                  "password": {
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "backupCodes": {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "RegenerateBackupCodes",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/2fa/disable": {
      "post": {
        "description": "Disable2FA disables 2FA for the user\nPOST /api/v1/security/2fa/disable",
        "operationId": "post_api_v1_security_2fa_disable",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "code": {
                    "type": "string"
                  },
                  "password": {
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Disable2FA",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/2fa/setup": {
      "post": {
        "description": "Setup2FA starts the 2FA setup process\nPOST /api/v1/security/2fa/setup",
        "operationId": "post_api_v1_security_2fa_setup",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.TwoFactorSetup"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Setup2FA",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/2fa/status": {
      "get": {
        "description": "Get2FAStatus returns the 2FA status for the user\nGET /api/v1/security/2fa/status",
        "operationId": "get_api_v1_security_2fa_status",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "backupCodesCount": {
                          "format": "int64",
                          "type": "integer"
                        },
                        "enabled": {
                          "type": "boolean"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Get2FAStatus",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/2fa/verify": {
      "post": {
        "description": "Verify2FA verifies a TOTP code and enables 2FA\nPOST /api/v1/security/2fa/verify",
        "operationId": "post_api_v1_security_2fa_verify",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "code": {
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "backupCodes": {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Verify2FA",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/audit-logs": {
      "get": {
        "description": "ListAuditLogs returns audit logs for the organization\nGET /api/v1/security/audit-logs",
        "operationId": "get_api_v1_security_audit_logs",
        "parameters": [
          {
            "in": "query",
            "name": "action",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "endDate",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "limit",
            "schema": {
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "offset",
            "schema": {
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "resource",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "resourceId",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "startDate",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "status",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "userId",
            "schema": {
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "logs": {
                          "items": {
                            "allOf": [
                              {
                                "$ref": "#/components/schemas/service.AuditLog"
                              }
                            ],
                            "nullable": true
                          },
                          "type": "array"
                        },
                        "total": {
                          "format": "int64",
                          "type": "integer"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListAuditLogs",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/events": {
      "get": {
        "description": "GetSecurityEvents returns security-related events\nGET /api/v1/security/events",
        "operationId": "get_api_v1_security_events",
        "parameters": [
          {
            "in": "query",
            "name": "limit",
            "schema": {
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/service.AuditLog"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetSecurityEvents",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/my-activity": {
      "get": {
        "description": "GetMyActivity returns the current user's activity\nGET /api/v1/security/my-activity",
        "operationId": "get_api_v1_security_my_activity",
        "parameters": [
          {
            "in": "query",
            "name": "limit",
            "schema": {
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/service.AuditLog"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetMyActivity",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/sessions": {
      "get": {
        "description": "ListSessions returns all active sessions for the current user\nGET /api/v1/security/sessions",
        "operationId": "get_api_v1_security_sessions",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "sessions": {
                          "items": {
                            "allOf": [
                              {
                                "$ref": "#/components/schemas/service.UserSession"
                              }
                            ],
                            "nullable": true
                          },
                          "type": "array"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListSessions",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/sessions/revoke-all": {
      "post": {
        "description": "RevokeAllSessions revokes all sessions except the current one\nPOST /api/v1/security/sessions/revoke-all",
        "operationId": "post_api_v1_security_sessions_revoke_all",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "revokedCount": {
                          "format": "int64",
                          "type": "integer"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "RevokeAllSessions",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/sessions/{uuid}": {
      "delete": {
        "description": "RevokeSession revokes a specific session\nDELETE /api/v1/security/sessions/:uuid",
        "operationId": "delete_api_v1_security_sessions_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "RevokeSession",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/webauthn/authenticate/begin": {
      "post": {
        "description": "BeginWebAuthnAuthentication starts WebAuthn authentication\nPOST /api/v1/security/webauthn/authenticate/begin",
        "operationId": "post_api_v1_security_webauthn_authenticate_begin",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.AuthenticationOptions"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "BeginWebAuthnAuthentication",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/webauthn/authenticate/finish": {
      "post": {
        "description": "FinishWebAuthnAuthentication completes WebAuthn authentication\nPOST /api/v1/security/webauthn/authenticate/finish",
        "operationId": "post_api_v1_security_webauthn_authenticate_finish",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.AuthenticationResponse"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "FinishWebAuthnAuthentication",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/webauthn/credentials": {
      "get": {
        "description": "ListWebAuthnCredentials lists all WebAuthn credentials\nGET /api/v1/security/webauthn/credentials",
        "operationId": "get_api_v1_security_webauthn_credentials",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/service.WebAuthnCredential"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListWebAuthnCredentials",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/webauthn/credentials/{uuid}": {
      "delete": {
        "description": "DeleteWebAuthnCredential deletes a WebAuthn credential\nDELETE /api/v1/security/webauthn/credentials/:uuid",
        "operationId": "delete_api_v1_security_webauthn_credentials_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteWebAuthnCredential",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/webauthn/register/begin": {
      "post": {
        "description": "BeginWebAuthnRegistration starts WebAuthn credential registration\nPOST /api/v1/security/webauthn/register/begin",
        "operationId": "post_api_v1_security_webauthn_register_begin",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.RegistrationOptions"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "BeginWebAuthnRegistration",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/security/webauthn/register/finish": {
      "post": {
        "description": "FinishWebAuthnRegistration completes WebAuthn credential registration\nPOST /api/v1/security/webauthn/register/finish",
        "operationId": "post_api_v1_security_webauthn_register_finish",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "name": {
                    "type": "string"
                  },
                  "response": {
                    "allOf": [
                      {
                        "$ref": "#/components/schemas/service.RegistrationResponse"
                      }
                    ],
                    "nullable": true
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.WebAuthnCredential"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "FinishWebAuthnRegistration",
        "tags": [
          "security"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/settings": {
      "get": {
        "description": "GetSettings returns the current user's settings\nGET /api/v1/settings Human session required; scoped API keys cannot access account settings. autoOrganizeDmarcReports defaults to true, including users without a settings row. Omit the update field to preserve it; false opts out of sorting future arrivals. The preference does not move existing messages, remove the folder or change DNS/receiving setup.",
        "operationId": "get_api_v1_settings",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.UserSettings"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetSettings",
        "tags": [
          "settings"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "put": {
        "description": "UpdateSettings updates the current user's settings\nPUT /api/v1/settings Human session required; scoped API keys cannot access account settings. autoOrganizeDmarcReports defaults to true, including users without a settings row. Omit the update field to preserve it; false opts out of sorting future arrivals. The preference does not move existing messages, remove the folder or change DNS/receiving setup.",
        "operationId": "put_api_v1_settings",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "autoOrganizeDmarcReports": false
              },
              "schema": {
                "$ref": "#/components/schemas/service.UpdateSettingsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.UserSettings"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UpdateSettings",
        "tags": [
          "settings"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/settings/aws/provision": {
      "post": {
        "deprecated": true,
        "description": "ProvisionResources provisions all AWS resources for email receiving",
        "operationId": "post_api_v1_settings_aws_provision",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/handler.ProvisionRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "nextSteps": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "resources": {
                      "$ref": "#/components/schemas/service.ProvisionedResources"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "warning": {
                      "type": "string"
                    }
                  },
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "properties": {
                        "code": {
                          "example": 400,
                          "type": "integer"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    {
                      "properties": {
                        "error": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        },
                        "success": {
                          "type": "boolean"
                        },
                        "valid": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "error"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "properties": {
                        "code": {
                          "example": 401,
                          "type": "integer"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    {
                      "properties": {
                        "error": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        },
                        "success": {
                          "type": "boolean"
                        },
                        "valid": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "error"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "properties": {
                        "code": {
                          "example": 500,
                          "type": "integer"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    {
                      "properties": {
                        "error": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        },
                        "success": {
                          "type": "boolean"
                        },
                        "valid": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "error"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ProvisionResources",
        "tags": [
          "settings"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy AWS provisioning handler with a distinct response envelope. Prefer domain setup-sending/sending-status and explicit /inbox/setup for the current SES workflow; this handler's compatibility is not verified by the documentation."
      }
    },
    "/api/v1/settings/aws/validate": {
      "post": {
        "deprecated": true,
        "description": "ValidateCredentials checks if AWS credentials are valid",
        "operationId": "post_api_v1_settings_aws_validate",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/handler.ValidateCredentialsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "valid": {
                      "type": "boolean"
                    }
                  },
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "properties": {
                        "code": {
                          "example": 400,
                          "type": "integer"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    {
                      "properties": {
                        "error": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        },
                        "success": {
                          "type": "boolean"
                        },
                        "valid": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "error"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "properties": {
                        "code": {
                          "example": 401,
                          "type": "integer"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    {
                      "properties": {
                        "error": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        },
                        "success": {
                          "type": "boolean"
                        },
                        "valid": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "error"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "properties": {
                        "code": {
                          "example": 500,
                          "type": "integer"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    {
                      "properties": {
                        "error": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        },
                        "success": {
                          "type": "boolean"
                        },
                        "valid": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "error"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ValidateCredentials",
        "tags": [
          "settings"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy AWS provisioning handler with a distinct response envelope. Prefer domain setup-sending/sending-status and explicit /inbox/setup for the current SES workflow; this handler's compatibility is not verified by the documentation."
      }
    },
    "/api/v1/shared-mailboxes": {
      "get": {
        "description": "ListSharedMailboxes lists all shared mailboxes\nGET /api/v1/shared-mailboxes",
        "operationId": "get_api_v1_shared_mailboxes",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/service.SharedMailbox"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListSharedMailboxes",
        "tags": [
          "shared-mailboxes"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      },
      "post": {
        "description": "CreateSharedMailbox creates a new shared mailbox\nPOST /api/v1/shared-mailboxes",
        "operationId": "post_api_v1_shared_mailboxes",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.CreateSharedMailboxInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.SharedMailbox"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "CreateSharedMailbox",
        "tags": [
          "shared-mailboxes"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      }
    },
    "/api/v1/shared-mailboxes/{id}": {
      "delete": {
        "description": "DeleteSharedMailbox deletes a shared mailbox\nDELETE /api/v1/shared-mailboxes/:id",
        "operationId": "delete_api_v1_shared_mailboxes_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteSharedMailbox",
        "tags": [
          "shared-mailboxes"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      },
      "get": {
        "description": "GetSharedMailbox gets a shared mailbox\nGET /api/v1/shared-mailboxes/:id",
        "operationId": "get_api_v1_shared_mailboxes_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.SharedMailbox"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetSharedMailbox",
        "tags": [
          "shared-mailboxes"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      }
    },
    "/api/v1/shared-mailboxes/{id}/members": {
      "get": {
        "description": "ListSharedMailboxMembers lists members of a shared mailbox\nGET /api/v1/shared-mailboxes/:id/members",
        "operationId": "get_api_v1_shared_mailboxes_id_members",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/service.SharedMailboxMember"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListSharedMailboxMembers",
        "tags": [
          "shared-mailboxes"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      },
      "post": {
        "description": "AddSharedMailboxMember adds a member to a shared mailbox\nPOST /api/v1/shared-mailboxes/:id/members",
        "operationId": "post_api_v1_shared_mailboxes_id_members",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.AddMemberInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.SharedMailboxMember"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "AddSharedMailboxMember",
        "tags": [
          "shared-mailboxes"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      }
    },
    "/api/v1/shared-mailboxes/{id}/members/{userId}": {
      "delete": {
        "description": "RemoveSharedMailboxMember removes a member from a shared mailbox\nDELETE /api/v1/shared-mailboxes/:id/members/:userId",
        "operationId": "delete_api_v1_shared_mailboxes_id_members_userId",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "userId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "RemoveSharedMailboxMember",
        "tags": [
          "shared-mailboxes"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      }
    },
    "/api/v1/sieve-scripts": {
      "get": {
        "description": "ListSieveScripts lists all Sieve scripts\nGET /api/v1/sieve-scripts",
        "operationId": "get_api_v1_sieve_scripts",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/service.SieveScript"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListSieveScripts",
        "tags": [
          "sieve-scripts"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      },
      "post": {
        "description": "CreateSieveScript creates a new Sieve script\nPOST /api/v1/sieve-scripts",
        "operationId": "post_api_v1_sieve_scripts",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.CreateSieveScriptInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.SieveScript"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "CreateSieveScript",
        "tags": [
          "sieve-scripts"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      }
    },
    "/api/v1/sieve-scripts/validate": {
      "post": {
        "description": "ValidateSieveScript validates a Sieve script\nPOST /api/v1/sieve-scripts/validate",
        "operationId": "post_api_v1_sieve_scripts_validate",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "script": {
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "error": {
                          "type": "string"
                        },
                        "valid": {
                          "type": "boolean"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ValidateSieveScript",
        "tags": [
          "sieve-scripts"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      }
    },
    "/api/v1/sieve-scripts/{id}": {
      "delete": {
        "description": "DeleteSieveScript deletes a Sieve script\nDELETE /api/v1/sieve-scripts/:id",
        "operationId": "delete_api_v1_sieve_scripts_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteSieveScript",
        "tags": [
          "sieve-scripts"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      },
      "get": {
        "description": "GetSieveScript gets a Sieve script\nGET /api/v1/sieve-scripts/:id",
        "operationId": "get_api_v1_sieve_scripts_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.SieveScript"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetSieveScript",
        "tags": [
          "sieve-scripts"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      },
      "put": {
        "description": "UpdateSieveScript updates a Sieve script\nPUT /api/v1/sieve-scripts/:id",
        "operationId": "put_api_v1_sieve_scripts_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "active": {
                    "allOf": [
                      {
                        "type": "boolean"
                      }
                    ],
                    "nullable": true
                  },
                  "name": {
                    "allOf": [
                      {
                        "type": "string"
                      }
                    ],
                    "nullable": true
                  },
                  "script": {
                    "allOf": [
                      {
                        "type": "string"
                      }
                    ],
                    "nullable": true
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.SieveScript"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UpdateSieveScript",
        "tags": [
          "sieve-scripts"
        ],
        "x-human-session-required": true,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Legacy stored configuration; not wired to SES ingestion. Storing a Sieve script, shared mailbox, auto-reply or forward does not enable its execution. Use /inbox/filters and external webhook workflows for supported SES organization/reply/forward automation."
      }
    },
    "/api/v1/sse/connect": {
      "get": {
        "description": "Browser clients obtain a 60-second stream ticket from POST /auth/stream-token. Headless clients use Bearer API keys with email:read. Stream tickets cannot call other endpoints.",
        "operationId": "get_api_v1_sse_connect",
        "parameters": [
          {
            "description": "Browser-only short-lived stream ticket from POST /auth/stream-token. Never place a session JWT or API key here. Headless integrations use Authorization: Bearer with email:read instead.",
            "in": "query",
            "name": "token",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "text/event-stream": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "description": "Event stream",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "Connect",
        "tags": [
          "sse"
        ],
        "x-api-key-scope": "email:read",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/templates": {
      "get": {
        "description": "ListTemplates returns all templates for the organization\nGET /api/v1/templates",
        "operationId": "get_api_v1_templates",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/model.EmailTemplate"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListTemplates",
        "tags": [
          "templates"
        ],
        "x-api-key-scope": "templates:read",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "post": {
        "description": "CreateTemplate creates a new email template\nPOST /api/v1/templates",
        "operationId": "post_api_v1_templates",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.CreateTemplateRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.EmailTemplate"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "CreateTemplate",
        "tags": [
          "templates"
        ],
        "x-api-key-scope": "templates:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/templates/{uuid}": {
      "delete": {
        "description": "DeleteTemplate deletes a template\nDELETE /api/v1/templates/:uuid",
        "operationId": "delete_api_v1_templates_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteTemplate",
        "tags": [
          "templates"
        ],
        "x-api-key-scope": "templates:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "get": {
        "description": "GetTemplate retrieves a template by UUID\nGET /api/v1/templates/:uuid",
        "operationId": "get_api_v1_templates_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.EmailTemplate"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetTemplate",
        "tags": [
          "templates"
        ],
        "x-api-key-scope": "templates:read",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "put": {
        "description": "UpdateTemplate updates a template\nPUT /api/v1/templates/:uuid",
        "operationId": "put_api_v1_templates_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.UpdateTemplateRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.EmailTemplate"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UpdateTemplate",
        "tags": [
          "templates"
        ],
        "x-api-key-scope": "templates:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/templates/{uuid}/preview": {
      "post": {
        "description": "PreviewTemplate renders a template with variables\nPOST /api/v1/templates/:uuid/preview",
        "operationId": "post_api_v1_templates_uuid_preview",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/model.PreviewTemplateRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.PreviewTemplateResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "PreviewTemplate",
        "tags": [
          "templates"
        ],
        "x-api-key-scope": "templates:read",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/tracking/click/{token}": {
      "get": {
        "description": "TrackClick handles link click tracking requests\nGET /api/v1/tracking/click/:token",
        "operationId": "get_api_v1_tracking_click_token",
        "parameters": [
          {
            "in": "path",
            "name": "token",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "302": {
            "description": "Redirect to the configured destination",
            "headers": {
              "Location": {
                "schema": {
                  "format": "uri-reference",
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "TrackClick",
        "tags": [
          "tracking"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/tracking/open/{token}": {
      "get": {
        "description": "TrackOpen handles email open tracking requests\nGET /api/v1/tracking/open/:token.gif",
        "operationId": "get_api_v1_tracking_open_token",
        "parameters": [
          {
            "in": "path",
            "name": "token",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "image/gif": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              }
            },
            "description": "Transparent tracking pixel"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "TrackOpen",
        "tags": [
          "tracking"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/unsubscribe/{token}": {
      "delete": {
        "description": "ConfirmUnsubscribe handles confirmed unsubscribe from landing page\nDELETE /api/v1/unsubscribe/:token",
        "operationId": "delete_api_v1_unsubscribe_token",
        "parameters": [
          {
            "in": "path",
            "name": "token",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "reason": {
                    "type": "string"
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "ConfirmUnsubscribe",
        "tags": [
          "unsubscribe"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "get": {
        "description": "GetUnsubscribePage returns data for the unsubscribe landing page\nGET /api/v1/unsubscribe/:token",
        "operationId": "get_api_v1_unsubscribe_token",
        "parameters": [
          {
            "in": "path",
            "name": "token",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "additionalProperties": {},
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "GetUnsubscribePage",
        "tags": [
          "unsubscribe"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "post": {
        "description": "OneClickUnsubscribe handles RFC 8058 one-click unsubscribe (POST only)\nPOST /api/v1/unsubscribe/:token",
        "operationId": "post_api_v1_unsubscribe_token",
        "parameters": [
          {
            "in": "path",
            "name": "token",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "OneClickUnsubscribe",
        "tags": [
          "unsubscribe"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhook-deliveries": {
      "get": {
        "description": "ListDeliveries User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "get_api_v1_webhook_deliveries",
        "parameters": [
          {
            "in": "query",
            "name": "page",
            "schema": {
              "default": 1,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "pageSize",
            "schema": {
              "default": 50,
              "description": "Values outside 1–100 use 50.",
              "maximum": 100,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "status",
            "schema": {
              "description": "Optional exact delivery status filter; unmatched values return an empty collection.",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/eventoutbox.DeliveryPage"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListDeliveries",
        "tags": [
          "webhook-deliveries"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhook-deliveries/{uuid}": {
      "get": {
        "description": "GetDelivery User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "get_api_v1_webhook_deliveries_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "attempts": {
                          "items": {
                            "$ref": "#/components/schemas/eventoutbox.Attempt"
                          },
                          "type": "array"
                        },
                        "delivery": {
                          "allOf": [
                            {
                              "$ref": "#/components/schemas/eventoutbox.Delivery"
                            }
                          ],
                          "nullable": true
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetDelivery",
        "tags": [
          "webhook-deliveries"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhook-deliveries/{uuid}/replay": {
      "post": {
        "description": "ReplayDelivery User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "post_api_v1_webhook_deliveries_uuid_replay",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ReplayDelivery",
        "tags": [
          "webhook-deliveries"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhook-triggers": {
      "get": {
        "description": "ListWebhookTriggers lists all webhook triggers\nGET /api/v1/webhook-triggers User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "get_api_v1_webhook_triggers",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/service.WebhookTrigger"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListWebhookTriggers",
        "tags": [
          "webhook-triggers"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "post": {
        "description": "CreateWebhookTrigger creates a new webhook trigger\nPOST /api/v1/webhook-triggers User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "post_api_v1_webhook_triggers",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/service.CreateWebhookTriggerInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.WebhookTrigger"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "CreateWebhookTrigger",
        "tags": [
          "webhook-triggers"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhook-triggers/types": {
      "get": {
        "description": "GetWebhookTriggerTypes returns available trigger types\nGET /api/v1/webhook-triggers/types User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "get_api_v1_webhook_triggers_types",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "additionalProperties": {
                          "type": "string"
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetWebhookTriggerTypes",
        "tags": [
          "webhook-triggers"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhook-triggers/{id}": {
      "delete": {
        "description": "DeleteWebhookTrigger deletes a webhook trigger\nDELETE /api/v1/webhook-triggers/:id User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "delete_api_v1_webhook_triggers_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteWebhookTrigger",
        "tags": [
          "webhook-triggers"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "get": {
        "description": "GetWebhookTrigger gets a webhook trigger\nGET /api/v1/webhook-triggers/:id User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "get_api_v1_webhook_triggers_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/service.WebhookTrigger"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetWebhookTrigger",
        "tags": [
          "webhook-triggers"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "put": {
        "description": "UpdateWebhookTrigger User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "put_api_v1_webhook_triggers_id",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "active": {
                    "allOf": [
                      {
                        "type": "boolean"
                      }
                    ],
                    "nullable": true
                  },
                  "description": {
                    "allOf": [
                      {
                        "type": "string"
                      }
                    ],
                    "nullable": true
                  },
                  "filters": {
                    "allOf": [
                      {
                        "additionalProperties": {},
                        "type": "object"
                      }
                    ],
                    "nullable": true
                  },
                  "name": {
                    "allOf": [
                      {
                        "type": "string"
                      }
                    ],
                    "nullable": true
                  },
                  "webhookUrl": {
                    "allOf": [
                      {
                        "type": "string"
                      }
                    ],
                    "nullable": true
                  }
                },
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "$ref": "#/components/schemas/service.WebhookTrigger"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UpdateWebhookTrigger",
        "tags": [
          "webhook-triggers"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhook-triggers/{id}/rotate-secret": {
      "post": {
        "description": "RotateWebhookTriggerSecret User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "post_api_v1_webhook_triggers_id_rotate_secret",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "$ref": "#/components/schemas/model.RotateSecretResponse"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "RotateWebhookTriggerSecret",
        "tags": [
          "webhook-triggers"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhook-triggers/{id}/test": {
      "post": {
        "description": "TestWebhookTrigger tests a webhook trigger\nPOST /api/v1/webhook-triggers/:id/test User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "post_api_v1_webhook_triggers_id_test",
        "parameters": [
          {
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/eventoutbox.Result"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "TestWebhookTrigger",
        "tags": [
          "webhook-triggers"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhooks": {
      "get": {
        "description": "ListWebhooks returns all webhooks for the organization\nGET /api/v1/webhooks User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "get_api_v1_webhooks",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/model.WebhookResponse"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "ListWebhooks",
        "tags": [
          "webhooks"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "post": {
        "description": "CreateWebhook creates a new webhook endpoint\nPOST /api/v1/webhooks User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "post_api_v1_webhooks",
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "events": [
                  "email.received",
                  "email.delivered",
                  "email.bounced"
                ],
                "name": "Mail automation",
                "url": "https://automation.example.com/webhook/mailat"
              },
              "schema": {
                "$ref": "#/components/schemas/model.CreateWebhookRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.WebhookResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "CreateWebhook",
        "tags": [
          "webhooks"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhooks/ses/incoming": {
      "post": {
        "description": "HandleIncoming",
        "operationId": "post_api_v1_webhooks_ses_incoming",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "properties": {
                        "status": {
                          "type": "string"
                        }
                      },
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [],
        "summary": "HandleIncoming",
        "tags": [
          "webhooks"
        ],
        "x-human-session-required": false,
        "x-mailat-backend": "ses",
        "x-mailat-backend-note": "SES email workflow and its stored mailbox/configuration data. Provider actions require configured AWS permissions and verified owned domains; receiving is opt-in."
      }
    },
    "/api/v1/webhooks/{uuid}": {
      "delete": {
        "description": "DeleteWebhook deletes a webhook\nDELETE /api/v1/webhooks/:uuid User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "delete_api_v1_webhooks_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "DeleteWebhook",
        "tags": [
          "webhooks"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "get": {
        "description": "GetWebhook retrieves a webhook by UUID\nGET /api/v1/webhooks/:uuid User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "get_api_v1_webhooks_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.WebhookResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetWebhook",
        "tags": [
          "webhooks"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      },
      "put": {
        "description": "UpdateWebhook updates a webhook\nPUT /api/v1/webhooks/:uuid User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "put_api_v1_webhooks_uuid",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "example": {
                "active": true,
                "events": [
                  "email.received",
                  "email.delivered"
                ]
              },
              "schema": {
                "$ref": "#/components/schemas/model.UpdateWebhookRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/model.WebhookResponse"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "UpdateWebhook",
        "tags": [
          "webhooks"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhooks/{uuid}/calls": {
      "get": {
        "description": "GetWebhookCalls returns recent webhook delivery attempts\nGET /api/v1/webhooks/:uuid/calls User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "get_api_v1_webhooks_uuid_calls",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "limit",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "items": {
                        "allOf": [
                          {
                            "$ref": "#/components/schemas/model.WebhookCallResponse"
                          }
                        ],
                        "nullable": true
                      },
                      "type": "array"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "GetWebhookCalls",
        "tags": [
          "webhooks"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhooks/{uuid}/rotate-secret": {
      "post": {
        "description": "RotateSecret generates a new secret for a webhook\nPOST /api/v1/webhooks/:uuid/rotate-secret User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "post_api_v1_webhooks_uuid_rotate_secret",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "$ref": "#/components/schemas/model.RotateSecretResponse"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "RotateSecret",
        "tags": [
          "webhooks"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    },
    "/api/v1/webhooks/{uuid}/test": {
      "post": {
        "description": "TestWebhook sends a test event to a webhook\nPOST /api/v1/webhooks/:uuid/test User-owned subscriptions. Secret returned only on create/rotate. Events: version,id,type,createdAt,data.messageUuid (+data.identityUuid where available). Verify X-Webhook-Signature t=<unix>,v1=<HMAC-SHA256(timestamp+'.'+rawBody)> with 5-minute timestamp tolerance; deduplicate id. 8 delivery attempts, then dead letter; replay keeps event id. Tests return real HTTP outcome. Key revocation does not delete subscriptions; disabled owners pause delivery. Public HTTPS only; redirects are blocked.",
        "operationId": "post_api_v1_webhooks_uuid_test",
        "parameters": [
          {
            "in": "path",
            "name": "uuid",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 0,
                      "type": "integer"
                    },
                    "data": {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/eventoutbox.Result"
                        }
                      ],
                      "nullable": true
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Success",
            "headers": {
              "X-RateLimit-Remaining": {
                "description": "Remaining requests in this API key's current minute window (present for API-key authentication).",
                "schema": {
                  "minimum": 0,
                  "type": "integer"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 400,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid input"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 401,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Missing, expired or revoked authentication"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 403,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Insufficient permission"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 404,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Resource not found"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 409,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Conflict or changed idempotency payload"
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 410,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Recovery cursor expired; resynchronize"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 429,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Rate limit exceeded; respect Retry-After",
            "headers": {
              "Retry-After": {
                "description": "Seconds until the next fixed-minute request window.",
                "schema": {
                  "minimum": 1,
                  "type": "integer"
                }
              }
            }
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "properties": {
                    "code": {
                      "example": 500,
                      "type": "integer"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "code",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Internal failure; retain the idempotency key"
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "summary": "TestWebhook",
        "tags": [
          "webhooks"
        ],
        "x-api-key-scope": "webhooks:manage",
        "x-mailat-backend": "mailat",
        "x-mailat-backend-note": "Mailat application, account or shared resource API. Individual operations can require configured external services; this label is not a runtime-readiness guarantee."
      }
    }
  },
  "servers": [
    {
      "url": "https://mail.example.com",
      "description": "Replace with your own Mailat instance origin. Paths already include /api/v1."
    }
  ],
  "x-mailat-source": {
    "repository": "https://github.com/dublyo/mailat",
    "baseCommit": "d06861eb95c2e0e0a05b51663d19aead5465d6e0",
    "contractSha256": "db66e1442f2715e2dcdbd93225ae20e9ab058d385bda78186f251390b1c86980",
    "modifiedFromCommit": true
  }
}
