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

# Create a new inventory level configuration for a SKU at a warehouse

> Creates an inventory level configuration that defines the minimum and maximum stock thresholds for a specific SKU at a specific warehouse. Optionally scoped to a region. Returns 409 if a level already exists for the same SKU + warehouse + region combination.



## OpenAPI

````yaml /openapi.json post /api/v1/inventory-levels
openapi: 3.1.0
info:
  title: Firstbase API Specification Beta
  description: Integration endpoints for Firstbase
  version: 0.1.0
servers:
  - url: /
    description: Default
security:
  - ApiKey: []
tags:
  - name: Inventory Orders
    description: Create and manage inventory orders
  - name: Shipment Notices V1
    description: 'Query shipment notice orders (V1: package items expose `inventories` list)'
  - name: Packages
    description: ''
  - name: Categories
    description: Query available categories for asset creation
  - name: Catalog
    description: ''
  - name: New Joiners
    description: New joiner provisioning pipeline for the organization
  - name: Orders
    description: ''
  - name: People
    description: >-
      Manage the users of Firstbase for your organization. API follows the SCIM
      standard.
    externalDocs:
      url: https://scim.cloud/
  - name: People — Lifecycle
    description: Offboard and reactivate users.
  - name: Assets
    description: Manage inventory assets
  - name: Regions V1
    description: Query regions (V1)
  - name: Warehouses V1
    description: Query warehouses (V1)
  - name: Brands
    description: Query available brands for asset creation
  - name: Inventory
    description: ''
  - name: Replacements
    description: Create and manage equipment replacements
  - name: Offices
    description: Manage and query office locations for the authenticated organization
  - name: Returns
    description: Return and Replacements
paths:
  /api/v1/inventory-levels:
    post:
      tags:
        - Inventory Levels
      summary: Create a new inventory level configuration for a SKU at a warehouse
      description: >-
        Creates an inventory level configuration that defines the minimum and
        maximum stock thresholds for a specific SKU at a specific warehouse.
        Optionally scoped to a region. Returns 409 if a level already exists for
        the same SKU + warehouse + region combination.
      operationId: createInventoryLevel
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateInventoryLevelRequest'
        required: true
      responses:
        '201':
          description: Inventory level created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InventoryLevelResponse'
        '400':
          description: Bad request — validation error or invalid SKU/warehouse/region
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicApiHttpErrors'
        '404':
          description: Not Found
          content:
            '*/*':
              schema:
                $ref: '#/components/schemas/PublicApiHttpErrors'
        '409':
          description: >-
            An inventory level already exists for this SKU, warehouse, and
            region combination
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicApiHttpErrors'
components:
  schemas:
    CreateInventoryLevelRequest:
      type: object
      description: Request to create an inventory level configuration
      properties:
        skuId:
          type: string
          format: uuid
          description: ID of the SKU to set inventory levels for
          example: 123e4567-e89b-12d3-a456-426614174000
        warehouseId:
          type: string
          format: uuid
          description: ID of the warehouse
          example: 123e4567-e89b-12d3-a456-426614174000
        minQuantity:
          type: integer
          format: int32
          description: Minimum quantity threshold
          example: 5
          minimum: 1
        maxQuantity:
          type: integer
          format: int32
          description: Maximum quantity threshold
          example: 20
          minimum: 1
        regionId:
          type: string
          format: uuid
          description: ID of the region (optional; uses org default when not provided)
          example: 123e4567-e89b-12d3-a456-426614174000
        includeUsed:
          type: boolean
          description: Whether to include used inventory in stock calculations
          example: false
        autoCreate:
          type: boolean
          description: Whether to automatically create inventory orders when stock is low
          example: false
        customerPoNumber:
          type: string
          description: >-
            Customer purchase order number to apply to restock orders created
            from this level
          example: PO-12345
      required:
        - autoCreate
        - includeUsed
        - maxQuantity
        - minQuantity
        - skuId
        - warehouseId
    InventoryLevelResponse:
      type: object
      description: >-
        Inventory level configuration with current stock details for a specific
        SKU, warehouse, and region
      properties:
        id:
          type: string
          format: uuid
          description: Unique identifier for this inventory level configuration
          example: 123e4567-e89b-12d3-a456-426614174000
        skuId:
          type: string
          format: uuid
          description: ID of the SKU whose stock level this configuration controls
          example: 123e4567-e89b-12d3-a456-426614174000
        warehouseId:
          type: string
          format: uuid
          description: ID of the warehouse where this inventory level applies
          example: 123e4567-e89b-12d3-a456-426614174000
        regionId:
          type: string
          format: uuid
          description: >-
            ID of the region scope for this inventory level; null means the
            organization's default region
          example: 123e4567-e89b-12d3-a456-426614174000
        minQuantity:
          type: integer
          format: int32
          description: Minimum quantity threshold
          example: 5
        maxQuantity:
          type: integer
          format: int32
          description: Maximum quantity threshold
          example: 20
        includeUsed:
          type: boolean
          description: Whether used inventory is included in stock calculations
        autoCreate:
          type: boolean
          description: Whether inventory orders are automatically created when stock is low
        active:
          type: boolean
          description: Whether this inventory level is active
        customerPoNumber:
          type: string
          description: >-
            Optional customer PO number copied to restock orders created from
            this level
          example: PO-12345
        stockDetails:
          $ref: '#/components/schemas/StockDetails'
          description: Current stock details for this inventory level
        createdInventoryOrderId:
          type: string
          format: uuid
          description: >-
            Inventory order id created by autoCreate; null when no restock was
            triggered.
          example: 123E4567-E89B-12D3-A456-426614174000
      required:
        - active
        - autoCreate
        - id
        - includeUsed
        - maxQuantity
        - minQuantity
        - skuId
        - stockDetails
        - warehouseId
    PublicApiHttpErrors:
      type: object
      properties:
        errors:
          type: array
          items:
            $ref: '#/components/schemas/PublicApiError'
      required:
        - errors
    StockDetails:
      type: object
      description: Current stock availability details
      properties:
        newInventories:
          type: integer
          format: int32
          description: Count of new-condition inventory items available
          example: 12
        usedInventories:
          type: integer
          format: int32
          description: Count of used-condition inventory items available
          example: 3
        pendingInventoryOrders:
          type: integer
          format: int32
          description: Count of pending inventory order items
          example: 2
        totalAvailable:
          type: integer
          format: int32
          description: >-
            Total effective available stock (new + pending, plus used if
            includeUsed)
          example: 14
        totalItemsToOrder:
          type: integer
          format: int32
          description: Number of items to order to reach max level
          example: 6
      required:
        - newInventories
        - pendingInventoryOrders
        - totalAvailable
        - totalItemsToOrder
        - usedInventories
    PublicApiError:
      type: object
      properties:
        detail:
          type: string
          description: Human-readable description of the error
          example: Invalid request
        source:
          type: string
          description: >-
            Entity or field path that caused the error (for example order,
            shipmentNotice, or person:email)
          example: request
      required:
        - detail
        - source
  securitySchemes:
    ApiKey:
      type: apiKey
      description: Prefix the value with "ApiKey" to indicate the custom authorization type
      name: Authorization
      in: header

````