SpecinboxDocs
← Dashboard

Authentication

The Authorization header, key formats and scopes.

Every /v1 request is authenticated with Authorization: Bearer <key>. We never accept a key as a query parameter or via HTTP Basic auth — if it isn't in the Authorization header, it isn't checked.

Authorization: Bearer tm_live_51Hx9kQ...v8T

Key format

A key is tm_live_ or tm_test_ followed by 43 base62 characters ([0-9A-Za-z]). Live keys touch real inboxes and count toward your quota; test keys only ever touch sandbox inboxes and fixture mail (see Test mode).

If you run a secret scanner (GitHub included) over your own repos, this is the pattern to flag a leaked Specinbox key:

\btm_(live|test)_[0-9A-Za-z]{43}\b

Secret vs. restricted keys

A secret key can do anything on your org. A restricted key is scoped to exactly what you pick when you create it:

ScopeGrants
inboxes:readList and read inboxes
inboxes:writeCreate and delete inboxes
messages:readList and read messages and attachments
messages:writeDelete messages, and send between your own org's inboxes
usage:readRead usage and quota numbers

A key without the right scope gets 403 insufficient_scope — see Errors.

Revoking and rolling

Revoking a key takes effect for every request within 10 seconds (we cache key lookups for that long). Rolling a key keeps the old secret working for up to 24 hours so a deploy has no downtime.