Start Question Flow

Instantiate a defined question flow

Overview

This node, named "Start Question Flow," is designed to manage Slack conversation flows integrated with a Supabase backend. It supports two main functions:

  • Start Conversation: Initiates a predefined question flow in Slack by selecting a conversation ID from a list fetched from Supabase. This is useful for triggering structured interactions or surveys within Slack channels.
  • Respond to Conversation: Processes incoming payloads (likely from Slack webhooks) to handle responses within an ongoing conversation flow.

Typical use cases include automating question-and-answer sessions, surveys, or interactive workflows inside Slack, backed by data stored and managed in Supabase.

Properties

Name Meaning
Select Node Function Choose the node's action:
- Start Conversation: Begin a new question flow.
- Respond to Conversation: Process an incoming response payload.
Select Conversation Name or ID When starting a conversation, select a conversation ID from a dynamically loaded list sourced from Supabase. Alternatively, specify an ID using an expression.
Payload When responding to a conversation, provide the JSON payload received from a webhook to process the response.

Output

The node outputs an array of JSON objects, each containing:

  • conversationId: The ID of the conversation involved in the current execution cycle.

No binary data output is produced by this node.

Dependencies

  • Supabase: Used as a backend database to fetch conversation IDs and store/manage question flows.
  • Slack Web API: Utilized to interact with Slack, sending messages or processing conversations.
  • Credentials Required:
    • An API key credential providing access to Supabase (including URL and public anon key).
    • A Slack authentication token to authorize Slack API calls.
    • A Slack channel ID used when starting conversations.

These credentials must be configured in n8n prior to using the node.

Troubleshooting

  • Common Issues:

    • Failure to load conversation IDs: Ensure the Supabase credentials are correct and that the table slack_question_flows exists with appropriate data.
    • Slack API errors: Verify the Slack token has sufficient permissions to post messages or read conversations.
    • Invalid or missing payload when responding: Confirm the webhook payload is correctly passed into the node.
  • Error Messages:

    • Errors related to Supabase queries may indicate connectivity issues or incorrect credentials.
    • Slack API errors often mention permission problems or invalid tokens; recheck the Slack token configuration.
    • If the node returns empty or undefined conversation IDs, verify that the Supabase query filters (question_weight = 1) match existing data.

Links and References

Discussion