You can use js fetch
async function send(url,data) {_x000D_
let r= await fetch(url, {_x000D_
method: "POST", _x000D_
headers: {_x000D_
"My-header": "abc" _x000D_
},_x000D_
body: JSON.stringify(data), _x000D_
})_x000D_
return await r.json()_x000D_
}_x000D_
_x000D_
// Example usage_x000D_
_x000D_
let url='https://server.test-cors.org/server?enable=true&status=200&methods=POST&headers=my-header';_x000D_
_x000D_
async function run() _x000D_
{_x000D_
let jsonObj = await send(url,{ some: 'testdata' });_x000D_
console.log(jsonObj[0].request.httpMethod + ' was send - open chrome console > network to see it');_x000D_
}_x000D_
_x000D_
run();
_x000D_