It is a set of different Microservice APIs built using Express JS which serve different purpose.
These microservices are built as a part of freeCodeCamp Backend Development and APIs project.
Timestamp Microservice API parses the input date and returns the UNIX and UTC timestamps for the provided input.
Access the API using either of these 2 services:
- Netlify: https://microservice-utility.netlify.app/api/
- Replit: https://timestamp-microservice.saideepd.repl.co/
{
"unix": 1642204800000,
"utc": "Sat, 15 Jan 2022 00:00:00 GMT"
}
Who Am I Microservice API is a Request Header Parser that provides client information of the user consuming the API. It provides the Client's IP address, Browser Language and the Browser's User Agent used for browsing the internet.
Access the API using either of these 2 services:
- Netlify: https://microservice-utility.netlify.app/api/whoami
- Replit: https://request-header-parser-microservice.saideepd.repl.co/
{
"ipaddress": "183.87.11.36",
"language": "en-GB,en-US;q=0.9,en;q=0.8",
"software": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/97.0.4692.71 Safari/537.36"
}
URL Shortener Microservice API is a service that helps you to shorten your lengthy website URLs with simple shorter URLs that are easy to remember & quick to type. This service uses MongoDB as database to store & retrieve the URLs.
Access the API using either of these 2 services:
- Netlify: https://tyni.netlify.app
- Replit: https://tinyurl.saideepd.repl.co/
{
"original_url": "https://www.freecodecamp.org/",
"short_url": 1
}
File Metadata Microservice API is a service that helps you to analyse your files by knowing its metadata. This app provides a simple UI to upload your files & the API provides information of the file like its name, type & size. The API uses Multer as a middleware to handle file uploads. Currently the API is configured to only accept files below 10 Mb in size due to server limitations, but that can be configured as per requirements & server plans.
Access the API using either of these 2 services:
- Netlify: https://metafile.netlify.app
- Replit: https://metafile.saideepd.repl.co/
{
"name": "github_icon_grey.png",
"type": "image/png",
"size": 224
}
- Netlify Serverless Functions
- Limiting the number of requests per minute to avoid crossing any cloud service's plan limits
- Simple way to build APIs using ExpressJS
- DOM Manipulation using JavaScript
- Connecting to & using MongoDB as a database for a web app
- Using Mongoose library to interact with MongoDB
- Validating of URL using Node's inbuilt DNS library
- Using Multer library as a middleware to handle file uploads
- Storing the files to either Disk or Memory using multer
- Limiting the size of files allowed to be uploaded using multer & body-parser
- Learnt about HTML events like onload, onbeforeunload, onformchange, etc.