> 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/warehouse/search-in-stock-logs-for-product-in-specified-warehouse.md).

# Search in stock logs for product in specified warehouse

Returns stock logs for a particular product in the specified warehouse.

Required permissions: WAREHOUSE\_HISTORY

```json
{"openapi":"3.0.2","info":{"title":"Flow Retail API version 2","version":"2.0.0"},"tags":[{"name":"Warehouse","description":"Warehouse"}],"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"}},"parameters":{"pageNumberQuery":{"description":"Reference to a specific page in a result set.","in":"query","name":"pageNumber","required":false,"schema":{"type":"integer"}},"pageSizeQuery":{"description":"The number of items per page in a result set.","in":"query","name":"pageSize","required":false,"schema":{"type":"integer"}}},"requestBodies":{"StockLogSearchRequest":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLogSearchRequestSchema"}}}}},"schemas":{"StockLogSearchRequestSchema":{"properties":{"fromDateTime":{"format":"date-time","type":"string"},"serialnumber":{"type":"string"},"tenantUserUid":{"$ref":"#/components/schemas/UID"},"toDateTime":{"format":"date-time","type":"string"}},"title":"StockLogSearchRequestSchema","type":"object"},"UID":{"title":"UID","type":"string","pattern":"^[A-Za-z0-9-_]+"},"StockLogResponseSchema":{"description":"Log data for a product's stock movements. Sorted by timestamp, descending","title":"StockLogResponseSchema","type":"object","required":["costDelta","costNew","costOrigin","costTransaction","createdAt","quantityDelta","quantityNew","quantityNotAvailable","quantityOrigin","reference","serialnumber","tenantUserUid","tenantUserName","transactionType","saleCostPrice","referenceDetails"],"properties":{"costDelta":{"type":"integer","description":"Average cost price delta"},"costNew":{"type":"integer","description":"Average cost price after the transaction"},"costOrigin":{"type":"integer","description":"Average cost price before the transaction"},"costTransaction":{"type":"integer","description":"The cost of the current transaction"},"createdAt":{"format":"date-time","type":"string"},"quantityDelta":{"type":"integer"},"quantityNew":{"type":"integer"},"quantityNotAvailable":{"type":"integer"},"quantityOrigin":{"type":"integer"},"reference":{"type":"integer"},"referenceDetails":{"$ref":"#/components/schemas/StockLogReferenceSchema"},"serialnumber":{"type":"string"},"tenantUserUid":{"$ref":"#/components/schemas/UID"},"tenantUserName":{"type":"string"},"transactionType":{"$ref":"#/components/schemas/TransactionTypeENUM"},"saleCostPrice":{"type":"integer"}}},"StockLogReferenceSchema":{"title":"StockLogReferenceSchema","type":"object","required":["salesOrder","rmaOrder","stocktaking","internalPurchaseOrder","serviceOrder","receivement","responseType"],"properties":{"salesOrder":{"$ref":"#/components/schemas/StockLogSalesOrderReferenceSchema"},"rmaOrder":{"$ref":"#/components/schemas/StockLogRmaOrderReferenceSchema"},"stocktaking":{"$ref":"#/components/schemas/StockLogStocktakingReferenceSchema"},"internalPurchaseOrder":{"$ref":"#/components/schemas/StockLogInternalPurchaseOrderReferenceSchema"},"serviceOrder":{"$ref":"#/components/schemas/StockLogServiceOrderReferenceSchema"},"receivement":{"$ref":"#/components/schemas/StockLogReceivementReferenceSchema"},"responseType":{"type":"string","enum":["salesOrder","rmaOrder","stocktaking","internalPurchaseOrder","serviceOrder","receivement","noReference"]}}},"StockLogSalesOrderReferenceSchema":{"title":"StockLogSalesOrderReferenceSchema","type":"object","nullable":true,"required":["orderNumber","orderUid","storeUid","orderItemUid"],"properties":{"orderNumber":{"type":"string"},"orderUid":{"$ref":"#/components/schemas/UID"},"storeUid":{"$ref":"#/components/schemas/UID"},"orderItemUid":{"$ref":"#/components/schemas/UID"}}},"StockLogRmaOrderReferenceSchema":{"title":"StockLogRmaOrderReferenceSchema","type":"object","nullable":true,"required":["rmaNumber","storeUid","rmaOrderUid","rmaOrderItemUid"],"properties":{"rmaNumber":{"type":"string"},"storeUid":{"$ref":"#/components/schemas/UID"},"rmaOrderUid":{"$ref":"#/components/schemas/UID"},"rmaOrderItemUid":{"$ref":"#/components/schemas/UID"}}},"StockLogStocktakingReferenceSchema":{"title":"StockLogStocktakingReferenceSchema","type":"object","nullable":true,"required":["name","storeUid","stocktakingUid","stocktakingItemUid"],"properties":{"name":{"type":"string"},"storeUid":{"$ref":"#/components/schemas/UID"},"stocktakingUid":{"$ref":"#/components/schemas/UID"},"stocktakingItemUid":{"$ref":"#/components/schemas/UID"}}},"StockLogInternalPurchaseOrderReferenceSchema":{"title":"StockLogInternalPurchaseOrderReferenceSchema","type":"object","nullable":true,"required":["internalPurchaseNumber","storeUid","internalPurchaseOrderUid","internalPurchaseOrderItemUid"],"properties":{"internalPurchaseNumber":{"type":"string"},"storeUid":{"$ref":"#/components/schemas/UID"},"internalPurchaseOrderUid":{"$ref":"#/components/schemas/UID"},"internalPurchaseOrderItemUid":{"$ref":"#/components/schemas/UID"}}},"StockLogServiceOrderReferenceSchema":{"title":"StockLogServiceOrderReferenceSchema","type":"object","nullable":true,"required":["serviceOrderNumber","storeUid","serviceOrderUid","serviceOrderItemUid"],"properties":{"serviceOrderNumber":{"type":"string"},"storeUid":{"$ref":"#/components/schemas/UID"},"serviceOrderUid":{"$ref":"#/components/schemas/UID"},"serviceOrderItemUid":{"$ref":"#/components/schemas/UID"}}},"StockLogReceivementReferenceSchema":{"title":"StockLogReceivementReferenceSchema","type":"object","nullable":true,"required":["purchaseNumber","storeUid","purchaseOrderUid","purchaseOrderItemUid","receivementUid","receivementItemUid"],"properties":{"purchaseNumber":{"type":"string"},"storeUid":{"$ref":"#/components/schemas/UID"},"purchaseOrderUid":{"$ref":"#/components/schemas/UID"},"purchaseOrderItemUid":{"$ref":"#/components/schemas/UID"},"receivementUid":{"$ref":"#/components/schemas/UID"},"receivementItemUid":{"$ref":"#/components/schemas/UID"}}},"TransactionTypeENUM":{"description":"|ENUM      | Description |\n| ---------------- | ------------ |\n| RECEIVE | Receive (Purchase)|\n| DELIVERY | Deliver ( Sales)|\n| MOVE | Move between depts|\n| RETURN | Return of items|\n| INVENTORY_CONTROL | Inventory Control|\n| INTERNAL | Theft / Internal use|\n| SET_STOCK | Set stock|\n| ADJUST_STOCK | Adjust stock|\n| ADJUST_COST | Adjust cost|\n| RMA_ORDER | RMA Order|\n","enum":["RECEIVE","DELIVERY","MOVE","RETURN","INVENTORY_CONTROL","INTERNAL","SET_STOCK","ADJUST_STOCK","ADJUST_COST","RMA_ORDER"],"title":"TransactionTypeENUM","type":"string"},"Paging":{"description":"totalCount The total number of items in the result set.\n\npageSize The number of items per page.\n\npageNumber The current page in the result set.","properties":{"pageNumber":{"type":"integer"},"pageSize":{"type":"integer"},"totalCount":{"type":"integer"}},"required":["totalCount","pageSize","pageNumber"],"title":"Paging","type":"object"}},"responses":{"StockLogListResponse":{"content":{"application/json":{"schema":{"properties":{"items":{"items":{"$ref":"#/components/schemas/StockLogResponseSchema"},"type":"array"},"paging":{"$ref":"#/components/schemas/Paging"}},"required":["items","paging"],"type":"object"}}},"description":"Example response"}}},"paths":{"/tenants/{tenantUid}/stores/{storeUid}/warehouses/{warehouseUid}/stock/{productUid}/logs/search":{"post":{"description":"Returns stock logs for a particular product in the specified warehouse.\n\nRequired permissions: WAREHOUSE_HISTORY","operationId":"post-tenants-stores-warehouses-stock-search-logs","parameters":[{"$ref":"#/components/parameters/pageNumberQuery"},{"$ref":"#/components/parameters/pageSizeQuery"}],"requestBody":{"$ref":"#/components/requestBodies/StockLogSearchRequest"},"responses":{"200":{"$ref":"#/components/responses/StockLogListResponse"}},"summary":"Search in stock logs for product in specified warehouse","tags":["Warehouse"]}}}}
```


---

# 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/warehouse/search-in-stock-logs-for-product-in-specified-warehouse.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.
