Overview
This node integrates with Lerty AI agents to perform various communication-related operations. Specifically, the "Send Typing Indicator" operation allows you to send a typing status (either start or stop typing) to a specified conversation within a Lerty agent context. This is useful in chatbots or conversational AI scenarios where you want to visually indicate to users that the agent is typing a response, enhancing user experience by mimicking natural human interaction.
Practical examples:
- In a customer support chatbot, show the typing indicator while the AI processes a user's query.
- Stop the typing indicator once the message has been sent or the agent is idle.
- Use it in multi-agent conversations to signal activity status.
Properties
| Name | Meaning |
|---|---|
| Agent | The Lerty AI agent to interact with. Can be selected from a list of agents or specified by ID. |
| Conversation ID | The unique identifier of the conversation where the typing indicator will be sent. |
| Typing | Boolean flag indicating whether to show (true) or stop (false) the typing indicator. |
| Additional Fields | Optional extra parameters: - Metadata: key-value pairs for additional context. - Timeout: request timeout in milliseconds (default 30000). |
Output
The output JSON contains the response from the Lerty API regarding the typing indicator status update. It includes any relevant data returned by the API and also merges the original trigger data from the input item under _originalTriggerData. This can be used for debugging or chaining further workflow steps.
No binary data is output by this operation.
Example output structure snippet:
{
"status": "success",
"conversationId": "conversation_123",
"typing": true,
"_originalTriggerData": { /* original input JSON */ }
}
Dependencies
- Requires an API key credential for authenticating with the Lerty API.
- The node uses HTTP requests to communicate with the Lerty service endpoints.
- Proper configuration of the Lerty API base URL and token is necessary.
- The node expects the conversation ID and agent ID to be valid and accessible via the API.
Troubleshooting
Common issues:
- Invalid or missing conversation ID: The node throws an error if the conversation ID is empty or contains unevaluated expressions.
- Missing or incorrect API credentials: Ensure the API key and base URL are correctly configured.
- Network or API access errors: Check connectivity and API availability.
Error messages:
"Conversation ID contains unevaluated expression": Indicates that the conversation ID parameter includes unresolved expressions; fix by ensuring proper expression syntax."Conversation ID is required but was empty": Provide a valid conversation ID.- HTTP errors from the API (e.g., 422 validation errors) will include details; verify the payload and parameters.
How to resolve:
- Validate all input parameters before execution.
- Confirm API credentials and permissions.
- Review API documentation for correct usage of conversation IDs and typing indicators.
Links and References
- Lerty API Documentation (hypothetical link)
- n8n Documentation on Creating Custom Nodes
- General best practices for chatbot UX and typing indicators: UX Collective Article