Skip to content

Error codes ​

Each failure has a stable code. Your code tests the code, and your app writes its own text for the member.

The SDK ​

A failed call gives your app an error with three fields.

FieldMeaning
codeA stable code. Test this field.
messageAn English text for a developer. Do not show it to a member.
retryabletrue when a new attempt with a new grant can work.
  • Each new attempt needs a new grant from your server.
  • A later version of the SDK can add a code. For a code that your app does not know, go by retryable.

retryable is false for eight codes: BLUETOOTH_UNAUTHORIZED, BLUETOOTH_UNSUPPORTED, PERMISSION_DENIED, NO_GATT_MATCH, CREDENTIAL_REJECTED, RENTAL_NOT_ACTIVE, SDK_TOO_OLD and INVALID_ARGUMENT. It is true for every other code.

The phone ​

CodeMeaningWhat your app does
BLUETOOTH_OFFBluetooth is off.Ask the member to turn Bluetooth on.
BLUETOOTH_UNAUTHORIZEDThe member blocked Bluetooth for your app.Send the member to the settings of your app.
BLUETOOTH_UNSUPPORTEDThe phone has no Bluetooth Low Energy.Send the member to your staff.
PERMISSION_DENIEDA permission is missing.Ask for the permission again, or send the member to the settings of your app.

The way to the lock ​

CodeMeaningWhat your app does
DEVICE_NOT_FOUNDThe lock is not in range.Ask the member to stand at the locker, and try again.
CONNECT_TIMEOUT, CONNECT_FAILEDThe phone could not connect to the lock.Try again.
CONNECTION_LOST, NOT_CONNECTEDThe link to the lock dropped.Try again.
RESPONSE_TIMEOUTThe lock did not answer.Try again.
WRONG_LOCKThe phone reached another lock than the one of the grant.Try again.
NO_GATT_MATCHThe device that the phone reached is not a Clevibox lock.Send the member to your staff.

The lock ​

CodeMeaningWhat your app does
ASK_FAILED, BAD_FRAME, CHECKSUMThe lock refused a command, or its answer was damaged.Try again.
CREDENTIAL_REQUIREDThe lock asked for its credential again.Try again.
CREDENTIAL_REJECTEDThe lock rejected its credential.Send the member to your staff, and tell Clevibox.

The grant ​

CodeMeaningWhat your app does
GRANT_INVALIDThe grant is unknown, or it was used before.Get a new grant, and try again.
GRANT_EXPIREDThe grant is older than 2 minutes.Get a new grant, and try again.
RENTAL_NOT_ACTIVEThe rental has ended.Show that the rental is over.

Clevibox ​

CodeMeaningWhat your app does
NETWORK_UNAVAILABLEThe phone cannot reach Clevibox.Ask the member to check the connection. See Site requirements.
SERVER_ERRORClevibox failed.Try again after a moment.
SDK_TOO_OLDThis version of the SDK is too old.Ask the member to update your app. Release your app with a new SDK.

Your code ​

CodeMeaningWhat your app does
OPERATION_IN_PROGRESSAnother call runs.Wait for the result of that call. Lock your Open button while a call runs.
INVALID_ARGUMENTThe call has a wrong argument, for example an empty grant.Correct your code.
CANCELLEDYour app cancelled the call. readStatus reports a cancel with this code.Nothing.
INTERNAL_ERRORThe SDK itself failed.Try again, and tell Clevibox the message.

The integration API ​

A failed request gets an HTTP status of 400 or more, and a body with error, message and sometimes details. See Errors in the API reference.

StatuserrorMeaningWhat your server does
400validation_errorA field is wrong. details.field names it.Correct the request.
400invalid_idAn ID in the address is not a UUID.Correct the request.
401invalid_api_keyThe key is missing, unknown or revoked.Check the key and its header.
403not_members_rentalThis member does not hold this rental.Check where your server takes the member ID from.
404club_not_found, compartment_not_found, rental_not_foundNothing with this ID exists for your key. A test key gets this answer for a live club, and a live key for a test club.Check the ID and the key.
409compartment_unavailableAnother member holds this compartment.Show the compartments again.
409compartment_out_of_serviceThe compartment is out of service.Show the compartments again.
409member_has_active_rentalThe member holds another compartment. details has its rental_id and compartment_id.Show that compartment to the member.
409rental_not_activeThe rental has ended.Show that the rental is over.
429rate_limitedToo many requests for this key.Wait for the seconds in the header Retry-After, and send the request again.

A status of 500 or more means that Clevibox failed. Wait a moment, and send the request again.