Sales Orders
Create, read, update and delete customer sales orders (pedidos de cliente)
📄️ Get sales order by ID
Returns a single customer sales order by its primary key, including line items and payments. Listing (`GET` without id) returns headers only. The response carries a strong `ETag` header with the current version.
📄️ Update sales order
Full replacement of an existing customer sales order. Send the `If-Match` header with the current ETag for optimistic concurrency control.
📄️ Delete sales order
Deletes a customer sales order. Send the `If-Match` header with the current ETag for optimistic concurrency control.
📄️ Merge-patch sales order
RFC 7396 merge-patch over `application/merge-patch+json`. Send only the fields you want to change; include a field with value `null` to remove it. Use the `If-Match` header for optimistic concurrency control.
📄️ List sales orders
Returns a paginated list of customer sales orders with envelope `{data, totalCount, skip, limit, hasMore}`. Supports optional RSQL `filter`, `sort` (default `lastModifiedAt:desc`), `skip`/`limit` pagination and `modifiedAfter`/`modifiedBefore` bookends. Limit is capped at 200; skip is clamped to >= 0.
📄️ Create sales order
Creates a new customer sales order with the provided data and optional line items and payments. Business logic runs in the legacy WAR via the internal commands gateway.