Telegram CoPilot icon

Telegram CoPilot

Your Personal Telegram CoPilot

Overview

This node, named "Telegram CoPilot," integrates with the Telegram API to perform various Telegram-related actions programmatically. Specifically for the User resource and the Create Private Chat operation, it allows creating a private chat with a specified user by their user ID. This can be useful in automation workflows where initiating direct conversations with users is required, such as customer support bots, notification systems, or personal assistants that interact with Telegram users.

Practical example: Automatically create a private chat with a new user who signs up on your platform, enabling you to send them welcome messages or gather additional information.

Properties

Name Meaning
User ID The unique identifier of the Telegram user with whom to create the private chat.
Force Boolean flag indicating whether the creation of the private chat should be forced even if a chat already exists.

Output

The node outputs an array of JSON objects representing the result of the invoked Telegram API method. For the "Create Private Chat" operation, the output JSON contains details about the newly created private chat, such as chat identifiers and metadata returned by Telegram.

No binary data output is indicated for this operation.

Dependencies

  • Requires an API key credential for authenticating with the Telegram API.
  • Depends on the TelePilot library and its connection manager to handle Telegram client sessions.
  • Requires proper login/authentication via phone number and code before performing operations.
  • Network access to Telegram servers is necessary.

Troubleshooting

  • Common issues:

    • Attempting to create a private chat without being logged in will cause errors. Ensure the login process is completed successfully using the login operations.
    • If the session is closed or terminated, the node throws an error instructing to log in again.
    • Invalid or missing user IDs may cause the Telegram API to return errors.
  • Error messages:

    • "Session was closed or terminated. Please login again: https://telepilot.co/login-howto"
      Indicates the Telegram client session is no longer valid; re-authenticate using the login flow.
    • "Please login: https://telepilot.co/login-howto"
      Means the node attempted an operation without an active authenticated session.
    • Errors related to unauthorized access also require re-login.

Links and References


This summary focuses on the "User" resource and "Create Private Chat" operation as requested.

Discussion