Skip to content

Error Codes Reference

This page documents all error codes returned by the RecordPlatform API.

Code Ranges

RangeCategory
200Success
10000-19999Parameter Validation Errors
20000-29999User/Authentication Errors
30000-39999External Service Errors (Blockchain, Storage)
40000-49999System Errors
50000-59999Business Data Errors
60000-69999Messaging Service Errors
70000-79999Permission Errors

Success

CodeNameDescription
200SUCCESSOperation successful

Parameter Errors (10000-19999)

CodeNameDescription
10000PARAM_ERRORParameter error (general)
10001PARAM_IS_INVALIDInvalid parameter
10002PARAM_IS_BLANKParameter is empty
10003PARAM_TYPE_BIND_ERRORParameter format error
10004PARAM_NOT_COMPLETEMissing parameter
10005JSON_PARSE_ERRORJSON parsing failed

User/Authentication Errors (20000-29999)

CodeNameDescription
20001USER_NOT_LOGGED_INUser not logged in
20002USER_LOGIN_ERRORAccount not found or wrong password
20003USER_ACCOUNT_FORBIDDENAccount disabled
20004USER_NOT_EXISTUser does not exist
20005USER_HAS_EXISTEDUser already exists
20006USER_ACCOUNT_LOCKEDAccount temporarily locked (too many login failures)

External Service Errors (30000-39999)

CodeNameDescription
30001CONTRACT_ERRORSmart contract call failed
30002INVALID_RETURN_VALUEInvalid contract return value
30003GET_USER_FILE_ERRORFailed to get user file
30004DELETE_USER_FILE_ERRORFailed to delete user file
30005GET_USER_SHARE_FILE_ERRORFailed to get shared file
30006BLOCKCHAIN_ERRORBlockchain service request failed
30007TRANSACTION_NOT_FOUNDTransaction record not found
30008TRANSACTION_RECEIPT_NOT_FOUNDTransaction receipt not found
30009FILE_SERVICE_ERRORFile service request failed
30010SERVICE_CIRCUIT_OPENService temporarily unavailable (circuit breaker)
30011SERVICE_TIMEOUTService response timeout
30012STORAGE_QUORUM_NOT_REACHEDStorage write quorum not reached
30013STORAGE_INSUFFICIENT_REPLICASInsufficient storage nodes available
30014STORAGE_DEGRADED_WRITEStorage wrote in degraded mode, will sync when nodes recover

System Errors (40000-49999)

CodeNameDescription
40001FILE_MAX_SIZE_OVERFLOWUpload size exceeds limit
40002FILE_ACCEPT_NOT_SUPPORTUnsupported file format
40003SYSTEM_BUSYSystem busy, please retry later
40004RATE_LIMIT_EXCEEDEDRequest rate limit exceeded
40005SERVICE_UNAVAILABLEService temporarily unavailable

Business Data Errors (50000-59999)

CodeNameDescription
50001RESULT_DATA_NONEData not found
50002DATA_IS_WRONGData error
50003DATA_ALREADY_EXISTEDData already exists
50004AUTH_CODE_ERRORVerification code error
50005FILE_UPLOAD_ERRORFile upload failed
50006FILE_DOWNLOAD_ERRORFile download failed
50007FILE_DELETE_ERRORFile delete failed
50008FILE_NOT_EXISTFile does not exist
50009FILE_EMPTYFile is empty
50010FILE_RECORD_ERRORFile attestation failed
50011SHARE_CANCELLEDShare link has been cancelled
50012SHARE_EXPIREDShare has expired

Messaging Errors (60000-69999)

CodeNameDescription
60001MESSAGE_NOT_FOUNDMessage not found
60002CONVERSATION_NOT_FOUNDConversation not found
60003CANNOT_MESSAGE_SELFCannot send message to yourself
60004ANNOUNCEMENT_NOT_FOUNDAnnouncement not found
60005TICKET_NOT_FOUNDTicket not found
60006TICKET_ALREADY_CLOSEDTicket already closed
60007TICKET_NOT_OWNERNot authorized to operate this ticket
60008INVALID_TICKET_STATUSInvalid ticket status
60009ATTACHMENT_LIMIT_EXCEEDEDAttachment count exceeds limit

Friend System Errors (60010-60019)

CodeNameDescription
60010NOT_FRIENDSNot friends, cannot send message
60011FRIEND_REQUEST_EXISTSFriend request already sent, awaiting response
60012ALREADY_FRIENDSAlready friends
60013CANNOT_ADD_SELFCannot add yourself as friend
60014FRIEND_REQUEST_NOT_FOUNDFriend request not found
60015FRIEND_REQUEST_PROCESSEDFriend request already processed
60016FRIEND_SHARE_NOT_FOUNDFriend share not found
60017FRIEND_SHARE_UNAUTHORIZEDNot authorized to operate this friend share

Permission Errors (70000-79999)

CodeNameDescription
70001PERMISSION_UNAUTHENTICATEDLogin required
70002PERMISSION_UNAUTHORIZEDInsufficient permissions
70004PERMISSION_TOKEN_EXPIREDToken expired
70005PERMISSION_LIMITAccess count limited
70006PERMISSION_TOKEN_INVALIDInvalid token
70007PERMISSION_SIGNATURE_ERRORSignature verification failed

Error Response Format

All error responses follow this structure:

json
{
  "code": 50008,
  "message": "File does not exist",
  "data": null
}

Handling Errors

Retry-able Errors

The following errors are safe to retry with exponential backoff:

  • 30010 SERVICE_CIRCUIT_OPEN
  • 30011 SERVICE_TIMEOUT
  • 40003 SYSTEM_BUSY
  • 40004 RATE_LIMIT_EXCEEDED
  • 40005 SERVICE_UNAVAILABLE

Token Refresh

When receiving 70004 (TOKEN_EXPIRED), the client should:

  1. Call refresh token endpoint (if available)
  2. Or redirect to login page

Storage Degraded Mode

30014 (STORAGE_DEGRADED_WRITE) indicates the write succeeded but with fewer replicas than configured. The system will automatically sync when nodes recover. This is not a failure but a warning.

Released under the Apache 2.0 License.