The Vend Developer Hub

Welcome to the Vend developer hub. You'll find comprehensive guides and documentation to help you start working with the Vend API as quickly as possible.

Suggest Edits

Authorization

 

The Vend API allows authorization using the OAuth 2.0 standard as documented here: https://tools.ietf.org/html/rfc6749. Currently, we only support the Authorization Code Grant.

OAuth 2.0

Developer account and Vend application

Before starting, create a Vend application. To do this follow the steps below:

Step 1. Register as a developer

If you have not done this yet, register a developer account here.

Your developer account credentials are independent of your Vend account so your existing Vend credentials will not work here.

Step 2. Create a Vend application

Once you sign in you will be redirected to the list of your Applications. Now you are ready to create your first app.

As a result, this process will give you the client_id and the client_secret which are used to identify your applications and are, therefore, required to complete the authorization process.

redirect_uri is the address of your server which will accept the callback request from Vend.

You will notice that a newly created app is marked as Not Approved. Don’t worry! You can still use this app. Not Approved just means that you can only connect your application to 30 Vend stores. This should be more than enough for private apps or testing/staging environments. You only need to get our approval for production ready, public applications.

Connecting your application to a Vend Retailer Account

Implement the following steps to connect your application to a Vend Retailer account:

Step 1. Requesting authorization code

The Retailer (resource owner) needs to authorize your application to access their data. Send them to the following URL so that they can authorize your application.

https://secure.vendhq.com/connect?response_type=code&client_id={client_id}&redirect_uri={redirect_uri}&state={state}

Once the Retailer has authorized the application, Vend will send an authorization code and the Retailer’s domain prefix to the Redirect URI you set up with your application.

Successful authorization response:

 {redirect_uri}?code={code}&domain_prefix={domain_prefix}&state={state}

Declined access response:

 {redirect_uri}?error=access_denied

The state parameter can be used to pass some arbitrary data, allowing you to bind the callback with a particular authorization request.

The redirect_uri parameter should be defined exactly as it was when creating your application, without any additional parameters.

Currently, the Vend API does not support scopes.

Step 2. Requesting an access token

Once you have the authorization code, your application can now request an access token and a refresh token.
The following data should be sent as “application/x-www-form-urlencoded” encoded body of a POST request.

This data should not be sent as GET parameters in a query string.

  • URL:
https://{domain_prefix}.vendhq.com/api/1.0/token
  • Parameters:
    • code
    • client_id
    • client_secret
    • grant_type - this is always authorization_code
    • redirect_uri

The code is a short-lived (10 minutes), single-use value. Based on that assumption, every new authorisation request should start with Step 1.

  • Response:

    {
        "access_token": "fMYgxHEYtcyT8cvtvgi1Za5DRs4vArSyvydlnd9f",
        "token_type": "Bearer",
        "expires": 1387145621,
        "expires_in": 86400,
        "refresh_token": "J3F62YPIQdfJjJia1xJuaHp7NoQYtm9y0WadNBTh"
    }
    

expires is an absolute timestamp in seconds since the Unix epoch time (1970-01-01T00:00:00Z). EpochConverter is a nice tool converting epoch timestamps to human dates.

expires_in is a relative time duration in seconds since this response was created. Currently, tokens expire in 24hrs.

Step 3. Using the token to access the Vend API

Your application can use the received access token to interact with the Vend API on behalf of the Retailer by providing the access token in an Authorization header.

GET https://someprefix.vendhq.com/api/products/{id}

Authorization: Bearer fMYgxHEYtcyT8cvtvgi1Za5DRs4vArSyvydlnd9f

Step 4. Refreshing the access token

When the access token expires, your application can request a new access token using the refresh token received in Step 2.

https://someprefix.vendhq.com/api/1.0/token

  • Parameters:

    • refresh_token
    • client_id
    • client_secret
    • grant_type - when refreshing tokens it should be refresh_token
  • Response:

    {
        "access_token": "KD7gspXvfAmOsspC65YDqqJQ6FcAYbRROc4zPIMZ",
        "token_type": "Bearer",
        "expires": 1387145621,
        "expires_in": 604800
    }
    

The response payload may include a refresh token. If so, you need to update your currently stored refresh token. If no refresh token exists in the payload, you can assume the refresh token was not rotated, and you can continue to use the original refresh token.

Personal Tokens

Personal Tokens are a simplified method of acquiring an access token, for those use cases where the OAuth flow will not work. Good examples of those are scripts running periodically in the background or desktop applications.

Personal Tokens can be created by admin users directly in the web application as described here.

To use a Personal Token to authorize a request, it should be used just like an OAuth token - it should be attached to every request in the Authorization header:

Authorization: Bearer fMYgxHEYtcyT8cvtvgi1Za5DRs4vArSyvydlnd9f
 
Suggest Edits

Pagination

 

API 0.x

Large data sets are returned as paginated data. When this occurs a pagination section will be returned in the result set. The first page of data will be returned in the response also.

{
    "pagination": {
        "results" : 7461,
        "page" : 1,
        "page_size" : 100,
        "pages" : 75
    },
    "customers": [
        { ... },
        { ... }
        ... and 98 other customers
    ]
}

Requesting Pages

You can request a different page by passing a different page parameter like:

https://domain_prefix.vendhq.com/api/products?page=23

Page size

It is possible to change the number of objects returned in the response. It can be done by passing the page_size parameter like:

https://domain_prefix.vendhq.com/api/products?page=23&page_size=200

200 is the maximum value of the page_size parameter.

API 2.0

Requesting subsequent pages is based on a resource specific cursor - an attribute called version which can be found on all collection resources. Here's an example based on the brand resource:

{
  "id": "b1e2624f-f019-11e3-a0f5-b8ca3a64f8f4",
  "name": "Generic Brand",
  "deleted_at": null,
  "version": 791094
}

The version attribute is simply a monotonically increasing integer. It is being incremented every time a resource is changed. This is a global parameter and it shouldn't be assumed that subsequent versions of the same resource will be incremented by 1.

First page

By default, the value of the after parameter will be assumed as equal 0 so it's not necessary to use it on the first page.
For a request with no after parameter or after=0, the first page of products will be returned, even if a resource with version = 0 may not exist in the given collection.
The body of the response will contain 2 JSON objects. The first one, data will be a collection of the requested resource type and the second one,
version will contain the lowest and highest version number of resources included in the response.

{
    "data": [
        {
            id: "0800273d-7d7f-11e5-e1c0-0aaccee64985",
            ...
        },
        ...
    ]
    "version": {
        "min": 11234566790,
        "max": 173456345676
    }
}

Subsequent pages

The response to that request should include a collection of 0 to n resources. The upper limit will probably be different depending on the endpoint.
The highest version number x from this collection (the max attribute above) should be used to request the next page like:

/api/2.0/products?after=x

This should be repeated until an empty collection is returned. This will mean that all items of the collection have been returned.

Sorting

Objects in returned collections will be sorted by the version number in an ascending order.

 
Suggest Edits

Rate limiting

 

The Vend API is rate-limited, to prevent a single API consumer from adversely affecting others using the platform.

Current limits

We currently only rate limit on a per-retailer basis. So, if your API integration or Vend add-on works with more than one retailer, you’ll have a separate rate limit for each. Requests from all apps count against the same limit, so even if your application doesn't make a lot of requests it may hit the limit because of another applications activity.
Currently, the per-retailer limit is calculated based on how many registers the retailer has. We might adjust these limits in the future. The current limit is:

300 x <number of registers> + 50

For a store with a single request that will result in a limit of 350 requests. The rate limiter is currently based on a 5 minute (300 seconds) window. This represents slightly more than one request per second, per register.

What happens when the limit is reached?

If you hit the rate limit, you’ll be unable to make any more API requests for that retailer until the limiter resets.
Below is an example of a response to a rate-limited request:

{
    "error": "Your access to the API has been rate limited",
    "limits": {
        "retailer": "651 > 650 for mydomainprefix"
    },
    "retry-after": "Thu, 28 Aug 2016 06:05:00 +0000"
}

The “retry-after” information is also provided via the Retry-After HTTP header.

Coping with Rate Limiting

The best way to deal with rate limiting is to process your Vend API requests in a queuing system.
You can then defer jobs that access the API, upon the first 429 response, until after the rate has been reset.
This approach has the advantage of using the API as fast as is possible, then pausing.

A less desirable solution is to pause/sleep any processes that use the API after each call;
this doesn’t respond as well to changes in the limits, nor to two processes using the API at once.
For these reasons, we strongly recommend a queue; most languages have many “deferred job” systems available.

 
Suggest Edits

User agent

 

We highly recommend setting a meaningful User-Agent header on all the request you make to the API.

In the case of a public web application, it is sufficient to use the application name, but you may also decide to add some more details like the version of your app or even a request id. This allows us to track these requests precisely in our logs when required. Even if your HTTP client library sets a default User-Agent header, it's usually not enough to uniquely identify the application which made the request. The more specific this header is, the more useful it will be to all parties.

Good examples:

  • PerfectApp-Curl/3.0.4/100119db
  • MyWellBehavedPublicApp

Bad examples:

  • -
  • Java/1.8.0_101
  • Python-urllib/3.4
  • Go-http-client/1.1
  • RestSharp/105.1.0.0
 
Suggest Edits

Request format

 

All of Vend APIs only support JSON-encoded data as requests and responses.
Headers for both the Content-Type and Accept should be set to application/json.

 
Suggest Edits

Dates and times

 

All dates and times in the API are in UTC. This means that when submitting dates and times in your requests your payload should include date/time in UTC.
When processing dates and times in responses from the API you should translate them to the local time of the associated outlet.

 
Suggest Edits

Consignments

 
 
 
Suggest Edits

List consignments

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a paginated list of consignments.

 
gethttps://domain_prefix.vendhq.com/api/consignment

Query Params

since
date-time

If included, returns only items modified since the given time. The provided date and time should be in UTC and formatted according to ISO 8601.

page
number

The number of the page of results to be returned.

page_size
number

The size of the page of results to be returned.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/consignment
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/consignment' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/consignment")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/consignment");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/consignment"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "results": 65,
  "page": 1,
  "page_size": 50,
  "pages": 2,
  "consignments": [
    {
      "id": "b8ca3a65-0183-11e4-fbb5-2812b9e74b37",
      "name": "Stocktake 1",
      "consignment_date": "2014-08-20 02:36:02",
      "due_at": null,
      "received_at": "2014-08-20 02:37:32",
      "retailer_id": "b1c50056-f019-11e3-a0f5-b8ca3a64f8f4",
      "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
      "supplier_id": null,
      "source_outlet_id": null,
      "status": "STOCKTAKE_COMPLETE",
      "type": "STOCKTAKE",
      "accounts_transaction_id": null
    },
    {
      "id": "b8ca3a65-0183-11e4-fbb5-281711e05741",
      "name": "Stock Transfer",
      "consignment_date": "2014-08-20 03:07:07",
      "due_at": "2014-08-21 00:00:00",
      "received_at": "2014-08-20 03:08:49",
      "retailer_id": "b1c50056-f019-11e3-a0f5-b8ca3a64f8f4",
      "outlet_id": "b8ca3a65-0183-11e4-fbb5-2816d2677218",
      "supplier_id": null,
      "source_outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
      "status": "RECEIVED",
      "type": "OUTLET",
      "accounts_transaction_id": null
    }
  ]
}
 
Suggest Edits

Create a consignment

Creates a new consignment.

 
posthttps://domain_prefix.vendhq.com/api/consignment

Body Params

name
string
required

The name of the consignment.

consignment_date
string

The date when the consignment was created.

due_at
string

The due date for the consignment.

received_at
string

The date when the consignment was received.

outlet_id
uuid
required

The ID of the outlet to which the goods are coming.

supplier_id
uuid

The ID of the supplier associated with this consignment.

source_outlet_id
uuid

The ID of the outlet from which the goods are coming. Only used for stock transfers.

status
string
required

Status of the consignment. One of: OPEN, SENT, RECEIVED, CANCELLED, STOCKTAKE, STOCKTAKE_COMPLETE.

type
string
required

The type of the consignment. One of: SUPPLIER, OUTLET, STOCKTAKE.

accounts_transaction_id
string

The ID of a transaction in an external system associated with this consignment.

 
curl --request POST \
  --url https://domain_prefix.vendhq.com/api/consignment
var request = require("request");

var options = { method: 'POST',
  url: 'https://domain_prefix.vendhq.com/api/consignment' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/consignment")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://domain_prefix.vendhq.com/api/consignment");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/consignment"

response = requests.request("POST", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "id": "0af7b240-ab83-11e7-eddc-38e5834289e2",
  "name": "API test 5",
  "consignment_date": "2017-05-14 20:40:05",
  "due_at": null,
  "received_at": null,
  "retailer_id": "b1c50056-f019-11e3-a0f5-b8ca3a64f8f4",
  "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
  "supplier_id": null,
  "source_outlet_id": null,
  "status": "OPEN",
  "type": "SUPPLIER",
  "accounts_transaction_id": null
}
 
