简体   繁体   中英

Updating Inventory on Clover Pos using the rest api

I'm trying to use clover's API to update inventory using a custom built inventory app for my families small business. I have used their APIs without issue for other functions. However, I cannot get it to update the stock of my items.

I followed their documentation here: https://www.clover.com/api_docs/#!/inventory/UpdateItemStock

However, I cannot seem to figure out where to put the new inventory count so that it will update clovers systems.

I know this is the base URL to access the API https://api.clover.com/v3/merchants/{{mId}}/item_stocks/{{itemID}}

(I'm currently using postman for testing so it will fill in the variables in the URL, and insert my API key in an authorization header)

I have tried:

  • Appending quantity=5.0 to the URL for example: https://api.clover.com/v3/merchants/{{mId}}/item_stocks/{{itemID}}?quantity=5.0

  • Sending quantity=5 as part of the body

Any help is greatly appreciated, thanks.

Make sure you are sending a POST to the endpoint:

POST /v3/merchants/{mId}/item_stocks/{itemId}

And put this in the body of the request:

{
  "quantity": 5
}

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM