Wishlist
Get All Wishlists
GET https://api.bigcommerce.com/stores/{store_hash}/v3/wishlistsRequest
Returns a list of wishlists. Optional filter parameters can be passed in.
Authentication
- X-Auth-Token in header
Parameters
- store_hash in path - string
- customer_id in query - integerAll wishlists relating to the customer.
- page in query with default of 1 - integerThe page number of results to return. 1 is the default and starts from record 0. Use in conjunction with the limit query parameter to request a specific set of records.
- limit in query with default of 50 - integerThe number of items to return per page. Default is 50 and maximum is 250.
- Accept in header with default of application/json - stringrequiredThe MIME type of the response body.
example
curl --request GET \
--url 'https://api.bigcommerce.com/stores/[store_hash]/v3/wishlists' \
--header 'Content-Type: application/json' \
--header 'X-Auth-Token: {{token}}'
Response
Body
object | application/json
dataarray[object]
example
{
"data": [
{
"id": 1,
"customer_id": 4,
"name": "My Wish List",
"is_public": false,
"token": "02d55481-13eb-4d1e-9d79-9062b518570d",
"items": []
},
{
"id": 2,
"customer_id": 11,
"name": "Christmas",
"is_public": false,
"token": "02d55481-13eb-4d1e-9d79-9062b518570d",
"items": [
{
"id": 1,
"product_id": 167
},
{
"id": 2,
"product_id": 174
},
{
"id": 3,
"product_id": 184
}
]
},
{
Create a Wishlist
POST https://api.bigcommerce.com/stores/{store_hash}/v3/wishlistsRequest
Creates a wishlist and wishlist item. More than one item can be added in the POST.
Required Fields
- name
- customer_id
Authentication
- X-Auth-Token in header
Parameters
- store_hash in path - string
- Accept in header with default of application/json - stringrequiredThe MIME type of the response body.
- Content-Type in header with default of application/json - stringrequiredThe MIME type of the request body.
Body
object | application/json
customer_idinteger
requiredThe customer id.Example: 12is_publicboolean
Whether the wishlist is available to the public.namestring
The title of the wishlist.Example: School Shoppingitemsarray[object]
Array of wishlist items.
example
{
"customer_id": 12,
"is_public": false,
"name": "School Shopping",
"items": [
{
"product_id": 12,
"variant_id": 152
}
]
}
Response
Body
object | application/json
dataobject
example
{
"data": {
"id": 30,
"customer_id": 10,
"name": "Christmas List",
"is_public": true,
"token": "d2d55481-13eb-4d1e-9d79-9062b518570d",
"items": [
{
"id": 44,
"product_id": 77,
"variant_id": 1
},
{
"id": 45,
"product_id": 80,
"variant_id": 1
},
{
"id": 46,
"product_id": 81,
"variant_id": 1
},
{
"id": 47,
"product_id": 86,
"variant_id": 1
},
{
"id": 48,
"product_id": 88,
Get a Wishlist
GET https://api.bigcommerce.com/stores/{store_hash}/v3/wishlists/{wishlist_id}Request
Returns a single wishlist.
Authentication
- X-Auth-Token in header
Parameters
- store_hash in path - string
- wishlist_id in path - integerrequiredID of the Wishlist.
- Accept in header with default of application/json - stringrequiredThe MIME type of the response body.
example
curl --request GET \
--url 'https://api.bigcommerce.com/stores/[store_hash]/v3/wishlists/[wishlist_id]' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header 'X-Auth-Token: {{token}}'
Response
Body
object | application/json
dataobject
example
{
"data": {
"id": 30,
"customer_id": 10,
"name": "Christmas List",
"is_public": true,
"token": "d2d55481-13eb-4d1e-9d79-9062b518570d",
"items": [
{
"id": 44,
"product_id": 77,
"variant_id": 1
},
{
"id": 45,
"product_id": 80,
"variant_id": 1
},
{
"id": 46,
"product_id": 81,
"variant_id": 1
},
{
"id": 47,
"product_id": 86,
"variant_id": 1
},
{
"id": 48,
"product_id": 88,
Update a Wishlist
PUT https://api.bigcommerce.com/stores/{store_hash}/v3/wishlists/{wishlist_id}Request
Updates a wishlist.
Use this endpoint to update existing wishlist items, change the wishlistʼs name and whether the wishlist is available publicly. To add or delete a wishlist item, see Wishlist Items.
Authentication
- X-Auth-Token in header
Parameters
- store_hash in path - string
- wishlist_id in path - integerrequiredID of the Wishlist.
- Accept in header with default of application/json - stringrequiredThe MIME type of the response body.
- Content-Type in header with default of application/json - stringrequiredThe MIME type of the request body.
Body
object | application/json
customer_idinteger
requiredThe customer ID. A read-only value.is_publicboolean
Whether the wishlist is available to the public.namestring
The title of the wishlist.itemsarray[object]
requiredArray of wishlist items.
example
{
"customer_id": 0,
"is_public": true,
"name": "string",
"items": [
{
"id": 12,
"product_id": 55,
"variant_id": 22
}
]
}
Response
Body
object | application/json
dataobject
example
{
"data": {
"id": 30,
"customer_id": 10,
"name": "Christmas List",
"is_public": true,
"token": "d2d55481-13eb-4d1e-9d79-9062b518570d",
"items": [
{
"id": 44,
"product_id": 77,
"variant_id": 1
},
{
"id": 45,
"product_id": 80,
"variant_id": 1
},
{
"id": 46,
"product_id": 81,
"variant_id": 1
},
{
"id": 47,
"product_id": 86,
"variant_id": 1
},
{
"id": 48,
"product_id": 88,
Delete a Wishlist
DELETE https://api.bigcommerce.com/stores/{store_hash}/v3/wishlists/{wishlist_id}Request
Deletes a wishlist.
Authentication
- X-Auth-Token in header
Parameters
- store_hash in path - string
- wishlist_id in path - integerrequiredID of the Wishlist.
- Accept in header with default of application/json - stringrequiredThe MIME type of the response body.
example
curl --request DELETE \
--url 'https://api.bigcommerce.com/stores/[store_hash]/v3/wishlists/[wishlist_id]' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header 'X-Auth-Token: {{token}}'
Response
See something you can improve? Edit this file on GitHub
Did you find what you were looking for?