gitricko / nes-games-api

REST API built with Node and Express that returns metadata for every NES game ever published

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

NES Games API

This is a simple REST API built with Node and Express that returns metadata for every NES game ever published. Tests were written using Insomnia and the Inso CLI tool and are run as part of a continuous integration pipeline using GitHub Actions.

Running the App Locally

  1. yarn install
  2. yarn start
  3. Navigate to http://localhost:3000 in your browser

Running the Tests Locally

yarn test to run the Insomnia test suite (Make sure you have the app running already in a separate terminal window. Otherwise, use yarn ci:start-and-test instead to start the app and run the tests all in one command.)

Available Endpoints

  • /
  • /games
  • /games/:gameId
  • /categories
  • /categories/:category
  • /developers
  • /developers/:developer
  • /publishers
  • /publishers/:publisher
  • /releaseyears
  • /releaseyears/:releaseYear

NPM Scripts

  • ci:start-and-test: Concurrently starts the app and runs the unit tests (used as part of the GitHub Actions workflow for CI)
  • ci:test: Waits for the app to be running locally on port 3000 and then runs the unit tests
  • format: Formats the code using Prettier
  • format-watch: Formats the code using Prettier in watch mode
  • start: Starts the app locally with a Node Express.js server running on port 3000
  • test: Runs the Insomnia test suite

Resources

Insomnia and Inso CLI

GitHub Actions

Other Libraries Used

NES Games

About

REST API built with Node and Express that returns metadata for every NES game ever published


Languages

Language:JavaScript 100.0%