# 说明
根据视图id获取项目集视图工作项列表
# url
https://api.tapd.cn/workitems/get_workitem_list_by_view_id
# 支持格式
JSON/XML(默认JSON格式)
# HTTP请求方式
GET
# 请求参数
| 字段名 | 必选 | 类型及范围 | 说明 | 特殊规则 |
|---|---|---|---|---|
| workspace_id | 是 | integer | 项目集ID | |
| view_id | 是 | integer | 视图ID | |
| current_user | 否 | string | 如果当前视图条件中有使用"当前登录用户"的,则需要传入该值 | |
| limit | 否 | integer | 设置返回数量限制,默认为30 | |
| page | 否 | integer | 返回当前数量限制下第N页的数据,默认为1(第一页) |
# 调用示例及返回结果
# 获取某视图下工作项列表
# curl 使用 Basic Auth 鉴权调用示例
curl -u 'api_user:api_password' 'https://api.tapd.cn/workitems/get_workitem_list_by_view_id?view_id=xxx&workspace_id=xxx'
# 返回结果
{
"status": 1,
"data": {
"story_count": 63,
"bug_count": 11,
"story_list": [
{
"name": "xxx",
"status": "xxx",
"priority": "xxx",
"iteration_id": "xxx",
"workspace_id": "xxx",
"created": "xxx",
"owner": "xxx",
"due": null,
"custom_field_four": "",
"custom_field_five": "",
"custom_field_seven": "",
"custom_field_eight": "",
"custom_field_35": "",
"custom_field_22": "",
"custom_field_41": "",
"custom_field_9": "",
"custom_field_11": "",
"id": "xxx",
"workitem_type_id": "xxx",
"parent_id": "0",
"secret_root_id": "0",
"children_id": "|",
"follower": "",
"path": "xxx:",
"level": "0",
"ancestor_id": "xxx",
"has_attachment": "0",
"effort": null,
"effort_completed": "0",
"remain": "0",
"exceed": "0",
"completed": null,
"modified": "xxx",
"begin": null,
"entity_type": "Story",
"category_name": "--",
"parent_name": "--",
"_parent_id": "0",
"workitem_type_name": "xxx",
"workitem_type_english_name": "xxx",
"workitem_type_color": "xxx",
"short_id": 0,
"attachment_count": 0,
"workspace_name": "xxx",
"iteration_name": "--",
"release_name": "--",
"story_name": "--",
"priority_name": "--",
"status_alias": "xxx",
"is_archived": 0
}
],
"bug_list": [
{
"title": "xxx",
"status": "xxx",
"priority": "",
"iteration_id": "0",
"project_id": "xxx",
"created": "xxx",
"current_owner": "",
"due": null,
"custom_field_two": "",
"custom_field_five": "",
"custom_field_7": "",
"custom_field_8": "",
"id": "xxx",
"follower": "",
"reporter": "xxx",
"delayed": "0",
"effort": null,
"effort_completed": "0",
"remain": "0",
"exceed": "0",
"progress": "0",
"resolved": null,
"modified": "xxx",
"begin": null,
"entity_type": "Bug",
"owner": "",
"name": "xxx",
"workspace_id": "xxx",
"resolution_name": "--",
"creator": "xxx",
"short_id": 0,
"project_name": "xxx",
"workspace_name": "xxx",
"attachment_count": 0,
"iteration_name": "--",
"release_name": "--",
"story_name": "--",
"priority_name": "--",
"severity_name": "--",
"_parent_id": 0,
"status_alias": "xxx",
"is_archived": 0
}
]
},
"info": "success"
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108