TQL查询任务
POST
https://open.teambition.com/api/task/tqlsearch该接口用于通过TQL提供强大的任务查询能力。
请求参数
Header 参数
Content-Type
string
可选
示例值:
application/json
Body 参数application/json
tql
string
必需
查询语句;参见 TQL介绍
pageSize
integer
分页大小
pageToken
string
分页token
orderBy
string
可选
排序字段;支持(dueDate/priority/createdDesc/updatedDesc/project/accomplished)
示例
{
"tql": "_projectId=5e991ceb26c51920e21e51c9",
"pageSize": 100,
"pageToken": "",
"orderBy": "dueDate"
}
示例代码
返回响应
成功(200)
HTTP 状态码: 200
内容格式: JSONapplication/json
数据结构
count
string
必需
返回码,200 表示成功
nextPageToken
string
必需
调用失败时的错误信息
result
array[object (result) {24}]
必需
taskId
string
任务 ID
projectId
string
项目 ID
templateId
string
任务类型 ID
tasklistId
string
任务列表 ID
taskgroupId
string
任务分组 ID
content
string
任务内容
executorId
string
执行者的用户 ID
statusId
string
工作流状态 ID
sprintId
string
迭代 ID
startDate
string
开始时间
dueDate
string
截止时间
accomplishDate
string
完成时间
note
string
任务备注
priority
integer
必需
优先级: 0:普通(默认值) 1:紧急 2:非常紧急
visible
string
必需
可见性: participants:任务参与者可见 projectMembers:项目成员可见(默认值)
parentTaskId
string
父任务 ID
ancestorIds
array[string]
必需
所有祖先任务,ancestorIds[0] 为直接父任务,ancestorIds[1] 为父任务的父任务,以此类推
participants
array[string]
必需
参与者的用户 ID 列表
customfields
array[object (customfields) {2}]
自定义字段列表
isDone
integer
是否完成
creatorId
string
创建人的用户 ID
created
string
任务创建时间
modifierId
string
必需
最近一次执行更新操作的用户 ID
updated
string
最近一次更新时间
示例
{
"count": "100",
"nextPageToken": "5a28e2036176bbde...",
"result": [
{
"operatorId": "5a28e2036176bbde...",
"projectId": "5e0d98527d161c00...",
"templateId": "5e1421647fd0daf8...",
"tasklistId": "5d5798a2d4268209...",
"taskgroupId": "5d5798a2d4268209...",
"content": "第一个任务",
"executorId": "5a28e2036176bbde...",
"statusId": "5e142164aef01b07...",
"startDate": "2019-12-01T10:30:00Z",
"dueDate": "2019-12-05T18:00:00Z",
"note": "第一个任务",
"priority": 0,
"visible": "projectMembers",
"parentTaskId": "",
"participants": [
"5a28e2036176bbde..."
],
"customfields": [
{
"cfId": "5e11b2b7ed69f340...",
"value": [
"abc"
]
}
]
}
]
}
最后修改时间: 3 年前