News
keyword_search(keyword, max_results=3)
Get the top headlines for a keyword
Parameters:
Name | Type | Description | Default |
---|---|---|---|
keyword |
str
|
Keyword which the news will be about |
required |
max_results |
int, optional
|
Number of news articles that will be returned. By default |
3
|
Returns:
Type | Description |
---|---|
list[str] | None
|
Return a list of strings with the news articles |
top_headlines_search(country='us', max_results=3)
Get the top headlines of a country
Parameters:
Name | Type | Description | Default |
---|---|---|---|
country |
str, optional
|
Name of the country the news will be about. By default |
'us'
|
max_results |
int, optional
|
Number of news article returned. By default |
3
|
Returns:
Type | Description |
---|---|
list[str] | None
|
Return a list of strings with the news articles |