An open API service indexing awesome lists of open source software.

https://github.com/alitursucular/serverless-github-repository-fetcher-microservice

Firebase serverless functions & ExpressJS based GitHub repository fetcher for my professional blog alitursucular.github.io
https://github.com/alitursucular/serverless-github-repository-fetcher-microservice

expressjs firebase firestore githubrepos microservice serverless

Last synced: about 2 months ago
JSON representation

Firebase serverless functions & ExpressJS based GitHub repository fetcher for my professional blog alitursucular.github.io

Awesome Lists containing this project

README

        

# Serverless GitHub Repository Fetcher Microservice

This repository implements a couple of serverless Firebase Cloud Functions using ExpressJS to fetch all of my public GitHub repository data. I use this data to power [my professional blog website](https://alitursucular.github.io/) that is hosted on GitHub Pages.

I could have simply fetched my repository data on the client. However, _for unauthenticated requests, the rate limit allows for up to 60 requests per hour. Unauthenticated requests are associated with the originating IP address, and not the person making requests.1_. To stay on the safe side, I decided to create this microservice and get this data from my cloud functions.

In essence, this microservice offers three functions. _alitursucularGithubRepos_, _alitursucularGithubRepoByName_ and a scheduled _fetchAlitursucularGithub_ function that updates Firestore every two hours. I am using `@octokit/rest` package for fetching my public repositories from GitHub.

_1_ [GitHub rate limiting](https://docs.github.com/en/rest/overview/resources-in-the-rest-api?apiVersion=2022-11-28#rate-limiting)