Suggest Edits

Get a consignment by ID

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.\s\s
\s\s
Returns a single consignment with a given ID.

 
gethttps://domain_prefix.vendhq.com/api/consignment/consignment_id

Path Params

consignment_id
uuid
required

The ID of the consignment to get.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/consignment/consignment_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/consignment/consignment_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/consignment/consignment_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/consignment/consignment_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/consignment/consignment_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "id": "0af7b240-ab83-11e7-eddc-38e5215a314f",
  "name": "API test 2 changed",
  "consignment_date": "2017-05-14 20:37:21",
  "due_at": "2017-06-01 00:00:00",
  "received_at": null,
  "retailer_id": "b1c50056-f019-11e3-a0f5-b8ca3a64f8f4",
  "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
  "supplier_id": null,
  "source_outlet_id": null,
  "status": "OPEN",
  "type": "SUPPLIER",
  "accounts_transaction_id": null
}
 
Suggest Edits

Update a consignment

Updates a consignment with the given ID.

 
puthttps://domain_prefix.vendhq.com/api/consignment/consignment_id

Path Params

consignment_id
uuid
required

The ID of the consignment to be updated.

Body Params

name
string
required

The name of the consignment.

consignment_date
string

The date when the consignment was created.

due_at
string

The due date for the consignment.

received_at
string

The date when the consignment was received.

outlet_id
uuid
required

The ID of the outlet to which the goods are coming.

supplier_id
uuid

The ID of the supplier associated with this consignment.

source_outlet_id
uuid

The ID of the outlet from which the goods are coming. Only used for stock transfers.

status
string
required

Status of the consignment. One of: OPEN, SENT, RECEIVED, CANCELLED, STOCKTAKE, STOCKTAKE_COMPLETE.

type
string
required

The type of the consignment. One of: SUPPLIER, OUTLET, STOCKTAKE.

accounts_transaction_id
string

The ID of a transaction in an external system associated with this consignment.

 
curl --request PUT \
  --url https://domain_prefix.vendhq.com/api/consignment/consignment_id
var request = require("request");

var options = { method: 'PUT',
  url: 'https://domain_prefix.vendhq.com/api/consignment/consignment_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/consignment/consignment_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("PUT", "https://domain_prefix.vendhq.com/api/consignment/consignment_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/consignment/consignment_id"

response = requests.request("PUT", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "id": "0af7b240-ab83-11e7-eddc-38e5215a314f",
  "name": "API test 2 changed",
  "consignment_date": "2017-05-14 20:37:21",
  "due_at": "2017-06-01T00:00:00.000Z",
  "received_at": null,
  "retailer_id": "b1c50056-f019-11e3-a0f5-b8ca3a64f8f4",
  "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
  "supplier_id": null,
  "source_outlet_id": null,
  "status": "OPEN",
  "type": "SUPPLIER",
  "accounts_transaction_id": null
}
 
Suggest Edits

Delete a consignment

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Deletes the consignment with a given ID.

 
deletehttps://domain_prefix.vendhq.com/api/consignment/consignment_id

Path Params

consignment_id
string
required

The ID of the consignment to be deleted

 
curl --request DELETE \
  --url https://domain_prefix.vendhq.com/api/consignment/consignment_id
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://domain_prefix.vendhq.com/api/consignment/consignment_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/consignment/consignment_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://domain_prefix.vendhq.com/api/consignment/consignment_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/consignment/consignment_id"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "status": "success"
}
 
Suggest Edits

Consignment Products

 
 
 
Suggest Edits

List consignment products

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a paginated list of consignment products.

 
gethttps://domain_prefix.vendhq.com/api/consignment_product

Query Params

consignment_id
uuid
required

The ID of a consignment to filter the items for. Shouldn't be used together with the product_id parameter.

product_id
uuid
required

The ID of a product to filter the items for. Shouldn't be used together with the consignment_id parameter.

page
number

The number of the page of results to be returned.

page_size
number

The size of the page of results to be returned.

 
curl --request GET \
  --url 'https://domain_prefix.vendhq.com/api/consignment_product?consignment_id=consignment_id&product_id=product_id'
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/consignment_product',
  qs: 
   { consignment_id: 'consignment_id',
     product_id: 'product_id' } };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/consignment_product?consignment_id=consignment_id&product_id=product_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/consignment_product?consignment_id=consignment_id&product_id=product_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/consignment_product"

querystring = {"consignment_id":"consignment_id","product_id":"product_id"}

response = requests.request("GET", url, params=querystring)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Create a consignment product

Adds a new product to a consignment.

 
posthttps://domain_prefix.vendhq.com/api/consignment_product

Body Params

consignment_id
uuid
required

The ID of the consignment associated with this item.

product_id
uuid
required

The ID of the product associated with this item.

count
int32
required

Quantity "ordered" for stock orders or "expected" for stock takes.

received
int32

Quantity "received" for stock orders or "counted" for stock takes.

cost
int32

Supply cost of the item for this consignment.

sequence_number
int32

Sequence order number for the item.

 
curl --request POST \
  --url https://domain_prefix.vendhq.com/api/consignment_product
var request = require("request");

var options = { method: 'POST',
  url: 'https://domain_prefix.vendhq.com/api/consignment_product' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/consignment_product")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://domain_prefix.vendhq.com/api/consignment_product");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/consignment_product"

response = requests.request("POST", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "id": "0af7b240-ab83-11e7-eddc-35e882a295ee",
  "consignment_id": "0af7b240-ab83-11e7-eddc-35e7dc9d25d0",
  "product_id": "0af7b240-ab83-11e7-eddc-35e81b24d85f",
  "count": 42,
  "received": null,
  "cost": 123.345,
  "sequence_number": 0
}
 
Suggest Edits

Get a single consignment product by ID

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a single consignment product.

 
gethttps://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id

Path Params

consignment_product_id
uuid
required

The ID of the consignment to get.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Update a consignment product

Updates an existing consignment product.

 
puthttps://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id

Path Params

consignment_product_id
uuid
required

The ID of the consignment to be updated.

Body Params

consignment_id
uuid
required

The ID of the consignment associated with this item.

product_id
uuid
required

The ID of the product associated with this item.

count
int32
required

Quantity "ordered" for stock orders or "expected" for stock takes.

received
int32

Quantity "received" for stock orders or "counted" for stock takes.

cost
int32

Supply cost of the item for this consignment.

sequence_number
int32

Sequence order number for the item.

 
curl --request PUT \
  --url https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id
var request = require("request");

