Actions7
Iniciar Sessão
AI-generatedOverview
This node integrates with ElevenLabs conversational agents, enabling users to manage and interact with AI-driven chat agents. It supports operations such as creating, retrieving, updating, deleting agents, starting conversation sessions, and sending messages within those sessions.
The "Iniciar Sessão" (Start Session) operation specifically initiates a new conversation session for a given agent. This is useful when you want to begin a fresh dialogue context with an existing conversational agent, optionally specifying language preferences or knowledge bases to tailor the session.
Practical examples:
- Starting a new chat session with a customer support bot in Portuguese.
- Initiating a conversation session with a sales assistant agent configured to use specific knowledge bases.
- Beginning a multi-turn dialogue where subsequent messages will be sent to the started session.
Properties
| Name | Meaning |
|---|---|
| ID do Agente | The unique identifier of the conversational agent for which the session will be started. |
| Opções Avançadas | Advanced options to customize the session: |
| - Conhecimentos | Comma-separated IDs of knowledge bases to include in the session's context. |
| - Forçar Resposta de Áudio | Boolean flag to always generate an audio response even if it normally wouldn't be generated. |
| - Limite de Pesquisa | Maximum number of search results to retrieve from the knowledge base during interactions. |
| - Idioma | Language code for the session, e.g., "pt-BR" for Brazilian Portuguese or "en-US" for English US. |
Output
The output JSON contains the response from the ElevenLabs API after starting a session. Typically, this includes details about the newly created session such as its unique session ID and any metadata returned by the service.
If the node supports binary data output (not explicitly shown for this operation), it would represent audio responses or other media generated by the agent.
Dependencies
- Requires an active API key credential for ElevenLabs API authentication.
- Relies on the ElevenLabs conversational agents API endpoints.
- Uses helper functions (
createBaseOptions,formatReturnData,handleApiError) presumably defined in bundled utilities for request construction, response formatting, and error handling.
Troubleshooting
Common issues:
- Invalid or missing agent ID: Ensure the provided agent ID exists and is correctly formatted.
- API authentication errors: Verify that the API key credential is valid and has necessary permissions.
- Network or timeout errors: Check connectivity to ElevenLabs API endpoints.
- Incorrect language codes or knowledge base IDs may cause unexpected behavior or empty sessions.
Error messages:
- Errors thrown by the API are caught and processed; they typically indicate invalid parameters or authorization failures.
- If an error occurs, the node attempts to return a structured error object; otherwise, it throws the error to halt execution.
Links and References
- ElevenLabs Conversational Agents API Documentation (hypothetical link, replace with actual if available)
- n8n documentation on Creating Custom Nodes
- General info on Language Codes for setting the session language property.