Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.tempinbox.dev/llms.txt

Use this file to discover all available pages before exploring further.

The session system lets users keep multiple inboxes active simultaneously (up to 3). It uses an HMAC-signed session_id cookie stored in Cloudflare KV.
Session endpoints are designed for browser clients. For API automation, track JWTs per address directly instead of using session management.

List session addresses

GET /api/session/addresses Returns all addresses in the current session and which one is active.
curl https://tempinbox.dev/api/session/addresses \
  -b cookies.txt   # sends session_id cookie
Response
{
  "addresses": [
    { "address": "[email protected]", "createdAt": 1748426400000 },
    { "address": "[email protected]", "createdAt": 1748430000000 }
  ],
  "activeAddress": "[email protected]"
}

Switch active address

POST /api/switch_address Switches the active inbox. Updates the jwt cookie to the JWT for the selected address. Also rotates the session_id for security.
curl -X POST https://tempinbox.dev/api/switch_address \
  -H "Content-Type: application/json" \
  -b cookies.txt -c cookies.txt \
  -d '{ "address": "[email protected]" }'
Response
{ "success": true, "address": "[email protected]" }

Logout

POST /api/logout Deletes the session from KV storage and clears jwt and session_id cookies.
curl -X POST https://tempinbox.dev/api/logout \
  -b cookies.txt -c cookies.txt
Response
{ "success": true }