var options = { method: 'PUT',
  url: 'https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("PUT", "https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id"

response = requests.request("PUT", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Delete a consignment product

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Deletes an item from the consignment.

 
deletehttps://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id

Path Params

consignment_product_id
string
required

The ID of the consignment product to be deleted.

 
curl --request DELETE \
  --url https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/consignment_product/consignment_product_id"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Customers

 
 
 
Suggest Edits

List customers

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a paginated list of customers.

 
gethttps://domain_prefix.vendhq.com/api/customers

Query Params

id
uuid

If included, searches for customers with the given unique ID. The id option cannot be used with the code or email options.

code
string

If included, searches for customers with the given customer code. The code option cannot be used with id or email options.

email
string

If included, searches for customers with the given email address. This is an exact match search. The email option cannot be used with the id or code options.

since
date-time

If included, returns only items modified since the given time. The provided date and time should be in UTC and formatted according to ISO 8601.

page
number

The number of the page of results to be returned.

page_size
number

The size of the page of results to be returned.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/customers
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/customers' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/customers")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/customers");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/customers"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Create or update a customer

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a single new or updated customer object.

 
posthttps://domain_prefix.vendhq.com/api/customers

Body Params

id
uuid

Existing customer ID. If included in the POST request it will cause an update instead of a creating a new customer.

customer_code
string

Short, unique customer code.

customer_group_id
uuid

The ID of the customer group this customer is associated with.

first_name
string

Customer's first name.

last_name
string

Customer's last name.

company_name
string

Customer's company name.

phone
string

Customer's phone number.

mobile
string

Customer's mobile phone number.

fax
string

Customer's fax number.

email
string

Customer's email address.

twitter
string

Twitter handle.

website
string

Website URL.

physical_address1
string

Address, line 1 - physical.

physical_address2
string

Address, line 2 - physical.

physical_suburb
string

Suburb - physical.

physical_city
string

City - physical.

physical_postcode
string

Post code - physical.

physical_state
string

State - physical.

physical_country_id
string

Country code - physical.

postal_address1
string

Address, line 1 - postal.

postal_address2
string

Address, line 2 - postal.

postal_suburb
string

Suburb - postal.

postal_city
string

City - postal.

postal_postcode
string

Post code - postal.

postal_state
string

State - postal.

postal_country_id
string

Country code - postal.

enable_loyalty
int32

Indicates whether customer's purchases should incur loyalty. 0 or 1.

date_of_birth
string

Customer's date of birth.

sex
string

Customer's gender.

custom_field_1
string

Custom field 1, able to store any data as a string.

custom_field_2
string

Custom field 2, able to store any data as a string.

custom_field_3
string

Custom field 3, able to store any data as a string.

custom_field_4
string

Custom field 4, able to store any data as a string.

note
string

Customer related notes.

 
curl --request POST \
  --url https://domain_prefix.vendhq.com/api/customers
var request = require("request");

var options = { method: 'POST',
  url: 'https://domain_prefix.vendhq.com/api/customers' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/customers")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://domain_prefix.vendhq.com/api/customers");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/customers"

response = requests.request("POST", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
 
 
 
Suggest Edits

List outlets

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a non-paginated list of outlets.

 
gethttps://domain_prefix.vendhq.com/api/outlets
 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/outlets
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/outlets' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/outlets")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/outlets");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/outlets"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Payment Types

 
 
 
Suggest Edits

List payment types

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a non-paginated list of payment types.

 
gethttps://domain_prefix.vendhq.com/api/payment_types
 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/payment_types
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/payment_types' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/payment_types")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/payment_types");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/payment_types"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
 
 
 
Suggest Edits

List products

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a paginated list of products.

 
gethttps://domain_prefix.vendhq.com/api/products

Query Params

order_by
string

Defines the attribute by which the query results should be ordered. One of: id(recommended), updated_at(default), name.

order_direction
string

Selects the order direction of the results returned. On of ASC(default), DESC.

since
date-time

If included, returns only items modified since the given time. The provided date and time should be in UTC and formatted according to ISO 8601.

active
string

If included, only active or inactive products will be returned. One of: '"0"' or '"1"'.

sku
string

If included, only the product with given sku will be returned. It may happen that there will be more products with the same sku. In this case all of them will be returned.

handle
string

If included, only products with given handle will be returned. This is useful for filtering all variants of a product, since all variants share the same handle.

page
number

The number of the page of results to be returned.

page_size
number

The size of the page of results to be returned.

deleted
boolean

Indicates whether deleted items should be included in the result.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/products
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/products' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/products")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/products");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/products"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Create or update a product

Returns a single new or updated product object.

 
posthttps://domain_prefix.vendhq.com/api/products

Body Params

id
uuid

Existing product ID. If included in the POST request it will cause an update instead of a creating a new object.

source_id
string

The ID that can be used to reference a product in another system.

variant_source_id
string

Reference ID to an external object. Should be POSTed as source_variant_id.

handle
string
required

The handle of the product. Creating a new product with a handle identical to one of an existing product will cause creating a variant.

type
string

The name of the product type associated with the product.

variant_option_one_name
string

The name of the variant option 1.

variant_option_one_value
string

The value of the variant option 1.

variant_option_two_name
string

The name of the variant option 2.

variant_option_two_value
string

The value of the variant option 2.

variant_option_three_name
string

The name of the variant option 3.

variant_option_three_value
string

The value of the variant option 3.

active
boolean

Indicates whether the product is currently active.
NOTE: Currently has to be submitted as "0" or "1". Will be returned as boolean value of true or false.

name
string
required

The name of the product. Should be posted without any variant related suffixes.

description
string

The description of the product. May include HTML.

sku
string
required

The SKU of the product. Should be unique for new products.

tags
string

A comma separated list of tags associated with the product.

brand_id
uuid

The ID of the brand associated with the product.

supplier_name
string

Product supplier's name.

supplier_code
string

The code of the supplier for the product.

supply_price
string

The default cost of supply for the product.

account_code_purchase
string

Code used to associate purchase (cost) of the product with a specific account.

account_code_sales
string

Code used to associate sales of the product with a specific account. When POSTing it should be delivered as account_code.

track_inventory
boolean

Indicated whether the system should track inventory count for this product.

button_order
int32

A number describing the position of a variant in the UI.

inventory
array of objects

A list of inventory records associated with the product.

retail_price
double
required

Retail price for the product. Tax inclusive or exclusive depending on the store settings.

tax_id
uuid

ID of the tax to be used as the default for this product (for inclusive stores).

 
curl --request POST \
  --url https://domain_prefix.vendhq.com/api/products
var request = require("request");

var options = { method: 'POST',
  url: 'https://domain_prefix.vendhq.com/api/products' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/products")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://domain_prefix.vendhq.com/api/products");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/products"

response = requests.request("POST", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Get a single product by ID

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns an array with a single product inside it.

 
gethttps://domain_prefix.vendhq.com/api/products/product_id

Path Params

product_id
uuid
required

An ID of an existing product.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/products/product_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/products/product_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/products/product_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/products/product_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/products/product_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Delete a product

Deleted a product by ID.

 
deletehttps://domain_prefix.vendhq.com/api/products/product_id

Path Params

product_id
string
required

The ID of the product to be deleted.

 
curl --request DELETE \
  --url https://domain_prefix.vendhq.com/api/products/product_id
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://domain_prefix.vendhq.com/api/products/product_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/products/product_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://domain_prefix.vendhq.com/api/products/product_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/products/product_id"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Register sales

 
 
 
Suggest Edits

List register sales

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a paginated list of register sales.

 
gethttps://domain_prefix.vendhq.com/api/register_sales

Query Params

since
date-time

If included, returns only items modified since the given time. The provided date and time should be in UTC and formatted according to ISO 8601.

outlet_id
uuid

If included, returns only register sales made for the given outlet, identified by ID.

status[]
string

If included, returns only register sales in the given state. The status[] parameter may be used more than once; returned sales will be in any of the specified states.

page
number

The number of the page of results to be returned.

page_size
number

The size of the page of results to be returned.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/register_sales
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/register_sales' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/register_sales")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/register_sales");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/register_sales"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Create or update a register sale

Returns a single new or updated product object.

 
posthttps://domain_prefix.vendhq.com/api/register_sales

Body Params

source_id
string

The ID of the sale on the client side or another system where the sale was originally created.

register_id
uuid

The ID of the register where the sale was created.

customer_id
uuid

The ID of the customer associated with this sale.

user_id
uuid
required

The ID of the user (cashier) who created the sale.

sale_date
string

The date of the sale. If not provided will be added as the time the sale reached the server.

note
string

A note on the sale entered by the cashier.

status
string
required

Status of the sale. One of: SAVED, CLOSED, ONACCOUNT, LAYBY, ONACCOUNT_CLOSED, LAYBY_CLOSED, VOIDED.

short_code
string

Short, unique code to be printed on the receipt for loyalty tracking purposes.

invoice_number
string

The invoice number for the sale. If left null it will be populated by Vend with the next available invoice number.

accounts_transaction_id
string

Xero invoice reference ID. Only editable for ONACCOUNT sales.

register_sale_products
array of objects

Line items.

register_sale_payments
array of objects

Payments.

 
curl --request POST \
  --url https://domain_prefix.vendhq.com/api/register_sales
var request = require("request");

var options = { method: 'POST',
  url: 'https://domain_prefix.vendhq.com/api/register_sales' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/register_sales")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://domain_prefix.vendhq.com/api/register_sales");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/register_sales"

response = requests.request("POST", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Get a single register sale by ID

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a single register sale with the given ID, in an array.

 
gethttps://domain_prefix.vendhq.com/api/register_sales/sale_id

Path Params

sale_id
uuid
required

An ID of an existing sale

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/register_sales/sale_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/register_sales/sale_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/register_sales/sale_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/register_sales/sale_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/register_sales/sale_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Registers

 
 
 
Suggest Edits

List registers

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a non-paginated list of registers.

 
gethttps://domain_prefix.vendhq.com/api/registers

Query Params

deleted
boolean

Indicates whether deleted items should be included in the result.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/registers
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/registers' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/registers")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/registers");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/registers"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Suppliers

 
 
 
Suggest Edits

List suppliers

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a paginated list of suppliers.

 
gethttps://domain_prefix.vendhq.com/api/supplier

Query Params

page
number

The number of the page of results to be returned.

page_size
number

The size of the page of results to be returned.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/supplier
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/supplier' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/supplier")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/supplier");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/supplier"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Create or update a supplier

Returns a single supplier object.

 
posthttps://domain_prefix.vendhq.com/api/supplier

Body Params

id
uuid

Existing supplier ID. If included in the POST request it will cause an update instead of a creating a new object.

name
string

The name of the supplier.

description
string

Supplier's description.

contact
object

Generic contact object embedded in other objects like outlet or supplier

contact.first_name
string

Contact's first name.

contact.last_name
string

Contact's last name.

contact.company_name
string

Contact's company name.

contact.phone
string

Contact's phone number.

contact.mobile
string

Contact's mobile phone number

contact.fax
string

Contact's fax number.

contact.email
string

Contact's email address.

contact.twitter
string

Contact's Twitter handle.

contact.website
string

The URL of the contact's website.

contact.physical_address1
string

Address, line 1 - physical.

contact.physical_address2
string

Address, line 2 - physical.

contact.physical_suburb
string

Suburb - physical.

contact.physical_city
string

City - physical.

contact.physical_postcode
string

Post code - physical.

contact.physical_state
string

State - physical.

contact.physical_country_id
string

Country code - physical.

contact.postal_address1
string

Address, line 1 - postal.

contact.postal_address2
string

Address, line 2 - postal.

contact.postal_suburb
string

Suburb - postal.

contact.postal_city
string

City - postal

contact.postal_postcode
string

Post code - postal.

contact.postal_state
string

State - postal.

contact.postal_country_id
string

Country code - postal.

 
curl --request POST \
  --url https://domain_prefix.vendhq.com/api/supplier
var request = require("request");

var options = { method: 'POST',
  url: 'https://domain_prefix.vendhq.com/api/supplier' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/supplier")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://domain_prefix.vendhq.com/api/supplier");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/supplier"

response = requests.request("POST", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Get a single supplier by ID

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a single supplier with the given ID.

 
gethttps://domain_prefix.vendhq.com/api/supplier/supplier_id

Path Params

supplier_id
string
required

An ID of an existing supplier object

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/supplier/supplier_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/supplier/supplier_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/supplier/supplier_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/supplier/supplier_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/supplier/supplier_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Delete a supplier

Deletes a single supplier by ID.

 
deletehttps://domain_prefix.vendhq.com/api/supplier/supplier_id

Path Params

supplier_id
uuid
required

The ID of the supplier to be deleted.

 
curl --request DELETE \
  --url https://domain_prefix.vendhq.com/api/supplier/supplier_id
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://domain_prefix.vendhq.com/api/supplier/supplier_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/supplier/supplier_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://domain_prefix.vendhq.com/api/supplier/supplier_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/supplier/supplier_id"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
 
 
Suggest Edits

List taxes

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a non-paginated list of taxes.

 
gethttps://domain_prefix.vendhq.com/api/taxes
 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/taxes
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/taxes' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/taxes")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/taxes");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/taxes"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Create a tax

Creates a new tax.

 
posthttps://domain_prefix.vendhq.com/api/taxes

Body Params

name
string
required

Tax name.

rate
double
required

Tax rate. 0.1 = 10%.

 
curl --request POST \
  --url https://domain_prefix.vendhq.com/api/taxes
var request = require("request");

var options = { method: 'POST',
  url: 'https://domain_prefix.vendhq.com/api/taxes' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/taxes")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://domain_prefix.vendhq.com/api/taxes");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/taxes"

response = requests.request("POST", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Get a single tax by ID

Returns a single tax with the given ID.

 
gethttps://domain_prefix.vendhq.com/api/taxes/tax_id

Path Params

tax_id
string
required

An ID of an existing tax object.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/taxes/tax_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/taxes/tax_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/taxes/tax_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/taxes/tax_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/taxes/tax_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
 
 
Suggest Edits

List users

DEPRECATED This endpoint has a 2.0 equivalent. We recommend using that instead.
Returns a non-paginated list of users.

 
gethttps://domain_prefix.vendhq.com/api/users
 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/users
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/users' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/users")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/users");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/users"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
 
 
 
Suggest Edits

List webhooks

Returns a list of webhooks. NOTE: This endpoint will only return webhooks created by the application which is making the request.

 
gethttps://domain_prefix.vendhq.com/api/webhooks
 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/webhooks
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/webhooks' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/webhooks")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/webhooks");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/webhooks"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Create a webhook

Creates and returns a new webhook.
NOTE: The Content-Type header for this request should be set to application/x-www-form-urlencoded.

 
posthttps://domain_prefix.vendhq.com/api/webhooks

Form Data

data
string
required

The value of this field should be set as a string representing a JSON payload like:
{"url":"http://123456.ngrok.io","active":true,"type":"product.update"}

 
curl --request POST \
  --url https://domain_prefix.vendhq.com/api/webhooks
var request = require("request");

var options = { method: 'POST',
  url: 'https://domain_prefix.vendhq.com/api/webhooks' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/webhooks")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://domain_prefix.vendhq.com/api/webhooks");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/webhooks"

response = requests.request("POST", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "id": "0af7b240-ab83-11e7-eddc-7311972c4cab",
  "retailer_id": "b1c50056-f019-11e3-a0f5-b8ca3a64f8f4",
  "user_id": "bc305bf6-6183-11e4-f15a-190c6647efc2",
  "url": "https://12345678.ngrok.io",
  "active": true,
  "type": "product.update"
}
 
Suggest Edits

Get a single webhook by ID

Returns a single webhooks with the given ID.

 
gethttps://domain_prefix.vendhq.com/api/webhooks/webhook_id

Path Params

webhook_id
uuid
required
 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/webhooks/webhook_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/webhooks/webhook_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/webhooks/webhook_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/webhooks/webhook_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/webhooks/webhook_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Update a webhook by ID

Updates a webhook with the given id.
NOTE: The Content-Type header for this request should be set to application/x-www-form-urlencoded.

 
puthttps://domain_prefix.vendhq.com/api/webhooks/webhook_id

Path Params

webhook_id
uuid
required

The ID of the webhook to be updated.

Form Data

data
string
required

The value of this field should be set as a string representing a JSON payload like:
{"active":false}

 
curl --request PUT \
  --url https://domain_prefix.vendhq.com/api/webhooks/webhook_id
var request = require("request");

var options = { method: 'PUT',
  url: 'https://domain_prefix.vendhq.com/api/webhooks/webhook_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/webhooks/webhook_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("PUT", "https://domain_prefix.vendhq.com/api/webhooks/webhook_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/webhooks/webhook_id"

response = requests.request("PUT", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "id": "0af7b240-ab83-11e7-eddc-730fe466aba3",
  "retailer_id": "b1c50056-f019-11e3-a0f5-b8ca3a64f8f4",
  "user_id": "bc305bf6-6183-11e4-f15a-190c6647efc2",
  "url": "https://12345678.ngrok.io",
  "active": false,
  "type": "product.update"
}
 
Suggest Edits

Delete a webhook by ID

Deletes the webhook with the given ID.

 
deletehttps://domain_prefix.vendhq.com/api/webhooks/webhook_id

Path Params

webhook_id
uuid
required
 
curl --request DELETE \
  --url https://domain_prefix.vendhq.com/api/webhooks/webhook_id
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://domain_prefix.vendhq.com/api/webhooks/webhook_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/webhooks/webhook_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://domain_prefix.vendhq.com/api/webhooks/webhook_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/webhooks/webhook_id"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "status": "success"
}
 
 
 
Suggest Edits

List brands

Returns a paginated list of brands.

 
gethttps://domain_prefix.vendhq.com/api/2.0/brands

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/brands
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/brands' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/brands")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/brands");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/brands"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "0adaafb3-6583-11e5-fb60-d5b67a17df2f",
      "name": "Peak Performance",
      "deleted_at": null,
      "version": 882391722
    },
    {
      "id": "0adaafb3-6583-11e5-fb60-ebae84675ae4",
      "name": "Sennheiser",
      "deleted_at": null,
      "version": 1013841198
    },
    {
      "id": "b1e2624f-f019-11e3-a0f5-b8ca3a64f8f4",
      "name": "Generic Brand",
      "deleted_at": null,
      "version": 2364279587
    }
  ]
}
 
Suggest Edits

Get a single brand

Returns a single brand with a requested ID

 
gethttps://domain_prefix.vendhq.com/api/2.0/brands/brand_id

Path Params

brand_id
string
required

Valid brand ID.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/brands/brand_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/brands/brand_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/brands/brand_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/brands/brand_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/brands/brand_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": {
    "id": "0adaafb3-6583-11e5-fb60-d5b67a17df2f",
    "name": "Peak Performance",
    "deleted_at": null,
    "version": 882391722
  }
}
 
Suggest Edits

Consignments

 
 
 
Suggest Edits

List consignments

Returns a paginated list of consignments.

 
gethttps://domain_prefix.vendhq.com/api/2.0/consignments

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

outlet_id
UUID

The ID of the outlet which the consignment is targeted at.

type
string

The type of consignments to be returned.

status
string

The status of consignments to be returned.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/consignments
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/consignments' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/consignments")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/consignments");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/consignments"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "7dbe52cd-0ae4-11e4-a0f5-b8ca3a64f8f4",
      "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
      "name": "Order - Mon 14 Jul 2014",
      "due_at": null,
      "type": "SUPPLIER",
      "status": "RECEIVED",
      "supplier_id": null,
      "source_outlet_id": null,
      "consignment_date": "2014-07-13T23:22:00+00:00",
      "received_at": "2015-07-30T02:59:51+00:00",
      "show_inactive": true,
      "supplier_invoice": "",
      "reference": null,
      "total_count_gain": null,
      "total_cost_gain": null,
      "total_count_loss": null,
      "total_cost_loss": null,
      "created_at": "2014-07-13T23:22:00+00:00",
      "updated_at": "2015-07-30T02:59:51+00:00",
      "deleted_at": null,
      "version": 827406,
      "filters": []
    },
    {
      "id": "b8ca3a65-0183-11e4-fbb5-2812b9e74b37",
      "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
      "name": "Stocktake 1",
      "due_at": null,
      "type": "STOCKTAKE",
      "status": "STOCKTAKE_COMPLETE",
      "supplier_id": null,
      "source_outlet_id": null,
      "consignment_date": "2014-08-20T02:36:02+00:00",
      "received_at": "2014-08-20T02:37:32+00:00",
      "show_inactive": true,
      "supplier_invoice": "",
      "reference": null,
      "total_count_gain": null,
      "total_cost_gain": null,
      "total_count_loss": null,
      "total_cost_loss": null,
      "created_at": "2014-08-20T02:36:02+00:00",
      "updated_at": "2014-08-20T02:37:32+00:00",
      "deleted_at": null,
      "version": 1228871,
      "filters": []
    },
    {
      "id": "b8ca3a65-0183-11e4-fbb5-281711e05741",
      "outlet_id": "b8ca3a65-0183-11e4-fbb5-2816d2677218",
      "name": "Stock Transfer",
      "due_at": "2014-08-21T00:00:00+00:00",
      "type": "OUTLET",
      "status": "RECEIVED",
      "supplier_id": null,
      "source_outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
      "consignment_date": "2014-08-20T03:07:07+00:00",
      "received_at": "2014-08-20T03:08:49+00:00",
      "show_inactive": true,
      "supplier_invoice": "",
      "reference": null,
      "total_count_gain": null,
      "total_cost_gain": null,
      "total_count_loss": null,
      "total_cost_loss": null,
      "created_at": "2014-08-20T03:07:07+00:00",
      "updated_at": "2014-08-20T03:08:49+00:00",
      "deleted_at": null,
      "version": 1228872,
      "filters": []
    }
  ]
}
 
