Products
Products as a Building Block can be physical things or services performed. Our APIs don't care.
We also have the concept of main products and sub-products. If a user buys a car, that would be a main product. They might also get the nice leather interior. They can't buy leather interior without buying the car, so the nice leather interior would be a sub-product. However, you can use the main product and sub-product relationship as you see fit, just follow the rules.
Rules for Main and Sub-Products:
Main products can have many sub-products.
A sub-product can have many main, aka parent, products.
A sub-product can not have any sub-products of its own.
A sub-product can not be purchased without it's parent product.
Product Object
Changes since API version 2019-02-01
2020-03-13 - New attribute `reserved_price`
Since we implemented a new Payment kind, Reserved Payment
, we introduce this new attribute. It is used to calculate the amount of a Reserved Payment
when it is in an Order
.
2019-09-18 - `image` type changed to Object
image
type changed to Image
Object.
2019-09-02 - `image_url` Deprecated
We are deprecating the old image_url
and replacing it with Image
Object
Product objects now support Attributes! This is a new way of extending the functionality of objects so they fit your specific use case. Check out "Templates and Attributes" for more detailed information.
Attributes | Type | Description |
|
| The name of the product. |
|
| Human readable ID that identifies the order easily, e.g. |
|
| Three letter currency code in standard ISO 4217 format. |
|
| The price of the product. |
|
| The price of the product used for a |
|
| The discount of the product, as a decimal between 0.0 and 0.1, e.g. 0.25 = 25%. |
|
| The price of the product calculated with the discount. It should be used to get the final price with the correct rounding. |
|
| The percentage of VAT in the product price, as a decimal between 0.0 and 0.1, e.g. 0.25 = 25%. |
|
| A full description of the product. |
|
| A brief description of the product. |
|
| Flag that marks whether or not it is a main product. Default is |
|
| A list of sub products under the main product. |
|
| The sub product’s parent. |
|
| List of tags associated with the product. |
|
| Dynamic product properties, supports any valid JSON. |
|
| The main |
|
| List of |
|
| URL for the product. Default is set to '/'. |
|
| An external reference, e.q: ID from Shopify or Magento. |
|
|
Note: A Main Product is the same thing as a Parent Product.
When creating a Product using the dashboard, the VAT amount should be given as a percentage, e.g. 25 = 25%. When using the API, the VAT amount should be given as a number between 0 and 1, e.g. 0.25 = 25%.
Medium Object
Attributes | Descriptions |
| Defines the type of media included. We only support |
| The path or URL of your image. |
| The name of the image. |
| A human readable ID. It's a string 6 characters long that is created automatically when the Product is saved. It can also be set manually. |
User Role
Note: The methods used to retrieve, list and search products do not require the use of the User's authorization token. This allows a user to access information regarding a product or products without having to sign in.
Retrieve a Product*
Path Parameters | Type | Description |
|
| Product ID |
Get List of All Products*
Query Parameters | Type | Description |
|
| Number of items to retrieve. Default is 10. |
|
| Which page to retrieve. Default is 0. |
|
| Field used for sorting results. Default is |
|
| Start date, |
|
| End date, |
|
| Date field used to filter results. Default is |
|
| Define the latitude. |
|
| Define the longitude. |
|
| If |
|
| If |
Search Products by Keywords*
Query Parameters | Type | Description |
|
| What you want to search for, e.g., name, description, or id. |
|
| Number of items to retrieve. Default is 10. |
|
| Which page to retrieve. Default is 0. |
|
| Field used for sorting results. Default is |
|
| Start date, |
|
| End date, |
|
| Date field used to filter results. Default is |
|
| Define the latitude. |
|
| Define the longitude. |
|
| If |
Search Products by Tags*
Find more information regarding searching with tags here
Query Parameters | Type | Description |
|
| Values of tags to search for, comma separated. |
|
| Number of items to retrieve. Default is 10. |
|
| Which page to retrieve. Default is 0. |
|
| Field used for sorting results. Default is |
|
| Start date, |
|
| End date, |
|
| Date field used to filter results. Default is |
|
| Define the latitude. |
|
| Define the longitude. |
|
| If |
Admin Role
*Paths listed above and denoted with a star are accessible to both Users and Admins. Additional Admin Role paths are listed below.
Create a Product
Body Parameter | Type | Description |
|
| The name of the product. |
|
| The price of the product. |
|
| The discount of the product, as a decimal between 0.0 and 0.1, e.g. 0.25 = 25%. |
|
| Three letter currency doe in standard ISO 4217 format. |
|
| The percentage of VAT in the product price, as a decimal between 0.0 and 0.1, e.g. 0.25 = 25%. |
|
| A full description of the product. |
|
| A brief description of the product. |
|
| Flag that marks whether or not it is a main product. Default is |
|
| List of sub-products under the product. Default is set to [ ]. |
|
| List of tags associated with the product. |
|
| The product's properties. |
|
| An |
|
| List of |
|
| An external reference, e.q: ID from Shopify or Magento |
|
| Attributes you want to add. For more explanation see "Templates and Attributes" |
Update the Sub-Products in a Product
A product can have multiple sub-products associated with it. These are found in the field _sub_products
.
Path Parameters | Type | Description |
|
| Product ID of main product. |
Body Parameters | Type | Description |
|
| Array of sub-product ids to associate with main product. |
Update a Product with an Image
To get an Image ID you have to create an image. Head up to the image documentation to learn how to do so.
Path Parameters | Type | Description |
|
| Product ID of main product. |
Body Parameters | Type | Description |
|
| Image ID. |
Update a Product with a Medium
When creating or updating a product with Media
you could use one of two ways. You can define a Medium
object or provide an Image
id. In the case you provide an Image
id we will create a Medium
object for you. This way, you can be sure that when you get a list of Media
you will have it in a consistent manner. The same should work when updating your products. We currently only support Media
of type Image
.
Path Parameter | Type | Description |
|
| Product ID of main product. |
Body Parameters | Type | Description |
|
| List of |
Last updated