https://news.s7risk.com
The News API provides real-time and historical access to global news content at scale.
Get news
This endpoint gets all available news items. The news items returned can be filtered in scope by adding query parameters to your request.
HTTP Request
curl -X GET 'https://news.s7risk.com/news' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer {{YOUR_AUTHENTICATION_TOKEN}}' \
-d 'search=eq:rockets' \
-d 'countryCode=in:AFG,IND,KOR' \
-d 'taxonomyId=in:8cfb8d8a-cd8c-41d8-8a58-da149c874e9b' \
-d 'publishedAt=lte:162515530' \
-d 'sort=publishedAt_desc' \
-d 'limit=200' \
-d 'page=30' \
--compressed
Headers
| Name | Type | Required | Description |
|---|---|---|---|
Authorization | string | ✔️ | Your authentication token (see the Auth API section for more information) |
Query Parameters
| Name | Type | Filter | Description |
|---|---|---|---|
search | string | eq/neq | A search term against the title and summary of news items |
countryCode | string | in/nin | A comma separated list of 3 Alpha-3 country codes |
taxonomyId | string | in/nin | A comma separated list of Taxonomy UUIDs |
publishedAt | string | bt / gte / lte | Either a single timestamp to filter before or after, or two comma separated timestamps to filter between. Defaults to 24 hours before the request is sent. Queries are limited to a maximum of 3 months. |
sort | string | ~ | What order to display the items in. Available options publishedAt_asc or publishedAt_desc. If no sort order is specified then results are sorted in chronological order |
limit | int | ~ | A limited result set between 1 and 5000. Defaults to 1000 |
page | int | ~ | A paginated result set between 1 and 10000. Defaults to 1 |
HTTP Response
{
"status": "success",
"data": {
"news": [
{
"id": "c1b8f161-e978-423b-981c-76301b6025cb",
"title": "Eid al-Adha prayers continue as rockets fired in Afghanistan",
"summary": "Rockets could be heard exploding nearby during prayers in Afghanistan to mark the start of the Muslim festival Eid al-Adha.",
"permalink": "https://www.bbc.co.uk/news/av/world-asia-57900618",
"taxonomy": {
"id": "8cfb8d8a-cd8c-41d8-8a58-da149c874e9b",
"score": 0.80
},
"subTaxonomies": [
{
"id": "a0841b07-e0d6-45b9-870c-1dd0a20b1845",
"score": 0.70
}
],
"industries": [
{
"reference": "in.pol",
"name": "Politics"
}
],
"countries": [
{
"code": "USA",
"name": "United States of America"
}
],
"keywords": [
"man",
"prayers"
],
"incidentId": null,
"publishedAt": 1625155307,
"createdAt": 1625155307,
"updatedAt": 1625155307
}
],
"meta": {
"total": 1,
"page": 1,
"pages": 1,
"pageSize": 100
}
}
}
Success
| Code | Status | Description |
|---|---|---|
| 200 | Success | Returns a body containing all valid News items |
Errors
| Code | Status | Description |
|---|---|---|
| 401 | Unauthorized | Expired or Invalid Authentication token |
| 422 | Unprocessable Entity | Incorrect or invalid parameter |
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article