Google News

FREEMIUM
By BFD | Updated 20 days ago | News, Media
Popularity

9.9 / 10

Latency

673ms

Service Level

100%

Health Check

N/A

README

Google News API Documentation

This is the documentation for the Google News API, which provides access to the latest news and articles from various news sources worldwide.

Base URL

The base URL for accessing the API is: hhttps://google-news13.p.rapidapi.com

Endpoints and Parameters

1. /world

Endpoint used to retrieve the latest news from around the world.

  • Parameters:
    • lr (optional): Language region parameter to specify the desired language and region of the news. Example: en-US (English, United States). If not provided, the default value will be used.

2. /latest

Endpoint used to retrieve the latest news from various categories.

  • Parameters:
    • lr (required): Language region parameter to specify the desired language and region of the news. Example: en-US (English, United States).

3. /business

Endpoint used to retrieve news related to business.

  • Parameters:
    • lr (required): Language region parameter to specify the desired language and region of the news. Example: en-US (English, United States).

4. /entertainment

Endpoint used to retrieve news related to entertainment.

  • Parameters:
    • lr (required): Language region parameter to specify the desired language and region of the news. Example: en-US (English, United States).

5. /health

Endpoint used to retrieve news related to health.

  • Parameters:
    • lr (required): Language region parameter to specify the desired language and region of the news. Example: en-US (English, United States).

6. /science

Endpoint used to retrieve news related to science.

  • Parameters:
    • lr (required): Language region parameter to specify the desired language and region of the news. Example: en-US (English, United States).

7. /sport

Endpoint used to retrieve news related to sports.

  • Parameters:
    • lr (required): Language region parameter to specify the desired language and region of the news. Example: en-US (English, United States).

8. /technology

Endpoint used to retrieve news related to technology.

  • Parameters:
    • lr (required): Language region parameter to specify the desired language and region of the news. Example: en-US (English, United States).

9. /search

Endpoint used to search for news based on a keyword.

  • Parameters:
    • keyword (required): The search keyword.
    • lr (optional): Language region parameter to specify the desired language and region of the news. Example: en-US (English, United States). If not provided, the default value will be used.

10. /search/suggest

Endpoint used to get keyword search suggestions based on user input.

  • Parameters:
    • keyword (required): The user input for keyword search suggestions.
    • lr (optional): Language region parameter to specify the desired language and region of the search suggestions. Example: en-US (English, United States). If not provided, the default value will be used.

Example Requests

Here are some examples of how to make requests to the Google News API endpoints:

  1. Retrieve the latest news from around the world:

    GET /google-news/world?lr=en-US
    
  2. Retrieve the latest business news:

    GET /google-news/business?lr=en-US
    
  3. Retrieve the latest entertainment news:

    GET /google-news/entertainment?lr=en-US
    
  4. Retrieve the latest health news:

    GET /google-news/health?lr=en-US
    
  5. Retrieve the latest science news:

    GET /google-news/science?lr=en-US
    
  6. Retrieve the latest sports news:

    GET /google-news/sport?lr=en-US
    
  7. Retrieve the latest technology news:

    GET /google-news/technology?lr=en-US
    
  8. Search for news articles using the keyword “COVID-19”:

    GET /google-news/search?keyword=COVID-19&lr=en-US
    
  9. Get keyword search suggestions based on user input “economy”:

    GET /google-news/search/suggest?keyword=economy&lr=en-US
    

Feel free to customize the requests by changing the values of parameters such as lr (language region) and keyword according to your desired language and search criteria.

Authentication

To access the Google News API, you will need to authenticate your requests by including an API key in the request header. Please refer to the authentication section in the API documentation for instructions on how to generate and include the API key in your requests.

Error Handling

In case of errors or invalid requests, the API will return appropriate HTTP status codes and error messages indicating the issue. Please refer to the API documentation for more details on the possible error responses and their meanings.

Conclusion

The Google News API provides a convenient way to access the latest news and articles from various categories and search for specific news using keywords. By making HTTP requests to the respective endpoints with the required parameters, you can retrieve the desired news information. Refer to the documentation for more detailed usage instructions and examples.

If you have any further questions or need assistance, please don’t hesitate to contact our support team at thedevisty@gmail.com.

Followers: 7
API Creator:
Rapid account: BFD
BFD
bfd
Log In to Rate API
Rating: 4.7 - Votes: 3