Need help with News API apitube

I’ve recently started using the new News API scraper, apitube. I haven’t fully figured it out yet. I’m trying to set up the retrieval of the real time crude news (I’ve managed to do this part, check it out below). However, I also need to collect archived news about natural gas and metals, and I’m stuck here. Has anyone worked with archived news from apitube?

import requests

url = “https://api.apitube.io/v1/news/everything

querystring = {
“category.name”: “Oil and gas - downstream activities”,
“language”: “en”,
“api_key”: “myKEY”
}
response = requests.request(“GET”, url, params=querystring)

print(response.text)

I think your API endpoint might be off. I am looking at their documentation and they do include a postman collection and it consists of all POST requests.

Specifically I found that they list all the categories with their id’s:

I found the id’s on the left. Here is also the POST request for getting news by category:

https://api.apitube.io/v1/news/category/{{category.taxonomy}}/{{category.id}}?api_key={{api_key}}

Here is the postman link I found on their documentation with more info on it:
https://www.postman.com/apitube/apitube/request/8whv8tc/get-news-by-category

They also, if you look on the postman, have a way to get news by topic. I would try out the 2 endpoints and see if you get your desired result.

TL

2 Likes