Suggest Edits

Create an inventory count

Creates a new consignment of type STOCKTAKE. Currently, this endpoint only supports creation of inventory counts (stock takes).

 
posthttps://domain_prefix.vendhq.com/api/2.0/consignments

Body Params

outlet_id
uuid
required

The ID of the outlet in which the count is taking place.

due_at
string

The date for which the count is scheduled.

show_inactive
boolean

Indicates whether inactive products should be included in the count.

name
string
required

The name of the inventory count

status
string
required

The status of the inventory count. One of: STOCKTAKE_SCHEDULED, STOCKTAKE_IN_PROGRESS, STOCKTAKE_IN_PROGRESS_PROCESSED, STOCKTAKE_COMPLETE.

filters
array of objects

An array of filter objects. Max 25.

type
string
required

Consignment type, for inventory counts always STOCKTAKE

 
curl --request POST \
  --url https://domain_prefix.vendhq.com/api/2.0/consignments
var request = require("request");

var options = { method: 'POST',
  url: 'https://domain_prefix.vendhq.com/api/2.0/consignments' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/consignments")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://domain_prefix.vendhq.com/api/2.0/consignments");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/consignments"

response = requests.request("POST", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": {
    "id": "0af7b240-ab83-11e7-eddc-402337165363",
    "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
    "name": "API Invenotry Count",
    "due_at": null,
    "type": "STOCKTAKE",
    "status": "STOCKTAKE_SCHEDULED",
    "supplier_id": null,
    "source_outlet_id": null,
    "consignment_date": "2017-05-24T01:49:25+00:00",
    "received_at": null,
    "show_inactive": true,
    "supplier_invoice": null,
    "reference": null,
    "total_count_gain": null,
    "total_cost_gain": null,
    "total_count_loss": null,
    "total_cost_loss": null,
    "created_at": "2017-05-24T01:49:25+00:00",
    "updated_at": "2017-05-24T01:49:25+00:00",
    "deleted_at": null,
    "version": 3505324485,
    "filters": []
  }
}
 
Suggest Edits

Get a single consignment

Returns a single consignment with the requested ID.

 
gethttps://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id

Path Params

consignment_id
uuid
required

Valid consignment ID.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": {
    "id": "7dbe52cd-0ae4-11e4-a0f5-b8ca3a64f8f4",
    "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
    "name": "Order - Mon 14 Jul 2014",
    "due_at": null,
    "type": "SUPPLIER",
    "status": "RECEIVED",
    "supplier_id": null,
    "source_outlet_id": null,
    "consignment_date": "2014-07-13T23:22:00+00:00",
    "received_at": "2015-07-30T02:59:51+00:00",
    "show_inactive": true,
    "supplier_invoice": "",
    "reference": null,
    "total_count_gain": null,
    "total_cost_gain": null,
    "total_count_loss": null,
    "total_cost_loss": null,
    "created_at": "2014-07-13T23:22:00+00:00",
    "updated_at": "2015-07-30T02:59:51+00:00",
    "deleted_at": null,
    "version": 827406,
    "filters": []
  }
}
 
Suggest Edits

Update an inventory count

Updates the inventory count with requested ID.

 
puthttps://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id

Path Params

consignment_id
uuid
required

Valid consignment ID.

Body Params

outlet_id
uuid
required

The ID of the outlet in which the count is taking place.

due_at
string

The date for which the count is scheduled.

show_inactive
boolean

Indicates whether inactive products should be included in the count.

name
string
required

The name of the inventory count

status
string
required

The status of the inventory count. One of: STOCKTAKE_SCHEDULED, STOCKTAKE_IN_PROGRESS, STOCKTAKE_IN_PROGRESS_PROCESSED, STOCKTAKE_COMPLETE.

filters
array of objects

An array of filter objects. Max 25.

type
string
required

Consignment type, for inventory counts always STOCKTAKE

 
curl --request PUT \
  --url https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id
var request = require("request");

var options = { method: 'PUT',
  url: 'https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("PUT", "https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id"

response = requests.request("PUT", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": {
    "id": "b8ca3a65-0183-11e4-fbb5-281711e05741",
    "outlet_id": "b8ca3a65-0183-11e4-fbb5-2816d2677218",
    "name": "Stock Transfer",
    "due_at": "2014-08-21T00:00:00+00:00",
    "type": "OUTLET",
    "status": "RECEIVED",
    "supplier_id": null,
    "source_outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
    "consignment_date": "2014-08-20T03:07:07+00:00",
    "received_at": "2014-08-20T03:08:49+00:00",
    "show_inactive": true,
    "supplier_invoice": "",
    "reference": null,
    "total_count_gain": null,
    "total_cost_gain": null,
    "total_count_loss": null,
    "total_cost_loss": null,
    "created_at": "2014-08-20T03:07:07+00:00",
    "updated_at": "2014-08-20T03:08:49+00:00",
    "deleted_at": null,
    "version": 1228872,
    "filters": []
  }
}
 
Suggest Edits

Delete a consignment

Deletes the consignment with the given ID.

 
deletehttps://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id

Path Params

consignment_id
uuid
required
 
curl --request DELETE \
  --url https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

List all products for a specific consignment

Returns a collection of consignment products associated with the specified consignment.

 
gethttps://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products

Path Params

consignment_id
uuid
required

The ID of the consignment for which products should be listed.

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "product_id": "fa16cdf8-063c-11e4-a0f5-b8ca3a64f8f4",
      "product_sku": null,
      "count": "10.00000",
      "received": "10.00000",
      "cost": "0.00000",
      "is_included": false,
      "status": "RECEIVE_SUCCESS",
      "created_at": "2015-02-23T18:46:12+00:00",
      "updated_at": "2015-07-30T02:59:51+00:00",
      "deleted_at": null,
      "version": 3542970
    },
    {
      "product_id": "fa16cdf8-063c-11e4-a0f5-b8ca3a64f8f4",
      "product_sku": null,
      "count": null,
      "received": "0.00000",
      "cost": "0.00000",
      "is_included": false,
      "status": "RECEIVE_SUCCESS",
      "created_at": "2015-02-23T18:46:24+00:00",
      "updated_at": "2015-07-30T02:59:51+00:00",
      "deleted_at": null,
      "version": 3542975
    },
    {
      "product_id": "fa16cdf8-063c-11e4-a0f5-b8ca3a64f8f4",
      "product_sku": null,
      "count": "10.00000",
      "received": "0.00000",
      "cost": "100.00000",
      "is_included": true,
      "status": "RECEIVE_SUCCESS",
      "created_at": "2014-07-13T23:22:59+00:00",
      "updated_at": "2015-07-30T02:59:51+00:00",
      "deleted_at": null,
      "version": 20813790
    }
  ],
  "version": {
    "max": 20813790,
    "min": 3542970
  }
}
 
Suggest Edits

Adjust the inventory item count

Increases or decreases the count for a specific product within the inventory count.

 
posthttps://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products

Path Params

consignment_id
uuid
required

Valid consignment ID.

Body Params

product_id
string
required

The ID of the product for which the count should be adjusted.

received
string
required

The adjustment value

 
curl --request POST \
  --url https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products
var request = require("request");

var options = { method: 'POST',
  url: 'https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products"

response = requests.request("POST", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Delete an item from an inventory count

Removes the count for a specific product from the inventory count.

 
deletehttps://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products/product_id

Path Params

consignment_id
string
required

Valid consignment (inventory count) ID.

product_id
string
required

The ID of a product included in the inventory count

 
curl --request DELETE \
  --url https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products/product_id
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products/product_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products/product_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products/product_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/consignments/consignment_id/products/product_id"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Channel request log

 
 
 
Suggest Edits

List request records

Returns a list of request log records.

 
gethttps://domain_prefix.vendhq.com/api/2.0/channel_requests

Query Params

status_code
string

Limit the requests to 1 or more status codes.

request_method
string

Limit the requests to 1 or more request methods.

occurred_before
date-time

Limit requests to before this RFC3339 date.

occurred_after
date-time

Limit requests to after this RFC3339 date.

status_code_before
string

Limit requests to those with status codes less than this value.

status_code_after
string

Limit requests to those with status codes greater than this value.

channel_id
string

If provided, request logs will be limited to the supplied channel id. If no id is provided, only requests logged with no channel id will be returned. Requests with no channel id indicate requests made during the setup process.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/channel_requests
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/channel_requests' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/channel_requests")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/channel_requests");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/channel_requests"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "1073019276397793280",
      "grouping_id": "job-5aa0bfd3f948109e314610883da6a6edf4c826db-1544662705",
      "request_method": "POST",
      "status_code": 200,
      "url": "https://woocommerce-domain.com/wp-json/wc/v2/products/batch",
      "request": "POST /wp-json/wc/v2/products/batch HTTP/1.1\r\nHost: woocommerce-domain.com\r\nUser-Agent: vend/integrations/268506b80c1d/go1.11\r\nContent-Length: 229\r\nAuthorization: [REDACTED]\r\nContent-Type: application/json\r\nAccept-Encoding: gzip\r\n\r\n{\"update\":[{\"id\":8,\"permalink\":\"\",\"date_created\":\"\",\"date_created_gmt\":\"0001-01-01T00:00:00\",\"date_modified\":\"\",\"date_modified_gmt\":\"0001-01-01T00:00:00\",\"price\":\"0\",\"stock_quantity\":\"0\",\"shipping_class_id\":0,\"variations\":null}]}",
      "response": "HTTP/2.0 200 OK\r\nContent-Length: 2137\r\nAccess-Control-Allow-Headers: Authorization, Content-Type\r\nAccess-Control-Expose-Headers: X-WP-Total, X-WP-TotalPages\r\nAllow: POST, PUT, PATCH\r\nCache-Control: no-cache, must-revalidate, max-age=0\r\nContent-Type: application/json; charset=UTF-8\r\nDate: Thu, 13 Dec 2018 00:58:25 GMT\r\nExpires: Wed, 11 Jan 1984 05:00:00 GMT\r\nLink: <https://woocommerce-domain.com/wp-json/>; rel=\"https://api.w.org/\"\r\nServer: nginx/1.14.1\r\nStrict-Transport-Security: max-age=31536000\r\nX-Content-Type-Options: nosniff\r\nX-Powered-By: PHP/7.2.12\r\nX-Robots-Tag: noindex\r\n\r\n{\"update\":[{\"id\":8,\"name\":\"Simple + All 2\",\"slug\":\"simple1\",\"permalink\":\"https:\\/\\/woocommerce-domain.com\\/product\\/simple1\\/\",\"date_created\":\"2018-12-12T23:39:14\",\"date_created_gmt\":\"2018-12-12T23:39:14\",\"date_modified\":\"2018-12-13T00:58:25\",\"date_modified_gmt\":\"2018-12-13T00:58:25\",\"type\":\"simple\",\"status\":\"publish\",\"featured\":false,\"catalog_visibility\":\"visible\",\"description\":\"Simple product\",\"short_description\":\"\",\"sku\":\"1000001\",\"price\":\"40\",\"regular_price\":\"40\",\"sale_price\":\"\",\"date_on_sale_from\":null,\"date_on_sale_from_gmt\":null,\"date_on_sale_to\":null,\"date_on_sale_to_gmt\":null,\"price_html\":\"<span class=\\\"woocommerce-Price-amount amount\\\"><span class=\\\"woocommerce-Price-currencySymbol\\\">&#36;<\\/span>40.00<\\/span>\",\"on_sale\":false,\"purchasable\":true,\"total_sales\":0,\"virtual\":false,\"downloadable\":false,\"downloads\":[],\"download_limit\":-1,\"download_expiry\":-1,\"external_url\":\"\",\"button_text\":\"\",\"tax_status\":\"taxable\",\"tax_class\":\"\",\"manage_stock\":true,\"stock_quantity\":0,\"in_stock\":false,\"backorders\":\"no\",\"backorders_allowed\":false,\"backordered\":false,\"sold_individually\":false,\"weight\":\"\",\"dimensions\":{\"length\":\"\",\"width\":\"\",\"height\":\"\"},\"shipping_required\":true,\"shipping_taxable\":true,\"shipping_class\":\"\",\"shipping_class_id\":0,\"reviews_allowed\":true,\"average_rating\":\"0\",\"rating_count\":0,\"related_ids\":[],\"upsell_ids\":[],\"cross_sell_ids\":[],\"parent_id\":0,\"purchase_note\":\"\",\"categories\":[{\"id\":16,\"name\":\"Type 1\",\"slug\":\"type-1\"}],\"tags\":[{\"id\":17,\"name\":\"Tag2\",\"slug\":\"tag2\"}],\"images\":[{\"id\":0,\"date_created\":\"2018-12-13T00:58:25\",\"date_created_gmt\":\"2018-12-13T00:58:25\",\"date_modified\":\"2018-12-13T00:58:25\",\"date_modified_gmt\":\"2018-12-13T00:58:25\",\"src\":\"https:\\/\\/woocommerce-domain.com\\/wp-content\\/plugins\\/woocommerce\\/assets\\/images\\/placeholder.png\",\"name\":\"Placeholder\",\"alt\":\"Placeholder\",\"position\":0}],\"attributes\":[],\"default_attributes\":[],\"variations\":[],\"grouped_products\":[],\"menu_order\":0,\"meta_data\":[],\"_links\":{\"self\":[{\"href\":\"https:\\/\\/woocommerce-domain.com\\/wp-json\\/wc\\/v2\\/products\\/8\"}],\"collection\":[{\"href\":\"https:\\/\\/woocommerce-domain.com\\/wp-json\\/wc\\/v2\\/products\"}]}}]}",
      "error": null,
      "occurred_at": "2018-12-13T00:58:25.919065Z"
    }
  ]
}
 
Suggest Edits

Get a single request log

Returns a single request log entry with a specific ID.

 
gethttps://domain_prefix.vendhq.com/api/2.0/channel_requests/request_log_id

Path Params

request_log_id
string
required
 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/channel_requests/request_log_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/channel_requests/request_log_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/channel_requests/request_log_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/channel_requests/request_log_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/channel_requests/request_log_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": {
    "id": "1073019276397793280",
    "grouping_id": "job-5aa0bfd3f948109e314610883da6a6edf4c826db-1544662705",
    "request_method": "POST",
    "status_code": 200,
    "url": "https://woocommerce-domain.com/wp-json/wc/v2/products/batch",
    "request": "POST /wp-json/wc/v2/products/batch HTTP/1.1\r\nHost: woocommerce-domain.com\r\nUser-Agent: vend/integrations/268506b80c1d/go1.11\r\nContent-Length: 229\r\nAuthorization: [REDACTED]\r\nContent-Type: application/json\r\nAccept-Encoding: gzip\r\n\r\n{\"update\":[{\"id\":8,\"permalink\":\"\",\"date_created\":\"\",\"date_created_gmt\":\"0001-01-01T00:00:00\",\"date_modified\":\"\",\"date_modified_gmt\":\"0001-01-01T00:00:00\",\"price\":\"0\",\"stock_quantity\":\"0\",\"shipping_class_id\":0,\"variations\":null}]}",
    "response": "HTTP/2.0 200 OK\r\nContent-Length: 2137\r\nAccess-Control-Allow-Headers: Authorization, Content-Type\r\nAccess-Control-Expose-Headers: X-WP-Total, X-WP-TotalPages\r\nAllow: POST, PUT, PATCH\r\nCache-Control: no-cache, must-revalidate, max-age=0\r\nContent-Type: application/json; charset=UTF-8\r\nDate: Thu, 13 Dec 2018 00:58:25 GMT\r\nExpires: Wed, 11 Jan 1984 05:00:00 GMT\r\nLink: <https://woocommerce-domain.com/wp-json/>; rel=\"https://api.w.org/\"\r\nServer: nginx/1.14.1\r\nStrict-Transport-Security: max-age=31536000\r\nX-Content-Type-Options: nosniff\r\nX-Powered-By: PHP/7.2.12\r\nX-Robots-Tag: noindex\r\n\r\n{\"update\":[{\"id\":8,\"name\":\"Simple + All 2\",\"slug\":\"simple1\",\"permalink\":\"https:\\/\\/woocommerce-domain.com\\/product\\/simple1\\/\",\"date_created\":\"2018-12-12T23:39:14\",\"date_created_gmt\":\"2018-12-12T23:39:14\",\"date_modified\":\"2018-12-13T00:58:25\",\"date_modified_gmt\":\"2018-12-13T00:58:25\",\"type\":\"simple\",\"status\":\"publish\",\"featured\":false,\"catalog_visibility\":\"visible\",\"description\":\"Simple product\",\"short_description\":\"\",\"sku\":\"1000001\",\"price\":\"40\",\"regular_price\":\"40\",\"sale_price\":\"\",\"date_on_sale_from\":null,\"date_on_sale_from_gmt\":null,\"date_on_sale_to\":null,\"date_on_sale_to_gmt\":null,\"price_html\":\"<span class=\\\"woocommerce-Price-amount amount\\\"><span class=\\\"woocommerce-Price-currencySymbol\\\">&#36;<\\/span>40.00<\\/span>\",\"on_sale\":false,\"purchasable\":true,\"total_sales\":0,\"virtual\":false,\"downloadable\":false,\"downloads\":[],\"download_limit\":-1,\"download_expiry\":-1,\"external_url\":\"\",\"button_text\":\"\",\"tax_status\":\"taxable\",\"tax_class\":\"\",\"manage_stock\":true,\"stock_quantity\":0,\"in_stock\":false,\"backorders\":\"no\",\"backorders_allowed\":false,\"backordered\":false,\"sold_individually\":false,\"weight\":\"\",\"dimensions\":{\"length\":\"\",\"width\":\"\",\"height\":\"\"},\"shipping_required\":true,\"shipping_taxable\":true,\"shipping_class\":\"\",\"shipping_class_id\":0,\"reviews_allowed\":true,\"average_rating\":\"0\",\"rating_count\":0,\"related_ids\":[],\"upsell_ids\":[],\"cross_sell_ids\":[],\"parent_id\":0,\"purchase_note\":\"\",\"categories\":[{\"id\":16,\"name\":\"Type 1\",\"slug\":\"type-1\"}],\"tags\":[{\"id\":17,\"name\":\"Tag2\",\"slug\":\"tag2\"}],\"images\":[{\"id\":0,\"date_created\":\"2018-12-13T00:58:25\",\"date_created_gmt\":\"2018-12-13T00:58:25\",\"date_modified\":\"2018-12-13T00:58:25\",\"date_modified_gmt\":\"2018-12-13T00:58:25\",\"src\":\"https:\\/\\/woocommerce-domain.com\\/wp-content\\/plugins\\/woocommerce\\/assets\\/images\\/placeholder.png\",\"name\":\"Placeholder\",\"alt\":\"Placeholder\",\"position\":0}],\"attributes\":[],\"default_attributes\":[],\"variations\":[],\"grouped_products\":[],\"menu_order\":0,\"meta_data\":[],\"_links\":{\"self\":[{\"href\":\"https:\\/\\/woocommerce-domain.com\\/wp-json\\/wc\\/v2\\/products\\/8\"}],\"collection\":[{\"href\":\"https:\\/\\/woocommerce-domain.com\\/wp-json\\/wc\\/v2\\/products\"}]}}]}",
    "error": null,
    "occurred_at": "2018-12-13T00:58:25.919065Z"
  }
}
 
Suggest Edits

Get a single request log as text

Returns a text representation of a single request log entry with a specific ID.

 
gethttps://domain_prefix.vendhq.com/api/2.0/channel_requests/request_log_id.txt

Path Params

request_log_id
string
required
 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/channel_requests/request_log_id.txt
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/channel_requests/request_log_id.txt' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/channel_requests/request_log_id.txt")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/channel_requests/request_log_id.txt");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/channel_requests/request_log_id.txt"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

ID                   1074422697280679936
GroupingID           api-TOx0VMzYJX
URL                  https://woo-i9n.dev.vendhq.works/wp-json/wc/v2/system_status
RequestMethod        GET
Request              GET /wp-json/wc/v2/system_status HTTP/1.1
                     Host: woo-i9n.dev.vendhq.works
                     User-Agent: vend/integrations/8e029c23748a/go1.10
                     Authorization: [REDACTED]
                     Content-Type: application/json
                     Accept-Encoding: gzip


StatusCode           401
Response             HTTP/2.0 401 Unauthorized
                     Content-Length: 107
                     Access-Control-Allow-Headers: Authorization, Content-Type
                     Access-Control-Expose-Headers: X-WP-Total, X-WP-TotalPages
                     Content-Type: application/json; charset=UTF-8
                     Date: Sun, 16 Dec 2018 21:55:07 GMT
                     Link: <https://woo-i9n.dev.vendhq.works/wp-json/>; rel="https://api.w.org/"
                     Server: nginx/1.14.0
                     Strict-Transport-Security: max-age=31536000
                     X-Content-Type-Options: nosniff
                     X-Powered-By: PHP/7.2.12
                     X-Robots-Tag: noindex

                     {"code":"woocommerce_rest_cannot_view","message":"Sorry, you cannot list resources.","data":{"status":401}}
 
Suggest Edits

List channel records

Returns a list of configured channels.

 
gethttps://domain_prefix.vendhq.com/api/2.0/channels
 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/channels
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/channels' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/channels")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/channels");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/channels"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Customer Groups

 
 
 
Suggest Edits

List customer groups

Returns a paginated list of customer groups.

 
gethttps://domain_prefix.vendhq.com/api/2.0/customer_groups

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/customer_groups
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/customer_groups' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/customer_groups")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/customer_groups");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/customer_groups"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "b1ca8902-f019-11e3-a0f5-b8ca3a64f8f4",
      "name": "All Customers",
      "group_id": "1111111111",
      "version": 29483,
      "created_at": "2014-06-09T21:04:49+00:00",
      "updated_at": "2014-06-09T21:04:49+00:00",
      "deleted_at": null
    },
    {
      "id": "dc85058a-a683-11e5-e112-46b9bd1f069e",
      "name": "VIP",
      "group_id": "VIP-Y968",
      "version": 157810,
      "created_at": "2015-08-19T21:32:06+00:00",
      "updated_at": "2015-08-19T21:32:06+00:00",
      "deleted_at": null
    },
    {
      "id": "06e35f89-3783-11e6-ec7e-0bf840380a64",
      "name": "Students",
      "group_id": "Students-2SFG",
      "version": 1205737356,
      "created_at": "2016-04-26T21:45:53+00:00",
      "updated_at": "2016-04-26T21:45:53+00:00",
      "deleted_at": null
    }
  ],
  "version": {
    "max": 1205737356,
    "min": 29483
  }
}
 
Suggest Edits

Customers

 
 
 
Suggest Edits

List customers

Returns a paginated list of customers.

 
gethttps://domain_prefix.vendhq.com/api/2.0/customers

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

deleted
boolean

