We Have a Public & Authenticated API

With the public API, you can get all of the product details in JSON format, and add and remove items from a cart. This allows you to keep the customer on your own site during the shopping process. For checkout they would still go through the VinoShipper.com checkout flow. The authenticated API lets you pull down order information and tracking details if you need to synchronize it with another system.

Public API


The cart API lets you create a cart, and then either POST or PUT items to it, the POST will add the quantity to the already existing quantity of the same wine ID if it exists, the PUT will update the quantity with the quantity you provide (to remove an item, send a PUT with 0 quantity). All of the calls return the current contents of the cart, subtotal, and a link to our checkout page.

The wine list API has some documentation on the fields returned, and the doc generator has the ability to generate requests so you should be able to play around with the APIs a bit from the UI. It’s not necessary to use our cart API, some companies use just the wine list API to keep the price up to date and flag sold out wines, and then maintain a local cart on their own side. Then they just send us the list of all the wines and quantities at checkout.

Here’s an example that uses the wine list API, but not the cart API http://speakwines.com/collections/all

Here’s an example that uses the wine list and cart APIs https://grapeseedwine.com/home/browse

To access the authenticated APIGo to vinoshipper.com and log, under the ‘Account’ top nav item, is a new ‘API Keys’ option. Use that to generate an API Key and secret. Use the api key and secret as the username and password in a Basic Auth header for your requests.

The order list call has two optional parameters: 'page' and 'status'. The results are paginated at 25 orders, to get subsequent pages just pass in the 'page' parameter.

The options for 'status' are: OPEN, SHIPPED, CANCELLED, DELIVERED All calls return the orders sorted by order date with the newest order first. Get all orderscurl --user 'key:secret' https://vinoshipper.com/api/winery/order Example: get the second page of orderscurl --user 'key:secret' https://vinoshipper.com/api/winery/order?page=2 Example: get not yet shipped and in-transit orderscurl --user 'key:secret' https://vinoshipper.com/api/winery/order?status=OPEN,SHIPPED You can also get a specific order by order number if you just want to check the status, or retrieve the tracking numbers. Example: get a specific order by order numbercurl --user 'key:secret' https://vinoshipper.com/api/winery/order/<ordernumber>