Tham chiếu mã lỗi
Mọi endpoint khi thất bại đều trả về phong bì JSON `{ "error": { "code": "...", "message": "..." } }`. Mã trạng thái HTTP cho biết nhóm lỗi tổng quát, còn chuỗi `code` xác định trường hợp cụ thể để client có thể rẽ nhánh xử lý.
400 Bad Request
invalid_requestRequest body cannot be decoded or required fields are missing.
invalid_providerProvider name in the URL is missing or unsupported.
unsupported_actionAccount action is not recognised.
invalid_conversation_typetype must be user, group, or channel.
unsupported_conversation_typeProvider does not support that operation for this conversation type.
unsupported_message_typemessage.type is not supported by the selected provider.
unsupported_provider_auth_modeauth_mode is not supported by the selected provider.
auth_mode_phone_requiredThe selected auth mode requires provider_data.phone at account creation.
invalid_reply_tokenreply_to.reply_token is tampered with, encrypted with a different key, or otherwise unreadable. Pass the token from data.message.reply_token back unchanged.
create_api_key_failedAPI key creation request was rejected.
update_api_key_failedAPI key update request was rejected.
rotate_api_key_failedAPI key rotation request was rejected.
create_webhook_endpoint_failedWebhook endpoint creation was rejected.
update_webhook_endpoint_failedWebhook endpoint update was rejected.
deactivate_webhook_endpoint_failedWebhook endpoint deactivation was rejected.
delete_webhook_endpoint_failedWebhook endpoint deletion was rejected.
update_workspace_failedWorkspace update was rejected.
401 Unauthorized
missing_api_keyThe X-Api-Key request header is missing.
invalid_api_keyThe API key is not recognised or has been disabled.
404 Not Found
not_foundThe route does not exist.
conversation_not_foundThe conversation could not be found by the provider.
contact_not_foundThe contact could not be found under this account.
group_not_foundThe group could not be found under this account.
409 Conflict
account_allocation_busyAccount allocation lock is held; retry after a short delay.
no_allocatable_serverNo allocatable provider server in the requested region.
workspace_account_quota_exceededThe workspace account quota has been exhausted.
duplicate_provider_accountAnother account in this workspace already uses the same provider identity.
account_already_authorizedThe account is already authorised; the requested auth action is rejected.
account_binding_not_foundThe account is not bound to an active provider server.
500 Internal Server Error
create_account_failedServer-side error while creating the account.
update_account_failedServer-side error while updating the account.
delete_account_failedServer-side error while deleting the account.
get_account_failedServer-side error while loading account details.
list_accounts_failedServer-side error while listing accounts.
get_session_failedServer-side error while loading the authentication session.
get_auth_state_failedServer-side error while loading authentication state.
run_action_failedServer-side error while running an account action.
run_runtime_action_failedServer-side error while running a runtime action.
run_session_action_failedServer-side error while running a session action.
run_auth_action_failedServer-side error while running an authentication action.
send_message_failedServer-side error while sending the message.
pin_message_failedServer-side or upstream error while pinning / unpinning the message.
revoke_message_failedServer-side or upstream error while revoking the message.
react_message_failedServer-side or upstream error while reacting to the message.
edit_message_failedServer-side or upstream error while editing the message text.
list_conversations_failedServer-side error while listing conversations.
get_conversation_failedServer-side error while loading the conversation.
list_conversation_members_failedServer-side error while listing conversation members.
mark_conversation_read_failedServer-side or upstream error while marking the conversation as read.
mark_conversation_unread_failedServer-side or upstream error while marking the conversation as unread.
mute_conversation_failedServer-side or upstream error while muting the conversation.
unmute_conversation_failedServer-side or upstream error while unmuting the conversation.
pin_conversation_failedServer-side or upstream error while pinning the conversation.
unpin_conversation_failedServer-side or upstream error while unpinning the conversation.
list_conversation_labels_failedServer-side or upstream error while listing conversation labels.
upsert_label_failedServer-side or upstream error while creating or updating a label.
delete_label_failedServer-side or upstream error while deleting a label.
set_label_members_failedServer-side or upstream error while tagging or untagging conversations.
list_contacts_failedServer-side error while listing contacts.
get_contact_failedServer-side error while loading the contact.
block_contact_failedServer-side or upstream error while blocking the contact.
unblock_contact_failedServer-side or upstream error while unblocking the contact.
list_blocklist_failedServer-side or upstream error while loading the blocklist.
set_contact_note_failedServer-side or upstream error while setting or clearing the contact note.
list_groups_failedServer-side error while listing groups.
get_group_failedServer-side error while loading the group.
create_group_failedServer-side or upstream error while creating the group.
leave_group_failedServer-side or upstream error while leaving the group.
update_group_members_failedServer-side or upstream error while updating group members.
update_group_info_failedServer-side or upstream error while updating the group name, description, or avatar (including admin-permission rejections).
list_group_join_requests_failedServer-side or upstream error while listing pending group join requests.
update_group_join_requests_failedServer-side or upstream error while approving / rejecting group join requests.
set_group_join_approval_mode_failedServer-side or upstream error while toggling the group join approval mode.
get_group_invite_code_failedServer-side or upstream error while fetching the group invite link / code.
list_webhook_endpoints_failedServer-side error while listing webhook endpoints.
get_webhook_endpoint_failedServer-side error while loading the webhook endpoint.
get_workspace_failedServer-side error while loading the workspace.
list_api_keys_failedServer-side error while listing API keys.
list_provider_regions_failedServer-side error while listing provider regions.
501 Not Implemented
unsupported_by_providerThe selected provider has not implemented this endpoint.
502 Bad Gateway
provider_adapter_not_foundThe provider adapter is unavailable or not registered.
503 Service Unavailable
allocation_service_unavailableThe allocation lock service is unavailable; retry shortly.