You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi so basically I am using apple new API for analytics, so I need to send a post request to the api to create a report, the closest thing I found on the internet to my task is the create article function you have. but I am failing miserably to create the right signature.
I have succeeded in making it work with python but it didn't work in Javascript. I think I am failing at creating the right canonical_request.
here is the python line for creating the canonical_request:
canonical_request = method + url + date + content_type + json.dumps(payload)
I tried copying your method by doing this:
let canonicalRequest = Buffer(method + host + endpoint + date + content_type + JSON.stringify(payload) , 'ascii')
but unfortunately didn’t work.
Would love to know if you have any input on this or if you can help me solve this problem.
Thanks,
The text was updated successfully, but these errors were encountered:
Hi so basically I am using apple new API for analytics, so I need to send a post request to the api to create a report, the closest thing I found on the internet to my task is the create article function you have. but I am failing miserably to create the right signature.
I have succeeded in making it work with python but it didn't work in Javascript. I think I am failing at creating the right canonical_request.
here is the python line for creating the canonical_request:
canonical_request = method + url + date + content_type + json.dumps(payload)
whereas;
content_type = "application/json"
payload = {"data":{"reportType":"ARTICLE_DETAIL", "startDate":"2022-11-07", "timezone":"-0000"}}
I tried copying your method by doing this:
let canonicalRequest = Buffer(method + host + endpoint + date + content_type + JSON.stringify(payload) , 'ascii')
but unfortunately didn’t work.
Would love to know if you have any input on this or if you can help me solve this problem.
Thanks,
The text was updated successfully, but these errors were encountered: