Queries information about an artifact build task.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | GetArtifactBuildTask |
The operation that you want to perform. Set the value to GetArtifactBuildTask. |
BuildTaskId | String | Yes | i2a-1yu**** |
The ID of the artifact build task. |
InstanceId | String | Yes | cri-shac42yvqzvq**** |
The ID of the Container Registry instance. |
RegionId | String | Yes | cn-hangzhou |
The ID of the region. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
ArtifactBuildType | String | IMAGE_TO_ACCELERATED_IMAGE |
The type of the artifact build task. Valid values:
|
BuildTaskId | String | i2a-1yu**** |
The ID of the artifact build task. |
Code | String | success |
The response code. |
EndTime | Integer | 156871880 |
The end time of the artifact build task. |
Instructions | List | null |
This parameter is left empty because it is a reserved parameter. |
IsSuccess | Boolean | true |
Indicates whether the operation is successful. |
RequestId | String | C4C7DD0C-C9D6-437A-A7EE-121EFD70D002 |
The ID of the request. |
SourceArtifact | Struct |
The information about the source artifact. |
|
ArtifactType | String | IMAGE |
The type of the artifact that is built in the task. The value can only be IMAGE. |
RepoId | String | cri-shac42yvqzvq**** |
The ID of the repository to which the source artifact belongs. The repository can only be an image repository. |
Version | String | latest |
The tag of the artifact. The artifact can only be an image. |
StartTime | Integer | 156871881 |
The start time of the artifact build task. |
TargetArtifact | Struct |
The artifact that is built in the task. |
|
ArtifactType | String | IMAGE |
The type of the artifact that is built in the task. The value can only be IMAGE. |
RepoId | String | crr-1234567 |
The ID of the repository to which the artifact that is built in the task belongs. The repository can only be an image repository. The value is the same as the ID of the repository to which the source artifact belongs. |
Version | String | latest_accelerated |
The tag of the artifact that is built in the task. The artifact can only be an image. |
TaskStatus | String | BUILDING |
The status of the artifact that is built in the task. Valid values:
|
Examples
Sample requests
http(s)://[Endpoint]/?Action=GetArtifactBuildTask
&BuildTaskId=i2a-1yu****
&InstanceId=cri-shac42yvqzvq****
&RegionId=cn-hangzhou
&<Common request parameters>
Sample success responses
XML
format
<TargetArtifact>
<Version>latest_accelerated</Version>
<ArtifactType>IMAGE</ArtifactType>
<RepoId>crr-1234567</RepoId>
</TargetArtifact>
<ArtifactBuildType>IMAGE_TO_ACCELERATED_IMAGE</ArtifactBuildType>
<IsSuccess>true</IsSuccess>
<EndTime>15687188001</EndTime>
<BuildTaskId>i2a-123456</BuildTaskId>
<RequestId>C4C7DD0C-C9D6-437A-A7EE-121EFD70D002</RequestId>
<StartTime>15687188001</StartTime>
<Instructions/>
<TaskStatus>BUILDING</TaskStatus>
<Code>success</Code>
<SourceArtifact>
<Version>latest</Version>
<ArtifactType>IMAGE</ArtifactType>
<RepoId>crr-1234567</RepoId>
</SourceArtifact>
JSON
format
{
"TargetArtifact": {
"Version": "latest_accelerated",
"ArtifactType": "IMAGE",
"RepoId": "crr-1234567"
},
"ArtifactBuildType": "IMAGE_TO_ACCELERATED_IMAGE",
"IsSuccess": true,
"EndTime": 15687188001,
"BuildTaskId": "i2a-123456",
"RequestId": "C4C7DD0C-C9D6-437A-A7EE-121EFD70D002",
"StartTime": 15687188001,
"Instructions": "",
"TaskStatus": "BUILDING",
"Code": "success",
"SourceArtifact": {
"Version": "latest",
"ArtifactType": "IMAGE",
"RepoId": "crr-1234567"
}
}
Error codes
For a list of error codes, visit the API Error Center.