univoozAPI
Errors

invalid_status_transition

The order cannot move to that status from its current status.

HTTP 422invalid_request_error

The test endpoint returns this error when you give a status that is not possible now.

Why it happens

The sequence moves forward only:

created → assigned → accepted → arrived_for_pickup → picked_up → arrived_for_delivery → delivered
  • You gave a status that is more than one step forward.
  • You gave an earlier status. An order does not go back.
  • You gave cancelled after picked_up. The cancellation rules also apply in test mode.

Why. Test mode uses the same rules as the dashboard. A test mode that permits more than production teaches you the wrong behaviour.

How to fix it

Move one step at a time. Send no body:

curl -X POST https://api.univooz.com/v1/test/orders/ORD-260729-LD4Q/advance \
  -H "Authorization: Bearer uv_test_YOUR_KEY"

Univooz then moves the order along created → accepted → arrived_for_pickup → picked_up → arrived_for_delivery → delivered.

Read status from each response.

Example response

{
  "error": {
    "type": "invalid_request_error",
    "code": "invalid_status_transition",
    "message": "Cannot move from 'created' to 'delivered'.",
    "param": "status",
    "doc_url": "https://docs.univooz.com/errors/invalid_status_transition",
    "request_id": "req_01KZCCF8ZH4M7XQ2VB9RSTNPKD"
  }
}

On this page