Indicates whether deleted items should be included in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/customers
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/customers' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/customers")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/customers");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/customers"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "b8ca3a65-0183-11e4-fbb5-4f73f02a9d1c",
      "customer_code": "Tony-N4ZJ",
      "first_name": "Anthony",
      "last_name": "Stark",
      "email": "tony@stark.com",
      "year_to_date": 0,
      "balance": -25840.85,
      "loyalty_balance": 5809.64,
      "note": "",
      "gender": "M",
      "date_of_birth": "1963-03-03",
      "company_name": "Stark Industries Inc",
      "do_not_email": false,
      "phone": "+001 555 12345678",
      "mobile": "+001 485 23456789",
      "fax": "+001 555 12345345",
      "twitter": "@ironman",
      "website": "http://www.starkinc.com",
      "physical_suburb": "Suburb",
      "physical_city": "Los Angeles",
      "physical_postcode": "23422",
      "physical_state": "California",
      "postal_suburb": "Suburb",
      "postal_city": "Los Angeles",
      "postal_state": "California",
      "customer_group_id": "b1ca8902-f019-11e3-a0f5-b8ca3a64f8f4",
      "enable_loyalty": true,
      "created_at": "2014-10-09T05:20:09+00:00",
      "updated_at": "2017-01-19T16:49:35+00:00",
      "deleted_at": null,
      "version": 2691964626,
      "postal_postcode": "23422",
      "name": "Anthony Stark",
      "physical_address_1": "Street 1",
      "physical_address_2": "Street 2",
      "physical_country_id": "NZ",
      "postal_address_1": "Street 1",
      "postal_address_2": "Street 2",
      "postal_country_id": "NZ",
      "custom_field_1": "test",
      "custom_field_2": "",
      "custom_field_3": "",
      "custom_field_4": ""
    },
    {
      "id": "06bf537b-c783-11e6-ff13-f21286299973",
      "customer_code": "UNNAMED-669D",
      "first_name": null,
      "last_name": null,
      "email": null,
      "year_to_date": 0,
      "balance": 0,
      "loyalty_balance": 0,
      "note": null,
      "gender": null,
      "date_of_birth": null,
      "company_name": null,
      "do_not_email": false,
      "phone": null,
      "mobile": null,
      "fax": null,
      "twitter": null,
      "website": null,
      "physical_suburb": null,
      "physical_city": null,
      "physical_postcode": null,
      "physical_state": null,
      "postal_suburb": null,
      "postal_city": null,
      "postal_state": null,
      "customer_group_id": "b1ca8902-f019-11e3-a0f5-b8ca3a64f8f4",
      "enable_loyalty": true,
      "created_at": "2017-02-13T17:33:25+00:00",
      "updated_at": "2017-02-13T17:33:25+00:00",
      "deleted_at": null,
      "version": 2847386277,
      "postal_postcode": null,
      "name": null,
      "physical_address_1": null,
      "physical_address_2": null,
      "physical_country_id": null,
      "postal_address_1": null,
      "postal_address_2": null,
      "postal_country_id": null,
      "custom_field_1": null,
      "custom_field_2": null,
      "custom_field_3": null,
      "custom_field_4": null
    }
  ]
}
 
Suggest Edits

Create a new customer

Creates a new customer.

 
posthttps://domain_prefix.vendhq.com/api/2.0/customers

Body Params

first_name
string
required

Customer's first name.

last_name
string
required

Customer 's last name.

customer_code
string

Customer code used for claiming loyalty.

customer_group_id
string

Customer group ID.

enable_loyalty
boolean
email
string

Customer's email address.

note
string

Customer note.

gender
string

Customer's gender. Can be M, F or null.

date_of_birth
string

Birthday.

company_name
string

Company name.

do_not_email
boolean

Indicates whether the customer opted out of email communications.

phone
string

Phone no.

mobile
string

Mobile phone no.

fax
string

Fax no.

twitter
string

Twitter handle.

website
string

Website URL.

physical_address_1
string

Physical address, line 1.

physical_address_2
string

Physical address, line 2.

physical_suburb
string

Physical address, suburb.

physical_city
string

Physical address, city.

physical_postcode
string

Physical address, post code.

physical_state
string

Physical address, state.

physical_country_id
string

Physical address, country code.

postal_address_1
string

Postal address, line 1.

postal_address_2
string

Postal address, line 2.

postal_suburb
string

Postal address, suburb.

postal_city
string

Postal address, city.

postal_postcode
string

Postal address, post code.

postal_state
string

Postal address, state.

postal_country_id
string

Postal address, country code.

custom_field_1
string

Custom field 1. Can be used to store random data.

custom_field_2
string

Custom field 2.

custom_field_3
string

Custom field 3.

custom_field_4
string

Custom field 4.

 
curl --request POST \
  --url https://domain_prefix.vendhq.com/api/2.0/customers
var request = require("request");

var options = { method: 'POST',
  url: 'https://domain_prefix.vendhq.com/api/2.0/customers' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/customers")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://domain_prefix.vendhq.com/api/2.0/customers");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/customers"

response = requests.request("POST", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": {
    "id": "0af7b240-ab83-11e7-eddc-4023c64c85e5",
    "customer_code": "Tony-37YP",
    "name": "Tony Stark",
    "first_name": "Tony",
    "last_name": "Stark",
    "email": "tony@starkinc.com",
    "year_to_date": 0,
    "balance": 0,
    "loyalty_balance": 0,
    "note": null,
    "gender": null,
    "date_of_birth": null,
    "company_name": null,
    "do_not_email": false,
    "contact_source": null,
    "phone": null,
    "mobile": null,
    "fax": null,
    "twitter": null,
    "website": null,
    "physical_address_1": null,
    "physical_address_2": null,
    "physical_suburb": null,
    "physical_city": null,
    "physical_postcode": null,
    "physical_state": null,
    "physical_country_id": null,
    "postal_address_1": null,
    "postal_address_2": null,
    "postal_suburb": null,
    "postal_city": null,
    "postal_postcode": null,
    "postal_state": null,
    "postal_country_id": null,
    "customer_group_id": "b1ca8902-f019-11e3-a0f5-b8ca3a64f8f4",
    "enable_loyalty": true,
    "custom_field_1": null,
    "custom_field_2": null,
    "custom_field_3": null,
    "custom_field_4": null,
    "created_at": "2017-05-24T01:53:25+00:00",
    "updated_at": "2017-05-24T01:53:25+00:00",
    "deleted_at": null,
    "version": 3505346597
  }
}
 
Suggest Edits

Get a single customer

Returns a single customer with a requested ID.

 
gethttps://domain_prefix.vendhq.com/api/2.0/customers/customer_id

Path Params

customer_id
uuid
required

Valid customer ID.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/customers/customer_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/customers/customer_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/customers/customer_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/customers/customer_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/customers/customer_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": {
    "id": "b8ca3a65-0183-11e4-fbb5-4f73f02a9d1c",
    "customer_code": "Tony-N4ZJ",
    "first_name": "Anthony",
    "last_name": "Stark",
    "email": "tony@stark.com",
    "year_to_date": 0,
    "balance": -25840.85,
    "loyalty_balance": 5809.64,
    "note": "",
    "gender": "M",
    "date_of_birth": "1963-03-03",
    "company_name": "Stark Industries Inc",
    "do_not_email": false,
    "phone": "+001 555 12345678",
    "mobile": "+001 485 23456789",
    "fax": "+001 555 12345345",
    "twitter": "@ironman",
    "website": "http://www.starkinc.com",
    "physical_suburb": "Suburb",
    "physical_city": "Los Angeles",
    "physical_postcode": "23422",
    "physical_state": "California",
    "postal_suburb": "Suburb",
    "postal_city": "Los Angeles",
    "postal_state": "California",
    "customer_group_id": "b1ca8902-f019-11e3-a0f5-b8ca3a64f8f4",
    "enable_loyalty": true,
    "created_at": "2014-10-09T05:20:09+00:00",
    "updated_at": "2017-01-19T16:49:35+00:00",
    "deleted_at": null,
    "version": 2691964626,
    "postal_postcode": "23422",
    "name": "Anthony Stark",
    "physical_address_1": "Street 1",
    "physical_address_2": "Street 2",
    "physical_country_id": "NZ",
    "postal_address_1": "Street 1",
    "postal_address_2": "Street 2",
    "postal_country_id": "NZ",
    "custom_field_1": "test",
    "custom_field_2": "",
    "custom_field_3": "",
    "custom_field_4": ""
  }
}
 
Suggest Edits

Update a customer

Updates the customer with the requested ID.

 
puthttps://domain_prefix.vendhq.com/api/2.0/customers/customer_id

Path Params

customer_id
uuid
required

Valid customer ID.

Body Params

first_name
string
required

Customer's first name.

last_name
string
required

Customer 's last name.

customer_code
string

Customer code used for claiming loyalty.

customer_group_id
string

Customer group ID.

enable_loyalty
boolean
email
string

Customer's email address.

note
string

Customer note.

gender
string

Customer's gender. Can be M, F or null.

date_of_birth
string

Birthday.

company_name
string

Company name.

do_not_email
boolean

Indicates whether the customer opted out of email communications.

phone
string

Phone no.

mobile
string

Mobile phone no.

fax
string

Fax no.

twitter
string

Twitter handle.

website
string

Website URL.

physical_address_1
string

Physical address, line 1.

physical_address_2
string

Physical address, line 2.

physical_suburb
string

Physical address, suburb.

physical_city
string

Physical address, city.

physical_postcode
string

Physical address, post code.

physical_state
string

Physical address, state.

physical_country_id
string

Physical address, country code.

postal_address_1
string

Postal address, line 1.

postal_address_2
string

Postal address, line 2.

postal_suburb
string

Postal address, suburb.

postal_city
string

Postal address, city.

postal_postcode
string

Postal address, post code.

postal_state
string

Postal address, state.

postal_country_id
string

Postal address, country code.

custom_field_1
string

Custom field 1. Can be used to store random data.

custom_field_2
string

Custom field 2.

custom_field_3
string

Custom field 3.

custom_field_4
string

Custom field 4.

 
curl --request PUT \
  --url https://domain_prefix.vendhq.com/api/2.0/customers/customer_id
var request = require("request");

var options = { method: 'PUT',
  url: 'https://domain_prefix.vendhq.com/api/2.0/customers/customer_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/customers/customer_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("PUT", "https://domain_prefix.vendhq.com/api/2.0/customers/customer_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/customers/customer_id"

response = requests.request("PUT", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": {
    "id": "0af7b240-ab83-11e7-eddc-4025043113d5",
    "customer_code": "Tony-AB2W",
    "name": "Tony Stark",
    "first_name": "Tony",
    "last_name": "Stark",
    "email": "tony@starkinc.com",
    "year_to_date": 0,
    "balance": 0,
    "loyalty_balance": 0,
    "note": null,
    "gender": null,
    "date_of_birth": null,
    "company_name": "Stark Inc.",
    "do_not_email": false,
    "contact_source": null,
    "phone": null,
    "mobile": null,
    "fax": null,
    "twitter": null,
    "website": null,
    "physical_address_1": null,
    "physical_address_2": null,
    "physical_suburb": null,
    "physical_city": null,
    "physical_postcode": null,
    "physical_state": null,
    "physical_country_id": null,
    "postal_address_1": null,
    "postal_address_2": null,
    "postal_suburb": null,
    "postal_city": null,
    "postal_postcode": null,
    "postal_state": null,
    "postal_country_id": null,
    "customer_group_id": "b1ca8902-f019-11e3-a0f5-b8ca3a64f8f4",
    "enable_loyalty": true,
    "custom_field_1": "Custom value 1",
    "custom_field_2": "Custom value 2",
    "custom_field_3": "Custom value 3",
    "custom_field_4": "Custom value 4",
    "created_at": "2017-05-24T02:02:18+00:00",
    "updated_at": "2017-05-24T02:03:59+00:00",
    "deleted_at": null,
    "version": 3505431251
  }
}
 
Suggest Edits

Delete a customer

Deletes the customer with the requested ID.

 
deletehttps://domain_prefix.vendhq.com/api/2.0/customers/customer_id

Path Params

customer_id
uuid
required

Valid customer ID.

 
curl --request DELETE \
  --url https://domain_prefix.vendhq.com/api/2.0/customers/customer_id
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://domain_prefix.vendhq.com/api/2.0/customers/customer_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/customers/customer_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://domain_prefix.vendhq.com/api/2.0/customers/customer_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/customers/customer_id"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Inventory

 
 
 
Suggest Edits

List inventory records

Returns a paginated list of inventory records.

 
gethttps://domain_prefix.vendhq.com/api/2.0/inventory

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/inventory
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/inventory' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/inventory")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/inventory");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/inventory"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "7896f269-2b20-ff38-602a-ace60b172b12",
      "product_id": "a0369f1f-9083-11e4-f68e-d26298afef03",
      "outlet_id": "b8ca3a65-0183-11e4-fbb5-2816d2677218",
      "inventory_level": 0,
      "reorder_point": null,
      "reorder_amount": null,
      "version": 1639940
    },
    {
      "id": "c15190b9-0c37-6b52-54e2-f804b00fa8c5",
      "product_id": "a0369f1f-9083-11e4-f68e-d26298afef03",
      "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
      "inventory_level": 0,
      "reorder_point": null,
      "reorder_amount": null,
      "version": 1639941
    },
    {
      "id": "0b32fb5c-9cff-5d26-2b64-1593ed2a463b",
      "product_id": "a0369f1f-9083-11e4-f68e-cc284567c50d",
      "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
      "inventory_level": -10,
      "reorder_point": null,
      "reorder_amount": null,
      "version": 3426971
    }
  ]
}
 
