N8N Tools - Typebot API icon

N8N Tools - Typebot API

Complete Typebot.io integration - Self-hosted chatbot builder with visual flows

Overview

This node integrates with the Typebot.io API, a self-hosted chatbot builder platform that allows creating and managing chatbots with visual flows. Specifically, the "Update Typebot in Session" operation under the "Chat" resource updates the configuration of an active chatbot session by sending new or modified Typebot JSON configuration to the ongoing chat session identified by a session ID.

This operation is useful when you want to dynamically change the chatbot's behavior or flow during an active conversation without starting a new session. For example, you might update the chatbot to reflect new questions, change variables, or modify the UI theme on the fly based on user input or external triggers.

Practical scenarios include:

  • Adjusting chatbot logic mid-conversation to handle special cases.
  • Injecting updated chatbot configurations after an external event.
  • Customizing the chatbot experience dynamically for different users within the same session.

Properties

Name Meaning
Session ID The unique identifier of the existing chat session to update.
Additional Fields A collection of optional fields to customize the update:
- Stream Enabled Enable streaming mode for real-time response updates (boolean).
- Prefilled Variables Variables to prefill in the typebot, specified as name-value pairs.
- Result ID Existing result ID to continue the conversation context.
- Theme Custom theme configuration provided as JSON to style the chatbot interface.
- Settings Custom settings for the chatbot session as JSON.
- Icon Emoji or URL string to set the chatbot icon.
- Typebot JSON The main JSON configuration object representing the updated chatbot flow/settings to apply.
- Export Format Format options for exporting results (CSV, JSON, Excel) — not relevant for this operation.
- Filename Custom filename for file uploads — not relevant here.
- File Size Limit MB File size limit in megabytes for uploads — not relevant here.

For this operation, the key property is Typebot JSON, which contains the updated chatbot configuration to be applied to the active session.

Output

The node outputs a JSON object containing the response from the Typebot API after attempting to update the chatbot session. This typically includes confirmation of the update or details about the updated session state.

The output structure is:

{
  "json": {
    // Response data from the Typebot API reflecting the updated session
  }
}

No binary data is produced by this operation.

Dependencies

  • Requires an API key credential for authenticating with the Typebot API.
  • Needs the base API URL and an authentication token configured in the node credentials.
  • The workspace ID is used internally to scope some operations but is not directly exposed for this operation.
  • The node makes HTTP POST requests to the Typebot API endpoint /api/v1/sessions/{sessionId}/updateTypebot.

Troubleshooting

  • Invalid Session ID: If the session ID does not exist or has expired, the API will return an error. Verify the session ID is correct and active.
  • Malformed Typebot JSON: Providing invalid JSON in the "Typebot JSON" field can cause parsing errors. Ensure the JSON is well-formed and matches the expected schema.
  • Authentication Errors: Missing or incorrect API keys or tokens will result in authorization failures. Confirm credentials are correctly set up.
  • API Endpoint Errors: Network issues or incorrect API URLs can cause request failures. Check connectivity and API URL correctness.
  • Continue On Fail: If enabled, the node will output error messages in the JSON output instead of stopping execution, allowing workflows to handle errors gracefully.

Links and References

Discussion