error object. The shape stays consistent across the API so your client can handle failures in a predictable way instead of writing endpoint-specific parsing logic for every error response.
Charge uses standard HTTP status codes to signal what kind of failure happened. In general, 4xx responses mean the request could not be completed as sent, while 5xx responses mean something unexpected happened on Charge’s side.
The most useful fields for debugging are usually type, code, message, and request. type tells you the broad category of failure, code identifies the specific condition when Charge has one, message is safe to show in logs and internal tooling, and request gives Charge support a concrete request to trace.
Endpoint reference pages may still call out especially relevant statuses or error codes when they matter for that operation, but they all use the same underlying error object described here.
Attributes
string | null
Short error code you can use to identify the error.Available options:
account_not_found, charging_session_conflict, charging_session_dependency_not_found, charging_session_not_found, charging_session_state_conflict, charging_station_not_found, driver_fleet_conflict, driver_not_found, driver_or_fleet_not_found, estimation_not_found, estimation_validation_error, fleet_not_found, invoice_finalize_invalid_state, invoice_not_found, invoice_payment_invalid_state, invoice_update_invalid_state, invoice_validation_error, invoice_void_invalid_state, owner_scope_invalid, payment_authorization_failed, payment_method_invalid_input, payment_method_not_found, payment_method_owner_not_found, payment_method_scope_invalid, payment_method_scope_not_found, policy_blocked, policy_not_found, rate_limit_exceeded, report_not_found, report_validation_error, reservation_cancel_invalid_state, reservation_invalid_input, reservation_invalid_state, reservation_not_found, reservation_update_invalid_state, transaction_not_found, unsupported_expand_value, vehicle_not_found, vehicle_owner_not_found, vehicle_telemetry_not_found, webhook_endpoint_not_foundstring
required
Human-readable description of the error.
string | null
Name of the request parameter that caused the error, if applicable.
string
required
Unique identifier for the request. Include this when contacting Charge support about a specific error.
integer
HTTP status code returned with the error.
string
required
Broad category of error.Available options:
invalid_request_error, authentication_error, rate_limit_error, api_error, idempotency_errorMore attributes
string
required
String representing the object’s type. Objects of the same type share the same value.
string | null
Link to the relevant section in the Charge API docs.

