Build an API Proxy Server - Hide Your API Keys, Rate Limiting & Caching
We will use Node.js & Express to create a server in order to hide public API keys, add rate limiting and caching
? Code:
https://github.com/bradtraversy/node-api-proxy-server
Demo App:
https://traversy-weather-app.herokuapp.com
Node.js API Masterclass Course: (promo code: OCTOBER2021)
https://www.udemy.com/course/nodejs-api-masterclass/?referralCode=F95A0D3B9CA1DB648F55
? Website & Courses:
https://traversymedia.com
? Show Support
Patreon: https://www.patreon.com/traversymedia
PayPal: https://paypal.me/traversymedia
? Follow Me On Social Media:
Twitter: https://twitter.com/traversymedia
Instagram: https://www.instagram.com/traversymedia
Linkedin: https://www.linkedin.com/in/bradtraversy
Timestamps:
0:00 - Intro
2:48 - Dependencies & scripts
4:45 - Basic Express server
6:15 - Environment variables
8:00 - Create the route
10:40 - Request from server
15:50 - Forwarding query params
19:55 - Rate limiting
22:40 - API caching
24:28 - Use server with the client app
26:50 - Deploy to Heroku
30:20 - Environment variables on Heroku
? Code:
https://github.com/bradtraversy/node-api-proxy-server
Demo App:
https://traversy-weather-app.herokuapp.com
Node.js API Masterclass Course: (promo code: OCTOBER2021)
https://www.udemy.com/course/nodejs-api-masterclass/?referralCode=F95A0D3B9CA1DB648F55
? Website & Courses:
https://traversymedia.com
? Show Support
Patreon: https://www.patreon.com/traversymedia
PayPal: https://paypal.me/traversymedia
? Follow Me On Social Media:
Twitter: https://twitter.com/traversymedia
Instagram: https://www.instagram.com/traversymedia
Linkedin: https://www.linkedin.com/in/bradtraversy
Timestamps:
0:00 - Intro
2:48 - Dependencies & scripts
4:45 - Basic Express server
6:15 - Environment variables
8:00 - Create the route
10:40 - Request from server
15:50 - Forwarding query params
19:55 - Rate limiting
22:40 - API caching
24:28 - Use server with the client app
26:50 - Deploy to Heroku
30:20 - Environment variables on Heroku
Traversy Media
Traversy Media features the best online web development and programming tutorials for all of the latest web technologies including Node.js, Angular 2, React.js, PHP, Rails, HTML, CSS and much more...