Task#
pyticktick.models.v1.responses.task
#
Response models for task related endpoints in TickTick API v1.
Classes:
Name | Description |
---|---|
ItemV1 |
Model for a response with checklist item information in the V1 API. |
TaskRespV1 |
Model for a response with task information in the V1 API. |
ItemV1
pydantic-model
#
Bases: BaseModel
Model for a response with checklist item information in the V1 API.
This model is used to represent a checklist item in the V1 API. It is used in the
TaskRespV1
model to represent checklist items of a task. It maps directly to the checklistitem
definition in the V1 API docs.
Show JSON schema:
{
"description": "Model for a response with checklist item information in the V1 API.\n\nThis model is used to represent a checklist item in the V1 API. It is used in the\n`TaskRespV1` model to represent checklist items of a task. It maps directly to the [checklistitem](https://developer.ticktick.com/docs#/openapi?id=checklistitem)\ndefinition in the V1 API docs.",
"properties": {
"id": {
"description": "Subtask identifier",
"title": "Id",
"type": "string"
},
"title": {
"description": "Subtask title",
"title": "Title",
"type": "string"
},
"status": {
"description": "The completion status of checklist item. Normal: 0, Completed: 1",
"title": "Status",
"type": "boolean"
},
"completedTime": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Subtask completed time in `yyyy-MM-dd'T'HH:mm:ssZ`",
"title": "Completedtime"
},
"isAllDay": {
"description": "All day",
"title": "Isallday",
"type": "boolean"
},
"sortOrder": {
"description": "Subtask sort order",
"title": "Sortorder",
"type": "integer"
},
"startDate": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Subtask start date time in `yyyy-MM-dd'T'HH:mm:ssZ`",
"title": "Startdate"
},
"timeZone": {
"description": "Subtask timezone. Example: 'America/Los_Angeles'",
"title": "Timezone",
"type": "string"
}
},
"required": [
"id",
"title",
"status",
"isAllDay",
"sortOrder",
"timeZone"
],
"title": "ItemV1",
"type": "object"
}
Config:
extra
:ignore
Fields:
-
id
(str
) -
title
(str
) -
status
(bool
) -
completed_time
(str | None
) -
is_all_day
(bool
) -
sort_order
(int
) -
start_date
(str | None
) -
time_zone
(str
)
Validators:
-
_status_from_int
→status
completed_time
pydantic-field
#
completed_time: str | None = None
Subtask completed time in yyyy-MM-dd'T'HH:mm:ssZ
start_date
pydantic-field
#
start_date: str | None = None
Subtask start date time in yyyy-MM-dd'T'HH:mm:ssZ
status
pydantic-field
#
status: bool
The completion status of checklist item. Normal: 0, Completed: 1
TaskRespV1
pydantic-model
#
Bases: BaseModel
Model for a response with task information in the V1 API.
This model is used to represent a task in the V1 API. It is used in a few different
endpoints, including GET /project/{project_id}/task/{task_id}
, POST /task
, and
POST /task/{task_id}
. It maps directly to the task
definition in the V1 API docs.
Show JSON schema:
{
"$defs": {
"ItemV1": {
"description": "Model for a response with checklist item information in the V1 API.\n\nThis model is used to represent a checklist item in the V1 API. It is used in the\n`TaskRespV1` model to represent checklist items of a task. It maps directly to the [checklistitem](https://developer.ticktick.com/docs#/openapi?id=checklistitem)\ndefinition in the V1 API docs.",
"properties": {
"id": {
"description": "Subtask identifier",
"title": "Id",
"type": "string"
},
"title": {
"description": "Subtask title",
"title": "Title",
"type": "string"
},
"status": {
"description": "The completion status of checklist item. Normal: 0, Completed: 1",
"title": "Status",
"type": "boolean"
},
"completedTime": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Subtask completed time in `yyyy-MM-dd'T'HH:mm:ssZ`",
"title": "Completedtime"
},
"isAllDay": {
"description": "All day",
"title": "Isallday",
"type": "boolean"
},
"sortOrder": {
"description": "Subtask sort order",
"title": "Sortorder",
"type": "integer"
},
"startDate": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Subtask start date time in `yyyy-MM-dd'T'HH:mm:ssZ`",
"title": "Startdate"
},
"timeZone": {
"description": "Subtask timezone. Example: 'America/Los_Angeles'",
"title": "Timezone",
"type": "string"
}
},
"required": [
"id",
"title",
"status",
"isAllDay",
"sortOrder",
"timeZone"
],
"title": "ItemV1",
"type": "object"
}
},
"description": "Model for a response with task information in the V1 API.\n\nThis model is used to represent a task in the V1 API. It is used in a few different\nendpoints, including `GET /project/{project_id}/task/{task_id}`, `POST /task`, and\n`POST /task/{task_id}`. It maps directly to the [task](https://developer.ticktick.com/docs#/openapi?id=task-1)\ndefinition in the V1 API docs.",
"properties": {
"id": {
"description": "Project identifier",
"title": "Id",
"type": "string"
},
"projectId": {
"description": "Task project id",
"title": "Projectid",
"type": "string"
},
"title": {
"description": "Task title",
"title": "Title",
"type": "string"
},
"isAllDay": {
"description": "All day",
"title": "Isallday",
"type": "boolean"
},
"completedTime": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Task completed time in `yyyy-MM-dd'T'HH:mm:ssZ`",
"title": "Completedtime"
},
"content": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Task content",
"title": "Content"
},
"desc": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Task description of checklist",
"title": "Desc"
},
"dueDate": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Task due date time in `yyyy-MM-dd'T'HH:mm:ssZ`",
"title": "Duedate"
},
"items": {
"anyOf": [
{
"items": {
"$ref": "#/$defs/ItemV1"
},
"type": "array"
},
{
"type": "null"
}
],
"default": null,
"description": "Subtasks of Task",
"title": "Items"
},
"priority": {
"description": "Task priority. None:0, Low:1, Medium:3, High:5",
"enum": [
0,
1,
3,
5
],
"title": "Priority",
"type": "integer"
},
"reminders": {
"anyOf": [
{
"items": {
"type": "string"
},
"type": "array"
},
{
"type": "null"
}
],
"default": null,
"description": "List of reminder triggers. Example: ['TRIGGER:P0DT9H0M0S', 'TRIGGER:PT0S']",
"title": "Reminders"
},
"repeatFlag": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Recurring rules of task. Example: 'RRULE:FREQ=DAILY;INTERVAL=1'",
"title": "Repeatflag"
},
"sortOrder": {
"description": "Task sort order",
"title": "Sortorder",
"type": "integer"
},
"startDate": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Start date time in `yyyy-MM-dd'T'HH:mm:ssZ`",
"title": "Startdate"
},
"status": {
"description": "Task completion status. Normal: 0, Completed: 2",
"title": "Status",
"type": "boolean"
},
"timeZone": {
"description": "Task timezone. Example: 'America/Los_Angeles'",
"title": "Timezone",
"type": "string"
}
},
"required": [
"id",
"projectId",
"title",
"isAllDay",
"priority",
"sortOrder",
"status",
"timeZone"
],
"title": "TaskRespV1",
"type": "object"
}
Config:
extra
:ignore
Fields:
-
id
(str
) -
project_id
(str
) -
title
(str
) -
is_all_day
(bool
) -
completed_time
(str | None
) -
content
(str | None
) -
desc
(str | None
) -
due_date
(str | None
) -
items
(list[ItemV1] | None
) -
priority
(Literal[0, 1, 3, 5]
) -
reminders
(list[str] | None
) -
repeat_flag
(str | None
) -
sort_order
(int
) -
start_date
(str | None
) -
status
(bool
) -
time_zone
(str
)
Validators:
-
_status_from_int
→status
completed_time
pydantic-field
#
completed_time: str | None = None
Task completed time in yyyy-MM-dd'T'HH:mm:ssZ
priority
pydantic-field
#
priority: Literal[0, 1, 3, 5]
Task priority. None:0, Low:1, Medium:3, High:5
reminders
pydantic-field
#
reminders: list[str] | None = None
List of reminder triggers. Example: ['TRIGGER:P0DT9H0M0S', 'TRIGGER:PT0S']
repeat_flag
pydantic-field
#
repeat_flag: str | None = None
Recurring rules of task. Example: 'RRULE:FREQ=DAILY;INTERVAL=1'