# Wabi for agents

Wabi runs your WhatsApp Business Account on Meta's Cloud API: managed webhooks, a live team inbox, localized templates, AI support agents with traces, and usage and cost analytics, from the dashboard, the REST API, MCP or the CLI. Bring your own WABA, pay Meta at cost.

## Connect and authenticate

- MCP (streamable HTTP): `https://getwabi.dev/api/mcp`. One tool per op. OAuth sign-in through the browser (see https://getwabi.dev/.well-known/oauth-protected-resource), or an API key.
- REST: `POST https://getwabi.dev/api/v1/{op}` with the op's input as JSON; read-only ops also accept GET with `?input=<url-encoded JSON>`. `GET https://getwabi.dev/api/v1` lists every op with its JSON Schema.
- CLI: `npx @meterapp/wabi <op> [--field value] [--json '<json>']`; `npx @meterapp/wabi login` signs in with the browser and saves a key. In CI set `WABI_API_KEY`.
- API keys: `Authorization: Bearer wabi_…`. Create one in Integrations, with `npx @meterapp/wabi login` or `create_api_key`. A key acts with its creator's role (viewer < member < admin < owner) and can be narrowed to scopes: `<group>:read`, `<group>:write`, `<group>:*`, `*:read`, and `billing:purchase` (implied by nothing). With a session or OAuth token, `x-wabi-org: <slug>` picks the organization.
- Errors are RFC 9457 problem+json with a `code` and `request_id`; a 402 carries a checkout_url. See https://getwabi.dev/docs/errors.

Claude Code:

```bash
claude mcp add --transport http wabi https://getwabi.dev/api/mcp
```

## Workflows

1. Orient: `get_onboarding` (the setup checklist and the next step), `get_account` (plan and usage), `get_organization`.
2. Try it: `get_sandbox` → send a template to a test customer (or `simulate_inbound_message` to open their window) → watch statuses and replies arrive.
3. Go live: connect a WhatsApp Business Account in Settings → Accounts (Embedded Signup or WABA id + system-user token); webhooks are managed for you.
4. Team: `list_members`, `create_team`, `share_resource` / `set_resource_visibility` for WhatsApp accounts and agents; invitations and role changes are done by a person in the dashboard.
5. Developer surfaces: `create_api_key` with scopes for a backend; customer webhook endpoints in Integrations.
6. Billing: `get_pricing` → `create_checkout_link` for a human to pay; `get_billing_link` for invoices and cancellation; `set_budget_cap` for overage.

## Rules

- Start with `get_onboarding`: it says what is set up, what is next and which op does it.
- Test in the sandbox first (`get_sandbox`, `simulate_inbound_message`). Never message real customers to test something.
- Respect WhatsApp's rules: free-form messages only inside a customer's 24-hour window (the customer wrote in the last 24 hours); otherwise send an approved template. Never message someone without the opt-in Meta requires, and honour opt-outs.
- Meta's message fees are billed by Meta to the customer's WhatsApp Business Account; never describe them as a charge from us, and never invent a price. Quote get_pricing.
- Never buy, change or cancel a plan on your own initiative. Quote the plan and price from get_pricing, and only call subscribe or cancel_subscription with confirm: true after a human approved it; otherwise give them the create_checkout_link URL.
- Inviting and removing members and changing roles are done by a person in the dashboard; do not try to work around a 403.
- Use read-only ops freely; every write is recorded in the activity log with your surface.
- When a call fails in a way that looks like a Wabi bug, report_issue with the error's request_id, the op and context; when the human wishes Wabi did something it cannot, request_feature. If they come back filed: false with `similar`, upvote_feedback the match instead. Never invent a review: submit_review only with the human's rating and words.

## Sandbox

Every organization has a simulated WhatsApp number on every plan, backed by a Meta simulator: nothing reaches real WhatsApp users, nothing is charged, and sandbox messages do not count against the plan. `get_sandbox` returns its account id, its phone number id (the sender), the test customers (15550100001, 15550100002, 15550100003, 15550100004, 15550100005) and the starter template `hello_world` (en_US, approved). Sends report sent at once, delivered after ~1 s and read after ~3 s; the test customer replies after ~5 s. `simulate_inbound_message` makes a test customer send any text, through the same pipeline as Meta traffic. Free-form text outside the 24-hour window fails with 131047, as on Meta. New templates are reviewed after ~60 s. Recipients ending in 0000 (e.g. 15550100000) fail with 131026. Guide: https://getwabi.dev/docs/sandbox.

## Pricing

Units: messages: every inbound and outbound WhatsApp message the platform processes (sandbox messages are free). ai_replies: one AI agent turn that writes a customer message or a suggested reply on our model key (bring-your-own-key turns are free). Meta bills its own per-message fees to your WhatsApp Business Account directly. We show them at cost and never mark them up or bill them. Yearly is two months free (10x the monthly price).

The full pricing document (JSON, no credential, the same shape on every Meter product): `GET https://getwabi.dev/api/v1/pricing`; MCP `get_pricing` (also on the no-auth catalog server https://getwabi.dev/api/mcp/catalog); CLI `npx @meterapp/wabi pricing --json`; human page: https://getwabi.dev/pricing.

- Free (`free`): free. 1,000 messages and 100 AI replies a month; 1 live number(s) plus the sandbox, 2 members, 30-day history. For trying Wabi on one number.
- Starter (`starter`): $29/month or $290/year. 10,000 messages and 1,000 AI replies a month; 1 live number(s) plus the sandbox, 5 members, 365-day history. For a small team answering customers on one number. Buy: https://getwabi.dev/checkout?plan=starter&ref=agent
- Growth (`growth`): $99/month or $990/year. 50,000 messages and 5,000 AI replies a month; 3 live number(s) plus the sandbox, 15 members, 365-day history. For businesses automating support and outreach across numbers. Buy: https://getwabi.dev/checkout?plan=growth&ref=agent
- Scale (`scale`): $299/month or $2,990/year. 250,000 messages and 25,000 AI replies a month; 10 live number(s) plus the sandbox, unlimited members, 365-day history. For operators running several brands, markets or locations. Buy: https://getwabi.dev/checkout?plan=scale&ref=agent
- Enterprise (`enterprise`): custom. custom messages and custom AI replies a month; custom live number(s) plus the sandbox, unlimited members, custom history. For larger volumes, security reviews and custom terms.

Overage: $1 per 1,000 messages and $0.02 per AI reply past the allowance, up to a monthly budget cap (default $58, 2x the plan price; change it on the billing page). Non-critical sends stop at the cap. Free: No overage: sends past the monthly allowance are refused until the next month or an upgrade.

Buying a plan (never collect card details; the human pays on Stripe):

- MCP `create_checkout_link`, CLI `wabi upgrade --plan growth [--yearly]`, REST `POST /api/v1/billing/checkout` return a Stripe Checkout URL for a human. Nothing is charged until they complete it.
- Before signup: create_checkout_link needs no account: without a credential it returns a Stripe Checkout URL for a human. After paying they sign in to Wabi with the same email; the subscription attaches to their organization on return (or claim_checkout {session_id}).
- With a saved card: subscribe {plan, interval, confirm: true} changes the plan on the organization's saved card, only after a human approved the price.
- Account and invoices: get_billing_link (invoices, card, cancel); get_account (plan, usage, what the next plan adds).
- Enterprise: Email jonathan@getwabi.dev.

## Customer webhooks

Signed events to HTTPS endpoints added in Integrations. Headers: `webhook-id`, `webhook-timestamp`, `webhook-signature` (Standard Webhooks). Body: `{ id, type, occurred_at, org_id, subject, data }`. Guide: https://getwabi.dev/docs/webhooks.

- Endpoints are HTTPS URLs added in Integrations in the dashboard, each with its own signing secret and an optional list of event types (none: every event).
- Delivery is at least once: the same event can arrive more than once, so deduplicate on webhook-id. Order is not guaranteed; use occurred_at.
- Answer with any 2xx within 10 seconds and do slow work afterwards. Anything else, or no answer, is retried with exponential backoff.
- After the last retry the delivery is marked dead. An endpoint that keeps failing is marked failing and its owners are told; every attempt, with its status code and latency, is in the endpoint's delivery log.
- Signatures follow the Standard Webhooks specification, so its libraries verify Wabi deliveries as they are.

Event types:

- `message.received`: A customer sent a message to one of your numbers (text, media, location, interactive reply, reaction).
- `message.sent`: Meta accepted an outbound message for delivery.
- `message.delivered`: An outbound message reached the customer's phone.
- `message.read`: The customer read an outbound message (when their read receipts are on).
- `message.failed`: An outbound message failed, with Meta's error code and whether a retry could help.
- `conversation.needs_reply`: A customer turn is waiting for a substantive answer from your business.
- `conversation.escalated`: An AI agent or a rule handed the conversation to a person, with the reason and a summary.
- `conversation.resolved`: The conversation was marked resolved.
- `window.expiring`: A customer's 24-hour service window closes soon; after it, only templates can be sent.
- `template.approved`: Meta approved a template in one language.
- `template.rejected`: Meta rejected a template in one language, with the reason.
- `template.quality_changed`: Meta changed a template's quality rating or paused or disabled it.
- `flow.submitted`: A customer completed a WhatsApp Flow; the payload carries their answers.
- `location.received`: A customer shared a location (a single pin; continuous live location is not available on the Cloud API).
- `agent.session.completed`: An AI agent session ended: resolved, escalated or timed out, with tokens and cost.
- `agent.execution.failed`: An AI agent turn failed (model or tool error); the conversation is left for a person.

## Feedback and reviews

Feature requests are public on https://getwabi.dev/feedback; issue reports are private to the reporter's organization and the Wabi team. Reviews are public on https://getwabi.dev/reviews, one per organization. Guide: https://getwabi.dev/docs/feedback.

| action | MCP tool | CLI | REST |
| --- | --- | --- | --- |
| list / search the board | `list_feedback` | `npx @meterapp/wabi feedback list` | `GET https://getwabi.dev/api/v1/feedback` (public) |
| request a feature | `request_feature` | `npx @meterapp/wabi feedback request "<title>"` | `POST https://getwabi.dev/api/v1/feedback/features` |
| report an issue | `report_issue` | `npx @meterapp/wabi feedback report "<title>" [--last]` | `POST https://getwabi.dev/api/v1/feedback/issues` |
| upvote | `upvote_feedback` | `npx @meterapp/wabi feedback upvote <id>` | `POST https://getwabi.dev/api/v1/feedback/{id}/votes` |
| post / edit a review | `submit_review` | `npx @meterapp/wabi review --rating 5 --body "…"` | `PUT https://getwabi.dev/api/v1/reviews/me` |

## Ops

### Sandbox

- `get_sandbox`: This organization's sandbox: a simulated WhatsApp number every organization gets, for trying messaging, templates, the inbox, AI agents and webhooks without Meta.
- `simulate_inbound_message` (write): Make a sandbox test customer send a WhatsApp text to this organization's sandbox number, as if they typed it on their phone.

### Events

- `list_events`: The organization's event log, newest first: every platform event (message.received, message.sent, message.delivered, message.read, message.failed…) with its payload, subject, source and time.
- `get_event`: One event from the organization's event log by id, with its payload and how each internal consumer handled it (done, failed with the error, dead after its retries).

### Organization

- `get_organization`: The organization this credential acts in: id, slug, name, default timezone and language (used by the inbox, reports and AI agents), and the caller's role.
- `update_organization` (write) (admin): Change the organization's name, default timezone (IANA, e.g.
- `list_activity`: Every change made through the platform, newest first: who (a person, an API key, an AI agent, a worker), from which surface (dashboard, api, mcp, cli, worker, ai) and what.
- `get_onboarding`: The organization's setup checklist, in order: send a message from the sandbox number, receive a reply, connect a live WhatsApp Business Account, get a template approved, deploy an AI agent, connect a developer surface (API key, MCP or CLI), invite a teammate.
- `get_referral_stats`: Wabi team only.
- `get_profile`: Your own settings, the same in every organization: `locale`, the language the dashboard and every email to you are written in (one of en), or null when you never chose one (the dashboard then follows the browser, emails are English).
- `update_profile` (write): Changes your own settings: `locale` (en) is the language of the dashboard and of every email Wabi sends you; null forgets it.

### Members and sharing

- `list_members`: Everyone in this organization with their email, role (owner, admin, member, viewer) and teams.
- `list_invites` (admin): Pending invitations to this organization (email, role, teams, who invited, when it expires).
- `list_teams`: Teams in this organization with their members (maintainer or member) and the resources (WhatsApp accounts, AI agents) shared with each team.
- `create_team` (write): Create a team (a group of members to share WhatsApp accounts and agents with, and to route conversations to).
- `update_team` (write): Rename a team or change its description.
- `delete_team` (write): Delete a team.
- `set_team_member` (write): Add an organization member to a team, or change their team role (maintainer manages the team; member is in it).
- `remove_team_member` (write): Take someone out of a team (they stay in the organization).
- `list_resource_access`: Who can see a shareable resource (a WhatsApp account or an AI agent): its visibility (org or restricted), its creator, and every grant to a team or person with its access (read, write, admin).
- `set_resource_visibility` (write): org: every organization member sees the resource (viewers read, members write).
- `share_resource` (write): Give a team or a person read, write or admin access to a WhatsApp account or AI agent (replacing what that team or person had).
- `unshare_resource` (write): Remove a team's or person's grant on a WhatsApp account or AI agent.
- `list_audit_log` (admin): Membership, role, team, invite, API key, billing, settings and sharing changes in this organization, newest first: who (a person, an API key, an OAuth client or the system), what, to what, and when.

### API keys

- `list_api_keys`: API keys of this organization (prefix only; the full key is shown once at creation), each with the role it acts with, its scopes and who created it.
- `create_api_key` (write): Create an organization API key for your backend, the CLI, an MCP host or CI.
- `revoke_api_key` (write): Revoke an API key immediately; every backend, CLI, CI job or MCP host using it stops working.

### Billing

- `get_pricing`: The plans (Free, Starter, Growth, Scale, Enterprise): price {monthly, yearly} in USD, included messages and AI replies a month, limits (live numbers, WhatsApp accounts, members, agents, history days; null is unlimited), features, overage rates and the default budget cap, a checkout_url per paid plan, and how_to_buy.
- `get_account`: Who this credential acts for and what it may use: the organization, your role in it (viewer, member, admin, owner) and whether you are a person, an OAuth client or an API key (acting_as, with the key's scopes), the plan in force (status, interval, renewal or end date, budget cap), usage this period against every limit (messages, AI replies, live numbers, members, agents) with what remains and the overage so far, and next_tier: what the next plan adds, its price and a checkout_url.
- `get_billing`: This organization's plan, subscription status, renewal or end date, budget cap, whether a card is saved (so subscribe can charge it), and usage this period against the plan (messages, AI replies, numbers, members, agents, overage so far).
- `create_checkout_link` (write) (admin): A Stripe Checkout URL where a human pays for a plan; hand it to them (or open it in their browser).
- `subscribe` (write) (admin): Start or change this organization's paid plan in one call, charging the card already saved for the organization.
- `cancel_subscription` (write) (admin): Cancel the paid plan at the end of the current period (no refund; the plan stays until then, then the organization is on Free).
- `resume_subscription` (write) (admin): Undo a cancellation that has not taken effect yet, so the plan renews as before.
- `set_budget_cap` (write) (admin): Set this organization's monthly overage budget cap in US dollars: usage past the plan's allowance is billed up to this amount, then non-critical sends (campaigns, bulk sends) stop until the next period.
- `claim_checkout` (write) (admin): Attach a checkout paid before signup (create_checkout_link without a credential) to this organization, by its session_id (cs_…).
- `create_billing_portal_link` (write) (admin): A private Stripe page where a human downloads invoices, updates the card or billing details, or cancels.
- `get_billing_link` (write) (admin): The Stripe customer portal for a human: invoices, card and billing details, plan change and cancellation.

### Feedback

- `list_feedback`: The Wabi feedback board: feature requests every customer can see, plus your own issue reports (and ones the team published), with status and upvotes, most upvoted first.
- `get_feedback`: One feedback item with its status, upvotes, comments (oldest first; official answers from the Wabi team are marked `official`) and its timeline of status changes with the team's notes.
- `list_my_feedback`: What your organization filed (every status), the items you get email about (filed, upvoted, commented, followed) with whether you muted them, your organization's review, and whether feedback email reaches you.
- `request_feature` (write): Files a feature request on the Wabi board and upvotes it for your organization.
- `report_issue` (write): Reports a problem with Wabi itself: a failing or wrong call (pass the request_id from the error or the X-Request-Id header, and the op), a message that was not delivered or delivered twice, a webhook that never arrived, a template that will not submit, an agent that misbehaved, a docs error.
- `upvote_feedback` (write): Adds your organization's upvote to a feature request or issue ("me too"); votes decide what gets built and fixed first, and you get an email when its status changes.
- `remove_feedback_vote` (write): Takes back your organization's upvote on a feature request or issue, and stops its emails unless you filed or commented on it.
- `comment_on_feedback` (write): Adds context to an existing feature request or issue: your use case, another failing request, a workaround.
- `set_feedback_subscription` (write): With id: start or stop emails about one feature request or issue.
- `submit_review` (write): Posts your organization's public review of Wabi (1–5 stars, what you like, what you don't, what you use it for), or edits it (once an hour; earlier versions are kept).
- `list_reviews`: Published reviews of Wabi with the aggregate (average rating, count and distribution) and the team's responses.
- `update_feedback` (write): Wabi team only.
- `respond_to_feedback` (write): Wabi team only.
- `respond_to_review` (write): Wabi team only.

Full schemas: https://getwabi.dev/llms-full.txt or https://getwabi.dev/openapi.json.
