Skip to main content
The API Channel is ChatbotX’s custom universal messaging integration gateway, allowing you to connect any external messaging platform, custom mobile application, or backend CRM system into your ChatbotX Workspace. With bidirectional, real-time communication, incoming messages from your connected platforms are instantly routed into ChatbotX to be handled automatically by AI Agents or live human agents. In turn, all outgoing replies from ChatbotX are forwarded back to your external system via Webhooks.

Key Capabilities and How It Works

The API Channel provides flexible, enterprise-grade capabilities for your Workspace:
  • Comprehensive Multimedia Support: Send and receive text messages, images, audio clips / voice notes, video files, and documents (PDF, DOCX, XLSX, etc.).
  • Unified Inbox: Messages from your custom channels appear directly in the centralized ChatbotX Inbox alongside Messenger, Zalo, WhatsApp, and Webchat.
  • AI & Flow Automation: Trigger Flow Automation sequences, smart AI Agent replies, or live chat routing rules immediately upon message arrival.

Bidirectional Data Flow

  1. Inbound (Receiving messages into ChatbotX): Your application or server makes an HTTP POST request containing the customer’s message to ChatbotX’s Inbound API Endpoint using your Channel API Token for authentication.
  2. Outbound (Sending replies from ChatbotX): When an AI Agent or live agent replies within ChatbotX Inbox, ChatbotX sends an HTTP POST payload containing the message response to your configured Callback URL.

How to Create an API Channel on ChatbotX

Follow these steps to create a new API Channel in your Workspace:

Step 1: Navigate to API Channel Settings

  1. Log in to your ChatbotX Workspace dashboard.
  2. In the left navigation menu, click Settings.
  3. Select the Channels tab in the top navigation bar.
  4. Scroll down to the channel list and select API.
  5. Click the Add API button in the upper-right corner.
Add Api Channel Settings Overview

Step 2: Configure Channel Details

In the Add API modal window, fill in the following fields:
  • Name: Enter a descriptive name for your channel (e.g., WhatsApp Support, Telegram Hotline, or Internal Mobile App).
  • Callback URL (Optional): Enter your server’s webhook endpoint URL to receive outgoing replies from ChatbotX. If your channel only receives messages and does not require ChatbotX to send replies back, you can leave this field blank.
Add Api Channel Modal Setup Form

Step 3: Create the Channel and Copy Your API Token

  1. Click the green Create button.
  2. ChatbotX will generate your unique Channel API Token (prefixed with cbx_api_...).
  3. Copy and store this token securely. You will use it in the Authorization: Bearer <TOKEN> header when sending inbound messages to ChatbotX.
Api Channel Created Token Copy
Note: You can create multiple API Channels within the same Workspace to independently manage different phone numbers, branches, or communication platforms.

Integrating Personal WhatsApp via WAHA ChatbotX Gateway

One of the most popular and powerful use cases for the API Channel is connecting personal or business WhatsApp Web numbers into ChatbotX using the WAHA ChatbotX Gateway (craybull/waha-chatbotx-dashboard). The modern Dashboard interface provides a streamlined 3-step setup workflow with real-time automatic state synchronization:
Waha Chatbotx Dashboard Multi Account View

Step 1: Deploy WAHA ChatbotX Gateway

You can run WAHA on your local machine, a Linux VPS, or any Docker environment. The fastest way is using Docker Compose with the dedicated ChatbotX configuration:
Once running, access the dashboard at http://localhost:3000/dashboard (or your public domain, e.g., https://waha.yourdomain.com/dashboard).

Step 2: Connect Your WhatsApp Account (Dashboard Step 1)

In the Step 1: Connect WhatsApp Account card on the left, choose your preferred pairing method:
  1. Select the QR Code tab.
  2. Open WhatsApp on your phone: go to Settings > Linked Devices.
  3. Tap Link a Device and point your phone’s camera at the QR code displayed on your screen.
Waha Dashboard Step 3 Qr Code Scan
💡 Real-time Instant Transition: As soon as your phone scans the code, the dashboard automatically hides the QR box and displays the green Connected Online badge with your WhatsApp display name and phone number in real time without refreshing the page.
  1. Select the Phone Pairing Code tab.
  2. Enter your WhatsApp phone number in international format (without leading zeros, e.g., 14155552671 or 84384524243).
  3. Click Get Code.
  4. An 8-digit pairing code will appear. Open WhatsApp on your phone > Linked Devices > Link with phone number > enter the 8-digit code to authenticate.
