/api/v1/lists/{listId}/tasks (POST)
POST
/api/v1/lists/{listId}/tasks
const url = 'https://example.com/api/v1/lists/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/tasks';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","title":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/api/v1/lists/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/tasks \ --header 'Content-Type: application/json' \ --data '{ "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "title": "example" }'Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ” listId
required
string format: uuid
Request Body
Section titled “Request Body ” Media type application/json
object
id
required
string format: uuid
title
required
string
Example generated
{ "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "title": "example"}Responses
Section titled “ Responses ”Created
Media type application/json
object
id
required
string format: uuid
listId
required
string format: uuid
title
required
string
done
required
boolean
starred
required
boolean
dueDate
required
string | null
notes
required
string | null
notesUpdatedAt
required
string | null
rank
required
string
assigneeId
required
string | null
assignedToMe
boolean
createdAt
required
string
updatedAt
required
string
deletedAt
string
Example generated
{ "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "listId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "title": "example", "done": true, "starred": true, "dueDate": "example", "notes": "example", "notesUpdatedAt": "example", "rank": "example", "assigneeId": "example", "assignedToMe": true, "createdAt": "example", "updatedAt": "example", "deletedAt": "example"}No valid session
Media type application/problem+json
object
type
required
string
title
required
string
status
required
number
code
required
string
Example generated
{ "type": "example", "title": "example", "status": 1, "code": "example"}Parent List not found
Media type application/problem+json
object
type
required
string
title
required
string
status
required
number
code
required
string
Example generated
{ "type": "example", "title": "example", "status": 1, "code": "example"}Idempotency-Key reused with a different request
Media type application/problem+json
object
type
required
string
title
required
string
status
required
number
code
required
string
Example generated
{ "type": "example", "title": "example", "status": 1, "code": "example"}