GetCheckRun - Get a check run
Use OpenAPI to retrieve details for a single check run.
|
Applicable editions |
Central edition, Region edition |
Endpoint and authorization information
- Obtain the endpoint: Replace {domain} in the API request syntax.
- Obtain a personal access token.
- Obtain organizationId: Required only for the Central edition. Go to the Organization Management console, then open the Basic Information page to obtain your organization ID.
|
Product |
Resource |
Required permission |
|
Code Management |
Check runs |
Read-only |
Request syntax
Central edition
GET https://{domain}/oapi/v1/codeup/organizations/{organizationId}/repositories/{repositoryId}/checkRuns/{checkRunId}
Region edition
GET https://{domain}/oapi/v1/codeup/repositories/{repositoryId}/checkRuns/{checkRunId}
Request headers
|
Parameter |
Type |
Required |
Description |
Example value |
|
x-yunxiao-token |
string |
Yes |
Your personal access token. |
pt-0fh3****0fbG_35af****0484 |
Request parameters
|
Parameter |
Type |
Location |
Required |
Description |
Example value |
|
organizationId |
string |
path |
|
The organization ID. |
60d54f3daccf2bbd6659f3ad |
|
repositoryId |
string |
path |
Yes |
The repository ID or the full path URL-encoded. |
2813489 or 60de7a6852743a5162b5f957%2FDemoRepo |
|
checkRunId |
integer |
path |
Yes |
The check run ID. It is unique. |
1 |
Request examples
Central edition
curl -X 'GET' \
'https://{domain}/oapi/v1/codeup/organizations/60d54f3daccf2bbd6659f3ad/repositories/2813489 or 60de7a6852743a5162b5f957%2FDemoRepo/checkRuns/1' \
-H 'Content-Type: application/json' \
-H 'x-yunxiao-token: pt-0fh3****0fbG_35af****0484'
Region edition
curl -X 'GET' \
'https://{domain}/oapi/v1/codeup/repositories/2813489 or 60de7a6852743a5162b5f957%2FDemoRepo/checkRuns/1' \
-H 'Content-Type: application/json' \
-H 'x-yunxiao-token: pt-0fh3****0fbG_35af****0484'
Response parameters
|
Parameter |
Type |
Description |
Example value |
| - |
object |
|
|
| annotations |
array |
Annotation information. |
|
| - |
object |
|
|
| annotationLevel |
string |
The annotation level: notice, warning, or failure. |
notice |
| createdAt |
string |
The time when the annotation was created. |
2024-10-05T15:30:45Z |
| endColumn |
integer |
The ending column number. This field is valid only when startLine equals endLine. |
2 |
| endLine |
integer |
End of line. |
2 |
| id |
integer |
The annotation ID. It is unique. |
1 |
| message |
string |
A summary message. |
check run annotation message |
| path |
string |
The file path. |
src/test/main.java |
| rawDetails |
string |
Detailed information. Maximum size is 64 KB. |
check run annotation raw details text |
| startColumn |
integer |
The starting column number. This field is valid only when startLine equals endLine. |
1 |
| startLine |
integer |
The starting line number. You must verify that the line number is valid in the file. Otherwise, the annotation will not display. |
1 |
| title |
string |
You can check the title of the annotation. |
check run annotation title |
| updatedAt |
string |
Last updated: |
2024-10-05T15:30:45Z |
| checkSuite |
object |
Information about the check suite. |
|
| id |
integer |
A unique identifier. |
1 |
| completedAt |
string |
The time when the third-party check completed. |
2024-10-05T15:30:45Z |
| conclusion |
string |
Conclusion: cancelled — Canceled. failure — Failed. neutral — Neutral, treated as successful. success — Successful. skipped — Skipped, treated as successful. timed_out — Timed out. |
success |
| createdAt |
string |
The time when the write-back record was created. |
2024-10-05T15:30:45Z |
| detailsUrl |
string |
A link to the third-party interaction system. You define this URL. The platform only provides navigation. |
http://example.test |
| externalId |
string |
The external system ID. |
1 |
| headSha |
string |
The commit ID. |
6da8c14b5a9102998148b7ea35f96507d5304f74 |
| id |
integer |
A unique identifier. |
1 |
| name |
string |
The name of the check run. |
Test Check Run |
| output |
object |
Information shown on the page. |
|
| images |
array |
Images to show. Maximum three images. |
|
| - |
object |
|
|
| alt |
string |
The alt text for the image. |
Test |
| caption |
string |
A brief description of the image. |
alt caption |
| imageUrl |
string |
The image URL. Make sure it is accessible. Otherwise, the page cannot load the image. |
https://example/example/w/100/h/100 |
| summary |
string |
A summary in Markdown format. Maximum length is 64 KB (65,535 characters). |
check run summary |
| text |
string |
Detailed information in Markdown format. Maximum length is 64 KB (65,535 characters). |
check run markdown content text |
| title |
string |
The title. |
check run title |
| startedAt |
string |
The time when the third-party check started. |
2024-10-05T15:30:45Z |
| status |
string |
The status: queued, in_progress, or completed. |
completed |
| updatedAt |
string |
The time when the write-back record was last updated. |
2024-10-05T15:30:45Z |
| writer |
object |
Information about the writer. |
|
| id |
string |
The user ID. |
62c795xxxb468af8 |
| logoUrl |
string |
The profile picture URL. |
https://example/example/w/100/h/100 |
| name |
string |
The user name. |
codeup-name |
| slug |
string |
The username used to log on. |
codeup-username |
| type |
string |
The writer type: User or Bot. |
User |
Response example
{
"annotations": [
{
"annotationLevel": "notice",
"createdAt": "2024-10-05T15:30:45Z",
"endColumn": 2,
"endLine": 2,
"id": 1,
"message": "check run annotation message",
"path": "src/test/main.java",
"rawDetails": "check run annotation raw details text",
"startColumn": 1,
"startLine": 1,
"title": "check run annotation title",
"updatedAt": "2024-10-05T15:30:45Z"
}
],
"checkSuite": {
"id": 1
},
"completedAt": "2024-10-05T15:30:45Z",
"conclusion": "success",
"createdAt": "2024-10-05T15:30:45Z",
"detailsUrl": "http://example.test",
"externalId": "1",
"headSha": "6da8c14b5a9102998148b7ea35f96507d5304f74",
"id": 1,
"name": "Test Check Run",
"output": {
"images": [
{
"alt": "Test",
"caption": "alt caption",
"imageUrl": "https://example/example/w/100/h/100"
}
],
"summary": "check run summary",
"text": "check run markdown content text",
"title": "check run title"
},
"startedAt": "2024-10-05T15:30:45Z",
"status": "completed",
"updatedAt": "2024-10-05T15:30:45Z",
"writer": {
"id": "62c795xxxb468af8",
"logoUrl": "https://example/example/w/100/h/100",
"name": "codeup-name",
"slug": "codeup-username",
"type": "User"
}
}
Error codes
For error codes related to this API, see the Error Code Center.