Receiving text/html instead of JSON.

Skip to first unread message

Fire Knight

Aug 31, 2022, 8:00:45 AMAug 31
to FatSecret Platform API
Hello all, when sending curl request to API, I am getting text/html response.  I sent header, 'Accept: application/json', but no help.  any suggestions/feedback would be much appreciated. Thanks

Kevin Nguyen

Nov 22, 2022, 10:30:17 AM (5 days ago) Nov 22
to FatSecret Platform API
Try setting the content type to: 'multipart/form-data' and setting 'format' to 'json' in your body/params.. I think the latter is probably the solution but that's how it works for me using Fetch.
Reply all
Reply to author
0 new messages