Posting using $fetch
Hey all! I have the following code in a server api endpoint:
https://api.server.com/logout/ always replays with
How do I correctly make the POST? Thank you!
7 Replies
how do you handle it in your backend?
https://api.server.com/logout/ Is not really my server but a third party service.
have you tried doing a similair thing with postman? just to make sure you're sending the data how they want it to
Try using
params
instead of body
, otherwise the suggestion aboveI have tried using Insomia and it works like this: POST to URL, structured as Form URL encoded. How do I translate it to my code?
This still doesn't work...
Maybe try to add an additional headers
"Accept" : "application/json"
This is how it worked in the end: