Actions26
- Bot Actions
- Conversation Actions
- Message Actions
- User Actions
- Event Actions
- State Actions
Conversation → List Messages
AI-generatedOverview
This node integrates with the Botpress conversational AI platform, specifically enabling interaction with conversations and their messages. The List Messages operation under the Conversation resource retrieves messages from a specified conversation. This is useful for scenarios where you want to fetch chat history or analyze conversation content programmatically.
Practical examples include:
- Extracting all messages from a customer support chat session for analysis.
- Displaying conversation history in a custom dashboard.
- Archiving messages for compliance or auditing purposes.
Properties
| Name | Meaning |
|---|---|
| Conversation ID | The unique identifier of the conversation whose messages you want to list (required). |
| Additional Fields | Optional parameters to customize the request: |
| - Tags | Comma-separated list of tags to filter or associate with the request (optional). |
| - Integration Channel | Name of the integration channel (e.g., telegram, slack) (optional). |
| - User Name | Display name for the user (optional). |
| - User Picture URL | Profile picture URL for the user (optional). |
| - Metadata | Additional metadata as a JSON object (optional). |
| - State Variables | State variables as a JSON object (optional). |
| - Event Type | Type of event to create (not used in this operation but part of additional fields). |
| - Event Payload | Event payload as JSON (not used here). |
| - Quick Replies | Comma-separated list of quick reply options (not used here). |
| - Actions | Card/message actions as a JSON array (not used here). |
| - Limit | Maximum number of messages to return (optional, default 100). |
| - Page Token | Token for pagination to retrieve the next set of results (optional). |
Output
The output is an array of message objects retrieved from the specified conversation. Each item in the output contains a json field representing the API response with the messages data. The structure typically includes message details such as message IDs, timestamps, sender information, message content, and any associated metadata.
No binary data output is involved in this operation.
Dependencies
- Requires an API key credential and access token for authenticating with the Botpress API.
- Needs the base URL of the Botpress API instance.
- Requires the bot ID to specify which bot's conversations are being accessed.
- Optionally uses an integration ID if interacting through a specific integration channel.
These credentials and configuration must be set up in n8n prior to using this node.
Troubleshooting
- Invalid Conversation ID: If the conversation ID does not exist or is incorrect, the API will likely return an error indicating the conversation was not found. Verify the conversation ID is correct.
- Authentication Errors: Missing or invalid API keys or tokens will cause authorization failures. Ensure credentials are correctly configured.
- Pagination Issues: When retrieving large numbers of messages, use the
LimitandPage Tokenproperties properly to paginate through results. - Malformed JSON in Additional Fields: If JSON fields like
metadataorstateVariablesare incorrectly formatted, the request may fail. Validate JSON syntax before input. - API Endpoint Changes: If the Botpress API version changes, endpoints or required headers might differ, causing errors. Keep the node updated accordingly.