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

# Smart Adjust Inventory

> Dynamically routes inventory adjustment requests to synchronous or asynchronous processing based on payload size. Smaller payloads are generally processed synchronously and return immediate results. Larger payloads are processed asynchronously and return a job ID for tracking. The request schema is identical to the standard Adjust API. For more information, see the <a href="/pages/smart-inventory-apis">Smart Inventory APIs guide</a>.



## OpenAPI

````yaml /openapi/openapi_inventory.json post /commerce/inventory/v5/inventory/smart-adjust/
openapi: 3.0.0
info:
  description: |-
    <div id="overview_INVENTORY">
                <h2>INVENTORY</h2>
                <p>Use the Inventory API to retrieve the inventory levels of requested products, refresh and adjust current
                    stock levels at fulfillment locations, and tag segmented inventory for different channels. When using tags for inventory segmentation, inventory records are separated into categories to identify
                    which portions of its
                    total quantity are intended for different channels, customer groups, fulfillment methods, or other
                    needs.
                    This allows for setting a percentage of the quantity that would be available for each category and
                    setting discrete units at the location level as available for each category. For example, tags could
                    define how much of each
                    inventory record is set aside for a certain sales channel: the Kibo storefront, Walmart, or Amazon. The
                    percentages of the
                    inventory allotted for each channel would add up to 100% - the Kibo storefront could have 80% of the
                    inventory, Amazon 10%, and Walmart 10%. For more information, see the <a href="/developer-guides/inventory">Inventory guides</a>.</p>
                <p>Use the <strong>Inventory</strong>, <strong>Inventory Allocation</strong>, and <strong>Modify Inventory</strong> resources to retrieve and update inventory levels.</p>  
                <p>Use the <strong>Inventory Job</strong> resource to retrieve information about your pending inventory update processing jobs.</p> 
                <p>Use the <strong>Inventory Tag</strong> and <strong>Tag Category</strong> resources to segment your inventory records.</p> 
            </div>
  title: Inventory
  version: 0.0.1
servers:
  - description: Kibo Base URL
    url: '{baseUrl}/api'
    variables:
      baseUrl:
        default: https://t1000000.sb.usc1.gcp.kibocommerce.com
        description: Base URL
security:
  - bearerAuth: []
paths:
  /commerce/inventory/v5/inventory/smart-adjust/:
    post:
      tags:
        - ModifyInventory
      summary: Smart Adjust Inventory
      description: >-
        Dynamically routes inventory adjustment requests to synchronous or
        asynchronous processing based on payload size. Smaller payloads are
        generally processed synchronously and return immediate results. Larger
        payloads are processed asynchronously and return a job ID for tracking.
        The request schema is identical to the standard Adjust API. For more
        information, see the <a href="/pages/smart-inventory-apis">Smart
        Inventory APIs guide</a>.
      operationId: smartAdjustInventory
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AdjustRequest'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SmartInventoryResponse'
          description: Successful operation
components:
  schemas:
    AdjustRequest:
      description: Request needed for adjusting inventory
      properties:
        items:
          description: List of items to adjust
          items:
            $ref: '#/components/schemas/AdjustItem'
          maxItems: 1000
          minItems: 1
          nullable: false
          type: array
        locationCode:
          description: Location Code
          minLength: 1
          nullable: false
          title: location code
          type: string
        pageNum:
          description: which page to show
          type: integer
        pageSize:
          description: how many results to show per page
          type: integer
        sortBy:
          description: index to sort results by
          type: string
        userID:
          description: user id
          type: integer
      required:
        - items
        - locationCode
      title: Adjust Request
      type: object
    SmartInventoryResponse:
      description: >-
        Response from smart inventory endpoints indicating the processing method
        used
      properties:
        jobID:
          description: >-
            The job identifier for tracking asynchronous requests. This field is
            null for synchronous requests.
          nullable: true
          type: string
        method:
          description: >-
            The processing method used: 'sync' for synchronous processing or
            'async' for asynchronous processing. Kibo determines the routing
            based on payload size.
          enum:
            - sync
            - async
          type: string
      type: object
    AdjustItem:
      description: Adjust Item
      properties:
        binID:
          description: Bin Location Identifier
          type: integer
        condition:
          description: Describes the state of the product
          maxLength: 50
          minLength: 0
          type: string
        date:
          description: >-
            Used by the retailer for storing information related to
            manufacturing date or expiry date and use date to allocate for
            better stock management
          format: date-time
          type: string
        deliveryDate:
          description: >-
            Date at which this inventory will become available. Expected format
            '2020-09-28T12:00:00-0500'
          format: date-time
          type: string
        externalID:
          description: >-
            External Identifier for the given future inventory record. Will not
            create a new future inventory record unless deliveryDate is
            specified
          type: string
        granularInventoryTrackingEnabled:
          readOnly: true
          type: boolean
        lotCode:
          description: Track which lot a product is manufactured in
          maxLength: 50
          minLength: 0
          type: string
        partNumber:
          description: Part/Product Number
          type: string
        quantity:
          description: Current Quantity of Item
          nullable: false
          type: integer
        serialNumber:
          description: A serial number is unique to a specific, physical unit of inventory
          maxLength: 50
          minLength: 0
          type: string
        sku:
          description: Stock Keeping Unit
          type: string
        tags:
          $ref: '#/components/schemas/tags'
        upc:
          description: Universal Product Code
          type: string
      required:
        - quantity
      title: Adjust Item
      type: object
    tags:
      additionalProperties:
        type: string
      description: Associative Map of <String, String> for tagCategoryName => tagName
      type: object
  securitySchemes:
    bearerAuth:
      bearerFormat: JWT
      description: JWT Authorization header using the Bearer scheme.
      scheme: bearer
      type: http

````