Suggest Edits

Outlet Product Taxes

 
 
 
Suggest Edits

List outlet product taxes

Returns a paginated list of outlet-product-tax records.

 
gethttps://domain_prefix.vendhq.com/api/2.0/outlet_taxes

Query Params

outlet_id
string

The ID of the outlet for which the results should be returned.

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

deleted
boolean

Indicates whether deleted items should be included in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/outlet_taxes
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/outlet_taxes' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/outlet_taxes")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/outlet_taxes");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/outlet_taxes"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
      "product_id": "b8ca3a65-0183-11e4-fbb5-281af7f3d091",
      "tax_id": "b1d192bc-f019-11e3-a0f5-b8ca3a64f8f4",
      "deleted_at": null,
      "version": 2162167
    },
    {
      "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
      "product_id": "b8ca3a65-0183-11e4-fbb5-281b151ee9a6",
      "tax_id": "b1d192bc-f019-11e3-a0f5-b8ca3a64f8f4",
      "deleted_at": null,
      "version": 2162183
    },
    {
      "outlet_id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
      "product_id": "b8ca3a64-f883-11e4-e0f5-15e94b089bc5",
      "tax_id": "b1cecdf6-f019-11e3-a0f5-b8ca3a64f8f4",
      "deleted_at": null,
      "version": 10734484
    }
  ],
  "version": {
    "min": 2162167,
    "max": 10734484
  }
}
 
 
 
 
Suggest Edits

List outlets

Returns a collection of outlets.

 
gethttps://domain_prefix.vendhq.com/api/2.0/outlets

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

deleted
boolean

Indicates whether deleted items should be included in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/outlets
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/outlets' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/outlets")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/outlets");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/outlets"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "b8ca3a65-0183-11e4-fbb5-2816d2677218",
      "name": "Second Outlet",
      "default_tax_id": "b1d192bc-f019-11e3-a0f5-b8ca3a64f8f4",
      "currency": "NZD",
      "currency_symbol": "$",
      "display_prices": "inclusive",
      "time_zone": "Pacific/Auckland",
      "physical_address_1": "Nuffield Street",
      "physical_address_2": "",
      "physical_suburb": "Newmarket",
      "physical_city": "Auckland",
      "physical_postcode": "1023",
      "physical_state": "Auckland",
      "physical_country_id": "NZ",
      "deleted_at": null,
      "version": 816974914,
      "attributes": []
    },
    {
      "id": "b1e04bd8-f019-11e3-a0f5-b8ca3a64f8f4",
      "name": "Main Outlet",
      "default_tax_id": "b1d192bc-f019-11e3-a0f5-b8ca3a64f8f4",
      "currency": "NZD",
      "currency_symbol": "$",
      "display_prices": "inclusive",
      "time_zone": "Pacific/Auckland",
      "physical_address_1": "Baker Street",
      "physical_address_2": "",
      "physical_suburb": "",
      "physical_city": "London",
      "physical_postcode": "",
      "physical_state": "",
      "physical_country_id": "GB",
      "deleted_at": null,
      "version": 909257071,
      "attributes": []
    },
    {
      "id": "06bf537b-c783-11e6-f6b9-53a81bd6b215",
      "name": "Sydney",
      "default_tax_id": "b1d192bc-f019-11e3-a0f5-b8ca3a64f8f4",
      "currency": "NZD",
      "currency_symbol": "$",
      "display_prices": "inclusive",
      "time_zone": "Australia/Sydney",
      "physical_address_1": "",
      "physical_address_2": "",
      "physical_suburb": "",
      "physical_city": "Sydney",
      "physical_postcode": "",
      "physical_state": "NSW",
      "physical_country_id": "AU",
      "deleted_at": null,
      "version": 1690497245,
      "attributes": [
        {
          "key": "order_reference",
          "value": "1"
        },
        {
          "key": "order_reference_prefix",
          "value": "SYD"
        },
        {
          "key": "return_reference",
          "value": "1"
        },
        {
          "key": "return_reference_prefix",
          "value": "SYD"
        }
      ]
    }
  ],
  "version": {
    "max": 1690497245,
    "min": 816974914
  }
}
 
Suggest Edits

Get a single outlet

Returns a single outlet with the requested ID.

 
gethttps://domain_prefix.vendhq.com/api/2.0/outlets/outlet_id

Path Params

outlet_id
uuid
required

Valid Outlet ID.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/outlets/outlet_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/outlets/outlet_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/outlets/outlet_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/outlets/outlet_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/outlets/outlet_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": {
    "id": "b8ca3a65-0183-11e4-fbb5-2816d2677218",
    "name": "Second Outlet",
    "default_tax_id": "b1d192bc-f019-11e3-a0f5-b8ca3a64f8f4",
    "currency": "NZD",
    "currency_symbol": "$",
    "display_prices": "inclusive",
    "time_zone": "Pacific/Auckland",
    "physical_address_1": "Nuffield Street",
    "physical_address_2": "",
    "physical_suburb": "Newmarket",
    "physical_city": "Auckland",
    "physical_postcode": "1023",
    "physical_state": "Auckland",
    "physical_country_id": "NZ",
    "deleted_at": null,
    "version": 816974914,
    "attributes": []
  }
}
 
Suggest Edits

Payment Types

 
 
 
Suggest Edits

List payment types

Returns a paginated collection of payment types.

 
gethttps://domain_prefix.vendhq.com/api/2.0/payment_types

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/payment_types
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/payment_types' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/payment_types")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/payment_types");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/payment_types"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "0adaafb3-6583-11e5-fb60-fd093076e9d3",
      "name": "Gift Card",
      "type_id": 118,
      "config": null,
      "deleted_at": null,
      "version": 1120194938
    },
    {
      "id": "dc85058a-a683-11e5-e112-51cc5a8ffc96",
      "name": "Loyalty",
      "type_id": 106,
      "config": {
        "url": "/pay/dc85058a-a683-11e5-e112-51cc5a8ffc96"
      },
      "deleted_at": null,
      "version": 342955
    },
    {
      "id": "dc85058a-a683-11e5-ef46-0b1f0d167dea",
      "name": "DPS",
      "type_id": 3,
      "config": {
        "url": "https://sec.paymentexpress.com/pxmi/logon",
        "print": true
      },
      "deleted_at": null,
      "version": 297938
    }
  ],
  "version": {
    "max": 1120194938,
    "min": 297938
  }
}
 
Suggest Edits

Price Book Products

 
 
 
Suggest Edits

List price book products

Returns a paginated list of price book products.

 
gethttps://domain_prefix.vendhq.com/api/2.0/price_book_products

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/price_book_products
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/price_book_products' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/price_book_products")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/price_book_products");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/price_book_products"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "327a1b25-4a47-9ba7-15cd-f65dfb3f06e2",
      "product_id": "9a84e9e1-f038-11e3-a0f5-b8ca3a64f8f4",
      "price_book_id": "b1cc4593-f019-11e3-a0f5-b8ca3a64f8f4",
      "price": 0,
      "loyalty_value": null,
      "min_units": null,
      "max_units": null,
      "version": 74322454,
      "created_at": "2014-06-10T00:46:05+00:00",
      "updated_at": "2014-06-10T00:46:05+00:00",
      "deleted_at": null
    },
    {
      "id": "dc85058a-a683-11e4-ef46-e15361f7916a",
      "product_id": "188a87aa-06fe-11e4-a0f5-b8ca3a64f8f4",
      "price_book_id": "dc85058a-a683-11e4-ef46-e1535cf1ebe5",
      "price": 246.92,
      "loyalty_value": 22,
      "min_units": 12.5,
      "max_units": 43.2,
      "version": 94533112,
      "created_at": "2014-07-09T00:15:13+00:00",
      "updated_at": "2016-04-13T22:27:29+00:00",
      "deleted_at": null
    },
    {
      "id": "dc85058a-a683-11e5-ef46-0fe437d43747",
      "product_id": "b8ca3a65-0183-11e4-fbb5-6ba391393b6e",
      "price_book_id": "dc85058a-a683-11e4-ef46-e1535cf1ebe5",
      "price": 1200,
      "loyalty_value": null,
      "min_units": null,
      "max_units": null,
      "version": 107001929,
      "created_at": "2014-11-14T02:11:38+00:00",
      "updated_at": "2015-06-11T02:47:49+00:00",
      "deleted_at": null
    }
  ]
}
 
Suggest Edits

Price Books

 
 
 
Suggest Edits

List price books

Returns a paginated list of price books

 
gethttps://domain_prefix.vendhq.com/api/2.0/price_books

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/price_books
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/price_books' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/price_books")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/price_books");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/price_books"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "b1cc4593-f019-11e3-a0f5-b8ca3a64f8f4",
      "name": "General Price Book (All Products)",
      "type": "BASE",
      "valid_from": null,
      "valid_to": null,
      "restrict_to_platform_key": "1",
      "restrict_to_platform_label": "In Store",
      "customer_group": {
        "id": "b1ca8902-f019-11e3-a0f5-b8ca3a64f8f4",
        "name": "All Customers",
        "group_id": "1111111111",
        "version": 29483,
        "created_at": "2014-06-09T21:04:49+00:00",
        "updated_at": "2014-06-09T21:04:49+00:00",
        "deleted_at": null
      },
      "customer_group_id": "b1ca8902-f019-11e3-a0f5-b8ca3a64f8f4",
      "outlet": null,
      "outlet_id": null,
      "version": 368354,
      "deleted_at": null
    },
    {
      "id": "dc85058a-a683-11e4-ef46-e2ecc5bda31a",
      "name": "API test",
      "type": "GENERAL",
      "valid_from": null,
      "valid_to": null,
      "restrict_to_platform_key": "1",
      "restrict_to_platform_label": "In Store",
      "customer_group": {
        "id": "b1ca8902-f019-11e3-a0f5-b8ca3a64f8f4",
        "name": "All Customers",
        "group_id": "1111111111",
        "version": 29483,
        "created_at": "2014-06-09T21:04:49+00:00",
        "updated_at": "2014-06-09T21:04:49+00:00",
        "deleted_at": null
      },
      "customer_group_id": "b1ca8902-f019-11e3-a0f5-b8ca3a64f8f4",
      "outlet": null,
      "outlet_id": null,
      "version": 398146,
      "deleted_at": null
    }
  ]
}
 
Suggest Edits

Get a single price book

Returns a single price book with a requested ID

 
gethttps://domain_prefix.vendhq.com/api/2.0/price_books/price_book_id

Path Params

price_book_id
uuid
required

Valid price book ID.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/price_books/price_book_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/price_books/price_book_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/price_books/price_book_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/price_books/price_book_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/price_books/price_book_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": {
    "id": "b1cc4593-f019-11e3-a0f5-b8ca3a64f8f4",
    "name": "General Price Book (All Products)",
    "type": "BASE",
    "valid_from": null,
    "valid_to": null,
    "restrict_to_platform_key": 1,
    "restrict_to_platform_label": "In Store",
    "customer_group": {
      "id": "b1ca8902-f019-11e3-a0f5-b8ca3a64f8f4",
      "name": "All Customers",
      "group_id": "1111111111",
      "version": 29483,
      "created_at": "2014-06-09T21:04:49+00:00",
      "updated_at": "2014-06-09T21:04:49+00:00",
      "deleted_at": null
    },
    "customer_group_id": "b1ca8902-f019-11e3-a0f5-b8ca3a64f8f4",
    "outlet": null,
    "outlet_id": null,
    "version": 368354,
    "deleted_at": null
  }
}
 
Suggest Edits

Product Images

 
 
 
Suggest Edits

Get a single product_image data

Returns the metadata for a single product image with a given ID.
This method is useful for checking the status of an image after it was uploaded.

 
gethttps://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id

Path Params

product_image_id
uuid
required

Valid product ID.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Set image position

Allows for changing the image position in the list

 
puthttps://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id

Path Params

product_image_id
string
required

Body Params

position
double
required

New position for the image.

 
curl --request PUT \
  --url https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id
var request = require("request");

