An Express + Node.js API for Allegiance
People want to support their favorite teams, talk about sports, and interact with other fans yet conversations are siloed across different channels. It's difficult to find fans and build connections both in person and online. Standard social networks lack features built for the needs of sports fans. We aim to build an app that will allow sports fans to connect with each other through groups and local engagement with other fans that are located nearby.
This project is deployed using Heroku. Please find Heroku documentation here.
Before running the server locally, it is recommended that the user reads the documentation embedded within this readme about the database and the api resources.
- Clone this repository
- npm install to install all required dependencies (note PostgreSQL must be setup for all actions from this point on)
- npx knex migrate:latest to create tables in the development environment
- npx knex seed:run to populate the database with seed data
- npm run server to start the server locally
The technologies selected (Express, Knex, Node) were chosen for the vibrant documentation, large base of developer users, and established package ecosystems present for each of the techs.
See link to diagram of the database model here. This project uses PostgreSQL in both development and production environments. Find documentation for PostgreSQL here. Note that the user will need to setup environment variables as required by Knex and PostgreSQL.
Sample variables:
DB_LOCAL=allegiance
DB_LOCAL_USER=postgres
DB_LOCAL_PASSWORD=password
DB_TEST=test
DB_TEST_USER=postgres
DB_TEST_PASSWORD=password
Allegiance uses Auth0 for its authentication and API call processes. Please find Auth0 documentation here, along with the step by step tutorial used in this project here.
All endpoints have been documented using Postman. The latest version can be found here.
@JarredStanford | @DerekSchwantner | @DaftBeowulf | @AngXuDev | @danpatrickoneill |
MIT © 2019 Allegiance