Actions32
- Bot Actions
- Callback Actions
- Chat Actions
- File Actions
- Message Actions
- Payment Actions
- Sticker Actions
Overview
The "Send Contact" operation of the Message resource in this node allows users to send a contact card to a specified chat via the Bale Messenger API. This is useful for sharing contact information such as phone numbers and names directly within a chat conversation.
Common scenarios include:
- Automatically sending customer support contact details to users.
- Sharing team member contacts in group chats.
- Distributing event or business contacts programmatically.
For example, you can configure the node to send a contact with a phone number and first name (optionally last name) to a chat identified by its unique Chat ID.
Properties
Name | Meaning |
---|---|
Chat ID | Unique identifier for the target chat where the contact will be sent. |
Phone Number | Phone number of the contact to be sent, e.g., "+989123456789". |
First Name | First name of the contact to be sent. |
Last Name | (Optional) Last name of the contact to be sent. |
Reply To Message ID | (Optional) If the message is a reply, the ID of the original message to reply to. |
Reply Markup | Additional interface options for the message's keyboard: Inline Keyboard, Reply Keyboard, None, or Reply Keyboard Remove. |
Reply Markup Options Details
- Inline Keyboard: Adds an inline keyboard next to the message with customizable rows and buttons. Buttons can have text, callback data, or URLs.
- Reply Keyboard: Adds a custom keyboard with reply options visible to the user.
- Reply Keyboard Remove: Requests clients to remove the custom keyboard.
- None: No additional interface options.
Output
The output JSON contains the response from the Bale Messenger API after sending the contact. It includes details about the sent contact message, such as message identifiers and status.
Example output structure (simplified):
{
"message_id": 123,
"chat": {
"id": "chatId",
"type": "private"
},
"contact": {
"phone_number": "+989123456789",
"first_name": "John",
"last_name": "Doe"
}
}
No binary data is output for this operation.
Dependencies
- Requires an active Bale Messenger API authentication token configured in n8n credentials.
- The node uses the official Bale Messenger API endpoint
https://tapi.bale.ai/bot
. - Network access to Bale Messenger API must be available.
Troubleshooting
- Invalid Chat ID: If the Chat ID is incorrect or the bot does not have permission to send messages to the chat, the API call will fail. Verify the Chat ID and bot permissions.
- Missing Required Fields: Phone Number and First Name are required. Omitting these will cause errors.
- API Authentication Errors: Ensure the API token credential is valid and has not expired.
- Reply Markup Misconfiguration: Incorrectly structured keyboards may cause the API to reject the request. Use the provided UI options carefully.
- Network Issues: Connectivity problems to the Bale API endpoint will result in request failures.
Error messages typically include the API response error details. Review those messages to identify issues like invalid parameters or authorization failures.
Links and References
- Bale Messenger Bot API Documentation
- n8n Documentation on Custom Nodes
- Telegram Bot API (similar concepts) — for understanding contact message structure (Bale API is similar)
This summary focuses specifically on the "Send Contact" operation of the "Message" resource based on the provided source code and property definitions.