Error and Warning Messages

Introduction

Agora SDK will return some error codes or warning codes when calling APIs or during runtime:

  • Error Messages means that the SDK encountered an error that can be not recovered automatically without application intervention. For example, the SDK returns an error if it fails to open a camera, and then the application needs to remind the user not to use the camera.
  • Warning Messages means that the SDK encountered an error that might be recovered automatically. A Warning Code is just for notification, which can usually be ignored.

Agora Native SDK

Error Message

Error Code Value Description
ERR_OK 0 No error.
ERR_FAILED 1 General error(the reason is not classified specifically).
ERR_INVALID_ARGUMENT 2 Invalid parameter called. For example, the specific channel name includes illegal characters.
ERR_NOT_READY 3 SDK module is not ready. For example, if some API relies on a specific module, but the module is not ready to provide service yet.
ERR_NOT_SUPPORTED 4 SDK does not support this function.
ERR_REFUSED 5 Request is rejected. It is only for SDK internal use, which means it won’t return to the application through any API or callback event.
ERR_BUFFER_TOO_SMALL 6 The buffer size is not big enough to store the returned data.
ERR_NOT_INITIALIZED 7 The SDK is not initialized before calling this API.
ERR_NO_PERMISSION 9 No permission. It is only for SDK internal use, which means it won’t return to the application through any API or callback event.
ERR_TIMEDOUT 10 API call timed-out. Some API requires the SDK to return the execution result, and this error occurs if the request takes too long for the SDK to process.
ERR_CANCELED 11 Request is cancelled. It is only for SDK internal use, which means it won’t return to the application through any API or callback event.
ERR_TOO_OFTEN 12 Call frequency is too high. It is only for SDK internal use, which means it won’t return to the application through any API or callback event.
ERR_BIND_SOCKET 13 SDK failed to bind to the network socket. It is only for SDK internal use, which means it won’t return to the application through any API or callback event.
ERR_NET_DOWN 14 Network is unavailable. It is only for SDK internal use, which means it won’t return to the application through any API or callback event.
ERR_NET_NOBUFS 15 No network buffers available. It is only for SDK internal use, which means it won’t return to the application through any API or callback event.
ERR_JOIN_CHANNEL_REJECTED 17 The request to join the channel is rejected. This error usually occurs when the user is already in the channel, and still calls the API to join the channel, for example, joinChannel.
ERR_LEAVE_CHANNEL_REJECTED 18 The request to leave the channel is rejected. This error usually occurs when the user has already left the channel, and still calls the API to leave the channel, for example, leaveChannel.
ERR_ALREADY_IN_USE 19 Resources have been occupied, and cannot be reused.
ERR_ABORTED 20 SDK gave up the request probably due to too many request. It is only for SDK internal use, which means it won’t return to the application through any API or callback event.
ERR_INIT_NET_ENGINE 21 Windows under specific firewall settings can cause the SDK fail to initialize and then crash.
ERR_INVALID_VENDOR_KEY 101 The specified App ID is invalid.
ERR_INVALID_CHANNEL_NAME 102 The specified Channel Name is invalid.
ERR_CHANNEL_KEY_EXPIRED 109 The current Channel Key is expired, no longer valid. See ERR_CHANNEL_KEY_EXPIRED(109) Error for more details.
ERR_INVALID_CHANNEL_KEY 110 The specified Channel Key is invalid. Usually the Channel Key was generated incorrectly. See ERR_INVALID_CHANNEL_KEY(110) Error for more details.
ERR_CONNECTION_INTERRUPTED 111 CONNECTION_INTERRUPTED callback.
It is only applicable to Agora Native SDK for Web.
ERR_CONNECTION_LOST = 112 112 CONNECTION_LOST callback.
It is only applicable to Agora Native SDK for Web.
ERR_NOT_IN_CHANNEL 113 The user is not in the channel.
ERR_SIZE_TOO_LARGE 114 The data size is too big.
ERR_BITRATE_LIMIT 115 limited bitrate.
ERR_TOO_MANY_DATA_STREAMS 116 Too many data streams.
ERR_STREAM_MESSAGE_TIMEOUT 117 Data stream timed out.
ERR_LOAD_MEDIA_ENGINE 1001 Failed to load media engine.
ERR_START_CALL 1002 Failed to start the call after enabling the media engine.
ERR_START_CAMERA 1003 Failed to start the camera.
ERR_START_VIDEO_RENDER 1004 Failed to start the video rendering module.
ERR_ADM_GENERAL_ERROR 1005 General error on Audio Device Module(the reason is not classified specifically).
ERR_ADM_JAVA_RESOURCE 1006 Audio Device Module:
Error in using java resources
ERR_ADM_SAMPLE_RATE 1007 Audio Device Module:
Error in setting the sampling frequency
ERR_ADM_INIT_PLAYOUT 1008 Audio Device Module:
Error in initializing the playback device
ERR_ADM_START_PLAYOUT 1009 Audio Device Module:
Error in starting the playback device
ERR_ADM_STOP_PLAYOUT 1010 Audio Device Module:
Error in stopping the playback device
ERR_ADM_INIT_RECORDING 1011 Audio Device Module:
Error in initializing the recording device
ERR_ADM_START_RECORDING 1012 Audio Device Module:
Error in starting the recording device
ERR_ADM_STOP_RECORDING 1013 Audio Device Module:
Error in stopping the recording device
ERR_ADM_RUNTIME_PLAYOUT_ERROR 1015 Audio Device Module:
Runtime playback error
ERR_ADM_RUNTIME_RECORDING_ERROR 1017 Audio Device Module:
Runtime recording error
ERR_ADM_RECORD_AUDIO_FAILED 1018 Audio Device Module:
Failed to record
ERR_ADM_INIT_LOOPBACK 1022 Audio Device Module:
Error in initializing the loopback device
ERR_ADM_START_LOOPBACK 1023 Audio Device Module:
Error in starting the loopback device
ERR_VDM_CAMERA_NOT_AUTHORIZED 1501 Video Device Module:
The camera is not authorized

