Querying the Operation History of a Test Plan
Function
This API is used to query the operation history of a test plan.
Calling Method
For details, see Calling APIs.
URI
GET /v1/projects/{project_id}/plans/{plan_id}/journals
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| project_id | Yes | String | Definition Project UUID, which uniquely identifies a project. For details about how to obtain the project UUID, see Obtaining a Project ID. Constraints 32 characters (letters and digits). Range N/A. Default Value N/A. |
| plan_id | Yes | String | Definition ID of a test plan. Constraints 11 to 34 characters. Range N/A. Default Value N/A. |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| offset | Yes | Long | Definition The position where the query starts. Constraints ≥ 0 Range 0–2000000 Default Value N/A. |
| limit | Yes | Long | Definition Number of items displayed on each page. Constraints N/A. Range 1–200 Default Value N/A. |
Request Parameters
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| X-Auth-Token | Yes | String | User token. It can be obtained by calling the IAM API used to obtain a user token. The value of X-Subject-Token in the response header is the user token. |
Response Parameters
Status code: 201
| Parameter | Type | Description |
|---|---|---|
| [Array elements] | Array of TestPlanJournalList objects | Definition Response structure for querying the operation history of a test plan in a project. Range N/A. |
| Parameter | Type | Description |
|---|---|---|
| detail | Array of TestPlanJournalDetail objects | Historical record details. |
| operate_time | String | Change time. |
| operator | NameAndId object | Definition Operator Range N/A. |
| plan_id | String | Definition Test plan ID. Range 11 to 34 characters. |
| project_id | String | Definition Project UUID, which uniquely identifies a project. For details about how to obtain the project UUID, see Obtaining a Project ID. Constraints 32 characters (letters and digits). Range N/A. |
| Parameter | Type | Description |
|---|---|---|
| added | Array of NameAndId objects | Records of adding test plan resources (work items or test cases). |
| deleted | Array of NameAndId objects | Records of removing test plan resources (work items or test cases). |
| journalized_type | String | Definition Specific type in change records. Example: test case or requirement. Range N/A. |
| type | String | Definition Whether the basic information or a resource is changed (adding or removing requirements/test cases). Range N/A. |
| updated | Array of AttributeChange objects | Definition Change of the basic information about the test plan. It includes the plan name, test type, plan processor, version, associated sprint, start date, end date, and description. Range N/A. |
| Parameter | Type | Description |
|---|---|---|
| id | String | Definition Object ID. Range N/A. |
| name | String | Definition Object name. Range N/A. |
| Parameter | Type | Description |
|---|---|---|
| attribute_type | String | Definition Changed test plan attributes. Range N/A. |
| new_value | String | Definition Changed value. Range N/A. |
| old_value | String | Definition Value before the change. Range N/A. |
Status code: 400
| Parameter | Type | Description |
|---|---|---|
| error_code | String | Definition Error code displayed after the API fails to be called. Range N/A. |
| error_msg | String | Definition Error message displayed after the API fails to be called. Range N/A. |
Status code: 401
| Parameter | Type | Description |
|---|---|---|
| error_code | String | Definition Error code displayed after the API fails to be called. Range N/A. |
| error_msg | String | Definition Error message displayed after the API fails to be called. Range N/A. |
Status code: 404
| Parameter | Type | Description |
|---|---|---|
| error_code | String | Definition Error code displayed after the API fails to be called. Range N/A. |
| error_msg | String | Definition Error message displayed after the API fails to be called. Range N/A. |
Status code: 500
| Parameter | Type | Description |
|---|---|---|
| error_code | String | Definition Error code displayed after the API fails to be called. Range N/A. |
| error_msg | String | Definition Error message displayed after the API fails to be called. Range N/A. |
Example Requests
get https://{endpoint}/v1/projects/efdb403066474ab08836b9eeaaa23bca/plans/9b26f58ec29943f681804a6628779a23/journals?offset=1&limit=10 Example Responses
Status code: 201
OK
[ {
"detail" : [ {
"added" : [ {
"id" : "ID",
"name" : "Name"
} ],
"deleted" : [ {
"id" : "ID",
"name" : "Name"
} ],
"journalized_type" : "plan",
"type" : "resource/attribute",
"updated" : [ {
"attribute_type" : "name",
"new_value" : "tester",
"old_value" : "test"
} ]
} ],
"operate_time" : "2021-07-10",
"operator" : {
"id" : "ID",
"name" : "Name"
},
"plan_id" : "c7c2ddf2ea914164ac6ee76bf11a30ea",
"project_id" : "9b26f58ec29943f681804a6628779a23"
} ] Status Codes
| Status Code | Description |
|---|---|
| 201 | OK |
| 400 | Bad request |
| 401 | Unauthorized |
| 404 | Not found |
| 500 | Internal server error |
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.