プラットフォームインテリジェンス API
Google 検索 API
毎日数十億人がGoogleを使ってウェブページ、ニュース、画像、動画、ローカル結果を検索し、発見性や評判管理、需要獲得に不可欠です。
APIリファレンス バージョン: 1.0.0 6 エンドポイント 認証
ベース URL
https://api.pressmonitor.com/google/v1 認証
すべてのリクエストはベアラートークン認証を使用します。すべての呼び出しにAuthorizationヘッダーを追加してください。
Authorization: Bearer YOUR_TOKEN GET
/web ウェブ検索
Search Web
パラメータ
| 名前 | タイプ | 場所 | 必須 | 説明 |
|---|---|---|---|---|
| query_text | string | query | はい | クエリテキスト |
| lang_code | string | query | いいえ | 言語コード |
| country_code | string | query | いいえ | 国コード |
| count | integer | query | いいえ | 返却する結果の数 |
| safesearch | string | query | いいえ | セーフサーチ |
コード例
curl --request GET \ --url 'https://api.pressmonitor.com/google/v1/web?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&safesearch=SOME_STRING_VALUE' const http = require("https"); const options = { "method": "GET", "hostname": "api.pressmonitor.com", "port": null, "path": "/google/v1/web?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&safesearch=SOME_STRING_VALUE", "headers": {} }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end(); import requests url = "https://api.pressmonitor.com/google/v1/web" querystring = {"query_text":"SOME_STRING_VALUE","lang_code":"SOME_STRING_VALUE","country_code":"SOME_STRING_VALUE","count":"SOME_INTEGER_VALUE","safesearch":"SOME_STRING_VALUE"} response = requests.request("GET", url, params=querystring) print(response.text) <?php $curl = curl_init(); curl_setopt_array($curl, [ CURLOPT_URL => "https://api.pressmonitor.com/google/v1/web?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&safesearch=SOME_STRING_VALUE", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 30, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "GET", ]); $response = curl_exec($curl); $err = curl_error($curl); curl_close($curl); if ($err) { echo "cURL Error #:" . $err; } else { echo $response; } OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://api.pressmonitor.com/google/v1/web?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&safesearch=SOME_STRING_VALUE") .get() .build(); Response response = client.newCall(request).execute(); レスポンス
200 成功
GET
/news ニュース検索
Search News
パラメータ
| 名前 | タイプ | 場所 | 必須 | 説明 |
|---|---|---|---|---|
| query_text | string | query | はい | クエリテキスト |
| lang_code | string | query | いいえ | 言語コード |
| country_code | string | query | いいえ | 国コード |
| count | integer | query | いいえ | 返却する結果の数 |
コード例
curl --request GET \ --url 'https://api.pressmonitor.com/google/v1/news?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE' const http = require("https"); const options = { "method": "GET", "hostname": "api.pressmonitor.com", "port": null, "path": "/google/v1/news?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE", "headers": {} }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end(); import requests url = "https://api.pressmonitor.com/google/v1/news" querystring = {"query_text":"SOME_STRING_VALUE","lang_code":"SOME_STRING_VALUE","country_code":"SOME_STRING_VALUE","count":"SOME_INTEGER_VALUE"} response = requests.request("GET", url, params=querystring) print(response.text) <?php $curl = curl_init(); curl_setopt_array($curl, [ CURLOPT_URL => "https://api.pressmonitor.com/google/v1/news?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 30, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "GET", ]); $response = curl_exec($curl); $err = curl_error($curl); curl_close($curl); if ($err) { echo "cURL Error #:" . $err; } else { echo $response; } OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://api.pressmonitor.com/google/v1/news?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE") .get() .build(); Response response = client.newCall(request).execute(); レスポンス
200 成功
GET
/images 画像検索
Search Images
パラメータ
| 名前 | タイプ | 場所 | 必須 | 説明 |
|---|---|---|---|---|
| query_text | string | query | はい | クエリテキスト |
| lang_code | string | query | いいえ | 言語コード |
| country_code | string | query | いいえ | 国コード |
| count | integer | query | いいえ | 返却する結果の数 |
| safesearch | string | query | いいえ | セーフサーチ |
| color | string | query | いいえ | 色 |
| size | string | query | いいえ | サイズ |
| type_image | string | query | いいえ | 画像タイプ |
| layout | string | query | いいえ | レイアウト |
コード例
curl --request GET \ --url 'https://api.pressmonitor.com/google/v1/images?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&safesearch=SOME_STRING_VALUE&color=SOME_STRING_VALUE&size=SOME_STRING_VALUE&type_image=SOME_STRING_VALUE&layout=SOME_STRING_VALUE' const http = require("https"); const options = { "method": "GET", "hostname": "api.pressmonitor.com", "port": null, "path": "/google/v1/images?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&safesearch=SOME_STRING_VALUE&color=SOME_STRING_VALUE&size=SOME_STRING_VALUE&type_image=SOME_STRING_VALUE&layout=SOME_STRING_VALUE", "headers": {} }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end(); import requests url = "https://api.pressmonitor.com/google/v1/images" querystring = {"query_text":"SOME_STRING_VALUE","lang_code":"SOME_STRING_VALUE","country_code":"SOME_STRING_VALUE","count":"SOME_INTEGER_VALUE","safesearch":"SOME_STRING_VALUE","color":"SOME_STRING_VALUE","size":"SOME_STRING_VALUE","type_image":"SOME_STRING_VALUE","layout":"SOME_STRING_VALUE"} response = requests.request("GET", url, params=querystring) print(response.text) <?php $curl = curl_init(); curl_setopt_array($curl, [ CURLOPT_URL => "https://api.pressmonitor.com/google/v1/images?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&safesearch=SOME_STRING_VALUE&color=SOME_STRING_VALUE&size=SOME_STRING_VALUE&type_image=SOME_STRING_VALUE&layout=SOME_STRING_VALUE", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 30, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "GET", ]); $response = curl_exec($curl); $err = curl_error($curl); curl_close($curl); if ($err) { echo "cURL Error #:" . $err; } else { echo $response; } OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://api.pressmonitor.com/google/v1/images?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&safesearch=SOME_STRING_VALUE&color=SOME_STRING_VALUE&size=SOME_STRING_VALUE&type_image=SOME_STRING_VALUE&layout=SOME_STRING_VALUE") .get() .build(); Response response = client.newCall(request).execute(); レスポンス
200 成功
GET
/videos 動画検索
Search Videos
パラメータ
| 名前 | タイプ | 場所 | 必須 | 説明 |
|---|---|---|---|---|
| query_text | string | query | はい | クエリテキスト |
| lang_code | string | query | いいえ | 言語コード |
| country_code | string | query | いいえ | 国コード |
| count | integer | query | いいえ | 返却する結果の数 |
| safesearch | string | query | いいえ | セーフサーチ |
| timelimit | string | query | いいえ | 時間制限 |
| duration | string | query | いいえ | 期間 |
| resolution | string | query | いいえ | 解像度 |
コード例
curl --request GET \ --url 'https://api.pressmonitor.com/google/v1/videos?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&safesearch=SOME_STRING_VALUE&timelimit=SOME_STRING_VALUE&duration=SOME_STRING_VALUE&resolution=SOME_STRING_VALUE' const http = require("https"); const options = { "method": "GET", "hostname": "api.pressmonitor.com", "port": null, "path": "/google/v1/videos?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&safesearch=SOME_STRING_VALUE&timelimit=SOME_STRING_VALUE&duration=SOME_STRING_VALUE&resolution=SOME_STRING_VALUE", "headers": {} }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end(); import requests url = "https://api.pressmonitor.com/google/v1/videos" querystring = {"query_text":"SOME_STRING_VALUE","lang_code":"SOME_STRING_VALUE","country_code":"SOME_STRING_VALUE","count":"SOME_INTEGER_VALUE","safesearch":"SOME_STRING_VALUE","timelimit":"SOME_STRING_VALUE","duration":"SOME_STRING_VALUE","resolution":"SOME_STRING_VALUE"} response = requests.request("GET", url, params=querystring) print(response.text) <?php $curl = curl_init(); curl_setopt_array($curl, [ CURLOPT_URL => "https://api.pressmonitor.com/google/v1/videos?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&safesearch=SOME_STRING_VALUE&timelimit=SOME_STRING_VALUE&duration=SOME_STRING_VALUE&resolution=SOME_STRING_VALUE", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 30, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "GET", ]); $response = curl_exec($curl); $err = curl_error($curl); curl_close($curl); if ($err) { echo "cURL Error #:" . $err; } else { echo $response; } OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://api.pressmonitor.com/google/v1/videos?query_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&safesearch=SOME_STRING_VALUE&timelimit=SOME_STRING_VALUE&duration=SOME_STRING_VALUE&resolution=SOME_STRING_VALUE") .get() .build(); Response response = client.newCall(request).execute(); レスポンス
200 成功
GET
/map 地図検索
Search Map
パラメータ
| 名前 | タイプ | 場所 | 必須 | 説明 |
|---|---|---|---|---|
| query_text | string | query | はい | クエリテキスト |
| place | string | query | いいえ | 場所 |
| street | string | query | いいえ | 通り |
| city | string | query | いいえ | 市区町村 |
| county | string | query | いいえ | 郡 |
| state | string | query | いいえ | 州 |
| country | string | query | いいえ | 国 |
| postalcode | string | query | いいえ | 郵便番号 |
| latitude | string | query | いいえ | 緯度 |
| longitude | string | query | いいえ | 経度 |
| radius | string | query | いいえ | 半径 |
コード例
curl --request GET \ --url 'https://api.pressmonitor.com/google/v1/map?query_text=SOME_STRING_VALUE&place=SOME_STRING_VALUE&street=SOME_STRING_VALUE&city=SOME_STRING_VALUE&county=SOME_STRING_VALUE&state=SOME_STRING_VALUE&country=SOME_STRING_VALUE&postalcode=SOME_STRING_VALUE&latitude=SOME_STRING_VALUE&longitude=SOME_STRING_VALUE&radius=SOME_STRING_VALUE' const http = require("https"); const options = { "method": "GET", "hostname": "api.pressmonitor.com", "port": null, "path": "/google/v1/map?query_text=SOME_STRING_VALUE&place=SOME_STRING_VALUE&street=SOME_STRING_VALUE&city=SOME_STRING_VALUE&county=SOME_STRING_VALUE&state=SOME_STRING_VALUE&country=SOME_STRING_VALUE&postalcode=SOME_STRING_VALUE&latitude=SOME_STRING_VALUE&longitude=SOME_STRING_VALUE&radius=SOME_STRING_VALUE", "headers": {} }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end(); import requests url = "https://api.pressmonitor.com/google/v1/map" querystring = {"query_text":"SOME_STRING_VALUE","place":"SOME_STRING_VALUE","street":"SOME_STRING_VALUE","city":"SOME_STRING_VALUE","county":"SOME_STRING_VALUE","state":"SOME_STRING_VALUE","country":"SOME_STRING_VALUE","postalcode":"SOME_STRING_VALUE","latitude":"SOME_STRING_VALUE","longitude":"SOME_STRING_VALUE","radius":"SOME_STRING_VALUE"} response = requests.request("GET", url, params=querystring) print(response.text) <?php $curl = curl_init(); curl_setopt_array($curl, [ CURLOPT_URL => "https://api.pressmonitor.com/google/v1/map?query_text=SOME_STRING_VALUE&place=SOME_STRING_VALUE&street=SOME_STRING_VALUE&city=SOME_STRING_VALUE&county=SOME_STRING_VALUE&state=SOME_STRING_VALUE&country=SOME_STRING_VALUE&postalcode=SOME_STRING_VALUE&latitude=SOME_STRING_VALUE&longitude=SOME_STRING_VALUE&radius=SOME_STRING_VALUE", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 30, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "GET", ]); $response = curl_exec($curl); $err = curl_error($curl); curl_close($curl); if ($err) { echo "cURL Error #:" . $err; } else { echo $response; } OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://api.pressmonitor.com/google/v1/map?query_text=SOME_STRING_VALUE&place=SOME_STRING_VALUE&street=SOME_STRING_VALUE&city=SOME_STRING_VALUE&county=SOME_STRING_VALUE&state=SOME_STRING_VALUE&country=SOME_STRING_VALUE&postalcode=SOME_STRING_VALUE&latitude=SOME_STRING_VALUE&longitude=SOME_STRING_VALUE&radius=SOME_STRING_VALUE") .get() .build(); Response response = client.newCall(request).execute(); レスポンス
200 成功
GET
/autocomplete オートコンプリート
Auto Complete
パラメータ
| 名前 | タイプ | 場所 | 必須 | 説明 |
|---|---|---|---|---|
| query_text | string | query | はい | クエリテキスト |
コード例
curl --request GET \ --url 'https://api.pressmonitor.com/google/v1/autocomplete?query_text=SOME_STRING_VALUE' const http = require("https"); const options = { "method": "GET", "hostname": "api.pressmonitor.com", "port": null, "path": "/google/v1/autocomplete?query_text=SOME_STRING_VALUE", "headers": {} }; const req = http.request(options, function (res) { const chunks = []; res.on("data", function (chunk) { chunks.push(chunk); }); res.on("end", function () { const body = Buffer.concat(chunks); console.log(body.toString()); }); }); req.end(); import requests url = "https://api.pressmonitor.com/google/v1/autocomplete" querystring = {"query_text":"SOME_STRING_VALUE"} response = requests.request("GET", url, params=querystring) print(response.text) <?php $curl = curl_init(); curl_setopt_array($curl, [ CURLOPT_URL => "https://api.pressmonitor.com/google/v1/autocomplete?query_text=SOME_STRING_VALUE", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 30, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "GET", ]); $response = curl_exec($curl); $err = curl_error($curl); curl_close($curl); if ($err) { echo "cURL Error #:" . $err; } else { echo $response; } OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder() .url("https://api.pressmonitor.com/google/v1/autocomplete?query_text=SOME_STRING_VALUE") .get() .build(); Response response = client.newCall(request).execute(); レスポンス
200 成功