Waha Dashboard Step 3 Phone Pairing Code
Once connected, Step 1 displays the active session card with Restart Session and Disconnect action buttons.
Waha Dashboard Device Connected Success

Step 3: Create Channel on ChatbotX (Dashboard Step 2)

In the Step 2: Create Channel on ChatbotX card on the upper-right:
  1. Click Open ChatbotX to quickly launch the channel management page in a new tab.
  2. Copy the auto-detected configuration:
    • Channel Name: Suggested name automatically synchronized with your WhatsApp profile name (e.g., Quoc Kiem (+84384524243)).
    • Callback URL: The dedicated Webhook route for this specific WhatsApp number (e.g., https://waha.yourdomain.com/webhooks/chatbotx).
  3. In ChatbotX, click Add API, paste the Channel Name and Callback URL, then click Create.
  4. Copy the generated Channel API Token.
Waha Dashboard Step 1 Callback Url Copy
In the Step 3: Link ChatbotX Channel card on the lower-right:
  1. Paste your Channel API Token into the ChatbotX API Token input field.
  2. Verify the ChatbotX API URL (default: https://app.chatbotx.io/api) and your Media & Webhook Base URL.
  3. Optionally check Forward WhatsApp group messages to ChatbotX if you want your AI bot to process group chat messages.
  4. Click Save & Activate Channel.
Waha Dashboard Step 2 Activate Token
Upon successful connection, the status pill changes to Linked & Active and the button updates to Channel Linked (Click to Update).
💡 Auto Disconnect Synchronization: If you ever click Disconnect in Step 1, the dashboard automatically syncs with Step 3, resetting the stored token and preparing the interface for a clean re-link.

Step 5: Test Inbound and Outbound Messaging

Once connected, verify end-to-end message flow immediately:
  1. Test Outbound Message:
    • The Test Outbound Message card appears directly below Step 1 as soon as the account is Online.
    • Enter a recipient phone number with country code (e.g., 14155552671) and your test message.
    • Click Send Test Message to verify immediate delivery from your connected WhatsApp account.
  2. Test Inbound Message:
    • Send a message from a different phone number to your connected WhatsApp number.
    • Open Inbox in ChatbotX to see the conversation appear instantly and watch your AI Agent reply automatically.
Waha Dashboard Test Outbound Message

Multi-Account WhatsApp Management

The Gateway allows you to connect and manage an unlimited number of concurrent WhatsApp accounts on a single deployment:
  1. In the WAHA Dashboard top bar, click the + Add Account button.
  2. Enter an identifier for the new session (e.g., account_2, sales_la, support_nyc).
  3. The dashboard initializes an independent session with its own unique Callback URL.
  4. Create a matching API Channel in ChatbotX and activate the token.
  5. Easily switch between accounts using the top session bar to view QR codes, monitor online status, or manage each number independently.

API Channel Technical Specification (For Developers)

If you are building custom bridges for other platforms (such as Viber, custom Telegram bots, SMS gateways, or internal mobile apps), you can send data directly to the ChatbotX REST API using the specifications below.

Inbound Text Message

Endpoint: POST https://app.chatbotx.io/api/v1/inbound
Headers:
  • Content-Type: application/json
  • Authorization: Bearer <YOUR_CHANNEL_API_TOKEN>
JSON Payload:

Inbound Media Message

The API Channel supports public direct URLs for media attachments: JSON Payload:

Outbound Webhook Response Format

When an AI Agent or human agent replies in ChatbotX Inbox, ChatbotX sends an HTTP POST request to your configured Callback URL:

Frequently Asked Questions (FAQ)

ChatbotX does not impose artificial rate limits on API Channels. Processing throughput depends on your Workspace plan tier and the capacity of your self-hosted webhook infrastructure.
Yes. You can create multiple API Channels in ChatbotX (e.g., WhatsApp Hotline, WhatsApp Sales US, WhatsApp Support EU). In the WAHA Dashboard, click Add Account to launch isolated sessions (account_2, account_3…) and link each to its corresponding ChatbotX Channel token.
  • Use official WhatsApp Cloud API: When you need broadcast marketing campaigns, Meta-approved pre-templated messages, or the official green verified business badge.
  • Use API Channel via WAHA: When you want to use your existing personal or business phone numbers for 1:1 customer engagement, avoid Meta per-conversation charges, and empower multiple support agents on a single phone line.