UpdatePipeline
This operation updates only YAML-based pipelines.
Try it now
Test
RAM authorization
Request syntax
POST /organization/{organizationId}/pipelines/update HTTP/1.1
Path Parameters
|
Parameter |
Type |
Required |
Description |
Example |
| organizationId |
string |
Yes |
The unique identifier of the organization. You can get this ID from the URL in Alibaba Cloud DevOps, for example, |
5ebbc0228123212b59xxxxx |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| name |
string |
Yes |
The name of the pipeline. |
示例流水线 |
| content |
string |
Yes |
The definition of the pipeline in YAML format. For more information about how to write the YAML content, see https://help.aliyun.com/document_detail/2249317.html. |
sources: # sources 配置流水线源节点
my_repo: # 流水线源唯一标识 id
type: codeup # 流水线源类型
name: 代码源名称 # 代码源的展示名称
endpoint: |
| pipelineId |
string |
Yes |
The ID of the pipeline. You can get this ID from the pipeline URL, for example, |
111xxx |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response body. |
||
| success |
boolean |
Indicates whether the request was successful. |
true |
| errorCode |
string |
The error code returned if the request fails. |
"" |
| errorMessage |
string |
The error message returned if the request fails. |
"" |
| requestId |
string |
The request ID. This ID is unique to each request and can be used for troubleshooting. |
ASSDS-ASSASX-XSAXSA-XSAXSAXS |
Examples
Success response
JSON format
{
"success": true,
"errorCode": "\"\"",
"errorMessage": "\"\"",
"requestId": "ASSDS-ASSASX-XSAXSA-XSAXSAXS"
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidParam.ParamNotPresent | The parameter is invalid. | The parameter is invalid. |
| 400 | InvalidUser.NotFound | The user that is invoking the API service is not a registered user. | The user that is invoking the API service is not a registered user. |
| 403 | Forbidden.AccessDenied | The user is not authorized to perform the operation. | The user is not authorized to perform the operation. |
| 403 | Forbidden.UserNotAdminOrOwner | The current user is not an admin or owner in the organization and is not authorized to perform the operation. | |
| 403 | Forbidden.UserNotInCurrentOrganization | The user is not in the organization and is not authorized to perform the operation. | |
| 404 | InvalidOrganization.NotFound | The organization is not found. | The organization is not found. Please check the organization ID. |
| 404 | InvalidPipeline.NotFound | The pipeline is not found. | The pipeline does not exist. |
| 404 | InvalidPipelineRun.NotFound | The pipeline execution instance is not found. | The pipeline execution instance is not found. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.