Get Started
Quickstart
Get an API key, make your first call, pick a workspace and read your campaigns. Five minutes from nothing to a first response.
This page covers what every integration needs: getting a key, the base URL, your first calls, errors, safe retries, pagination and live updates.
All examples call the live API at https://api.bavlio.com. Replace bav_YOUR_KEY with your key before running them.
1. Get an API key
- 1
New to Bavlio: start a registration
POST /registrationsneeds no credential. It opens an account and answers with an API key. Pass your email address and Bavlio sends a verification link straight away. The account becomes permanent once the address is verified; one still unverified after 7 days is deleted.The
api_keyfield of the answer is your key. It is shown only once. - 2
Already have an account: create a key
Connect Bavlio's MCP server to an AI tool such as Claude or Cursor. It signs you in with your Bavlio account; then ask it to create an API key. Once you hold any credential,
POST /api-keyscreates more keys. - 3
Store it as a secret
Keep the key in your runtime's secret store, for example as
BAVLIO_API_KEY. Never commit it to source. Keys start withbav_.
2. Authenticate
Send the key as a Bearer token in the Authorization header of every request. GET /whoami answers with the account the key belongs to.
3. Pick a workspace
Campaigns, the inbox, billing and everything else live in a workspace. A call acts in your default workspace unless the bavlio-workspace header names another one. GET /workspaces lists the workspaces you belong to; each workspace.id is a value for the header.
A new account has no workspace yet: saving your company profile with PUT /workspace creates the first one. See Choosing a workspace.
4. Read your campaigns
The answer holds every campaign of the workspace under campaigns. Leave the bavlio-workspace header out to read your default workspace.
5. Handle errors
Every error the API returns on purpose has the same JSON body: a stable code to match on, the HTTP status as statusCode and a message for people. Full list at Errors.
On a 4xx, fix the request. On a 429, wait the retryAfterSeconds the body names. On a 502 or 503, retry with exponential backoff.
6. Retry sends safely
Sending a reply and approving a review accept an Idempotency-Key header. Send the same key again after a network failure and Bavlio answers with the first call's outcome instead of sending twice. See Errors → Idempotency.
7. Page through long lists
Two lists come in pages: a campaign's activity and the inbox's conversations. Pass the next_cursor of one page back as ?cursor= to get the next; null means you have them all. Every other list comes whole. See Pagination.
8. Follow changes live
GET /inbox/changes is a stream of server-sent events that says when conversations, LinkedIn accounts or email change, so you know when to read them again. Bavlio does not call your servers: there are no webhooks. See Watch inbox changes.
Copy this for your AI assistant
Paste this into Claude, ChatGPT, Cursor or Codex to give it the right context for a Bavlio integration.
FAQ
How do I authenticate?
How do I authenticate?
Send your API key as a Bearer token: Authorization: Bearer bav_<your-key>. Keys belong to your account and work in every workspace you belong to; the bavlio-workspace header picks one.
What is the base URL?
What is the base URL?
https://api.bavlio.com. Paths have no version prefix: GET /campaigns, not GET /v1/campaigns.
How do I retry safely after a network failure?
How do I retry safely after a network failure?
Retry reads (GET) freely. Sending a reply and approving a review take an Idempotency-Key, so retry them with the same key. For any other write, read the current state first and retry only if the first call did not land.
How do I paginate results?
How do I paginate results?
Only a campaign's activity and the inbox's conversations come in pages: follow next_cursor until it is null. Every other list returns everything at once. See Pagination.
Are there webhooks?
Are there webhooks?
No. Bavlio does not call your servers. Follow GET /inbox/changes for live updates, or read the lists you care about again on a timer.
What is the rate limit?
What is the rate limit?
There is no general request limit. A few actions have their own, such as 20 LinkedIn replies an hour per account. See Rate Limits.