Front-End Deploy: https://a.humanrightsfirstasylum.dev/ (enable 3rd party cookies!)
- Please request credentials because project contains sensitive stakeholder information
Back-up Front-End Deploy: https://human-rights-first-asylum-fe.vercel.app/ - Repo
Back-End: https://hrf-asylum-api.herokuapp.com/ - Repo
(If the deployment links stop working, it's because this was originally a school project that utilized the school's AWS and Okta resources.)
- This project is built with the Basic Node API Scaffold. To get started with the project, go here and follow the instructions. Be sure to read the instructions carefully. We found it easiest to use ElephantSQL for setting up your local database.
- Project deployed here, using Heroku Postgres.
- View the Swagger docs (backend endpoint visualization)
- Corresponding Front-end Repository
- Front-end deployment, using AWS Amplify.
cacache cron mime-types json2csv aws-sdk
- Create a local Postgres database/instance.
- Clone the repo locally to your machine
- Create an .env file on the top level of the repo, with the provided credentials.
- run:
npm install
to download all dependencies. - run:
npm run watch:dev
to start your local development server.
- There are several comments throughout the code that are in place for the Swagger docs, these comments should remain untouched unless the endpoints change.
- Once there is an actionable API from DS, this backend will use AWS to connect to the API and update our database. This
update
function can be found in./utils/update.js
- Currently, there is a function to clear this cache every 30 days (located in
./utils/update.js
), but it is currently commented out. We are still waiting for a working DS model before we uncomment that file. - As we near the end of labs, we are learning of some potential changes from the stakeholder regarding judge types, the stakeholder now wants to keep track of Board of Immigration Appeals (BIA) judges that are assigned to cases as well as the Immigration Judge (IJ) assigned. This could mean that the database as it stands will need to be redone and new queries will need to be written in the
judgeModel
. If this new information is confirmed, there will be a lot of work to be done. We have drawn up a proposed database schema in the event that a rework of the database is necessary. Both the current database schema and the proposed database schema can be found in./reference
. - Currently, only the
/profile
endpoints require authentication. In the future, auth will need to be added to all endpoints however it has not been done yet to make it easier for the entire team to work with the data. - Adding profiles was not in scope for this iteration, but there is an endpoint created for it. Because of the Okta integration, we were told that adding profiles was not something we would be doing.
- The
.env.sample
file contains all of the environment variables needed and where to find the values in order to run the project locally. - It is encouraged that you install the "Better Comments" extension for VSCode, there are several comments that were written with this extension in mind.
- No known bugs!
- Add auth to various endpoints
- Add an edit case endpoint
- Better mock seed data. Currently, only user profiles, cases, and judges are seeded. Future seeding:
- Protected Grounds: Race, Religion, Nationality, Political Opinion, Protected Social Group
- Protected Social Groups
- Positive Tags
- Negative Tags
- All Join tables
- DS - Code has not been tested whether it will properly post to datascience Postgres database. Datascience PG database was unavailable during the project.
- The update function written in middleware only works in theory. Once the DS server is up, it will need to be tested and tweaked.
- Testing needs to be written more fully. The only tests that reliably pass are the profile tests.
- Some Case PDFs have the case ID's redacted. If it is not provided by the DS db, we need to generate an (autoincremented) ID
Ava Wingfield | Tom Bauer | Ryan Lee |
Tzong-Lian Tsay | Trevor Beadle | Reuben Palumbo |
Anna Brander | Maycie Morris | Lynda Santiago |