Skip to content

A REST API for the Machathon 5.00 Tech Summit and its competitions.

License

Notifications You must be signed in to change notification settings

Apolo151/machathon5_api

Repository files navigation

machathon5_api

A REST API for the Machathon 5.00 Tech Summit and its competitions.

This api will interact with various services as needed, such as:

  • summit registration form - link
  • competition leaderboard - link
  • Submission requests coming from the competition's simulator - Simulator link

Note: The event has successfully ended, so the official data has been removed and the current data is just dummy data for presentation.

This repo can be used as a template for anyone wanting to hold a similar event or summit.

Functionality

Event Registration

Event attendees will be able to register for the event through a web form.

Competition Registration (TBD)

Teams will be able to register for any competition in the event through a web form.

Competition Submission

Competitors solutions get submitted by sending a request to the API to store the submission in the database.

Leaderboard

Competitors will be able to see their scores and rankings through the competition leaderboard.

Local Setup

using nvm is recommended for installing node.

  • Clone repo
git clone https://github.com/Apolo151/machathon5_api.git
cd machathon5_api
  • install node modules
npm install
  • create a .env file and add needed environment variables
touch .env

# example .env file
DATABASE_URL='YOUR DATABASE CONNECTION STRING'
TEST_DATABASE_URL='YOUR TEST DATABASE CONNECTION STRING'
SERVER_PORT=3000 # the port on which the servers listens to connections on

running app

  • in development mode
npm run start-dev
  • build and run
npm start

Testing

  • run unit tests
npm run test:unit; npm run dropdb
  • run unit tests with code coverage
npm run test:unit:coverage; npm run dropdb

check jest docs.

Future Plan/Improvements

  • Implement Auth
  • Add Dockerfile

check issues for a comprehensive list.

About

A REST API for the Machathon 5.00 Tech Summit and its competitions.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published