Warning Message

Warning Code Value Description
WARN_INVALID_VIEW 8 The specified view is invalid. It is required to specify a view when using the video call function, otherwise, it returns this warning.
WARN_INIT_VIDEO 16 Failed to initialize the video function.
WARN_PENDING 20 The request is pending. Usually it is due to some module is not ready, and the SDK postponed processing the request.
WARN_NO_AVAILABLE_CHANNEL 103 No channel resources are available. Maybe because the server cannot allocate channel resources.
WARN_LOOKUP_CHANNEL_TIMEOUT 104 Timed-out when looking up the channel. When joining a channel, the SDK looks up the specified channel. The warning usually occurs when the network condition is too bad to connect to the server.
WARN_LOOKUP_CHANNEL_REJECTED 105 The server rejected the request to look up the channel. The server cannot process this request or request is illegal.
WARN_OPEN_CHANNEL_TIMEOUT 106 Timed-out when opening the channel. Once the specific channel is found, the SDK opens the channel. The warning usually occurs when the network condition is too bad to connect to the server.
WARN_OPEN_CHANNEL_REJECTED 107 The server rejected the request to open the channel. The server cannot process this request or request is illegal.
WARN_ADM_RUNTIME_PLAYOUT_WARNING 1014 Audio Device Module:
Warning in runtime playback device
WARN_ADM_RUNTIME_RECORDING_WARNING 1016 Audio Device Module:
Warning in runtime recording device
WARN_ADM_RECORD_AUDIO_SILENCE 1019 Audio Device Module:
No valid audio data collected
WARN_ADM_PLAYOUT_MALFUNCTION 1020 Audio Device Module:
playback device failure
WARN_ADM_RECORD_MALFUNCTION 1021 Audio Device Module:
Recording device failure
WARN_ADM_HOWLING 1051 Audio Device Module:
Howling is detected

Agora Web SDK

Error Message

