/peru_news

One site for all Peruvian news headlines

Primary LanguagePython

Peru News

The main site is here.

Scrapper

Use it to scrap articles from Peruvian news websites.

Run the scrapper with

python scrappy/app.py

Api

You can find the api here.

Endpoints

There are 2 main endpoints:
  • Sources /v1/sources - returns all sources that are currently being scrapped.
  • Sections /v1/sections - returns all available sections.
  • Articles /v1/articles/?source=[SOURCE] - returns all scrapped articles from a given source. See the 'supported sources' for a list of available sources.

Request Parameters

All of the following are to be used with the /articles endpoint.

  • source - A string of identifiers for the news sources you want information for. Use the /sources endpoint for a list of supported sources.
  • date - The date articles were published in the format YYYY-MM-DD.
  • section - Section within the source. See 'supported sections' for available options.
  • pageSize - The number of results to return per page (request). 20 is the default, 100 is the maximum.
  • page - Use this to page through the results if the total results found is greater than the page size.

Supported Sources

Supported Sections

  • politica
  • mundo
  • economia
  • actualidad
  • deportes
  • entretenimiento
  • tecnologia