---
title: "Returns stock data for the distribution centers (Verteilzentrum) about a product."
url: "https://developer.migros.ch/apis/products-related-8/versions/605be1d6-ffb8-4b27-8cd0-286a81eaec29/operations/get-stock-data-by-product"
---

> Full API specification: https://developer.migros.ch/apis/products-related-8/versions/605be1d6-ffb8-4b27-8cd0-286a81eaec29.md

# Returns stock data for the distribution centers (Verteilzentrum) about a product.

`GET` `/migros/products/v8/products/{id}/stock-data`

Operation ID: `get-stock-data-by-product`

Returns stock data for the distribution centers (Verteilzentrum) about a product.

## Path parameters

- `id` (string, required) - Product id for which to get stock data (slug not supported)

## Responses

- `200` - Returned when successful
- `404` - Returned when the requested resource could not be not found.

## OpenAPI definition

```yaml
openapi: 3.0.0
info:
  title: Products Related
  version: "8"
servers:
  - description: Public Kong Gateway URL
    url: https://api.migros.ch
paths:
  /migros/products/v8/products/{id}/stock-data:
    get:
      description: Returns stock data for the distribution centers (Verteilzentrum)
        about a product.
      operationId: get-stock-data-by-product
      parameters:
        - description: Product id for which to get stock data (slug not supported)
          in: path
          name: id
          required: true
          schema:
            type: string
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/StockData"
          description: Returned when successful
        "404":
          $ref: "#/components/responses/404"
      summary: Returns stock data for the distribution centers (Verteilzentrum) about
        a product.
      tags:
        - Products Related
security:
  - Kong-Api-Key: []
    basicAuth: []
components:
  schemas:
    StockData:
      description: Information about the stock in the distribution centers
        (Verteilzentrum) from SAP.
      properties:
        distribution_centers:
          items:
            $ref: "#/components/schemas/DistributionCenter"
          type: array
        product_id:
          description: |-
            Sum of the effective quantities over all inventories.

            Each EF value is floored before adding together.
          type: string
        total_quantity:
          type: integer
      required:
        - product_id
        - total_quantity
        - distribution_centers
      type: object
    DistributionCenter:
      properties:
        distribution_center_id:
          description: >-
            Limit how many items one customer may order (A).


            Mostly the same as the freely usable stock, except for specific
            products like new game consoles or face masks at the beginning of
            the pandemic.
          type: string
        per_customer:
          nullable: true
          type: integer
        present:
          nullable: true
          type: integer
        usable:
          nullable: true
          type: integer
      required:
        - distribution_center_id
      type: object
  responses:
    "404":
      description: Returned when the requested resource could not be not found.
  securitySchemes:
    Kong-Api-Key:
      description: Kong key-auth authentication
      in: header
      name: X-Api-Key
      type: apiKey
    basicAuth:
      scheme: basic
      type: http
```
