Openapi
Update an inventory stock record for a product.
Supabase browser session cookie. Supabase may split larger session values into chunked cookies like sb-auth-token.0.
In: cookie
uuiduuidapplication/json
The inventory stock record payload.
TypeScript Definitions
Use the request body type in TypeScript.
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X PATCH "https://example.com/v1/organizations/123/inventory/stock-records/123" \ -H "Content-Type: application/json" \ -d '{ "productId": "dcd53ddb-8104-4e48-8cc0-5df1088c6113", "onHandQuantity": 0 }'{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "organizationId": "7bc05553-4b68-44e8-b7bc-37be63c6d9e9", "productId": "dcd53ddb-8104-4e48-8cc0-5df1088c6113", "product": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "organizationId": "7bc05553-4b68-44e8-b7bc-37be63c6d9e9", "categoryIds": [ "7a99018c-b68f-4d32-be08-29a0cbea434a" ], "categories": [ { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "organizationId": "7bc05553-4b68-44e8-b7bc-37be63c6d9e9", "parentId": "70850378-7d3c-4f45-91b7-942d4dfbbd43", "name": "string", "slug": "string", "icon": "string", "description": "string", "position": 0, "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z" } ], "name": "string", "slug": "string", "brand": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "organizationId": "7bc05553-4b68-44e8-b7bc-37be63c6d9e9", "name": "string", "slug": "string", "description": "string", "website": "string", "logoUrl": "http://example.com", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z" }, "manufacturer": "string", "sku": "string", "ean": "string", "defaultSellingPrice": 0, "vatPercentage": 0, "status": "active", "updatedAt": "2019-08-24T14:15:22Z", "tags": [ { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "organizationId": "7bc05553-4b68-44e8-b7bc-37be63c6d9e9", "kind": "task", "name": "string", "slug": "string", "color": "string", "description": "string", "position": 0, "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z" } ], "images": [ { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "organizationId": "7bc05553-4b68-44e8-b7bc-37be63c6d9e9", "productId": "dcd53ddb-8104-4e48-8cc0-5df1088c6113", "url": "http://example.com", "altText": "string", "position": 0, "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z" } ], "suppliers": [ { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "organizationId": "7bc05553-4b68-44e8-b7bc-37be63c6d9e9", "productId": "dcd53ddb-8104-4e48-8cc0-5df1088c6113", "supplierId": "e01eb4c4-8eb9-4fb7-b625-61f58c6148db", "supplier": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "organizationId": "7bc05553-4b68-44e8-b7bc-37be63c6d9e9", "name": "string", "email": "string", "phone": "string", "website": "string", "notes": "string", "status": "active", "code": "string", "accountNumber": "string", "kvk": "string", "btw": "string", "orderingEmail": "string", "billingEmail": "string", "addressLine1": "string", "addressLine2": "string", "addressCity": "string", "addressState": "string", "addressPostalCode": "string", "addressCountry": "string", "currency": "string", "paymentTermsDays": 0, "defaultLeadTimeDays": 0, "defaultInventoryLocationId": "39ba1a59-f7f9-4e8f-a32f-270329b3f772", "source": "string", "externalId": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z" }, "supplierSku": "string", "orderCode": "string", "unitCost": 0, "currency": "string", "isPreferred": true, "minOrderQuantity": 0, "orderMultiple": 0, "leadTimeDays": 0, "isActive": true, "externalId": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z" } ], "manufacturerPartNumber": "string", "currency": "string", "unitOfMeasure": "string" }, "locationId": "1a5515a3-ba81-4a42-aee7-ad9ffc090a54", "location": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "organizationId": "7bc05553-4b68-44e8-b7bc-37be63c6d9e9", "name": "string", "description": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z" }, "onHandQuantity": 0, "reservedQuantity": 0, "availableQuantity": 0, "reorderPoint": 0, "parLevel": 0, "lotNumber": "string", "serialNumber": "string", "expiresOn": "2019-08-24", "status": "available", "notes": "string", "createdBy": "25a02396-1048-48f9-bf93-102d2fb7895e", "updatedBy": "b0efe45f-0520-4e21-90f0-7e35f137732e", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "binLocation": "string", "unitCost": 0, "currency": "string", "lastCountedOn": "2019-08-24"}uuidlength <= 2400 <= value0 <= value0 <= value0 <= valuelength <= 240length <= 240dateValue in
length <= 4000length <= 2400 <= valuedate