Error Codes
Sendbird Chat SDK for Flutter has two types of error codes:
- Client error codes: these errors are usually caused by something the client app side did, such as incorrect or invalid parameters, or sending a request when disconnected.
- Server error codes: these errors are usually caused by a Sendbird server side issue.
Client error codes
The following errors that are defined in error_code.dart
are six-digit integers beginning with 800.
Error | Code | Description |
---|---|---|
unknownError | 800000 | The client app encounters an unexpected exception while trying to sending a request. |
connectionRequired | 800101 | The request from a client app failed because the device isn't connected to the server. |
connectionCanceled | 800102 | The connection is canceled or the disconnecting method is called while trying to connect to the server via the connecting method. |
invalidParameter | 800110 | The parameter of the method specifies an invalid value. |
networkError | 800120 | The connection failed due to the unstable network or an unexpected error in the Chat SDK network library. |
networkRoutingError | 800121 | The request routing to the server failed. |
malformedData | 800130 | The data format of the server response is invalid. |
malformedErrorData | 800140 | The data format of the error message is invalid due to the problem with the request. |
wrongChannelType | 800150 | The specified channel type in the request is invalid. |
markAsReadRateLimitExceeded | 800160 | The interval between the successive mark-messages-as-read requests is less than a second. |
queryInProgress | 800170 | A retrieval request is arriving while the server is still processing the previous retrieval request for channels, messages, or users, and in preparation to send the response. |
ackTimeout | 800180 | The server failed to send a response for the request in 10 seconds (timed-out). |
loginTimeout | 800190 | The server failed to send a response for the login request in 10 seconds (timed-out). |
webSocketConnectionClosed | 800200 | The request failed due to being submitted while disconnected from the server. |
webSocketConnectionFailed | 800210 | The websocket connection to the server failed to establish. |
requestFailed | 800220 | The server failed to process the request due to an internal reason. |
fileUploadCancelFailed | 800230 | The request to cancel file upload failed due to an unexpected error. |
fileUploadCanceled | 800240 | The file upload request is canceled. |
fileUploadTimeout | 800250 | The file upload request failed because it's timed-out. |
fileSizeLimitExceeded | 800260 | The file upload request failed because the file size was too big. |
timerWasExpired | 800301 | A timer-related function failed because the time ran out. |
timerWasAlreadyDone | 800302 | A timer-related function failed because the time ran out. |
passedInvalidAccessToken | 800500 | The access token provided for the request specifies an invalid value. |
sessionKeyRefreshSucceeded | 800501 | The session key was successfully refreshed. |
sessionKeyRefreshFailed | 800502 | The session key wasn't refreshed. |
Server error codes
The following errors are six-digit integers beginning with 400, 500, and 900.
Code | Description |
---|---|
400100 | invalidParameteraValueString |
400101 | nvalidParameterValueNumber |
400102 | invalidParameterValueList |
400103 | invalidParameterValueJson |
400104 | invalidParameterValueBoolean |
400105 | invalidParameterValueRequired |
400106 | invalidParameterValuePositive |
400107 | invalidParameterValueNegative |
400108 | nonAuthorized |
400109 | tokenExpired |
400110 | invalidChannelUrl |
400111 | invalidParameterValue |
400151 | unusableCharacterIncluded |
400201 | notFoundInDatabase |
400202 | duplicatedData |
400300 | userDeactivated |
400301 | userNotExist |
400302 | accessTokenNotValid |
400303 | authUnknownError |
400304 | appIdNotValid |
400305 | authUserIdTooLong |
400306 | authPlanQuotaExceeded |
400309 | sessionKeyExpired |
400310 | sessionTokenRevoked |
400401 | invalidApiToken |
400402 | parameterMissing |
400403 | invalidJsonBody |
500901 | internalServerError |
500910 | rateLimitExceeded |
900010 | socketLoginRequired |
900020 | socketUserNotMember |
900021 | socketUserDeactivated |
900022 | socketUserNotOwnerOfMessage |
900023 | socketUserSendMessageNotAllowed |
900025 | socketInvalidMentionForMessage |
900026 | socketInvalidPushOptionForMessage |
900027 | socketTooManyMetaKeyForMessage |
900028 | socketTooManyMetaValueForMessage |
900029 | socketTooManyMetaArrayForMessage |
900030 | socketGuestNotAllowed |
900040 | socketMutedUserInApplicationSendMessageNotAllowed |
900041 | socketMutedUserInChannelSendMessageNotAllowed |
900050 | socketChannelFrozen |
900060 | socketProfanityMessageBlocked |
900061 | socketBannedUrlsBlocked |
900065 | socketRestrictedDomainBlocked |
900066 | socketModeratedFileBlocked |
900070 | socketEnterDeletedChannel |
900080 | socketBlockedUserReceiveMessageNotAllowed |
900081 | socketDeactivatedUserReceiveMessageNotAllowed |
900090 | socketWrongChannelType |
900100 | socketBannedUserSendMessageNotAllowed |
900200 | socketTooManyMessages |
900300 | socketMessageNotFound |
900400 | socketTooManyParticipants |
900500 | socketChannelNotFound |