var options = { method: 'PUT',
  url: 'https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("PUT", "https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id"

response = requests.request("PUT", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Delete a product_image

Deletes the product_image with the requested ID.

 
deletehttps://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id

Path Params

product_image_id
string
required
 
curl --request DELETE \
  --url https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id
var request = require("request");

var options = { method: 'DELETE',
  url: 'https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("DELETE", "https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/product_images/product_image_id"

response = requests.request("DELETE", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Product Types

 
 
 
Suggest Edits

ListProductTypes

Returns a paginated list of product types.

 
gethttps://domain_prefix.vendhq.com/api/2.0/product_types

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/product_types
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/product_types' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/product_types")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/product_types");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/product_types"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "b1e2babe-f019-11e3-a0f5-b8ca3a64f8f4",
      "name": "General",
      "deleted_at": null,
      "version": 449902
    },
    {
      "id": "b8ca3a65-0183-11e4-fbb5-3a61730ca2ef",
      "name": "Test type",
      "deleted_at": null,
      "version": 551718
    },
    {
      "id": "bc305bf6-6183-11e4-f15a-162d346b231e",
      "name": "Enrollment Packages",
      "deleted_at": null,
      "version": 627462
    }
  ]
}
 
Suggest Edits

Get a single product type

Returns a single product type with a given ID.

 
gethttps://domain_prefix.vendhq.com/api/2.0/product_types/product_type_id

Path Params

product_type_id
uuid
required

Valid product type ID.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/product_types/product_type_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/product_types/product_type_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/product_types/product_type_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/product_types/product_type_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/product_types/product_type_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": {
    "id": "b1e2babe-f019-11e3-a0f5-b8ca3a64f8f4",
    "name": "General",
    "deleted_at": null,
    "version": 449902
  }
}
 
 
 
 
Suggest Edits

List products

Returns a paginated list of products.

 
gethttps://domain_prefix.vendhq.com/api/2.0/products

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

deleted
boolean

Indicates whether deleted items should be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/products
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/products' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/products")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/products");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/products"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": [
    {
      "id": "b8ca3a65-0183-11e4-fbb5-9776c5cd0240",
      "source_id": null,
      "source_variant_id": null,
      "variant_parent_id": null,
      "name": "Product 0003",
      "variant_name": "Product 0003",
      "handle": "0003",
      "sku": "0003",
      "supplier_code": null,
      "active": true,
      "has_inventory": true,
      "is_composite": false,
      "description": null,
      "image_url": "https://secure.vendhq.com/images/placeholder/product/no-image-white-standard.png",
      "created_at": "2015-01-08T20:41:50+00:00",
      "updated_at": "2015-08-18T23:28:00+00:00",
      "deleted_at": null,
      "source": "USER",
      "account_code": null,
      "account_code_purchase": null,
      "supply_price": 0,
      "version": 59780745,
      "type": null,
      "supplier": null,
      "brand": null,
      "variant_options": [],
      "categories": [],
      "images": [],
      "has_variants": false,
      "button_order": 0,
      "price_including_tax": 3.02632,
      "price_excluding_tax": 2.63158,
      "loyalty_amount": null,
      "supplier_id": null,
      "product_type_id": null,
      "brand_id": null,
      "is_active": true,
      "image_thumbnail_url": "https://secure.vendhq.com/images/placeholder/product/no-image-white-thumb.png",
      "tag_ids": [],
      "attributes": []
    },
    {
      "id": "b8ca3a65-0183-11e4-fbb5-9776c5faaed2",
      "source_id": null,
      "source_variant_id": null,
      "variant_parent_id": null,
      "name": "Product 0005",
      "variant_name": "Product 0005",
      "handle": "0005",
      "sku": "0005",
      "supplier_code": null,
      "active": true,
      "has_inventory": true,
      "is_composite": false,
      "description": null,
      "image_url": "https://secure.vendhq.com/images/placeholder/product/no-image-white-standard.png",
      "created_at": "2015-01-08T20:41:51+00:00",
      "updated_at": "2015-08-18T23:28:00+00:00",
      "deleted_at": null,
      "source": "USER",
      "account_code": null,
      "account_code_purchase": null,
      "supply_price": 0,
      "version": 59780753,
      "type": null,
      "supplier": null,
      "brand": null,
      "variant_options": [],
      "categories": [],
      "images": [],
      "has_variants": false,
      "button_order": 0,
      "price_including_tax": 5.04385,
      "price_excluding_tax": 4.38596,
      "loyalty_amount": null,
      "supplier_id": null,
      "product_type_id": null,
      "brand_id": null,
      "is_active": true,
      "image_thumbnail_url": "https://secure.vendhq.com/images/placeholder/product/no-image-white-thumb.png",
      "tag_ids": [],
      "attributes": []
    },
    {
      "id": "b8ca3a65-0183-11e4-fbb5-9776c611d865",
      "source_id": null,
      "source_variant_id": null,
      "variant_parent_id": null,
      "name": "Product 0006",
      "variant_name": "Product 0006",
      "handle": "0006",
      "sku": "0006",
      "supplier_code": null,
      "active": true,
      "has_inventory": true,
      "is_composite": false,
      "description": null,
      "image_url": "https://secure.vendhq.com/images/placeholder/product/no-image-white-standard.png",
      "created_at": "2015-01-08T20:41:51+00:00",
      "updated_at": "2015-08-18T23:28:00+00:00",
      "deleted_at": null,
      "source": "USER",
      "account_code": null,
      "account_code_purchase": null,
      "supply_price": 0,
      "version": 59780757,
      "type": null,
      "supplier": null,
      "brand": null,
      "variant_options": [],
      "categories": [],
      "images": [],
      "has_variants": false,
      "button_order": 0,
      "price_including_tax": 6.05263,
      "price_excluding_tax": 5.26316,
      "loyalty_amount": null,
      "supplier_id": null,
      "product_type_id": null,
      "brand_id": null,
      "is_active": true,
      "image_thumbnail_url": "https://secure.vendhq.com/images/placeholder/product/no-image-white-thumb.png",
      "tag_ids": [],
      "attributes": []
    }
  ],
  "version": {
    "min": 59780745,
    "max": 59780757
  }
}
 
Suggest Edits

Get a single product

Returns a single product object with a given ID.

 
gethttps://domain_prefix.vendhq.com/api/2.0/products/product_id

Path Params

product_id
uuid
required

Valid product ID.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/products/product_id
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/products/product_id' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/products/product_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "https://domain_prefix.vendhq.com/api/2.0/products/product_id");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/products/product_id"

response = requests.request("GET", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

{
  "data": {
    "id": "b8ca3a65-0183-11e4-fbb5-7988a6ed80f8",
    "source_id": null,
    "source_variant_id": null,
    "variant_parent_id": null,
    "name": "Bravo",
    "variant_name": "Bravo / Black / Cotton / Cotton",
    "handle": "bravo",
    "sku": "787878",
    "supplier_code": "123456",
    "active": true,
    "has_inventory": true,
    "is_composite": false,
    "description": "<p>The best product ever, except for the next one.</p>",
    "image_url": "https://vendimageuploadcdn.global.ssl.fastly.net/350,fit,q90/vend-images/product/original/f/0/f0ebadbc30947444d438678a4a7bd6d996f392fc.jpg",
    "created_at": "2014-12-01T18:34:15+00:00",
    "updated_at": "2017-08-21T23:50:39+00:00",
    "deleted_at": null,
    "source": "USER",
    "account_code": null,
    "account_code_purchase": null,
    "supply_price": 100,
    "version": 4284638488,
    "type": {
      "id": "b1e2babe-f019-11e3-a0f5-b8ca3a64f8f4",
      "name": "General",
      "deleted_at": null,
      "version": 449902
    },
    "supplier": {
      "id": "dc85058a-a683-11e5-ef46-08f9a926615e",
      "name": "Peak",
      "source": "",
      "description": "",
      "deleted_at": null,
      "version": 2089502
    },
    "brand": {
      "id": "0adaafb3-6583-11e5-fb60-d5b67a17df2f",
      "name": "Peak Performance",
      "deleted_at": null,
      "version": 882391722
    },
    "variant_options": [
      {
        "id": "9a972fbe-3b53-102e-b60f-4abbcbc88955",
        "name": "Color",
        "value": "Black"
      },
      {
        "id": "6b8f11e2-5188-11e0-9d7a-4040f540b50a",
        "name": "Fabric",
        "value": "Cotton"
      },
      {
        "id": "6b8f11e2-5188-11e0-9d7a-4040f540b50a",
        "name": "Fabric",
        "value": "Cotton"
      }
    ],
    "categories": [
      {
        "id": "b8ca3a65-0183-11e4-fbb5-a7e973b74d92",
        "name": "tag_test",
        "deleted_at": null,
        "version": 1446856
      },
      {
        "id": "bc305bf6-6183-11e4-f15a-16ced23b8465",
        "name": "variant",
        "deleted_at": null,
        "version": 961180
      }
    ],
    "images": [
      {
        "id": "06bf537b-c783-11e6-f6b9-b73917d393b6",
        "url": "https://vendimageuploadcdn.global.ssl.fastly.net/1920,fit/vend-images/product/original/f/0/f0ebadbc30947444d438678a4a7bd6d996f392fc.jpg",
        "version": 2398861114,
        "sizes": {
          "ss": "https://vendimageuploadcdn.global.ssl.fastly.net/50x50,q90/vend-images/product/original/f/0/f0ebadbc30947444d438678a4a7bd6d996f392fc.jpg",
          "standard": "https://vendimageuploadcdn.global.ssl.fastly.net/350,fit,q90/vend-images/product/original/f/0/f0ebadbc30947444d438678a4a7bd6d996f392fc.jpg",
          "st": "https://vendimageuploadcdn.global.ssl.fastly.net/40x40,q90/vend-images/product/original/f/0/f0ebadbc30947444d438678a4a7bd6d996f392fc.jpg",
          "original": "https://vendimageuploadcdn.global.ssl.fastly.net/1920,fit/vend-images/product/original/f/0/f0ebadbc30947444d438678a4a7bd6d996f392fc.jpg",
          "thumb": "https://vendimageuploadcdn.global.ssl.fastly.net/160,fit,q90/vend-images/product/original/f/0/f0ebadbc30947444d438678a4a7bd6d996f392fc.jpg",
          "sl": "https://vendimageuploadcdn.global.ssl.fastly.net/150x150,q90/vend-images/product/original/f/0/f0ebadbc30947444d438678a4a7bd6d996f392fc.jpg",
          "sm": "https://vendimageuploadcdn.global.ssl.fastly.net/100x100,q90/vend-images/product/original/f/0/f0ebadbc30947444d438678a4a7bd6d996f392fc.jpg"
        }
      }
    ],
    "has_variants": true,
    "button_order": 2,
    "price_including_tax": 126.5,
    "price_excluding_tax": 110,
    "loyalty_amount": null,
    "attributes": [],
    "supplier_id": "dc85058a-a683-11e5-ef46-08f9a926615e",
    "product_type_id": "b1e2babe-f019-11e3-a0f5-b8ca3a64f8f4",
    "brand_id": "0adaafb3-6583-11e5-fb60-d5b67a17df2f",
    "is_active": true,
    "image_thumbnail_url": "https://vendimageuploadcdn.global.ssl.fastly.net/160,fit,q90/vend-images/product/original/f/0/f0ebadbc30947444d438678a4a7bd6d996f392fc.jpg",
    "tag_ids": [
      "b8ca3a65-0183-11e4-fbb5-a7e973b74d92",
      "bc305bf6-6183-11e4-f15a-16ced23b8465"
    ]
  }
}
 
Suggest Edits

Upload an image

Upload a binary file with an image to be used for a product. This request should be encoded as multipart/form-data.

 
posthttps://domain_prefix.vendhq.com/api/2.0/products/product_id/actions/image_upload

Path Params

product_id
UUID
required

The ID of the product which the imaged should be associated with.

Form Data

image
file
required

File to upload. Can be in jpg or png format.

 
curl --request POST \
  --url https://domain_prefix.vendhq.com/api/2.0/products/product_id/actions/image_upload
var request = require("request");

var options = { method: 'POST',
  url: 'https://domain_prefix.vendhq.com/api/2.0/products/product_id/actions/image_upload' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/products/product_id/actions/image_upload")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
var data = JSON.stringify(false);

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "https://domain_prefix.vendhq.com/api/2.0/products/product_id/actions/image_upload");

xhr.send(data);
import requests

url = "https://domain_prefix.vendhq.com/api/2.0/products/product_id/actions/image_upload"

response = requests.request("POST", url)

print(response.text)
A binary file was returned

Your OAuth2 token is incorrect or has expired

No response examples available
 
Suggest Edits

Get inventory data for a single product

Returns inventory data for a single product in all the outlets.

 
gethttps://domain_prefix.vendhq.com/api/2.0/products/product_id/inventory

Path Params

product_id
uuid
required

Valid product ID.

Query Params

after
int64

The lower limit for the version numbers to be included in the response.

before
int64

The upper limit for the version numbers to be included in the response.

page_size
integer

The maximum number of items to be returned in the response.

 
curl --request GET \
  --url https://domain_prefix.vendhq.com/api/2.0/products/product_id/inventory
var request = require("request");

var options = { method: 'GET',
  url: 'https://domain_prefix.vendhq.com/api/2.0/products/product_id/inventory' };

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
require 'uri'
require 'net/http'

url = URI("https://domain_prefix.vendhq.com/api/2.0/products/product_id/inventory")

http = Net::HTTP.