मुख्य सेवाएं API
ऑनलाइन समाचार खोज डायरेक्ट API
ऑनलाइन समाचार में डिजिटल-नेटीव आउटलेट्स, समाचार पत्र, प्रसारक, केबल सेवाएँ और वेब पर प्रकाशित मैगज़ीन द्वारा रिपोर्टिंग शामिल है। यह प्रतिष्ठा, बाजार संकेतों, नीति विकास और तेजी से चल रही सार्वजनिक जानकारी के लिए महत्वपूर्ण है।
API संदर्भ संस्करण: 1.0.0 3 एंडपॉइंट प्रमाणीकरण
बेस URL
https://api.pressmonitor.com/news-online/v1 प्रमाणीकरण
सभी अनुरोध Bearer टोकन प्रमाणीकरण का उपयोग करते हैं। प्रत्येक कॉल में Authorization हेडर जोड़ें।
Authorization: Bearer YOUR_TOKEN GET
/headlines शीर्षक
News Headlines
पैरामीटर
| नाम | प्रकार | स्थान | आवश्यक | विवरण |
|---|---|---|---|---|
| keywords_text | string | query | हां | किवर्ड्स टेक्स्ट |
| lang_code | string | query | नहीं | भाषा कोड |
| country_code | string | query | नहीं | देश कोड |
| count | integer | query | नहीं | गिनती |
| cursor | string | query | नहीं | कर्सर |
कोड उदाहरण
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(); प्रतिक्रियाएं
200 सफलता
GET
/briefs संक्षेप
News Briefs
पैरामीटर
| नाम | प्रकार | स्थान | आवश्यक | विवरण |
|---|---|---|---|---|
| keywords_text | string | query | हां | किवर्ड्स टेक्स्ट |
| lang_code | string | query | नहीं | भाषा कोड |
| country_code | string | query | नहीं | देश कोड |
| count | integer | query | नहीं | गिनती |
| cursor | string | query | नहीं | कर्सर |
कोड उदाहरण
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(); प्रतिक्रियाएं
200 सफलता
GET
/fulltext पूर्ण पाठ
News Fulltext
पैरामीटर
| नाम | प्रकार | स्थान | आवश्यक | विवरण |
|---|---|---|---|---|
| keywords_text | string | query | हां | किवर्ड्स टेक्स्ट |
| lang_code | string | query | नहीं | भाषा कोड |
| country_code | string | query | नहीं | देश कोड |
| count | integer | query | नहीं | गिनती |
| cursor | string | query | नहीं | कर्सर |
कोड उदाहरण
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(); प्रतिक्रियाएं
200 सफलता