AI Agent v2 with MCP (Model Context Protocol) support allows your bots to connect to external systems such as CRMs, ERPs, and APIs, turning them into truly autonomous agents.

What Is AI Agent with MCP?

The AI Agent block has evolved from a simple LLM wrapper into an agentic platform. It can now:
  • 🔌 Connect to external MCP servers such as your CRM, ERP, or any API
  • 🏠 Access internal Sendbot data such as credits, bots, and users
  • 🛠️ Execute actions on behalf of the user, such as searching leads or scheduling visits
  • 💬 Maintain context with conversation memory

Configuring AI Agent

1. Drag the AI Agent Block

In the editor, drag the AI Agent block into your flow.

2. Configure the Model and Credentials

Choose your AI provider (OpenAI, Anthropic, Google, and so on) and configure the credentials.

3. Enable MCP Servers

In the “MCP Servers (External Tools)” section, you can:

Sendbot Internals

Enable “Enable Sendbot Internals” to give the agent access to:
ToolDescription
sendbot_get_userCurrent user information
sendbot_get_creditsWorkspace credit balance
sendbot_list_botsList of bots in the workspace
sendbot_get_bot_statsStatistics for a bot
sendbot_set_variableSets variables in the session

External MCP Servers

Add external MCP servers by clicking ”+ Add MCP Server”:
Server Name
string
required
A friendly name for the server, for example My CRM
MCP Server URL
string
required
The URL of your server’s MCP endpoint, for example https://api.mycrm.com/mcp
Authentication
enum
Authentication type:
  • none - No authentication
  • api-key - API key
  • bearer - Bearer token
Allowed Tools
array
List of allowed tools. Leave empty to allow all tools.
Require User Confirmation
boolean
default:"true"
If enabled, write actions stay blocked until the user explicitly confirms them in your flow or application.

Example: Real Estate CRM

Suppose your CRM exposes an MCP server with these tools:
  • searchProperty(filters) - Searches properties
  • scheduleVisit(propertyId, date) - Schedules a visit
  • checkAvailability(propertyId) - Checks availability

Setup in Sendbot

  1. Add the MCP server: https://mycrm.com/mcp
  2. Configure authentication with your API key
  3. Enable Require User Confirmation for write actions

Example Conversation

User: “I want a 3-bedroom apartment in Copacabana” Agent: (calls searchProperty({ bedrooms: 3, neighborhood: 'Copacabana' }))
I found 5 options. Here they are:
  1. Rua Barata Ribeiro, 123 - BRL 850,000
  2. Av. Atlantica, 456 - BRL 1,200,000 …
User: “Schedule a visit for the first one tomorrow at 2 PM” Agent: (calls scheduleVisit('property-1', '2026-01-24T14:00'))
✅ Visit scheduled successfully for tomorrow at 2 PM.

Building Your Own MCP Server

To create a compatible MCP server, your endpoint should implement:

POST /tools/list

Returns the list of available tools:
{
  "tools": [
    {
      "name": "searchProperty",
      "description": "Searches properties based on filters",
      "inputSchema": {
        "type": "object",
        "properties": {
          "bedrooms": { "type": "number", "description": "Number of bedrooms" },
          "neighborhood": { "type": "string", "description": "Neighborhood name" }
        }
      }
    }
  ]
}

POST /tools/call

Executes a tool: Request:
{
  "name": "searchProperty",
  "arguments": { "bedrooms": 3, "neighborhood": "Copacabana" }
}
Response:
{
  "content": [
    { "type": "text", "text": "I found 5 properties..." }
  ]
}

Auditing and Security

All tool executions are logged in the database in the AgentToolExecution table for audit purposes.
Always enable “Require User Confirmation” for actions that modify data, such as create, update, or delete.