GET /v1/ecommerce/products/:id/stock
Read a product’s stock per variant: the master total, what is allocated to branches, and what is left in the warehouse.
GET
Stock de un producto por variante y sucursal
Returns where a product’s stock is. Each variant carries its master total, how much of it is allocated to branches, and how much is still in the warehouse.
Endpoint
Required scope
ecommerce:stock:read
Headers
Path parameters
Example request
Response
200 OK
401 Unauthorized
Missing, invalid, revoked, or expired token.403 Forbidden
The token does not have theecommerce:stock:read scope.
404 Not Found
No product with that id, or it belongs to a different company.502 Bad Gateway
ECOMMERCE_UPSTREAM_ERROR — the ecommerce service could not answer.
Operational notes
totalis the master stock. Branch quantities are a split of it, not an addition:allocatedis what sits in branches andwarehouse_availableis what is left.- The same shape comes back from writes. Adjusting or transferring stock responds with this body, so you do not need a follow-up read.
Stock de un producto por variante y sucursal