01
Send email#
Provide text, HTML, or both. Use reply_to_message_id to preserve thread and email reply headers.
Shell
curl https://botinbox.dev/v0/inboxes/INBOX_ID/messages \
-X POST -H "Authorization: Bearer $BOTINBOX_API_KEY" -H "Content-Type: application/json" \
-d '{"to":["human@example.com"],"subject":"Hello","text":"Sent by my agent"}'02
List and search#
Use q for PostgreSQL full-text search across subject, sender, plain text, reply text, and stripped HTML; unread=true for unread inbound messages; label for label filtering; and limit/cursor for pagination.
Shell
curl "https://botinbox.dev/v0/inboxes/INBOX_ID/messages?q=invoice&unread=true&limit=25" \
-H "Authorization: Bearer $BOTINBOX_API_KEY"03
Read state#
Mark an individual message read or unread.
Shell
curl https://botinbox.dev/v0/inboxes/INBOX_ID/messages/MESSAGE_ID \
-X PATCH -H "Authorization: Bearer $BOTINBOX_API_KEY" -H "Content-Type: application/json" \
-d '{"read":true}'