> ## Documentation Index
> Fetch the complete documentation index at: https://docs.shipstream.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Replenishment Index Status

> Returns the rebuild lifecycle of the Warehouse's published Replenishment Index: the requested,
building, and published generations, whether the published generation satisfies the newest
request, and failure diagnostics.

Poll this endpoint until `generation_current` is `true` and `status` is `idle`, then read the
published report at `/v1/inventory/warehouses/{id}/replenishment-report` — its `meta` carries
the same `published_generation`, `generation_current`, and `generation_published_at` values.

A Warehouse that has never had a rebuild requested returns NULL `status` and NULL generations;
only an unknown Warehouse is `404`.



## OpenAPI

````yaml GET /v1/inventory/warehouses/{id}/replenishment-index/status
openapi: 3.0.3
info:
  title: ShipStream
  version: '1.0'
  license:
    name: Commercial (Copyright 2025 - All Rights Reserved)
    url: https://shipstream.io
  contact:
    name: ShipStream Support
    email: help@shipstream.io
  termsOfService: https://shipstream.io/legal/api-terms/
servers:
  - url: https://{base_url_domain}/api/global
    description: Direct API Url
    variables:
      base_url_domain:
        default: example.shipstream.app
        description: >-
          The fully qualified domain name for your ShipStream WMS instance. This
          is either a custom domain, or a subdomain of shipstream.app,

          and will be the same as the domain name for the page which you use to
          login to ShipStream WMS.
security:
  - ShipStream_bearerAuth: []
tags:
  - name: Warehouses
    x-displayName: Warehouses
  - name: Products
    x-displayName: Products
  - name: ProductProfiles
    x-displayName: ProductProfiles
  - name: HandlingClasses
    x-displayName: HandlingClasses
  - name: Locations
    x-displayName: Locations
  - name: LocationTags
    x-displayName: LocationTags
  - name: SlotTypes
    x-displayName: SlotTypes
  - name: Levels
    x-displayName: Levels
  - name: HoldReasons
    x-displayName: HoldReasons
  - name: Holds
    x-displayName: Holds
  - name: Replenishment
    x-displayName: Replenishment
  - name: LocationProfiles
    x-displayName: LocationProfiles
  - name: SlottingRules
    x-displayName: SlottingRules
  - name: Deliveries
    description: Every thing about a Delivery Receiving
    x-displayName: Deliveries
  - name: Shipments
    x-displayName: Shipments
  - name: Orders
    x-displayName: Orders
  - name: Retailers
    x-displayName: Retailers
  - name: Users
    x-displayName: Users
  - name: User Roles
    x-displayName: User Roles
  - name: Merchants
    x-displayName: Merchants
  - name: Healthcheck
    x-displayName: Healthcheck
paths:
  /v1/inventory/warehouses/{id}/replenishment-index/status:
    get:
      tags:
        - Replenishment
      summary: Get Replenishment Index Status
      description: >-
        Returns the rebuild lifecycle of the Warehouse's published Replenishment
        Index: the requested,

        building, and published generations, whether the published generation
        satisfies the newest

        request, and failure diagnostics.


        Poll this endpoint until `generation_current` is `true` and `status` is
        `idle`, then read the

        published report at `/v1/inventory/warehouses/{id}/replenishment-report`
        — its `meta` carries

        the same `published_generation`, `generation_current`, and
        `generation_published_at` values.


        A Warehouse that has never had a rebuild requested returns NULL `status`
        and NULL generations;

        only an unknown Warehouse is `404`.
      operationId: getReplenishmentIndexStatus
      parameters:
        - name: id
          in: path
          schema:
            type: integer
            format: int32
          required: true
          description: The `id` of the referenced `Warehouse`.
      responses:
        '200':
          description: The Warehouse's current Replenishment Index rebuild status.
          content:
            application/json:
              schema:
                type: object
                properties:
                  resource:
                    $ref: >-
                      #/components/schemas/Inventory_API_v1_ReplenishmentIndexStatus
              example:
                resource:
                  type: ReplenishmentIndexStatus
                  id: 1
                  status: idle
                  requested_generation: 5
                  building_generation: null
                  published_generation: 5
                  generation_current: true
                  generation_published_at: '2026-08-01T10:00:00Z'
                  requested_at: null
                  started_at: '2026-08-01T09:31:00Z'
                  updated_at: '2026-08-01T10:00:00Z'
                  attempt_count: 1
                  last_error: null
        '400':
          $ref: '#/components/responses/Inventory_API_v1_400-bad-request'
        '404':
          $ref: '#/components/responses/Inventory_API_v1_404-not-found'
        '500':
          $ref: '#/components/responses/Inventory_API_v1_500-internal-server-error'
