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

# Create a lots

> Create a lots

### Request body

`CreateLotRequest`

<ParamField body="cost_per_unit" type="string,null">
  Decimal unit cost as a string.
</ParamField>

<ParamField body="expiration_date" type="string,null">
  RFC 3339 timestamp.
</ParamField>

<ParamField body="lot_number" type="string,null">
  Lot number; auto-generated when omitted.
</ParamField>

<ParamField body="notes" type="string,null" />

<ParamField body="production_date" type="string,null">
  RFC 3339 timestamp.
</ParamField>

<ParamField body="quantity" type="string" required>
  Decimal quantity as a string.
</ParamField>

<ParamField body="sku" type="string" required />

<ParamField body="supplier_id" type="string,null" />

<ParamField body="supplier_lot" type="string,null" />

### Responses

<ResponseField name="201" type="LotResponse" />

<ResponseField name="400" type="ErrorBody" />

<RequestExample>
  ```bash cURL theme={null}
  curl --request POST \
    --url 'https://api.stateset.com/api/v1/lots' \
    --header 'Authorization: Bearer YOUR_API_KEY' \
    --header 'Content-Type: application/json' \
    --data '{
    "cost_per_unit": null,
    "expiration_date": null,
    "lot_number": null,
    "notes": null,
    "production_date": null,
    "quantity": "string",
    "sku": "string",
    "supplier_id": null,
    "supplier_lot": null
  }'
  ```
</RequestExample>

<ResponseExample>
  ```json 201 theme={null}
  {
    "created_at": "string",
    "expiration_date": null,
    "id": "string",
    "lot_number": "string",
    "production_date": "string",
    "quantity_available": "string",
    "quantity_produced": "string",
    "quantity_remaining": "string",
    "quantity_reserved": "string",
    "sku": "string",
    "status": "string"
  }
  ```
</ResponseExample>
