Skip to content

Hamid293/kwanso-backend

Repository files navigation

Installation

$ npm install

Running the app

# development
$ npm run start

# watch mode
$ npm run start:dev

# production mode
$ npm run start:prod

Routes

Following routes are implemented.

POST /register

Body: { email: "[email protected]", password: "password" } Returns: { user: { id: 1, email: "[email protected]" } }

POST /login

Body: { email: "[email protected]", password: "password" } Returns: { jwt: "JWT" }

GET /user

Headers: Authorization: Bearer JWT Returns: { user: { id: 1, email: "[email protected]" } }

POST /create-task

Headers: Authorization: Bearer JWT Body: { name: "Task name" } Returns: { task: { id: 1, name: "Task name" } }

GET /list-tasks

Headers: Authorization: Bearer JWT Returns: { tasks: [{ id: 1, name: "Task name" }, { id: 2, name: "Second task" }] }

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published