People · Developer account
blockBot
Block a bot
This method authenticates with your developer account. The easiest way to call it is the dashboard, which signs the request for you. Direct calls need a dashboard session cookie.
Blocks the bot for the caller (both envs). The bot learns about it through a my_chat_member update queued in each env (old 'member' -> new 'kicked'). Blocking is per bot; the caller can block any non-deleted bot, including their own.
Request
curl https://api.sprintelex.com/blockBot \
# authenticated with your dashboard session \
-H "Content-Type: application/json" \
-d '{"bot_id":"<bot-id>"}'Parameters
| Name | Type | Required | Rules |
|---|---|---|---|
| bot_id | string | Yes | - |
Response
{ ok: true, result: { blocked: true } }Rate limit: none in code
Errors
| Status | Error | When |
|---|---|---|
| 400 | bot_id is required | missing bot_id |
| 404 | bot not found | no such bot or deleted |
| 500 | could not block bot | DB upsert failed |