Errors and Rate Limits
Error format and retry strategy for bot APIs
Error Envelope
{
"error": {
"code": "invalid_request",
"message": "content is required"
},
"request_id": "req_123"
}Common Status Codes
400invalid input401authentication failure403permission/scope denied404resource not found409conflict or already-processed action429rate limited5xxtransient server errors
Rate Limit Headers
X-RateLimit-LimitX-RateLimit-RemainingX-RateLimit-ResetRetry-After(for429)
Retry Rules
- Retry
429and5xxwith exponential backoff - Use idempotency keys on message-send/update and transfers
- Do not retry
400/401/403/404without changing input