Skip to content

This is an simple free API scrating news on climate change from prominent newspapar and serving thse news on RAPID API using NodeJS .

Notifications You must be signed in to change notification settings

cetinogut/2023_climate-change-live-api

Repository files navigation

climate-change-live-api

A Demo to show how to build your own API and host in on RapidAPI

To run this project

You can run this project on your local machine. Just pull it down and do the following:

npm i

  1. Run the command above to install all the packages

Start the Project

  1. Now run the server i your localhost
npm run start
  1. Open http://localhost:8000/news with your browser to see the results of the scrape in your terminal. You can also used certain paramters to get news from individual sources.

  2. If you want to deploy the api to Netlify: create folders functions with api.js ( a modified version of index.js) and functions with empty index.html file + netlify.toml

  3. Add a new script to package.json for build ("build": "netlify deploy --prod")

  4. When"you npm run build" the app will be deployed to your netlify site, follow the netlify cli options. Choose "dist" for publish folder when prompted.

  5. Happy coding!!!

https://rapidapi.com/cetinogutgm/api/climate-news-api6

MIT Licence

About

This is an simple free API scrating news on climate change from prominent newspapar and serving thse news on RAPID API using NodeJS .

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published