node.jsサーバーからGoogleのPlaces APIを使用しようとしています
これは私がアクセスしようとしている URL です。
サーバーからのリクエストを処理する最良の方法はどれですか?
ありがとう!
node.jsサーバーからGoogleのPlaces APIを使用しようとしています
これは私がアクセスしようとしている URL です。
サーバーからのリクエストを処理する最良の方法はどれですか?
ありがとう!
https.get
またはを使用しhttps.request
ます。
const https = require("https");
https.get("https://maps.googleapis.com/maps/api/place/textsearch/json?query=parkings+in+Madrid,Spain&sensor=true&key=key", function(res) {
console.log("Got response: " + res.statusCode);
}).on('error', function(e) {
console.log("Got error: " + e.message);
});