> For the complete documentation index, see [llms.txt](https://docs.flowretail.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.flowretail.com/docs/developers/api-documentation/service-shipment/update-service-shipment.md).

# Update service shipment

Update service shipment. For receiver, either a store or an external workshop must be set (by its UID). Setting an item's receivedDate when the receiver is a store other than the one that owns the service order moves that service order to the receiving store, through the same mechanism as the service order move endpoint and with the same effects: the owning storeUid changes, createdFromStoreUid is left alone, the assignment ends, one MOVED event records the move and the ended assignment, and the receiving store's service staff are notified. A service order already at the receiving store is left where it is, and a service order in a terminal state is not moved by a receive — the receipt is still recorded. A receive is keyed on the item's receivedDate alone, whatever the shipment's status. It is judged by this operation's own permission alone, which on a path carrying no store means SERVICE\_ORDER anywhere in the tenant; unlike the service order move endpoint, which is judged at the store the service order is leaving, the move a receive causes requires no permission at either store.

Required permissions: SERVICE\_ORDER

```json
{"openapi":"3.0.2","info":{"title":"Flow Retail API version 2","version":"2.0.0"},"tags":[{"name":"ServiceShipment","description":"ServiceShipment"}],"servers":[{"description":"Flow Retail Production","url":"https://api.flowretail.com/v2"},{"description":"Flow Retail Stage","url":"https://api.stage.flowretail.com/v2"}],"security":[{"accessToken":[]},{"authToken":[]},{"integrationToken":[]}],"components":{"securitySchemes":{"accessToken":{"description":"Access token recevied after user login with a deviceToken","scheme":"bearer","type":"http"},"authToken":{"description":"Token received from the auth service","scheme":"bearer","type":"http"},"integrationToken":{"scheme":"bearer","type":"http"}},"responses":{"ServiceShipmentResponse":{"description":"Example response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceShipmentResponseSchema"}}}}},"schemas":{"ServiceShipmentResponseSchema":{"title":"ServiceShipmentResponseSchema","type":"object","properties":{"serviceShipmentUid":{"$ref":"#/components/schemas/UID"},"sender":{"$ref":"#/components/schemas/ServiceShipmentSenderSchema"},"receiver":{"$ref":"#/components/schemas/ServiceShipmentReceiverResponseSchema"},"status":{"$ref":"#/components/schemas/ServiceShipmentStatusENUM"},"note":{"type":"string"},"trackingNumber":{"type":"string"},"shipmentNumber":{"type":"string"},"items":{"type":"array","items":{"$ref":"#/components/schemas/ServiceShipmentItemResponseSchema"}},"createdBy":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"lastModifiedBy":{"type":"string"},"lastModifiedAt":{"type":"string","format":"date-time"},"shipmentDate":{"type":"string","format":"date-time"},"allReceived":{"type":"boolean"}},"required":["serviceShipmentUid","sender","receiver","status","note","trackingNumber","shipmentNumber","items","createdBy","createdAt","lastModifiedBy","lastModifiedAt","shipmentDate","allReceived"]},"UID":{"title":"UID","type":"string","pattern":"^[A-Za-z0-9-_]+"},"ServiceShipmentSenderSchema":{"title":"ServiceShipmentSenderSchema","type":"object","properties":{"storeUid":{"$ref":"#/components/schemas/UID"}},"required":["storeUid"]},"ServiceShipmentReceiverResponseSchema":{"title":"ServiceShipmentReceiverSchema","type":"object","properties":{"storeUid":{"$ref":"#/components/schemas/UID"},"externalWorkshopUid":{"$ref":"#/components/schemas/UID"}},"required":["storeUid","externalWorkshopUid"]},"ServiceShipmentStatusENUM":{"title":"ServiceShipmentStatusENUM","description":"Where a service shipment stands.\nNOT_SENT: the shipment is registered but has not left the sender. IN_TRANSIT: it is on its way. RECEIVED: it has arrived at the receiver.\nA shipment never drives the state of the service orders it carries: the state IN_TRANSIT is set by ordinary status changes on the service order. The store that owns a service order changes through the move mechanism alone — the move endpoint, or the receipt of a shipment item at a store other than the one that owns it, which goes through that same mechanism.","type":"string","enum":["NOT_SENT","IN_TRANSIT","RECEIVED"]},"ServiceShipmentItemResponseSchema":{"title":"ServiceShipmentItemResponseSchema","type":"object","properties":{"serviceOrderUid":{"$ref":"#/components/schemas/UID"},"receivedDate":{"type":"string","format":"date-time"},"createdAt":{"type":"string","format":"date-time"},"createdBy":{"type":"string"},"lastModifiedAt":{"type":"string","format":"date-time"},"lastModifiedBy":{"type":"string"}},"required":["serviceOrderUid","receivedDate","createdAt","createdBy","lastModifiedAt","lastModifiedBy"]},"ServiceShipmentUpdateSchema":{"title":"ServiceShipmentUpdateSchema","type":"object","properties":{"sender":{"$ref":"#/components/schemas/ServiceShipmentSenderSchema"},"receiver":{"$ref":"#/components/schemas/ServiceShipmentReceiverUpdateSchema"},"note":{"type":"string"},"status":{"$ref":"#/components/schemas/ServiceShipmentStatusENUM"},"trackingNumber":{"type":"string"},"shipmentNumber":{"type":"string"},"shipmentDate":{"type":"string","format":"date-time"},"items":{"type":"array","items":{"$ref":"#/components/schemas/ServiceShipmentItemUpdateSchema"}}},"required":["sender","receiver"]},"ServiceShipmentReceiverUpdateSchema":{"title":"ServiceShipmentReceiverUpdateSchema","description":"Where the shipment is going: either a store of the tenant or an external workshop, one of the two. When an item of the shipment is received on the shipment update and this receiver is a store other than the one that owns the service order, that service order is moved to this store.","type":"object","properties":{"storeUid":{"$ref":"#/components/schemas/OptionalUID"},"externalWorkshopUid":{"$ref":"#/components/schemas/OptionalUID"}}},"OptionalUID":{"title":"OptionalUID","type":"string","pattern":"^[A-Za-z0-9-_]*"},"ServiceShipmentItemUpdateSchema":{"title":"ServiceShipmentItemUpdateSchema","type":"object","properties":{"serviceOrderUid":{"$ref":"#/components/schemas/UID"},"receivedDate":{"type":"string","format":"date-time","description":"When the shipment item was received. Setting it on the shipment update, when the shipment's receiver is a store other than the one that owns the service order, moves that service order to the receiving store, with the effects the service order move endpoint has; the shipment create never moves a service order, whatever it carries."}},"required":["serviceOrderUid"]}},"requestBodies":{"ServiceShipmentUpdateRequest":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceShipmentUpdateSchema"}}}}}},"paths":{"/tenants/{tenantUid}/serviceorders/shipments/{serviceShipmentUid}":{"put":{"summary":"Update service shipment","operationId":"put-service-shipment","responses":{"200":{"$ref":"#/components/responses/ServiceShipmentResponse"}},"description":"Update service shipment. For receiver, either a store or an external workshop must be set (by its UID).\nSetting an item's receivedDate when the receiver is a store other than the one that owns the service order moves that service order to the receiving store, through the same mechanism as the service order move endpoint and with the same effects: the owning storeUid changes, createdFromStoreUid is left alone, the assignment ends, one MOVED event records the move and the ended assignment, and the receiving store's service staff are notified. A service order already at the receiving store is left where it is, and a service order in a terminal state is not moved by a receive — the receipt is still recorded.\nA receive is keyed on the item's receivedDate alone, whatever the shipment's status. It is judged by this operation's own permission alone, which on a path carrying no store means SERVICE_ORDER anywhere in the tenant; unlike the service order move endpoint, which is judged at the store the service order is leaving, the move a receive causes requires no permission at either store.\n\nRequired permissions: SERVICE_ORDER","requestBody":{"$ref":"#/components/requestBodies/ServiceShipmentUpdateRequest"},"tags":["ServiceShipment"]}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.flowretail.com/docs/developers/api-documentation/service-shipment/update-service-shipment.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
