Commerce
Put v1commercecollections products
PUT
/
v1
/
commerce
/
collections
/
{collectionID}
/
products
cURL
curl --request PUT \
--url https://api.wazapin.com/v1/commerce/collections/{collectionID}/products \
--header 'Content-Type: application/json' \
--data '
{
"product_ids": [
"<string>"
]
}
'const options = {
method: 'PUT',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({product_ids: ['<string>']})
};
fetch('https://api.wazapin.com/v1/commerce/collections/{collectionID}/products', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.wazapin.com/v1/commerce/collections/{collectionID}/products"
payload = { "product_ids": ["<string>"] }
headers = {"Content-Type": "application/json"}
response = requests.put(url, json=payload, headers=headers)
print(response.text){
"active": true,
"id": "<string>",
"slug": "<string>",
"sort_order": 123,
"title": "<string>",
"description": "<string>",
"image_url": "<string>",
"product_count": 123
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}⌘I
cURL
curl --request PUT \
--url https://api.wazapin.com/v1/commerce/collections/{collectionID}/products \
--header 'Content-Type: application/json' \
--data '
{
"product_ids": [
"<string>"
]
}
'const options = {
method: 'PUT',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({product_ids: ['<string>']})
};
fetch('https://api.wazapin.com/v1/commerce/collections/{collectionID}/products', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.wazapin.com/v1/commerce/collections/{collectionID}/products"
payload = { "product_ids": ["<string>"] }
headers = {"Content-Type": "application/json"}
response = requests.put(url, json=payload, headers=headers)
print(response.text){
"active": true,
"id": "<string>",
"slug": "<string>",
"sort_order": 123,
"title": "<string>",
"description": "<string>",
"image_url": "<string>",
"product_count": 123
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}