Updated on 2023-06-12 GMT+08:00

Obtains bug statistics.

Function

Obtains bug statistics by module.

URI

GET /v4/projects/{project_id}/bug-statistic

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Specifies the 32-bit ID of the devcloud project.

Minimum: 32

Maximum: 32

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

Specifies the user token. It can be obtained by calling an IAM API. The value of X-Subject-Token in the response header is the user token.

Minimum: 10

Maximum: 32768

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

bug_statistics

Array of BugStatisticResponseV4 objects

Bug Statistics

Table 4 BugStatisticResponseV4

Parameter

Type

Description

critical_num

Integer

Indicates the number of critical bugs.

defect_index

Double

DI

module

String

Module

normal_num

Integer

Indicates the number of minor bugs.

serious_num

Integer

Number of Major Defects

tip_num

Integer

Indicates the number of trivial bugs.

total

Integer

Total

Status code: 400

Table 5 Response body parameters

Parameter

Type

Description

error_msg

String

Description

error_code

String

Error Codes

Status code: 401

Table 6 Response body parameters

Parameter

Type

Description

error_msg

String

Description

error_code

String

Error Codes

Example Requests

GET https://{endpoint}/v4/projects/526cefde62004de2b62b5e8dd2c2b3af/bug-statistic

GET https://{endpoint}/v4/projects/526cefde62004de2b62b5e8dd2c2b3af/bug-statistic

Example Responses

Status code: 200

OK

{
  "bug_statistics" : [ {
    "critical_num" : 0,
    "defect_index" : 1,
    "module" : "",
    "normal_num" : 1,
    "serious_num" : 0,
    "tip_num" : 0,
    "total" : 1
  } ]
}

Status Codes

Status Code

Description

200

OK

400

Bad Request

401

Unauthorized

Error Codes

See Error Codes.