Servicios Principales API
API Directa de Búsqueda de Noticias en Línea
Las noticias en línea incluyen reportajes publicados por medios nativos digitales, periódicos, emisoras, servicios de noticias y revistas en la web. Son importantes para la reputación, señales de mercado, desarrollos de políticas e información pública de rápido movimiento.
Referencia de API Versión: 1.0.0 3 Endpoints Autenticación
URL base
https://api.pressmonitor.com/news-online/v1 Autenticación
Todas las solicitudes utilizan autenticación mediante token Bearer. Agrega el encabezado de Autorización a cada llamada.
Authorization: Bearer YOUR_TOKEN GET
/headlines Titulares
News Headlines
Parámetros
| Nombre | Tipo | Ubicación | Requerido | Descripción |
|---|---|---|---|---|
| keywords_text | string | query | Sí | Texto de Palabras Clave |
| lang_code | string | query | No | Código de Idioma |
| country_code | string | query | No | Código de País |
| count | integer | query | No | Cantidad |
| cursor | string | query | No | Cursor |
Ejemplos de código
curl --request GET \ --url 'https://api.pressmonitor.com/news-online/v1/headlines?keywords_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&cursor=SOME_STRING_VALUE' const http = require("https"); const options = { "method": "GET", "hostname": "api.pressmonitor.com", "port": null, "path": "/news-online/v1/headlines?keywords_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&cursor=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/news-online/v1/headlines" querystring = {"keywords_text":"SOME_STRING_VALUE","lang_code":"SOME_STRING_VALUE","country_code":"SOME_STRING_VALUE","count":"SOME_INTEGER_VALUE","cursor":"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/news-online/v1/headlines?keywords_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&cursor=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/news-online/v1/headlines?keywords_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&cursor=SOME_STRING_VALUE") .get() .build(); Response response = client.newCall(request).execute(); Respuestas
200 Éxito
GET
/briefs Resúmenes
News Briefs
Parámetros
| Nombre | Tipo | Ubicación | Requerido | Descripción |
|---|---|---|---|---|
| keywords_text | string | query | Sí | Texto de Palabras Clave |
| lang_code | string | query | No | Código de Idioma |
| country_code | string | query | No | Código de País |
| count | integer | query | No | Cantidad |
| cursor | string | query | No | Cursor |
Ejemplos de código
curl --request GET \ --url 'https://api.pressmonitor.com/news-online/v1/briefs?keywords_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&cursor=SOME_STRING_VALUE' const http = require("https"); const options = { "method": "GET", "hostname": "api.pressmonitor.com", "port": null, "path": "/news-online/v1/briefs?keywords_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&cursor=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/news-online/v1/briefs" querystring = {"keywords_text":"SOME_STRING_VALUE","lang_code":"SOME_STRING_VALUE","country_code":"SOME_STRING_VALUE","count":"SOME_INTEGER_VALUE","cursor":"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/news-online/v1/briefs?keywords_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&cursor=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/news-online/v1/briefs?keywords_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&cursor=SOME_STRING_VALUE") .get() .build(); Response response = client.newCall(request).execute(); Respuestas
200 Éxito
GET
/fulltext Texto Completo
News Fulltext
Parámetros
| Nombre | Tipo | Ubicación | Requerido | Descripción |
|---|---|---|---|---|
| keywords_text | string | query | Sí | Texto de Palabras Clave |
| lang_code | string | query | No | Código de Idioma |
| country_code | string | query | No | Código de País |
| count | integer | query | No | Cantidad |
| cursor | string | query | No | Cursor |
Ejemplos de código
curl --request GET \ --url 'https://api.pressmonitor.com/news-online/v1/fulltext?keywords_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&cursor=SOME_STRING_VALUE' const http = require("https"); const options = { "method": "GET", "hostname": "api.pressmonitor.com", "port": null, "path": "/news-online/v1/fulltext?keywords_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&cursor=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/news-online/v1/fulltext" querystring = {"keywords_text":"SOME_STRING_VALUE","lang_code":"SOME_STRING_VALUE","country_code":"SOME_STRING_VALUE","count":"SOME_INTEGER_VALUE","cursor":"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/news-online/v1/fulltext?keywords_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&cursor=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/news-online/v1/fulltext?keywords_text=SOME_STRING_VALUE&lang_code=SOME_STRING_VALUE&country_code=SOME_STRING_VALUE&count=SOME_INTEGER_VALUE&cursor=SOME_STRING_VALUE") .get() .build(); Response response = client.newCall(request).execute(); Respuestas
200 Éxito