The API for BetterDo. This repository houses the application logic by providing a simple REST API.
It's recommended you run this with the UI. See betterdo-ui.
- 🤖 Simple usable REST API
- 🤓 Elegant application structure for easy adaption
- ✅ 100% end-to-end test coverage
- 🛤Ability to authenticate with Google (and ability to add others) 🛤
- ⌨️ Built on TypeScript
- 🎼 Leverages GitHub actions for automated production deploys and testing
-
Copy
.env.sample
to.env
and then fill it in.cp .env.sample .env
-
Generate VAPID key details and fill them into
.env
npx web-push generate-vapid-keys
-
Create Google OAuth tokens (see here) and enter details into Google OAUTH
.env
sections. -
Install MongoDB with
brew tap mongodb/brew && brew install mongodb-community
-
Run
npm install
-
Run
npm start
/
- The landing page/app
- The application (requires authentication)/auth/google
- Authenticate with Google Endpoint/auth/google/callback
- Google authentication callback/auth/logout
- Logout endpoint/api/lists
- Methods around updating listsGET
: get listsPUT
add listPOST
update listDELETE
delete list
/api/tasks
- Methods around updating tasksGET
: get taskPUT
add taskPOST
update taskDELETE
deleteTask
/api/users/:email
- GET method for seeing if a user exists with an email/api/user
- GET method for current user information/api/users
- POST method for modifying current user