Topic headlines
curl --request GET \
--url https://api.bonai.io/google-news/topic-headlines \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.bonai.io/google-news/topic-headlines"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.bonai.io/google-news/topic-headlines', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.bonai.io/google-news/topic-headlines"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}curl --request GET \
--url https://api.bonai.io/google-news/topic-headlines \
--header 'Authorization: Bearer <token>'{
"success": true,
"totalHits": 123,
"size": 123,
"pageSize": 123,
"page": 123,
"totalPages": 123,
"articles": [
{
"title": "<string>",
"url": "<string>",
"date": "2023-11-07T05:31:56Z",
"thumbnail": "<string>",
"description": "<string>",
"authors": [
"<string>"
],
"source": {
"name": "<string>",
"url": "<string>",
"favicon": "<string>",
"publication_id": "<string>"
},
"keywords": [
"<string>"
]
}
]
}{
"success": false,
"code": 123,
"message": "<string>",
"fields": [
{
"name": "<string>",
"type": "<string>",
"description": "<string>"
}
]
}{
"success": false,
"code": 123,
"message": "<string>",
"fields": [
{
"name": "<string>",
"type": "<string>",
"description": "<string>"
}
]
}API Reference
Topic headlines
Get headlines for a specific topic.
GET
/
topic-headlines
Topic headlines
curl --request GET \
--url https://api.bonai.io/google-news/topic-headlines \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.bonai.io/google-news/topic-headlines"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.bonai.io/google-news/topic-headlines', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.bonai.io/google-news/topic-headlines"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}curl --request GET \
--url https://api.bonai.io/google-news/topic-headlines \
--header 'Authorization: Bearer <token>'{
"success": true,
"totalHits": 123,
"size": 123,
"pageSize": 123,
"page": 123,
"totalPages": 123,
"articles": [
{
"title": "<string>",
"url": "<string>",
"date": "2023-11-07T05:31:56Z",
"thumbnail": "<string>",
"description": "<string>",
"authors": [
"<string>"
],
"source": {
"name": "<string>",
"url": "<string>",
"favicon": "<string>",
"publication_id": "<string>"
},
"keywords": [
"<string>"
]
}
]
}{
"success": false,
"code": 123,
"message": "<string>",
"fields": [
{
"name": "<string>",
"type": "<string>",
"description": "<string>"
}
]
}{
"success": false,
"code": 123,
"message": "<string>",
"fields": [
{
"name": "<string>",
"type": "<string>",
"description": "<string>"
}
]
}Authorizations
Your Bonai API key, sent as Authorization: Bearer <key>. The api-key and x-api-key headers are also accepted.
Headers
API version to consume. Defaults to the latest version (2026-05-25).
Available options:
2026-05-25, 2024-01-01, 2022-01-01 Query Parameters
Topic ID
Country code
Language code
Date filter
Response
Successful response
Example:
true
Total number of matching items
Number of results in this page
Maximum items per page
Current page number
Total number of pages
Hide child attributes
Hide child attributes
Was this page helpful?