The Products API enables the retrieval of all products available in the store. This API employs pagination, meaning that to access subsequent pages, you should utilize the page parameter.
It's important to note that this API exclusively returns product details and does not include collection details.
http://api.shopper.com/v1/products?page={page}&limit={limit}&order_by={order_by}
Parameters
Parameter | Type | Description |
---|---|---|
page | integer | Page number, please note that the starting page number is 0 |
limit | integer | The maximum number of results to fetch. The default limit is 100 |
order_by | string | For sorting. Possible values: create_date, name. For inverse sort order, sign '-' before the value. Eg: order_by=-create_date. |
Sample output
{
"status": 200,
"message": "OK",
"current": 1,
"start": 1,
"end": 1,
"limit": 100,
"total": 32,
"next_page": "https://api.shopper.com/v1/products?page=2&limit=100",
"products": [
{
"id": "605844cfcae4f600189c5dd4",
"name": "Nike Glider",
"image": "https://cdn.shopper.com/shopper-v2/demo/assets/user_products/503d62c4-386b-42fd-a515-b48cf0763151.png",
"featured": false,
"create_date": "2021-11-15T04:45:57.259Z",
"product_url": "https://www.nike.com/glider",
"url": "https://www.shopper.com/p/sjEq",
"collection": {
"name": "My Product Collections",
"id": "605844cfcae4f600189c5dd4"
},
"store": {
"name": "Nike",
"url": "https://www.shopper.com/aff_redirect?source=web&store_id=nike-com&type=store"
},
"affiliate_url": "https://www.shopper.com/p/sjEq/r",
"description": "Nike Glider is one of the best sneakers I ever had"
},
{
"id": "605844cfcae4f600189c5dd4",
"name": "Beats Headphone",
"image": "https://cdn.shopper.com/shopper-v2/demo/assets/user_products/0d317260-8052-434c-a182-580d69a25a2c.png",
"featured": false,
"create_date": "2021-11-15T04:45:57.259Z",
"product_url": "https://apple.com/beats-by-dre",
"url": "https://www.shopper.com/p/YrUO",
"collection": {
"name": "My Product Collections",
"id": "605844cfcae4f600189c5dd4"
},
"store": {
"name": "Apple",
"url": "https://www.shopper.com/aff_redirect?source=web&store_id=apple-com&type=store"
},
"affiliate_url": "https://www.shopper.com/p/YrUO/r",
"description": "Beats made Dre a Billionaire"
},
]
}
Response body
id: Product ID
name: Name of the product
image: Product image URL
featured: This response flag serves as an indicator for a featured product
create_date: Date of creation of the product in ISO 8601 format
product_url: URL of the original product page
url: The affiliate link for the store's homepage
collection: Details of the collection to which the product has been added
store: Details of the store associated with the product
store_active: This response flag allows you to check affiliate status of a store. The affiliate status denotes whether the store maintains an active affiliate connection. Stores may be removed from the affiliate network due to various reasons, including switching between networks or non-payment of dues. Utilizing the true and false flags enables you to discern whether the store is actively participating in an affiliate program.
affiliate_url: Affiliate URL of the products created
description: Product description
Response status
Status | Reason |
---|---|
500 | Internal server error |
200 | Success |
400 | Invalid request parameters |
405 | API method is not allowed, contact admin to get access |
401 | Invalid authentication parameters |