Telegram CoPilot icon

Telegram CoPilot

Your Personal Telegram CoPilot

Overview

This node integrates with Telegram via the TelePilot API, enabling automation of various Telegram user-related actions. Specifically, for the User resource and Create Private Chat operation, it allows creating a private chat with a specified Telegram user. This is useful in scenarios where you want to programmatically initiate direct conversations with users, such as sending automated messages, customer support interactions, or bot-driven communication setups.

Practical example:

  • Automatically create a private chat with a new user who signs up on your platform, then send them a welcome message.
  • Force creation of a private chat even if one already exists, ensuring fresh context or session.

Properties

Name Meaning
User ID The unique identifier of the Telegram user with whom to create the private chat.
Force Boolean flag indicating whether to force the creation of the private chat (true/false).

Output

The node outputs an array of JSON objects representing the result of the invoked Telegram API call. For the "Create Private Chat" operation, the output JSON contains details about the newly created private chat object returned by Telegram's API. This typically includes chat identifiers, type, and metadata related to the private chat.

No binary data output is produced by this operation.

Dependencies

  • Requires an active Telegram API authentication credential (an API key/token) configured in n8n.
  • Depends on the TelePilot Node Connection Manager to handle client sessions and API invocation.
  • The node expects the Telegram account to be logged in; otherwise, it will throw login-related errors.
  • No additional external services are required beyond Telegram's API.

Troubleshooting

  • Error: "Please login"
    Occurs if the Telegram client session is not authenticated. Resolve by using the login flow provided by the node (e.g., via the ChatTrigger node) and following the guide at https://telepilot.co/login-howto.

  • Session closed or terminated errors
    If the client session was closed unexpectedly, the node may throw errors indicating the session cannot be reused. Re-login is required.

  • Invalid User ID
    Providing an incorrect or non-existent user ID may cause the Telegram API to return errors. Verify the user ID before invoking.

  • Force flag misuse
    Setting force to true forces chat creation even if a chat exists, which might lead to unexpected behavior if used improperly.

  • API rate limits or restrictions
    Telegram may restrict certain operations based on account status or API limits. Handle errors gracefully and consider retry logic.

Links and References

Discussion