Php Api Call Using Curl In Javascript The Xy