Skip to content

Swagger Markdown

Chinmay Deshmukh edited this page May 1, 2020 · 3 revisions

Doto

A brief visual description of backend API. NB. Authorization Header required for using API.

Version: 1.0.0

License: Swagger UI License: MIT

/task/get

GET

Description:

Get all Tasks for user

Parameters
Name Located in Description Required Schema
User email (String) No
Responses
Code Description Schema
200 List of tasks associated with this user Tasks

/task/post

POST

Description:

Create new task in system

Parameters
Name Located in Description Required Schema
body No Task
Responses
Code Description
200 taskId: 'taskId', Successful: 'True'
400 taskId: 'taskId', Successful: 'False'

/task

PUT

Description:

Edit Task in System

Parameters
Name Located in Description Required Schema
taskId taskId (String) No
body No Task
Responses
Code Description
200 taskId: 'taskId', Successful: 'True'
400 taskId: 'taskId', Successful: 'False'

DELETE

Description:

Delete Task in System

Parameters
Name Located in Description Required Schema
taskId taskId (String) No
Responses
Code Description
200 taskId: 'taskId', Deleted: 'True'
400 taskId: 'taskId', Deleted: 'False'

/user/get

GET

Description:

Get user details

Parameters
Name Located in Description Required Schema
email email (String) No
Responses
Code Description Schema
200 Here are all the User Details User
400 Error: could not find user with specified email.

/user/update

PUT

Description:

Update user details

Parameters
Name Located in Description Required Schema
email email (String) No
body No User
Responses
Code Description
200 email: 'email', Successful: 'True'
400 email: 'email', Successful: 'False'

/user/email

GET

Description:

Get all users details

Parameters
Name Located in Description Required Schema
Responses
Code Description Schema
200 Here are all the Users and their Details Users
400 msg: failed

Models

User

Name Type Description Required
email string Yes
name string No
picture string No
themePreference string No
startTime date No
endTime date No
points integer No
unlockedItems array No

Users

Name Type Description Required
Users array

Task

Name Type Description Required
user User Yes
taskId string Yes
title string Yes
description string No
location string No
priority integer No
duration integer Yes
startDate date Yes
endDate date Yes
reminderDate date No
isComplete boolean No
dueDate date No
travelTime integer No
reminderType integer No
earliestDate date Yes
category integer No

Tasks

Name Type Description Required
Tasks array
Clone this wiki locally