Querying a Work Template (V2)
Function
This API is used to query a work template (V2).
Calling Method
For details, see Calling APIs.
URI
GET /v2/project-template/template
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
search |
No |
String |
Definition: Fuzzy search by name. Constraints: N/A Value range: N/A Default value: N/A |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
X-Auth-Token |
Yes |
String |
Definition: User token. Obtain a token by calling the IAM API forobtaining a user token. The value of X-Subject-Token in the response header is the user token. Constraints: Mandatory. Value range: Minimum length: 10 characters. Maximum length: 32,768 characters. Default value: N/A |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
result |
result object |
Definition: Returned result. |
status |
String |
Definition: Returned status. Value range: success: Command execution succeeds. error: Command execution failed. |
Parameter |
Type |
Description |
---|---|---|
templates |
Array of templates objects |
Definition: Template. Value range: N/A |
Parameter |
Type |
Description |
---|---|---|
name |
String |
Definition: Template name. Value range: N/A |
description |
String |
Definition: Template description. Value range: N/A |
creator |
creator object |
Definition: Template owner. Value range: N/A |
source_project |
source_project object |
Definition: Source project of a template. Value range: N/A |
count |
Integer |
Definition: Number of templates. Value range: N/A |
project_list |
Array of project_list objects |
Definition: Project list. Value range: N/A |
children |
Array of children objects |
Definition: Sub-item. Value range: N/A |
Parameter |
Type |
Description |
---|---|---|
nick_name |
String |
Definition: Owner name. Value range: N/A |
Parameter |
Type |
Description |
---|---|---|
project_name |
String |
Definition: Name of the source project of a template. Value range: N/A |
Parameter |
Type |
Description |
---|---|---|
name |
String |
Definition: Project name. Value range: N/A |
identifier |
String |
Definition: Project UUID. Value range: N/A |
description |
String |
Definition: Template description. Value range: N/A |
total |
Integer |
Definition: Priority. Value range: N/A |
close |
Integer |
Definition: Whether the project is closed. Value range: 0: closed 1: open |
role |
Integer |
Definition: Project member role. Value range: N/A |
type |
String |
Definition: Project type. Value range: Scrum |
mem_count |
Integer |
Definition: Number of project members. Value range: N/A |
Parameter |
Type |
Description |
---|---|---|
id |
Integer |
Definition: Sub-project ID. Value range: N/A |
name |
String |
Definition: Name of a sub-project. Value range: N/A |
description |
String |
Definition: Sub-project description. Value range: N/A |
authorId |
Integer |
Definition: ID of the sub-project owner. Value range: N/A |
count |
Integer |
Definition: Number of sub-projects. Value range: N/A |
Example Requests
{endpoint}/v2/project-template/template
Example Responses
Status code: 200
Response indicating successful retrieval of work item template settings.
{ "result" : { "templates" : [ { "name" : "Scrum", "description" : "Default work item template", "creator" : { "nick_name" : "System" }, "source_project" : { "project_name" : "" }, "count" : 1311, "project_list" : [ { "name" : "Scrum01192024", "identifier" : "9cf57d978ce74cb7aa4b444e1ca379fd", "description" : "", "total" : 0, "close" : 0, "role" : 0, "type" : "scrum", "mem_count" : 0 } ], "children" : [ { "id" : 384006, "name" : "12345", "description" : "", "authorId" : 4091, "count" : 0 } ] } ] }, "status" : "success" }
Status Codes
Status Code |
Description |
---|---|
200 |
Response indicating successful retrieval of work item template settings. |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot