Sign in | Sign up

getting 400 all the time, in the demos as well

Tagged:

Currently contains 1 post

Avatar

September 05, 2018 07:51

nivijah

an example request:

var options = {
url: ‘https://trackapi.nutritionix.com/v2/natural/nutrients’,
headers: {
‘Content-Type’:‘application/json’,
‘x-app-id’:‘XXX’,
‘x-app-key’:‘XXX
},
body: ‘apple’ //simplified. tried – body: JSON.stringify(string)
};

tried the demos with my tokens, where remote-user-id = 0
Unexpected token <first character> in JSON at position 0

Reply to thread