API & MCP
MCP for Agents
Connect your own Agent to Hast AIP with the same Public API Key.
This page is specifically for Agent clients and the people configuring them. Public API and MCP expose the same AIP business capabilities, with one key, one Profile and the same permissions. Create or reuse a key in AIP → API keys; do not create a second MCP key. Select the required read/write scopes, including business-resources:read/write for CRM and customer communication knowledge. Existing keys do not automatically gain new scopes.
Connection
Use the Backplane URL for your environment, available in the API documentation linked from API Keys. Replace BACKPLANE_URL below. The transport is Streamable HTTP; authenticate every request with Authorization: Bearer hast_pk_.... Your client must support custom headers. This is a common configuration shape; adapt it to the client. Store the real key securely, outside prompts and source control. Hast does not use MCP OAuth discovery for this endpoint.
{
"mcpServers": {
"hast": {
"url": "BACKPLANE_URL/api/public/v1/mcp",
"headers": { "Authorization": "Bearer <YOUR_EXISTING_PUBLIC_API_KEY>" }
}
}
}
Copy this prompt to your Agent
Help me connect to Hast AIP through MCP so you can create and manage Agents,
channels, knowledge bases, CRM and Connectors based on my needs.
MCP URL: BACKPLANE_URL/api/public/v1/mcp
Transport: Streamable HTTP
Authentication: Use my existing Public API Key in the Authorization: Bearer header.
Read it from HAST_API_KEY or a secure credential store; do not display the key.
After connecting, read hast://guides/overview to learn about the platform, then
consult relevant guides and use tools as needed for my requests.
If you need more information, client configuration or external service authorization
from me, explain the steps I need to take.
Discover capabilities
Read these resources after connecting. They contain prerequisites, request examples, creation order, permission requirements and verification steps. Clients without resource support can use get_guides_topic with path.topic. REST clients read the same content at GET /api/public/v1/guides/{topic}.
hast://guides/overviewhast://guides/enterprise-agenthast://guides/channelshast://guides/whatsapphast://guides/knowledge-crmhast://guides/connectors
Build and verify an enterprise Agent
- Discover the live model catalog, policy options, existing Agents, Skills, knowledge and connected accounts.
- Create the required Skills, write-only Secrets, indexed knowledge, optional CRM and communication knowledge.
- Save an AIP Agent through
POST /webhooks, selecting only owned resource IDs and needed capabilities. - Complete provider authorization and installation, bind the channel and read back its final reply policy.
- Run
/webhooks/{hook_id}/invoke, follow paged session events to a terminal result, and test the actual knowledge, CRM, Connector and original-channel reply. - Configure schedules only when requested. Verify timezone, next run and run history. Report incomplete consent or delivery explicitly.
API parity and limits
Tools map to the same public routes and scope checks. JSON inputs separate path, query and body; results contain status and body. HTTP errors set MCP isError. Multipart upload uses upload.filename, upload.data_base64 and optional form; decoded files are limited to 10 MiB. MCP reads events as finite cursor pages, while REST also supports SSE. MCP replies are bounded to 16 MiB; larger archives remain downloadable with the Public API. A 202 response means accepted, not completed. Provider consent, external messaging delivery and account billing requirements still apply. Revoke the same key to stop both API and MCP access.
MCP transport specification · Tools · Resources · Official Go SDK