docs: add API structure
This commit is contained in:
parent
0c0f71a72e
commit
cb4530c1ba
1 changed files with 30 additions and 0 deletions
30
src/app/api/README.md
Normal file
30
src/app/api/README.md
Normal file
|
@ -0,0 +1,30 @@
|
||||||
|
# Todoist API
|
||||||
|
|
||||||
|
## Create Task
|
||||||
|
POST /api/task
|
||||||
|
|
||||||
|
## Read Task
|
||||||
|
GET /api/task -> List all task
|
||||||
|
GET /api/task/[taskId] -> Get specific task
|
||||||
|
|
||||||
|
## Update Task
|
||||||
|
PATCH /api/task/[taskId]
|
||||||
|
|
||||||
|
## Delete Task
|
||||||
|
DELETE /api/task/[taskId]
|
||||||
|
|
||||||
|
## Task Structure
|
||||||
|
*Subject to change*
|
||||||
|
|
||||||
|
```js
|
||||||
|
{
|
||||||
|
taskId: number,
|
||||||
|
userId: string,
|
||||||
|
title: string,
|
||||||
|
description: string,
|
||||||
|
dueDate: Date,
|
||||||
|
createdAt: Date,
|
||||||
|
modifiedAt: Date,
|
||||||
|
markedAsDone: boolean,
|
||||||
|
}
|
||||||
|
```
|
Loading…
Add table
Reference in a new issue