max_validate_message
Validate a message body before sending to MAX: 4000-char text, format, keyboard limits (210/30/7, 3 per row with link/open_app/request_*), button fields and lengths, attachment combinations (≤12 media, file only with a keyboard, audio/sticker/contact alone), comment restrictions, Telegram fields left in the body.
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": {
"body": "<body>"
},
"name": "max_validate_message"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| body | Yes | NewMessageBody JSON: {text, format, attachments, link, notify} | |
| lang | No | Answer language: 'en' English, 'ru' Russian. Pick the user's language; default ru (or XONTA_MAX_LANG) | |
| target | No | message — POST /messages, comment — POST /messages/{id}/comments | message |
| chat_type | No | Where it goes, for channel-specific rules |