> ## Documentation Index
> Fetch the complete documentation index at: https://docs.keebai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Tool catalogue

> All 101 MCP tools, grouped by domain, with the scope each one requires.

Every tool below is exposed by [`POST /v1/mcp`](/dev/mcp/overview) and delegates to the same service as its REST counterpart, so the behaviour, validation, and tenancy rules documented across these pages apply unchanged.

The **Scope** column is the scope your token needs. Without it the tool still appears in `tools/list`, and the call fails with `INSUFFICIENT_SCOPE` — see [how scopes are enforced](/dev/mcp/overview#scopes-are-enforced-per-tool-not-per-connection).

Tools marked 🔴 delete data permanently.

## Contacts

Read and write the people on the other side of your channels. See the [Contacts endpoints](/dev/endpoints/contacts-list) for the full field reference.

| Tool                       | Scope             | What it does                                                                                                                                                    |
| -------------------------- | ----------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `keebai_contacts_list`     | `contacts:read`   | List contacts, most recently active first. The way to find a contact id before opening a CRM ticket. Never returns merged contacts or the `playground` channel. |
| `keebai_contact_get`       | `contacts:read`   | Get one contact by id, with custom fields and last-activity timestamps.                                                                                         |
| `keebai_contact_create`    | `contacts:write`  | Create a contact. `user_id` is the identifier inside the channel — on WhatsApp, the phone without the leading `+`.                                              |
| `keebai_contact_update`    | `contacts:write`  | Partial update. An empty string does not clear a field, and `custom_fields` is merged rather than replaced.                                                     |
| 🔴 `keebai_contact_delete` | `contacts:delete` | Delete a contact and its change history. Conversations survive.                                                                                                 |

## CRM

The full pipeline: customers, tickets, tasks, notes. See the [CRM overview](/dev/crm/overview) for how the entities relate.

<Warning>
  CRM reads are **company-wide**. Every `*_list` and `*_get` tool returns records from every project in your company, not just the one the token was minted for.
</Warning>

### Customers

| Tool                            | Scope                  | What it does                                                                      |
| ------------------------------- | ---------------------- | --------------------------------------------------------------------------------- |
| `keebai_crm_customers_list`     | `crm:customers:read`   | List customers with free-text search and pagination.                              |
| `keebai_crm_customer_get`       | `crm:customers:read`   | Get one customer by id.                                                           |
| `keebai_crm_customer_create`    | `crm:customers:write`  | Create a customer. No implicit deduplication — calling twice creates two records. |
| `keebai_crm_customer_update`    | `crm:customers:write`  | Partial update. `tags` replaces the whole tag list.                               |
| 🔴 `keebai_crm_customer_delete` | `crm:customers:delete` | Delete a customer.                                                                |

### Tickets

| Tool                           | Scope                | What it does                                                                                              |
| ------------------------------ | -------------------- | --------------------------------------------------------------------------------------------------------- |
| `keebai_crm_tickets_list`      | `crm:tickets:read`   | List tickets filtered by pipeline, stage, tag, contact, assignee, category, channel, or date.             |
| `keebai_crm_ticket_get`        | `crm:tickets:read`   | Get one ticket by id.                                                                                     |
| `keebai_crm_ticket_create`     | `crm:tickets:write`  | Create a ticket for an existing contact. `chat_user` is required — find it with `keebai_contacts_list`.   |
| `keebai_crm_ticket_update`     | `crm:tickets:write`  | Update closing state, resolution, priority, amount, tags, and conversation summary.                       |
| `keebai_crm_ticket_move_stage` | `crm:tickets:write`  | Move a ticket between pipeline stages. Reports whether the destination needs a human and what comes next. |
| 🔴 `keebai_crm_ticket_delete`  | `crm:tickets:delete` | Delete a ticket.                                                                                          |

### Tasks

| Tool                        | Scope              | What it does                                                        |
| --------------------------- | ------------------ | ------------------------------------------------------------------- |
| `keebai_crm_tasks_list`     | `crm:tasks:read`   | List tasks, optionally filtered by status.                          |
| `keebai_crm_task_get`       | `crm:tasks:read`   | Get one task by id.                                                 |
| `keebai_crm_task_create`    | `crm:tasks:write`  | Create a task. The creator is the token's owner.                    |
| `keebai_crm_task_update`    | `crm:tasks:write`  | Update title, assignee, status, priority, due date, or description. |
| 🔴 `keebai_crm_task_delete` | `crm:tasks:delete` | Delete a task.                                                      |

### Notes

| Tool                        | Scope              | What it does                                                               |
| --------------------------- | ------------------ | -------------------------------------------------------------------------- |
| `keebai_crm_notes_list`     | `crm:notes:read`   | List notes, optionally filtered by contact, ticket, or type.               |
| `keebai_crm_note_get`       | `crm:notes:read`   | Get one note by id.                                                        |
| `keebai_crm_note_create`    | `crm:notes:write`  | Create a note. It must attach to a contact or a ticket; neither one fails. |
| `keebai_crm_note_update`    | `crm:notes:write`  | Update the body or the type. What it is attached to cannot change.         |
| 🔴 `keebai_crm_note_delete` | `crm:notes:delete` | Delete a note.                                                             |

## Knowledge

Retrieval and authoring against the tenant knowledge base. See the [Knowledge overview](/dev/knowledge/overview).

| Tool                               | Scope              | What it does                                                                       |
| ---------------------------------- | ------------------ | ---------------------------------------------------------------------------------- |
| `keebai_knowledge_search`          | `knowledge:query`  | Full-text, vector, or hybrid search. Returns `node_id`, title, snippet, and score. |
| `keebai_knowledge_tree`            | `knowledge:read`   | The full folder and document tree. Use it to discover `node_id`s.                  |
| `keebai_knowledge_folder_create`   | `knowledge:write`  | Create a folder.                                                                   |
| `keebai_knowledge_document_create` | `knowledge:write`  | Create a document from Markdown. Triggers a reindex.                               |
| 🔴 `keebai_knowledge_node_delete`  | `knowledge:delete` | Delete a node. Deleting a folder takes its contents with it.                       |
| `keebai_knowledge_assign`          | `knowledge:assign` | Assign nodes to every worker of an assistant.                                      |

## Messaging

Everything under [`/v1/messages`](/dev/messaging/overview). Every send tool takes an optional `channel` (`whatsapp`, `whatsapp_qr`, `instagram`, `messenger`; defaults to `whatsapp`) plus `channel_id` or `phone_number_id` to pick the concrete channel. Free-form sends only work inside the 24-hour window; outside it, only `keebai_send_template` gets through.

| Tool                               | Scope           | What it does                                                                                                         |
| ---------------------------------- | --------------- | -------------------------------------------------------------------------------------------------------------------- |
| `keebai_send_text`                 | `messages:send` | Free-form text.                                                                                                      |
| `keebai_send_template`             | `messages:send` | A Meta-approved template. The only way out of the 24-hour window. Pass `flow_token` to bind one of its FLOW buttons. |
| `keebai_send_image`                | `messages:send` | Image by link or `media_id`.                                                                                         |
| `keebai_send_video`                | `messages:send` | Video by link or `media_id`.                                                                                         |
| `keebai_send_audio`                | `messages:send` | Audio file, or a voice note with `voice: true`.                                                                      |
| `keebai_send_document`             | `messages:send` | PDF, DOCX, and the like.                                                                                             |
| `keebai_send_sticker`              | `messages:send` | WebP sticker.                                                                                                        |
| `keebai_send_location`             | `messages:send` | A map pin.                                                                                                           |
| `keebai_send_contacts`             | `messages:send` | Share contact cards in a chat. Does **not** create contacts — that is `keebai_contact_create`.                       |
| `keebai_send_reaction`             | `messages:send` | React with an emoji; an empty emoji clears it.                                                                       |
| `keebai_mark_read`                 | `messages:send` | Mark an inbound message read, optionally with the typing indicator.                                                  |
| `keebai_send_interactive_buttons`  | `messages:send` | Up to 3 quick reply buttons.                                                                                         |
| `keebai_send_interactive_list`     | `messages:send` | A tappable menu, up to 10 sections.                                                                                  |
| `keebai_send_interactive_cta_url`  | `messages:send` | One button that opens a URL.                                                                                         |
| `keebai_send_interactive_catalog`  | `messages:send` | Opens your Meta product catalog.                                                                                     |
| `keebai_send_interactive_carousel` | `messages:send` | Up to 10 media cards, each with its own URL button.                                                                  |
| `keebai_send_flow`                 | `messages:send` | Send a published [WhatsApp Flow](/dev/messaging/flows) as an interactive message.                                    |
| `keebai_send_raw`                  | `messages:send` | Escape hatch: an unvalidated Meta Graph API body.                                                                    |
| `keebai_send_bulk`                 | `messages:bulk` | Broadcast a template to up to 5000 recipients. Costs money at Meta.                                                  |
| `keebai_bulk_status`               | `messages:bulk` | Progress of a broadcast: sent, failed, pending.                                                                      |

## WhatsApp Flows

In-chat forms. See the [Flows guide](/dev/messaging/flows) for the full lifecycle.

| Tool                    | Scope         | What it does                                                                |
| ----------------------- | ------------- | --------------------------------------------------------------------------- |
| `keebai_flow_create`    | `flows:write` | Register a Flow at Meta and upload its Flow JSON. Starts as a draft.        |
| `keebai_flow_list`      | `flows:read`  | List the project's Flows with their status and `meta_flow_id`.              |
| `keebai_flow_get`       | `flows:read`  | One Flow, including its stored Flow JSON.                                   |
| `keebai_flow_update`    | `flows:write` | Update a draft Flow. Sending `flow_data` re-uploads it at Meta.             |
| `keebai_flow_publish`   | `flows:write` | Publish. Meta validates here, and a published Flow can no longer be edited. |
| 🔴 `keebai_flow_delete` | `flows:write` | Delete. Meta only allows this on drafts.                                    |

## Media

| Tool                     | Scope           | What it does                                                                          |
| ------------------------ | --------------- | ------------------------------------------------------------------------------------- |
| `keebai_media_get`       | `messages:send` | Metadata of a WhatsApp media object: mime type, size, sha256, temporary download URL. |
| 🔴 `keebai_media_delete` | `messages:send` | Delete an uploaded media. Messages already sent with it are unaffected.               |

<Note>
  Uploading and downloading the binary itself is REST-only — `POST /v1/media/upload` is multipart and `GET /v1/media/{id}/download` returns raw bytes, and neither fits a JSON tool call.
</Note>

## Ecommerce

Read-only access to the catalog, carts, and sales. See the [ecommerce overview](/dev/ecommerce/overview) for how the records relate — a cart is not a draft sale.

| Tool                             | Scope                     | What it does                                                                                                    |
| -------------------------------- | ------------------------- | --------------------------------------------------------------------------------------------------------------- |
| `keebai_ecommerce_products_list` | `ecommerce:products:read` | List the catalog with full-text search. Covers products created in Keebai and those synced from an integration. |
| `keebai_ecommerce_product_get`   | `ecommerce:products:read` | Get one product with its variants, images, and stock.                                                           |
| `keebai_ecommerce_carts_list`    | `ecommerce:carts:read`    | List carts, including abandoned ones. Filter by recovery status to find the ones worth following up on.         |
| `keebai_ecommerce_cart_get`      | `ecommerce:carts:read`    | Get one cart with its line items and the customer's contact details.                                            |
| `keebai_ecommerce_sales_list`    | `ecommerce:sales:read`    | List sales by status, payment status, contact, or date range.                                                   |
| `keebai_ecommerce_sale_get`      | `ecommerce:sales:read`    | Get one sale with its items, amount breakdown, and payment state.                                               |

<Note>
  There are no write tools here. Creating a sale or pushing a product goes through the platform integration, not the API.
</Note>

## Loyalty

Points, stamps, and wallet cards. See the [loyalty overview](/dev/loyalty/overview) for the data model — in particular that there is no reward entity and that balances are a projection, not a sum of the ledger.

| Tool                                     | Scope           | What it does                                                                                                                     |
| ---------------------------------------- | --------------- | -------------------------------------------------------------------------------------------------------------------------------- |
| `keebai_loyalty_programs_list`           | `loyalty:read`  | List programs, newest first. Only the rules variant matching the program's type is populated. Start here for the program id.     |
| `keebai_loyalty_program_get`             | `loyalty:read`  | Get one program: points per currency unit and expiry, stamps target and reward, or tier thresholds.                              |
| `keebai_loyalty_templates_list`          | `loyalty:read`  | List a program's wallet card designs. Read-only — the card is designed in the portal.                                            |
| `keebai_loyalty_template_get`            | `loyalty:read`  | Get one template with its branding, fields, and barcode.                                                                         |
| `keebai_loyalty_memberships_list`        | `loyalty:read`  | Find a membership by customer id, phone, name, program, or status. Phone matches on a digit subsequence.                         |
| `keebai_loyalty_membership_get`          | `loyalty:read`  | Get one membership with its balance, stamps, and tier.                                                                           |
| `keebai_loyalty_membership_enroll`       | `loyalty:write` | Enroll a customer. The details are copied as given and never re-resolved; a repeat enrollment conflicts rather than duplicating. |
| `keebai_loyalty_ledger_list`             | `loyalty:read`  | Movement history of a membership, newest first, each entry with the balance it produced.                                         |
| ⚠️ `keebai_loyalty_ledger_record`        | `loyalty:write` | Move a balance — earn, redeem, or adjust. Updates the card in the customer's wallet. Not idempotent.                             |
| `keebai_loyalty_pass_issue_google`       | `loyalty:write` | Issue the Google Wallet pass and return the save link. Reissuing reuses the existing pass.                                       |
| `keebai_loyalty_pass_issue_apple_link`   | `loyalty:write` | Issue the Apple Wallet pass and return a public download link.                                                                   |
| ⚠️ `keebai_loyalty_pass_notify`          | `loyalty:write` | Push a message to the customer's phone. A real notification to a real person.                                                    |
| `keebai_loyalty_pass_notifications_list` | `loyalty:read`  | What was already sent to this membership, and how many devices it reached.                                                       |

<Warning>
  Tools marked ⚠️ have effects outside Keebai. `keebai_loyalty_ledger_record` moves a balance a customer can spend and is **not idempotent** — a retried call double-counts. `keebai_loyalty_pass_notify` sends a push notification to a real phone.

  Neither is destructive, so neither carries the 🔴 marker, but hand `loyalty:write` to an agent with the same care you would give `messages:send`.
</Warning>

## Assistants

Read and write the configuration of the assistants themselves: the [blocks that make up their prompt](/dev/assistants/overview) and the webhook functions they can call. Thirty tools, all on `assistants:read` or `assistants:write`.

| Tool                                            | Scope              | What it does                                                                                |
| ----------------------------------------------- | ------------------ | ------------------------------------------------------------------------------------------- |
| `keebai_assistants_list`                        | `assistants:read`  | List the active assistants of the project. Start here for the id everything else needs.     |
| `keebai_assistant_get`                          | `assistants:read`  | One assistant with its model, knowledge nodes, and ordered block references.                |
| `keebai_assistant_create`                       | `assistants:write` | Create one. It is born with an empty personality and response-policy block attached.        |
| `keebai_assistant_update`                       | `assistants:write` | Partial update of name, description, avatar, model, active flag, knowledge nodes.           |
| 🔴 `keebai_assistant_delete`                    | `assistants:write` | Delete permanently. Its blocks survive in the catalogue.                                    |
| `keebai_assistant_blocks_list`                  | `assistants:read`  | The blocks wired into one assistant, in prompt order, metadata only.                        |
| `keebai_assistant_blocks_set`                   | `assistants:write` | Replace the whole block list. The only way to reorder or pin. Blocks left out get detached. |
| `keebai_assistant_block_attach`                 | `assistants:write` | Attach one block. Fails on a cross-company block or a duplicate identity block.             |
| `keebai_assistant_block_detach`                 | `assistants:write` | Detach one block. The block itself is untouched.                                            |
| `keebai_assistant_blocks_catalog`               | `assistants:read`  | Every block in the project, attached or not, filtered by type or family.                    |
| `keebai_assistant_block_get`                    | `assistants:read`  | One block's metadata, including whether its content is writable.                            |
| `keebai_assistant_block_create_personification` | `assistants:write` | Create a personality block: role, tone, how it addresses people.                            |
| `keebai_assistant_block_create_objective`       | `assistants:write` | Create an objective block: what to achieve and how you know it did.                         |
| `keebai_assistant_block_create_response_format` | `assistants:write` | Create a format block: length, emoji usage, formatting rules.                               |
| `keebai_assistant_block_create_steps`           | `assistants:write` | Create a steps block: the procedure, in order.                                              |
| `keebai_assistant_block_create_cases_possible`  | `assistants:write` | Create a cases block: situations and how to answer each.                                    |
| `keebai_assistant_block_create_do_not`          | `assistants:write` | Create a restrictions block: what it must never do.                                         |
| `keebai_assistant_block_create_response_policy` | `assistants:write` | Create a policy block: when to stay silent, when to react.                                  |
| `keebai_assistant_block_update`                 | `assistants:write` | Rename a block or flip its archived flag.                                                   |
| `keebai_assistant_block_archive`                | `assistants:write` | Archive a block. Reversible; assistants still attached keep using it.                       |
| `keebai_assistant_block_content_get`            | `assistants:read`  | Read a block's current content. Free blocks come back as text.                              |
| `keebai_assistant_block_content_save`           | `assistants:write` | Replace the content, creating a new version. The five catalogue types refuse.               |
| `keebai_assistant_block_versions_list`          | `assistants:read`  | Version history, newest first, without the payloads.                                        |
| `keebai_assistant_block_version_get`            | `assistants:read`  | Read one historical version, to check it before restoring.                                  |
| `keebai_assistant_block_version_restore`        | `assistants:write` | Restore an old version by appending it as a new one. Nothing is lost.                       |
| `keebai_assistant_functions_list`               | `assistants:read`  | The company's webhook functions. Secret values come back masked.                            |
| `keebai_assistant_function_get`                 | `assistants:read`  | One function with its URL, parameters, and the blocks referencing it.                       |
| ⚠️ `keebai_assistant_function_create`           | `assistants:write` | Create a webhook the assistant can call. The URL must be a public https host.               |
| ⚠️ `keebai_assistant_function_update`           | `assistants:write` | Partial update. Omitting headers keeps the stored ones; never echo back a `***`.            |
| 🔴 `keebai_assistant_function_delete`           | `assistants:write` | Delete permanently. Fails while a block still references it.                                |

<Warning>
  **Writing here changes what your bots say to customers.** An agent with `assistants:write` can rewrite any prompt block and create webhook functions that make Keebai's infrastructure call an external host — the URL is validated against loopback, private ranges and internal names, but a public host of the agent's choosing is allowed. Treat it as a higher-privilege scope than the read side, and read [webhook security](/dev/assistants/webhook-security) before handing it out.

  **Functions are company-wide**, unlike assistants and blocks, which are scoped to the token's project.
</Warning>

## Not exposed as tools

Scheduling, templates, channels, webhooks, tenants, and setup links have no MCP tools yet. Use the [REST API](/dev/overview) for those.

The binary Apple `.pkpass` has no tool either, for the same reason as media download: it is a file, not JSON. The Apple link tool covers the same use case.
