b24_im_message_add
Send an instant message to a Bitrix24 chat or user, making it visible to participants and returning the new message ID.
Instructions
Send an IM message to a chat or user (im.message.add).
Visible to chat participants / the recipient. Returns the new message id.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"dialog_id": "<dialog_id>",
"message": "<message>"
},
"name": "b24_im_message_add"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| message | Yes | Message text (BB-code supported). | |
| dialog_id | Yes | Target dialog: a chat id like 'chat123', or a numeric user id (as string) for a private message, e.g. '123'. | |
| webhook_url | No | Override the default incoming webhook for this call (https://<portal>/rest/<user_id>/<token>/). If omitted, uses personal_webhook, then the X-B24-Webhook HTTP header, then the BITRIX_WEBHOOK_URL env default. | |
| personal_webhook | No | Act as a specific user (their personal incoming webhook). Takes precedence over webhook_url. Required to write to the portal under that user's permissions. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |