Actions12
Overview
The "Get Chat Members" operation of the Telegram Client node retrieves a list of all members in a specified Telegram chat or channel. This is useful for scenarios where you need to analyze, manage, or interact with the participants of a group or channel. For example, you might want to export member information for reporting, send targeted messages, or automate membership management tasks.
Practical examples:
- Fetching all members of a community channel to send personalized updates.
- Auditing group membership before performing administrative actions.
- Integrating member data into CRM or marketing tools.
Properties
| Name | Meaning |
|---|---|
| Chat ID | The unique identifier or username of the chat/channel (e.g., @username or -100xxxx). |
| Options | Additional optional parameters: • Silent: Send message silently without notification (not applicable here). • Caption: Caption for media messages (not applicable here). • Parse Mode: How to parse message text (not applicable here). • Limit: Maximum number of chat members to return (default 100). |
Note: For the "Get Chat Members" operation, only the Chat ID and Limit option are relevant.
Output
The output JSON contains:
success: Boolean indicating if the operation succeeded.members: An array of member objects representing each participant in the chat. Each member object includes details such as user ID, username, status, and other Telegram-specific metadata.
Example output structure:
{
"success": true,
"members": [
{
"id": 123456789,
"username": "exampleuser",
"status": "member",
...
},
...
]
}
No binary data is output by this operation.
Dependencies
- Requires valid Telegram API credentials including an API ID, API hash, and a session string.
- The node uses the Telegram Client API via a third-party SDK bundled within the node.
- Network connectivity to Telegram servers is necessary.
- No additional environment variables or external services beyond Telegram API access are required.
Troubleshooting
Common issues:
- Missing or invalid Telegram API credentials will cause authentication failure.
- Providing an incorrect or inaccessible Chat ID may result in errors or empty member lists.
- Exceeding Telegram API rate limits can cause temporary failures.
- Insufficient permissions (e.g., not being a member or admin of the chat) may prevent fetching members.
Error messages:
"No credentials provided": Ensure that the Telegram API credentials are configured correctly in n8n."Authentication failed: ...": Check the validity of the API ID, API hash, and session string."Operation 'getChatMembers' is not supported": Indicates a misconfiguration; verify the selected operation.- Other errors from Telegram API calls usually include descriptive messages; review them to adjust inputs or permissions.
Resolution tips:
- Double-check the Chat ID format and ensure the bot/user has access.
- Verify API credentials and refresh session tokens if needed.
- Use smaller limits if hitting rate limits.
- Enable "Continue on Fail" in the node settings to handle intermittent errors gracefully.