components:
  schemas:
    Inventory_API_v1_ReplenishmentIndexStatus:
      title: ReplenishmentIndexStatus
      type: object
      description: >-
        Rebuild lifecycle of one Warehouse's published Replenishment Index. A
        Warehouse that has never had a rebuild requested reads as NULL `status`
        and NULL generations, whether or not internal bookkeeping has already
        created a state row for it.
      properties:
        type:
          type: string
          enum:
            - ReplenishmentIndexStatus
        id:
          type: integer
          format: int32
          minimum: 1
          description: Warehouse ID.
        status:
          type: string
          nullable: true
          enum:
            - idle
            - building
            - superseded
            - failed
            - null
          description: >-
            Durable rebuild lifecycle state. `idle` when no build is running,
            `building` while a generation is being computed, `superseded` after
            a `force` rebuild invalidated the running build (it stops without
            publishing and the fresh generation takes over), `failed` after the
            latest completed attempt failed — `failed` and `last_error` describe
            that attempt, and a pending successor may already be queued. A
            `requested_generation` greater than `building_generation` means a
            newer generation is pending regardless of status. A Warehouse that
            stays `failed` is retried server-side with operator alerting. NULL
            when no rebuild was ever requested.
        requested_generation:
          type: integer
          format: int64
          nullable: true
          description: >-
            Newest generation requested for complete recalculation, or NULL when
            none was ever requested.
        building_generation:
          type: integer
          format: int64
          nullable: true
          description: >-
            Generation currently being computed, or NULL when no build is in
            progress. Non-NULL only while `status` is `building`, `superseded`,
            or `failed`; while `failed` it identifies the generation whose
            attempt failed.
        published_generation:
          type: integer
          format: int64
          nullable: true
          description: >-
            Generation currently visible in the published Replenishment Report,
            or NULL when nothing has been published yet. The same value appears
            in the report's `meta.published_generation`.
        generation_current:
          type: boolean
          nullable: true
          description: >-
            Whether the published generation satisfies the newest rebuild
            request. NULL when no rebuild was ever requested. The same value
            appears in the report's `meta.generation_current`.
        generation_published_at:
          type: string
          format: date-time
          nullable: true
          description: >-
            Time the published generation was completed, or NULL when nothing
            has been published.
        requested_at:
          type: string
          format: date-time
          nullable: true
          description: >-
            Time the currently pending, not-yet-claimed generation was first
            requested. NULL while a build is running or when nothing is pending.
        started_at:
          type: string
          format: date-time
          nullable: true
          description: Start time of the latest rebuild attempt.
        updated_at:
          type: string
          format: date-time
          nullable: true
          description: Last rebuild progress, heartbeat, or lifecycle-state change time.
        attempt_count:
          type: integer
          format: int32
          minimum: 0
          description: >-
            Attempts recorded for the generation currently being built or last
            attempted — reset when a new generation is claimed and incremented
            on same-generation retries. Zero for a Warehouse that never built.
        last_error:
          type: string
          nullable: true
          description: >-
            Classified summary of the latest rebuild failure — one of a small
            set of fixed messages, not the raw diagnostic (which stays in the
            server log) — or NULL when the latest attempt succeeded.
      required:
        - type
        - id
        - status
        - requested_generation
        - building_generation
        - published_generation
        - generation_current
        - generation_published_at
        - requested_at
        - started_at
        - updated_at
        - attempt_count
        - last_error
      additionalProperties: false
      example:
        type: ReplenishmentIndexStatus
        id: 1
        status: idle
        requested_generation: 5
        building_generation: null
        published_generation: 5
        generation_current: true
        generation_published_at: '2026-08-01T10:00:00Z'
        requested_at: null
        started_at: '2026-08-01T09:31:00Z'
        updated_at: '2026-08-01T10:00:00Z'
        attempt_count: 1
        last_error: null
  responses:
    Inventory_API_v1_400-bad-request:
      description: >-
        The request was invalid. The client must change the request. See the
        response body for more details.
      content:
        application/json:
          schema:
            type: object
            properties:
              errors:
                type: array
                items:
                  type: object
                  properties:
                    type:
                      type: string
                      description: The error type code.
                      enum:
                        - parser
                        - parameters
                        - openapi
                    message:
                      type: string
                      description: An English sentence describing the error type.
                    details:
                      type: array
                      description: >-
                        An array of objects describing which keys are
                        responsible for the error and detailed messages
                        describing why they are not valid.
                      items:
                        type: object
                        properties:
                          key:
                            type: string
                            description: The path to the key which relates to the error.
                          message:
                            type: string
                            description: >-
                              An English sentence describing the details of the
                              error.
                        additionalProperties: false
                  additionalProperties: false
                minItems: 1
            additionalProperties: false
          example:
            errors:
              - type: parameters
                message: The supplied parameters are invalid.
    Inventory_API_v1_404-not-found:
      description: >-
        The requested resource was not found. It may have been deleted, it may
        have never existed, or you may not have permission to view it.
      content:
        application/json:
          schema:
            type: object
            properties:
              errors:
                type: array
                items:
                  type: object
                  properties:
                    type:
                      type: string
                      description: The error type code.
                      enum:
                        - not_found
                    message:
                      type: string
                      description: An English sentence describing the error type.
                    details:
                      type: array
                      description: >-
                        An array of objects describing which keys are
                        responsible for the error and detailed messages
                        describing why they are not valid.
                      items:
                        type: object
                        properties:
                          key:
                            type: string
                            description: The path to the key which relates to the error.
                          message:
                            type: string
                            description: >-
                              An English sentence describing the details of the
                              error.
                        additionalProperties: false
                  additionalProperties: false
                minItems: 1
            additionalProperties: false
          example:
            errors:
              - type: not_found
                message: The server could not find the requested resource.
    Inventory_API_v1_500-internal-server-error:
      description: >-
        Internal Server Error - Something wrong happened at server side. Contact
        server administrator for more details.
  securitySchemes:
    ShipStream_bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        Generate a JWT access token through a Custom Global Integration and
        provide it with each request in the `Authorization` header prefixed with
        "Bearer" and then a single space.

````