You can also do a POST request to https://yourappid:javascript-key=yourjavascriptkey@yourcustomdomain.back4app.io/functions/yourfunctionname so you don't need to include the headers. You can enable your custom domain at ServerSettings -> Web Hosting.
You can also do a POST request to https://yourappid:javascript-key=yourjavascriptkey@yourcustomdomain.back4app.io/functions/yourfunctionname so you don't need to include the headers. You can enable your custom domain at ServerSettings -> Web Hosting.