First-party app
Chatbase Chatbase

Chatbase

Create and manage Chatbase AI agents, chat with them, and run their helpdesk, sources, and WhatsApp surfaces.

stable AI & Machine LearningCustomer SupportCommunication

About

Chatbase ships in the w6w first-party pack. It declares 35 actions, 2 health checks, and the host runs its code in a sandbox that never sees the credential.

App id
io.w6w.chatbase
Version
0.1.1
Author
w6w
Licence
MIT
Categories
AI & Machine Learning · Customer Support · Communication

Overview

Chatbase builds AI agents trained on your own content — a website, uploaded files, Q&A pairs — and puts them in front of customers over a chat widget, WhatsApp, Slack, and a growing set of other channels. This app covers Chatbase’s API v2, its current, structured REST surface: create and configure agents, train them, chat with one directly (as a bot-to-bot or backend integration, not just the widget), and manage the conversations, knowledge sources, helpdesk tickets, and WhatsApp templates those agents produce.

Every agent-management, chat, conversation, source, helpdesk, and WhatsApp action here talks to API v2 (www.chatbase.co/api/v2), which Chatbase itself points integrators toward from its own legacy v1 docs. The one exception is reading captured leads, which as of this writing has no v2 equivalent at all and is served from the older v1 surface (www.chatbase.co/api/v1) — both hosts resolve to the same hostname, so a single Connection and network allowlist cover both.

File-type knowledge sources (PDF/DOC/DOCX uploads) are deliberately left out: Chatbase serves that upload from a different host (files.chatbase.co) as a binary multipart body, and this sandbox’s fetch coerces every request body to a string on its way to the network — the same limitation that caps this pack’s Box and Dropbox uploads to text content. Plain-text, Q&A, and link sources (the create-source / update-source actions here) are unaffected and cover the rest of Chatbase’s knowledge-source surface.

Build with Chatbase

Three routes to the same 35 actions. The Workflow tab is generated from Chatbase's own manifest and carries its real ids, so it is copy-pasteable; the Code and CLI examples are the same call for any action on any app, so every app-specific value in them is a blank you fill in.

Toggle Auto-Retrain

agent-auto-retrain-toggle

Enable or disable automatic retraining every 7 days for an agent.

Chat With Agent

agent-chat

Send a message to an agent and get its response. Non-streaming.

Clone Agent

agent-clone

Create a full deep-clone of an agent, including its sources (except Notion).

Create Agent

agent-create

Create a new agent. Provide a URL to pre-train it from that website automatically.

Delete Agent

agent-delete

Permanently delete an agent and all its sources. Irreversible.

Get Agent

agent-get

Fetch one agent's full configuration.

List Agents

agent-list

List every agent in this workspace.

Train Agent

agent-train

Queue a training job for the agent. Asynchronous — poll Get Agent for `status`.

Update Agent

agent-update

Partially update an agent's name and/or instructions. Only provided fields change.

Get Conversation

conversation-get

Get conversation metadata and its most recent messages. Only finds conversations created through the API — use the messages endpoint's cursor to page further back.

List Conversations

conversation-list

List conversations for an agent, ordered by createdAt.

List Conversation Messages

conversation-messages-list

List a conversation's messages, paginating backward from the newest. Each page is chronological oldest to newest.

List Conversations For A User

conversation-user-list

List conversations for a specific user under an agent, ordered by last activity.

List Leads

lead-list

List leads captured by an agent's lead form. Uses the legacy v1 API — v2 has no leads endpoint as of this writing.

Update Message Feedback

message-feedback-update

Set or clear feedback on an assistant message.

Retry Message

message-retry

Retry generating an assistant response from a given message, truncating the conversation at that point.

Create Source

source-create

Create a text, Q&A, or link knowledge source for an agent. File uploads use a separate endpoint this app does not cover — see the README.

Delete Source

source-delete

Mark a source for deletion. Restore it before this point with Restore Source.

Get Source

source-get

Fetch one knowledge source by ID.

List Sources

source-list

List an agent's knowledge sources. Ticket sources are excluded.

Restore Source

source-restore

Restore a source pending deletion back to its previous active state.

Get Sources Summary

source-summary-get

Aggregated counts and sizes per source type, and whether a retrain is pending.

Update Source

source-update

Update a text, Q&A, or link source. Only send fields relevant to that source's own type — a link's URL is immutable; delete and recreate to change it.

List Teams

team-list

List the helpdesk teams configured for an agent.

Create Ticket

ticket-create

Create a helpdesk ticket on behalf of a customer.

Get Ticket

ticket-get

Fetch a single ticket by its per-agent ticket number.

List Tickets

ticket-list

List helpdesk tickets for an agent, with filters and cursor pagination. Filters combine with AND.

Add Ticket Message

ticket-message-add

Post a customer-visible reply on a ticket. Markdown in, sanitized HTML out. A 201 confirms the reply was recorded, not delivered.

List Ticket Messages

ticket-messages-list

List a ticket's message thread. Defaults to chronological order, oldest first.

Search Tickets

