Skip to content

alfasoon/news-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

1 Commit
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

News-api

News API server with GNews integration, search functionality, and caching

Version 1.0.0

by alfasoon <alfasoon@gmail.com>


  • Built a custom in-memory caching system (no Redis needed)
  • Uses native fetch API instead of axios for HTTP requests
  • Cache keys are generated from URL paths and query parameters
  • Expired cache entries get cleaned up every 5 minutes automatically
  • Focus on find endpoints - search by title, author, or keywords
  • Comprehensive error handling with descriptive messages and timestamps
  • TODO: Add rate limiting when I have more time

Node.js Express.js JavaScript API Cache

โญ Public Url

https://github.com/alfasoon/news-api

๐Ÿ“š Tech Stack

  • Node.js
  • Express.js
  • JavaScript
  • GNews API
  • Custom In-Memory Cache
  • Fetch API
  • CORS

๐Ÿ“ธ Screenshots

N.A

๐Ÿ“œ Scripts

start : $ node server.js
dev : $ nodemon server.js
test : $ echo "Error: no test specified" && exit 1

๐Ÿ”‘ Keywords

๐Ÿ‘พ Submit issues at

https://github.com/alfasoon/news-api/issues

ยฉ๏ธ License

ISC

Dependencies

  • express : $ ^4.18.2
  • cors : $ ^2.8.5

Dev Dependencies

  • nodemon : $ ^3.0.1

<img src="https://cdn.dribbble.com/users/2401141/screenshots/5487982/developers-gif-showcase.gif"

Documentations


Built with โค๏ธ using Node.js and Express.js

About

Just a test for news api

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •