When developing an application that requires our user data or updating it, you will need to run the code locally.
This API is currently only for internal use which is why there is no option for API keys to interact with the API in your own app.
You will need node, npm, and Docker Desktop for this.
- Clone this repository
- Enter the root directory
- Create a
.env.developmentfile with the entries that are specified in.env.example- You will need to create some of your own resources such as a Google Cloud App. You can refer to the Google Auth section
npm run docker:extto startnpm run exitdocker:extto stop the server ORnpm run exitdocker:ext -- -vto stop the server AND erase the persisting database
- Go to
localhost:8000/docsto view the documentation - Go to
localhost:5555for Prisma Studio - this is a dev environment tool that lets you see and modify your data freely. - **Ensure you
git pull origin mainoften so that you get the latest changes. There is currently no autoupdate mechanism.
Your local copy will have no data associated with it. You should try creating a few users and resources based off the documentation page.
Auth is handled with cookies so whichever user you are logged in with is automatically used for authorization for the endpoints. This means if you want to act under a certain account, you must logout (or use a different auth environment), then login to get the new cookie.
- Create a couple of users (either using GAuth or Email)
- One regular "USER" like a hacker
- One "ADMIN" which would be an organizer
- The ADMIN role needs to be hand changed in Prisma studio
- Login as a regular user and create a couple of resources such as an Application.
- Login as an admin and test the /admin routes (the only routes available to admins)