N8N Tools - Botpress API
Actions26
- Bot Actions
- Conversation Actions
- Message Actions
- User Actions
- Event Actions
- State Actions
Overview
This node integrates with the Botpress conversational AI platform, specifically enabling management of conversations within a bot. The Create Conversation operation allows users to start a new conversation session for a specified user in the Botpress system.
Typical use cases include:
- Initiating a new chat session programmatically when a user starts interacting with a bot.
- Creating conversations linked to specific users and integration channels (e.g., Telegram, Slack).
- Tagging conversations or attaching metadata for better tracking and analytics.
For example, you might use this node to create a conversation when a customer visits your website and begins a chat, associating it with their user ID and tagging it as "support" or "sales".
Properties
| Name | Meaning |
|---|---|
| User ID | The unique identifier of the user for whom the conversation is being created. |
| Additional Fields | A collection of optional fields to customize the conversation: |
| - Tags | Comma-separated list of tags to categorize or label the conversation. |
| - Integration Channel | Name of the integration channel (e.g., telegram, slack) through which the conversation occurs. |
| - User Name | Display name for the user associated with the conversation. |
| - User Picture URL | URL of the user's profile picture. |
| - Metadata | Additional metadata as a JSON object to attach custom data to the conversation. |
| - State Variables | JSON object representing state variables related to the conversation. |
| - Event Type | Type of event to create (not typically used in conversation creation). |
| - Event Payload | JSON payload for an event (not typically used in conversation creation). |
| - Quick Replies | Comma-separated list of quick reply options (not typically used in conversation creation). |
| - Actions | JSON array defining card/message actions (not typically used in conversation creation). |
| - Limit | Maximum number of results to return (not applicable for creation). |
| - Page Token | Token for pagination (not applicable for creation). |
Output
The node outputs a JSON object representing the response from the Botpress API after creating the conversation. This typically includes details such as:
- Conversation ID
- Associated user information
- Tags applied
- Integration channel info
- Metadata and state variables if provided
No binary data output is generated by this operation.
Dependencies
- Requires an API key credential for authenticating with the Botpress API.
- Needs configuration of the Botpress API base URL, access token, bot ID, and optionally an integration ID.
- The node sends requests via a proxy service hosted at
https://n8ntools.io/api/v1/proxy/botpressusing an additional API key for that proxy.
Troubleshooting
Common issues:
- Missing or invalid user ID will cause the API call to fail.
- Incorrect or missing API credentials will result in authentication errors.
- Providing malformed JSON in metadata or other JSON fields will cause parsing errors.
- Using unsupported tags or integration names may lead to unexpected behavior.
Error messages:
"Unknown conversation operation: createConversation"indicates a misconfiguration of the operation parameter.- Authentication errors usually mention invalid tokens or unauthorized access; verify API keys and tokens.
- JSON parse errors suggest invalid JSON input in fields like metadata or actions; ensure valid JSON syntax.
To resolve errors, double-check all required parameters, validate JSON inputs, and confirm API credentials are correctly set up.