{"templateId":"openapi_docs","sharedDataIds":{"openAPIDocsStore":"oas-index.yaml","sidebar":"sidebar-sidebars.yaml"},"props":{"definitionId":"index.yaml","dynamicMarkdocComponents":[],"baseSlug":"/","seo":{"title":"Manage PO Statuses","description":"**Goal:** move a Sortly purchase order to match where it has got to in your own\nprocess, whether that decision was made in another system or over email.\n\nEvery transition uses the same endpoint and the same two fields: the target `status` and\nthe `version` you got from your last read.\n\n- A stale `version` is rejected with `409`. Read immediately before writing, and retry\n  with the new one.\n- Sending a status the order already has changes nothing, so a retried delivery is\n  safe.\n\n| From | Can move to |\n|---|---|\n| `draft`, `ready_for_review`, `approved` | each other, or `ordered` |\n| `ordered` | `voided` or `closed` |\n| `partially_received`, `received` | `closed` |\n| `voided`, `closed` | final |\n\nAnything outside that returns `400`. `received` and `partially_received` cannot be\nrequested here at all: Sortly sets them when a delivery is recorded against the order,\neither in the app or through the receive endpoint.\n\n"},"itemId":"manage-po-statuses","disableAutoScroll":true,"metadata":{"subType":"openapi-operation"},"compilationErrors":[],"markdown":{"partials":{},"variables":{"rbac":{"teams":["anonymous"]},"user":{},"remoteAddr":{"hostname":"developer.sortly.com","port":4000,"ipAddress":"216.73.217.178"},"lang":"default_locale","env":{"PUBLIC_REDOCLY_BRANCH_NAME":"master"}}},"pagePropGetterError":{"message":"","name":""}},"slug":"/manage-po-statuses","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}