I am trying to create a scenario to make an API call to Shopify to create a collection and upload an image.
I can GET data so I know I have authorized correctly.
I have the required products access scope in the auth key.
Here is what is in the API call:
URL:
smart_collections.json
API Version: 2023-01
Method: POST
Key: Content-type
Value: application/JSON
There is no query string.
I copied the request body directly from the shopify API:
From initial looks, it looks like the body that you are sending is malformed, not sure if it due to formatting here in the community or it is what you are setting in Make itself. Can you crosscheck and see if there is no new lines in body_html?
Can you copy-paste this from here and replace the body content in Make an API call module and right click the module to run it once and see if you are still getting the issue?
Hello,
Thanks so much for the assistance.
It must be the formatting here, there are no extra lines.
I copied and pasted from your link and no change, I am still getting
The operation failed with an error. [400] [Collection]
I wasn’t really sure what to put for the payload, I copied the Smart Collection resource from the side of the documentation. What you put works though! I just need to change it to the image url so it will be uploaded.
It works!!
Thank you!
I can’t figure out where you got the syntax of the payload, I don’t see it anywhere on the page but I understand how it works now. Thank you so much! I’m very new to this!