Add an item price to a vendor
Records that this vendor supplies an item at a given unit cost, with optional lead time, minimum order quantity and preferred-supplier flag. Each item can be added to a vendor once.
How to use it
- Take the vendor id from Create a vendor or List vendors and the itemId from List items.
- Send unitCost and, optionally, leadTimeDays (default 0), minimumOrderQty (default 1) and isPreferred.
- Adding the same item to the same vendor twice is rejected. The price then appears in List vendors for an item.
BearerAuthAuthorizationBearer <JWT>id*stringID of the record (UUID).
uuidX-TenantID*stringYour merchant's tenant code — the value typed in the Domain field on the iotoms login screen. See Concepts.
application/json- body
itemId*stringRequired. Item code from List items. Each item can be added to a vendor only once.
unitCost*numberRequired. Vendor's price per unit, in the merchant's currency.
leadTimeDays*integerDays the vendor usually takes to deliver. Defaults to 0.
int32minimumOrderQty*numberSmallest quantity the vendor accepts per order. Defaults to 1.
isPreferred*booleanMark this vendor as the preferred supplier for the item. Defaults to false.
notes?|Optional free-text notes.
OK
*/*- response
status*stringOutcome of the call: SUCCESS when it worked, ERROR when it failed.
message*stringShort human-readable message describing the outcome, for example "Vendor created". Do not parse it.
data?The vendor item price record that was created.
curl -X POST 'https://beta.iotoms.com/api/v1/procurement/vendors/497f6eca-6276-4993-bfeb-53cbbbba6f08/items' \ -H 'X-TenantID: your-tenant-code' \ -H 'Content-Type: application/json' \ -d '{ "itemId": "string", "unitCost": 0, "leadTimeDays": 0, "minimumOrderQty": 0, "isPreferred": true}'{ "status": "string", "message": "string", "data": { "id": 0, "vendorId": "e9b57fab-1850-44d4-8499-71fd15c845a0", "itemId": "string", "itemName": "string", "unitCost": 0, "leadTimeDays": 0, "minimumOrderQty": 0, "isPreferred": true, "notes": "string" }}