ticket-search

Free-text search over ticket messages, ranked by relevance. Not paginated.

List Ticket Statuses

ticket-status-list

List the active (non-archived) ticket statuses for an agent, ordered by category then position. Answers a bare array — no pagination.

Update Ticket

ticket-update

Partially update a ticket's status, assignee, or team.

Submit Tool Result

tool-result-submit

Submit the result of a client-side action the agent invoked. Continue the conversation afterward with Chat With Agent (message omitted).

List WhatsApp Templates

whatsapp-template-list

List approved WhatsApp templates across the agent's connected WhatsApp Business Accounts.

Send WhatsApp Template Message

whatsapp-template-send

Send an approved WhatsApp template to a phone number from one of the agent's connected numbers.

A workflow step names the app and the action, and the editor fills in the connection when you pick one. This is the Step shape from the workflow spec, carrying Chatbase's real ids.

{
  "manifestVersion": "2",
  "name": "chatbase-example",
  "steps": [
    {
      "id": "agent-auto-retrain-toggle",
      "uses": {
        "app": "io.w6w.chatbase",
        "action": "agent-auto-retrain-toggle",
        "connection": "conn_YOUR_CONNECTION_ID"
      },
      "with": {
        "agentId": "<agentId>",
        "enabled": "<enabled>"
      }
    }
  ]
}

Here are some of the things you can do

  • Toggle Auto-Retrain

    perform
    agent-auto-retrain-toggle
  • Chat With Agent

    perform
    agent-chat
  • Clone Agent

    perform
    agent-clone
  • Create Agent

    perform
    agent-create
  • Get Agent

    read
    agent-get

+30 more actions available

Every app-specific value here is a blank you have to fill in. An app action is reached through the connection that authenticates it, so the address is a connection id, not the app id — and connections belong to your account, so a public page cannot know yours. Create one for Chatbase, then fill in the three blanks: conn_YOUR_CONNECTION_ID, the action key, and the parameters that action declares. The call itself is real — the shape is transcribed from the studio's own snippet builder, which prints the same kind of blanks — but nothing in it is specific to Chatbase. The Workflow tab is where this app's real ids are.

Install
npm install @w6w/sdk
yarn add @w6w/sdk
pnpm add @w6w/sdk
deno add npm:@w6w/sdk
Code
import { W6wClient, isActionRun } from "@w6w/sdk";

// Reads W6W_BASE_URL and W6W_TOKEN from the environment when omitted.
const client = new W6wClient();

const envelope = await client.run({
  urn: "conn_YOUR_CONNECTION_ID",
  action: "agent-auto-retrain-toggle",
  payload: {
    agentId: "<value>",
    enabled: "<value>",
  },
});

if (isActionRun(envelope)) console.log(envelope.value);
Install the CLI
npm install -g @w6w/cli
CLI
w6w run conn_YOUR_CONNECTION_ID --action agent-auto-retrain-toggle --payload '{"agentId":"<value>","enabled":"<value>"}'

Give an AI agent Chatbase — without giving it Chatbase's credentials. One MCP endpoint exposes every app, function and workflow the caller is entitled to, as tools it can discover and run. Access is granted per team while we onboard.

One tool call
{
  "name": "w6w_invoke",
  "arguments": {
    "ref": "app:io.w6w.chatbase#agent-auto-retrain-toggle",
    "input": {
      "agentId": "<agentId>",
      "enabled": "<enabled>"
    }
  }
}

Every tool names its target with a single ref. The app: form above doesn't name a connection at all — the host resolves which of the caller's Chatbase connections to sign with, and refuses rather than guesses when the answer is ambiguous.

What the agent gets

Credentials it can't read

The token is attached host-side, at the moment of the call. It is never a tool argument, never in the model's context, and never in a transcript — so a prompt injection has nothing to exfiltrate.

A tool surface scoped to the caller

Tools are derived per end user from what that person has actually connected and is entitled to — not one shared bot identity carrying the union of everyone's access.

A durable workflow in one call

Multi-step work runs on the workflow engine and returns a run handle the agent can poll — retries, branching and state survive the conversation that started them.

Health-aware discovery

Chatbase's declared health checks are on the surface too, so an agent can tell "the vendor is down" from "your credential expired" before it burns a retry on either.

The MCP surface is part of the hosted platform. Chatbase itself is MIT, and the runtime that executes it is source-available (FSL).

Request MCP access

Health checks

Chatbase declares its own checks, so its health is a property of the app rather than something the host guesses at.

service

Chatbase API health

Chatbase publishes no usable status page (its Statuspage instance is an unclaimed decoy and status.chatbase.co is a dead, expired-certificate host) — this reads the API's own unauthenticated GET /health instead, the best signal Chatbase publishes for whether the platform is up.

quota

Request-rate headroom

Reads X-RateLimit-Limit / X-RateLimit-Remaining / X-RateLimit-Reset from GET /agents?limit=1 — present on every v2 response. Chatbase's other quota, message credits, has no readable balance endpoint and only surfaces as an error at chat time.