HTTP API
The HTTP server hosts both the Web UI and JSON API on the configured HTTP host and port.
Health
Section titled “Health”GET /api/healthReturns:
{ "status": "ok" }Connection settings
Section titled “Connection settings”GET /api/connectionReturns the SMTP connection settings currently used by the server.
Message events
Section titled “Message events”GET /api/eventsOpens a Server-Sent Events stream for mailbox updates.
List messages
Section titled “List messages”GET /api/messagesSupported query parameters:
| Parameter | Description |
|---|---|
q |
Search text. |
hasAttachments |
Filter by attachment presence. |
receivedAfter |
Filter messages received after a timestamp. |
receivedBefore |
Filter messages received before a timestamp. |
Clear messages
Section titled “Clear messages”DELETE /api/messagesDeletes all retained messages.
Get a message
Section titled “Get a message”GET /api/messages/:idReturns message details for a captured message.
Delete a message
Section titled “Delete a message”DELETE /api/messages/:idDeletes a captured message.
Download an attachment
Section titled “Download an attachment”GET /api/messages/:id/attachments/:attachmentIdReturns the stored attachment content with attachment headers.