Value Description
‘INVALID_KEY’ Invalid user key
‘INVALID_OPERATION’ Invalid user operation
‘INVALID_LOCAL_STREAM’ Invalid local stream
‘INVALID_REMOTE_STREAM’ Invalid remote stream
‘INVALID_DYNAMIC_KEY’ Invalid Channel Key
‘DYNAMIC_KEY_TIMEOUT’ Expired Channel Key
‘SOCKET_ERROR’ Socket connection error
‘SOCKET_DISCONNECTED’ Cannot connect to Socket
‘PEERCONNECTION_FAILED’ Peer connection lost
‘CONNECT_GATEWAY_ERROR’ Cannot connect to the Web Server
‘SERVICE_NOT_AVAILABLE’ Service not available
‘JOIN_CHANNEL_FAILED’ Failed to join channel
‘PUBLISH_STREAM_FAILED’ Failed to publish stream
‘UNPUBLISH_STREAM_FAILED’ Failed to unpublish stream
‘SUBSCRIBE_STREAM_FAILED’ Failed to subscribe stream
‘UNSUBSCRIBE_STREAM_FAILED’ Failed to unsubscribe stream
‘101’ Invalid App ID
‘102’ Invalid channel name
‘109’ Expired Channel Key
‘110’ Invalid Channel Key

Agora Signaling SDK

Error Message

Error Code Value Description
SUCCESS 0 No error
LOGOUT_E_OTHER 100 Logout due to some reasons, for example, normally network issues.
LOGOUT_E_USER 101 User logged out
LOGOUT_E_NET 102 Network issue
LOGOUT_E_KICKED 103 The account is logged in other place
LOGOUT_E_PACKET 104 obsolete
LOGOUT_E_TOKENEXPIRED 105 Signaling Key expired
LOGOUT_E_OLDVERSION 106 obsolete
LOGOUT_E_TOKENWRONG 107 obsolete
LOGIN_E_OTHER 200 Unknown reason
LOGIN_E_NET 201 Network issue
LOGIN_E_FAILED 202 Rejected by server
LOGIN_E_CANCEL 203 User cancelled the login
LOGIN_E_TOKENEXPIRED 204 Signaling Key expired, login rejected
LOGIN_E_OLDVERSION 205 obsolete
LOGIN_E_TOKENWRONG 206 Signaling Key is invalid, see LOGIN_E_TOKENWRONG(206) Error for more details.
LOGIN_E_TOKEN_KICKED 207 User has used a renewed Signaling Key to log in some place else.
LOGIN_E_ALREADY_LOGIN 208 The user has already logged in. Ignore this error.
JOINCHANNEL_E_OTHER 300 Failed to join a channel
SENDMESSAGE_E_OTHER 400 Failed to send message
SENDMESSAGE_E_TIMEOUT 401 Timed-out in sending message
QUERYUSERNUM_E_OTHER 500 Failed to query the channel user number.
QUERYUSERNUM_E_TIMEOUT 501 Timed-out in querying the channel user number
QUERYUSERNUM_E_BYUSER 501 obsolete
LEAVECHANNEL_E_OTHER 600 Left channel out of unknown reason
LEAVECHANNEL_E_KICKED 601 Kicked out by the administrator
LEAVECHANNEL_E_BYUSER 602 The user has left the channel
LEAVECHANNEL_E_LOGOUT 603 Kicked out of the channel upon logout
LEAVECHANNEL_E_DISCONN 604 Left the channel due to network outage
INVITE_E_OTHER 700 Call fails
INVITE_E_REINVITE 701 Repeated calls
INVITE_E_NET 702 Network issue
INVITE_E_PEEROFFLINE 703 The other user is offline
INVITE_E_TIMEOUT 704 Call timed-out
INVITE_E_CANTRECV 705 obsolete
GENERAL_E 1000 general error
GENERAL_E_FAILED 1001 general error - failure
GENERAL_E_UNKNOWN 1002 general error-unknown
GENERAL_E_NOT_LOGIN 1003 general error-action before login
GENERAL_E_WRONG_PARAM 1004 general error-parameter calling error