ProductInventory
Type: schema
TypeScript Definition
typescript
ProductInventory: {{
/** @description required only if product has_variant = true. otherwise it can be excluded or pass null. */
variant_id?: string | null;
/** @description `null` for products without variants. */
variant_name?: $Read<string | null>;
product_id?: $Read<string>;
product_name?: $Read<string>;
/** @description Can be used for the product having variants. if true, same inventry details will be updated to other variants which are not mentioned in request body. */
update_other_variants?: $Write<boolean>;
track_quantity?: boolean;
track_lot_batch?: boolean;
allow_backorder?: boolean;
low_stock_threshold?: $Read<number>;
stock_available?: $Read<boolean>;
stock?: {
sku?: $Read<string | null>;
warehouse?: components["schemas"]["WarehouseBasicDetail"] | null;
/** Format: date */
opening_stock_date?: string | null;
warehouse_id: string;
warehouse_name?: $Read<string | null>;
received_quantity?: $Read<number>;
reserved_quantity?: $Read<number>;
sold_quantity?: $Read<number>;
adjusted_quantity?: $Read<number>;
/** @description Send `null` to clear the stock of a deactivated warehouse. */
stock_quantity: number | null;
lot_batch?: string | null;
/** Format: date */
mfg_date?: string | null;
/** Format: date */
exp_date?: string | null;
manufacturer?: string | null;
/** Format: date-time */
created_at?: $Read<string>;
/** Format: date-time */
modified_at?: $Read<string>;
}[];
};
/** ProductPricing */
}Component References
| Reference | Resolves To |
|---|---|
components["schemas"]["WarehouseBasicDetail"] | WarehouseBasicDetail |
OpenAPI Schema
json
{
"title": "ProductInventory",
"type": "object",
"properties": {
"variant_id": {
"description": "required only if product has_variant = true. otherwise it can be excluded or pass null.\n",
"type": [
"string",
"null"
]
},
"variant_name": {
"description": "`null` for products without variants.",
"type": [
"string",
"null"
],
"readOnly": true
},
"product_id": {
"type": "string",
"readOnly": true
},
"product_name": {
"type": "string",
"readOnly": true
},
"update_other_variants": {
"description": "Can be used for the product having variants. if true, same inventry details will be updated to other variants which are not mentioned in request body.",
"type": "boolean",
"writeOnly": true
},
"track_quantity": {
"type": "boolean"
},
"track_lot_batch": {
"type": "boolean"
},
"allow_backorder": {
"type": "boolean"
},
"low_stock_threshold": {
"type": "number",
"readOnly": true
},
"stock_available": {
"type": "boolean",
"readOnly": true
},
"stock": {
"type": "array",
"items": {
"type": "object",
"required": [
"warehouse_id",
"stock_quantity"
],
"properties": {
"sku": {
"type": [
"string",
"null"
],
"readOnly": true
},
"warehouse": {
"oneOf": [
{
"$ref": "#/components/schemas/WarehouseBasicDetail"
},
{
"type": "null"
}
]
},
"opening_stock_date": {
"type": [
"string",
"null"
],
"format": "date"
},
"warehouse_id": {
"type": "string"
},
"warehouse_name": {
"type": [
"string",
"null"
],
"readOnly": true
},
"received_quantity": {
"type": "number",
"readOnly": true
},
"reserved_quantity": {
"type": "number",
"readOnly": true
},
"sold_quantity": {
"type": "number",
"readOnly": true
},
"adjusted_quantity": {
"type": "number",
"readOnly": true
},
"stock_quantity": {
"description": "Send `null` to clear the stock of a deactivated warehouse.",
"type": [
"number",
"null"
]
},
"lot_batch": {
"type": [
"string",
"null"
]
},
"mfg_date": {
"type": [
"string",
"null"
],
"format": "date"
},
"exp_date": {
"type": [
"string",
"null"
],
"format": "date"
},
"manufacturer": {
"type": [
"string",
"null"
]
},
"created_at": {
"type": "string",
"format": "date-time",
"readOnly": true
},
"modified_at": {
"type": "string",
"format": "date-time",
"readOnly": true
}
}
}
}
},
"x-tags": [
"Catalog"
]
}Auto-generated from OpenAPI spec and TypeScript definitions