Skip to navigation

Errors & codes

Errors & codes

Response format

Success

{
"statusCode": 200,
"data": {},
"message": "Success",
"success": true
}

Error

{
"statusCode": 400,
"success": false,
"message": "Validation error.",
"errors": {
"code": "VALIDATION_ERROR",
"details": "..."
}
}

HTTP statuses

HTTPMeaning
200Success
201Order created
400Validation or business rule error
401Missing or invalid x-api-key
404Ride not found
500Server error

Business codes

CodeEndpointMeaning
FARE_CALCULATEDFare estimateFare quotes returned
RIDE_CREATEDCreate orderOrder created
USER_HAVE_ACTIVE_RIDECreate orderRider already has an active ride
WEBHOOK_REQUIREDCreate orderwebhookURL was not provided
VALIDATION_ERRORAnyInvalid request body
RIDE_CANCELLEDCancelRide cancelled
RIDE_NOT_FOUNDCancel / feedbackUnknown orderId
RIDE_NOT_CANCELLABLECancelRide cannot be cancelled in its current state
FEEDBACK_SUBMITTEDFeedbackFeedback saved
SERVER_ERRORAnyUnexpected failure

Active ride rule

A rider can have only one active ride at a time. Create order returns USER_HAVE_ACTIVE_RIDE when an active ride already exists.