API Keys¶
Manage and test REST API credentials without leaving the Admin Console.
Create & rotate keys¶
- Open Admin Console → API Keys
- Click Create Key and choose scopes (fax:send, inbound:list, admin, etc.)
- Copy the generated token (
fbk_live_<id>_<secret>) — it is only shown once - Rotate or revoke from the same screen; Faxbot records the change in audit logs when enabled
Note
For production, set REQUIRE_API_KEY=true in the Setup Wizard or Security tab so unauthenticated requests are rejected.
Smoke test from the console¶
- Use Send Fax to queue a test while the new key is active
- View the auto-generated curl example in the sidebar if you need to script verification
- Diagnostics → API Auth lists recent successes/failures with reasons
Quick examples¶
- Open Admin Console → API Keys
- Create a key with the scopes you need (e.g.,
fax:send,fax:read) - Open Send Fax and queue a test while the key is selected
- Check Jobs for status updates
BASE="http://localhost:8080"
curl -X POST "$BASE/fax" \
-H "X-API-Key: $API_KEY" \
-F to=+15551234567 \
-F file=@./document.pdf
# Then check status
curl -H "X-API-Key: $API_KEY" "$BASE/fax/$JOB_ID"
const FaxbotClient = require('faxbot');
const client = new FaxbotClient('http://localhost:8080', process.env.API_KEY);
(async () => {
const job = await client.sendFax('+15551234567', './document.pdf');
console.log('Queued:', job.id);
const status = await client.getStatus(job.id);
console.log('Status:', status.status);
})();
from faxbot import FaxbotClient
client = FaxbotClient('http://localhost:8080', api_key=os.getenv('API_KEY'))
job = client.send_fax('+15551234567', './document.pdf')
print('Queued', job['id'])
status = client.get_status(job['id'])
print('Status', status['status'])
Troubleshooting¶
- 401 Unauthorized → Scope missing or wrong key. Reissue the key with
fax:send/fax:readscopes. - Rate limited → Global limit hit; adjust
MAX_REQUESTS_PER_MINUTEin Settings → Security. - 413 / 415 → File too large or wrong type; review Images & PDFs.
For automation examples, see the Node SDK and Python SDK.