Development discussions around Shopify APIs
To continue receiving payouts, you need to secure your account by turning on two-step authentication. If two-step authentication is not turned on your payouts will be paused. Learn more
Hi,
When I try to add a product to a custom collection, I get the error code 406.
My command call is
POST https: //.......myshopify.com/admin/api/2020-07/collects.json
With this JSON
{'collect': {'product_id': myProduct_id, 'collection_id': myCustomCollection_id}}
Both myProduct_id and myCustomCollection_id correspond to real and correctly created entities.
Anyone know why?
Thanks
Solved! Go to the solution
This is an accepted solution.
I've whatch better my command call in debug mode...
My command call was wrong ...
Thanks to all
Hi
Do you have the correct permissions against those API keys?
Can you also show us the code that you're actually using to make the call?
406 Error normally means there's some kind of error in the way the request is formatted.
This is my APP level permission for PRODUCT
Product View or manage product, variants and collections Access indicators: read_products, write_products | Read and write |
I've read this on DOCS the sintax for this call.
https://shopify.dev/docs/admin-api/rest/reference/products/collect#create-2020-07
POST /admin/api/2020-07/collects.json
{
"collect": {
"product_id": 921728736,
"collection_id": 841564295
}
}
This is exactly what I write when I make the API call
This is an accepted solution.
I've whatch better my command call in debug mode...
My command call was wrong ...
Thanks to all
User | RANK |
---|---|
5 | |
5 | |
5 | |
4 | |
4 |
Learn these 5 things I had to learn the hard way with starting and running my own business
By Kitana Jan 27, 2023Would you love to unleash the unbridled power of the Google Shopping Channel into your sho...
By Gabe Jan 6, 2023How can you turn a hobby into a career? That’s what Emmanuel did while working as a wa...
By Skye Dec 30, 2022