Create Tekton pipeline
POST /tekton_pipelines
This request creates a Tekton pipeline. Requires a pipeline tool already created in the toolchain using the toolchain API https://cloud.ibm.com/apidocs/toolchain#create-tool, and use the tool ID to create the Tekton pipeline
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.create
Request
Request Body
TektonPipelinePrototype
next_build_number
integer
Specify the build number that will be used for the next pipeline run. Build numbers can be any positive whole number between 0 and 100000000000000.
enable_notifications
boolean
Flag to enable notifications for this pipeline. If enabled, the Tekton pipeline run events will be published to all the destinations specified by the Slack and Event Notifications integrations in the parent toolchain.
enable_partial_cloning
boolean
Flag to enable partial cloning for this pipeline. When partial clone is enabled, only the files contained within the paths specified in definition repositories are read and cloned, this means that symbolic links might not work
id
Required *
object
Universally Unique Identifier
worker
WorkerIdentity
Specify the worker that is to be used to run the trigger, indicated by a worker object with only the worker ID. If not specified or set as `worker: { id: 'public' }`, the IBM Managed shared workers are used.
id
Required *
string
ID of the worker
Response
201 - Tekton pipeline data
name
string
String
status
string
Pipeline status
resource_group
ResourceGroupReference
The resource group in which the pipeline was created
toolchain
ToolchainReference
Toolchain object containing references to the parent toolchain
id
string
Universally Unique Identifier
definitions
array
Definition list
properties
array
Tekton pipeline's environment properties
updated_at
string
Standard RFC 3339 Date Time String
created_at
string
Standard RFC 3339 Date Time String
triggers
array
Tekton pipeline triggers list
worker
Worker
Details of the worker used to run the pipeline
runs_url
string
URL for this pipeline showing the list of pipeline runs
href
object
General href URL
build_number
integer
The latest pipeline run build number. If this property is absent, the pipeline hasn't had any pipeline runs
next_build_number
integer
The build number that will be used for the next pipeline run
enable_notifications
boolean
Flag to enable notifications for this pipeline. If enabled, the Tekton pipeline run events will be published to all the destinations specified by the Slack and Event Notifications integrations in the parent toolchain. If omitted, this feature is disabled by default
enable_partial_cloning
boolean
Flag to enable partial cloning for this pipeline. When partial clone is enabled, only the files contained within the paths specified in definition repositories are read and cloned, this means that symbolic links might not work. If omitted, this feature is disabled by default
enabled
boolean
Flag to check if the trigger is enabled
400 - Malformed request syntax or invalid request body
errors
array
Array of errors
trace
string
Unique error identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Get Tekton pipeline data
GET /tekton_pipelines/{id}
This request retrieves the Tekton pipeline data for the pipeline identified by `{id}`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.read
Request
Response
200 - Tekton pipeline data
name
string
String
status
string
Pipeline status
resource_group
ResourceGroupReference
The resource group in which the pipeline was created
toolchain
ToolchainReference
Toolchain object containing references to the parent toolchain
id
string
Universally Unique Identifier
definitions
array
Definition list
properties
array
Tekton pipeline's environment properties
updated_at
string
Standard RFC 3339 Date Time String
created_at
string
Standard RFC 3339 Date Time String
triggers
array
Tekton pipeline triggers list
worker
Worker
Details of the worker used to run the pipeline
runs_url
string
URL for this pipeline showing the list of pipeline runs
href
object
General href URL
build_number
integer
The latest pipeline run build number. If this property is absent, the pipeline hasn't had any pipeline runs
next_build_number
integer
The build number that will be used for the next pipeline run
enable_notifications
boolean
Flag to enable notifications for this pipeline. If enabled, the Tekton pipeline run events will be published to all the destinations specified by the Slack and Event Notifications integrations in the parent toolchain. If omitted, this feature is disabled by default
enable_partial_cloning
boolean
Flag to enable partial cloning for this pipeline. When partial clone is enabled, only the files contained within the paths specified in definition repositories are read and cloned, this means that symbolic links might not work. If omitted, this feature is disabled by default
enabled
boolean
Flag to check if the trigger is enabled
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Update Tekton pipeline data
PATCH /tekton_pipelines/{id}
This request updates Tekton pipeline data, such as the worker ID or build number, for example. Use other endpoints such as /definitions, /triggers, and /properties for other configuration updates
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Request Body
Response
200 - Tekton pipeline data
name
string
String
status
string
Pipeline status
resource_group
ResourceGroupReference
The resource group in which the pipeline was created
toolchain
ToolchainReference
Toolchain object containing references to the parent toolchain
id
string
Universally Unique Identifier
definitions
array
Definition list
properties
array
Tekton pipeline's environment properties
updated_at
string
Standard RFC 3339 Date Time String
created_at
string
Standard RFC 3339 Date Time String
triggers
array
Tekton pipeline triggers list
worker
Worker
Details of the worker used to run the pipeline
runs_url
string
URL for this pipeline showing the list of pipeline runs
href
object
General href URL
build_number
integer
The latest pipeline run build number. If this property is absent, the pipeline hasn't had any pipeline runs
next_build_number
integer
The build number that will be used for the next pipeline run
enable_notifications
boolean
Flag to enable notifications for this pipeline. If enabled, the Tekton pipeline run events will be published to all the destinations specified by the Slack and Event Notifications integrations in the parent toolchain. If omitted, this feature is disabled by default
enable_partial_cloning
boolean
Flag to enable partial cloning for this pipeline. When partial clone is enabled, only the files contained within the paths specified in definition repositories are read and cloned, this means that symbolic links might not work. If omitted, this feature is disabled by default
enabled
boolean
Flag to check if the trigger is enabled
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Delete a Tekton pipeline instance
DELETE /tekton_pipelines/{id}
This request deletes the Tekton pipeline instance that is associated with the pipeline toolchain integration
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.delete
Request
Response
204 - Tekton pipeline instance deleted
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
List pipeline run records
GET /tekton_pipelines/{pipeline_id}/pipeline_runs
This request lists pipeline run records, which have data about the runs, such as status, user_info, trigger and other information. Default limit is 50
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline-run.read
Request
Path Parameters
Query Parameters
start
string
A page token that identifies the start point of the list of pipeline runs. This value is included in the response body of each request to fetch pipeline runs
limit
integer
The number of pipeline runs to return, sorted by creation time, most recent first
status
Filters the collection to resources with the specified status
trigger.name
Filters the collection to resources with the specified trigger name
Response
200 - List of pipeline runs
pipeline_runs
array
Tekton pipeline runs list
limit
integer
The number of pipeline runs to return, sorted by creation time, most recent first
first
RunsFirstPage
First page of pipeline runs
next
RunsNextPage
Next page of pipeline runs relative to the `start` and `limit` params. Only included when there are more pages available
last
RunsLastPage
Last page of pipeline runs relative to the `start` and `limit` params. Only included when the last page has been reached
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline run not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Trigger a pipeline run
POST /tekton_pipelines/{pipeline_id}/pipeline_runs
Trigger a new pipeline run using either the manual or the timed trigger, specifying the additional properties or overriding existing ones as needed
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.pipeline-run.create
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline-run.create
Request
Request Body
PipelineRunPrototype
description
string
Optional description for the created PipelineRun
trigger_name
string
Trigger name
trigger_properties
TriggerProperties
An object containing string values only. It provides additional 'text' properties or overrides existing pipeline/trigger properties that can be used in the created run
secure_trigger_properties
SecureTriggerProperties
An object containing string values only. It provides additional `secure` properties or overrides existing `secure` pipeline/trigger properties that can be used in the created run
trigger_headers
TriggerHeaders
An object containing string values only that provides the request headers. Use `$(header.header_key_name)` to access it in a TriggerBinding. Most commonly used as part of a Generic Webhook to provide a verification token or signature in the request headers
trigger_body
TriggerBody
An object that provides the request body. Use `$(body.body_key_name)` to access it in a TriggerBinding. Most commonly used to pass in additional properties or override properties for the pipeline run that is created
trigger
PipelineRunTrigger
Trigger details passed when triggering a Tekton pipeline run
name
Required *
string
Trigger name
properties
object
An object containing string values only. It provides additional 'text' properties or overrides existing pipeline/trigger properties that can be used in the created run
secure_properties
object
An object containing string values only. It provides additional `secure` properties or overrides existing `secure` pipeline/trigger properties that can be used in the created run
headers
object
An object containing string values only that provides the request headers. Use `$(header.header_key_name)` to access it in a TriggerBinding. Most commonly used as part of a Generic Webhook to provide a verification token or signature in the request headers
body
object
An object that provides the request body. Use `$(body.body_key_name)` to access it in a TriggerBinding. Most commonly used to pass in additional properties or override properties for the pipeline run that is created
Response
201 - Pipeline run result and its status
id
string
Universally Unique Identifier
href
string
General href URL
user_info
UserInfo
Information about the user that triggered a pipeline run. Only included for pipeline runs that were manually triggered
status
string
Status of the pipeline run
definition_id
string
The aggregated definition ID
definition
RunDefinition
Reference to the pipeline definition of a pipeline run
description
string
Optional description for the created PipelineRun
worker
PipelineRunWorker
Worker details used in this pipeline run
pipeline_id
object
Universally Unique Identifier
pipeline
RunPipeline
Reference to the pipeline to which a pipeline run belongs
listener_name
string
Listener name used to start the run
trigger
Trigger
Tekton pipeline trigger
event_params_blob
string
Event parameters object in String format that was passed in upon creation of this pipeline run, the contents depends on the type of trigger. For example, the Git event payload is included for Git triggers, or in the case of a manual trigger the override and added properties are included
trigger_headers
string
Trigger headers object in String format that was passed in upon creation of this pipeline run. Omitted if no trigger_headers object was provided when creating the pipeline run
properties
array
Properties used in this Tekton pipeline run. Not included when fetching the list of pipeline runs
created_at
string
Standard RFC 3339 Date Time String
updated_at
object
Standard RFC 3339 Date Time String
run_url
string
URL for the details page of this pipeline run
error_message
string
Error message that provides details when a pipeline run encounters an error
400 - Malformed request syntax or invalid request body
errors
array
Array of errors
trace
string
Unique error identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline run not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Get a pipeline run record
GET /tekton_pipelines/{pipeline_id}/pipeline_runs/{id}
This request retrieves details of the pipeline run identified by `{id}`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline-run.read
Request
Path Parameters
Query Parameters
includes
Defines if response includes definition metadata
Response
200 - Pipeline run detail
id
string
Universally Unique Identifier
href
string
General href URL
user_info
UserInfo
Information about the user that triggered a pipeline run. Only included for pipeline runs that were manually triggered
status
string
Status of the pipeline run
definition_id
string
The aggregated definition ID
definition
RunDefinition
Reference to the pipeline definition of a pipeline run
description
string
Optional description for the created PipelineRun
worker
PipelineRunWorker
Worker details used in this pipeline run
pipeline_id
object
Universally Unique Identifier
pipeline
RunPipeline
Reference to the pipeline to which a pipeline run belongs
listener_name
string
Listener name used to start the run
trigger
Trigger
Tekton pipeline trigger
event_params_blob
string
Event parameters object in String format that was passed in upon creation of this pipeline run, the contents depends on the type of trigger. For example, the Git event payload is included for Git triggers, or in the case of a manual trigger the override and added properties are included
trigger_headers
string
Trigger headers object in String format that was passed in upon creation of this pipeline run. Omitted if no trigger_headers object was provided when creating the pipeline run
properties
array
Properties used in this Tekton pipeline run. Not included when fetching the list of pipeline runs
created_at
string
Standard RFC 3339 Date Time String
updated_at
object
Standard RFC 3339 Date Time String
run_url
string
URL for the details page of this pipeline run
error_message
string
Error message that provides details when a pipeline run encounters an error
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline run not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Delete a pipeline run record
DELETE /tekton_pipelines/{pipeline_id}/pipeline_runs/{id}
This request deletes the pipeline run record identified by `{id}`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline-run.delete
Request
Response
204 - Pipeline run deleted
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline run not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Cancel a pipeline run
POST /tekton_pipelines/{pipeline_id}/pipeline_runs/{id}/cancel
This request cancels a running pipeline run identified by `{id}`. Use `force: true` in the body if the pipeline run can't be cancelled normally
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline-run.update
Request
Request Body
CancelBody
force
boolean
Flag indicating whether the pipeline cancellation action is forced or not
Path Parameters
pipeline_id
Required *
The Tekton pipeline ID
id
Required *
ID of current instance
Query Parameters
Response
202 - Pipeline run detail
id
string
Universally Unique Identifier
href
string
General href URL
user_info
UserInfo
Information about the user that triggered a pipeline run. Only included for pipeline runs that were manually triggered
status
string
Status of the pipeline run
definition_id
string
The aggregated definition ID
definition
RunDefinition
Reference to the pipeline definition of a pipeline run
description
string
Optional description for the created PipelineRun
worker
PipelineRunWorker
Worker details used in this pipeline run
pipeline_id
object
Universally Unique Identifier
pipeline
RunPipeline
Reference to the pipeline to which a pipeline run belongs
listener_name
string
Listener name used to start the run
trigger
Trigger
Tekton pipeline trigger
event_params_blob
string
Event parameters object in String format that was passed in upon creation of this pipeline run, the contents depends on the type of trigger. For example, the Git event payload is included for Git triggers, or in the case of a manual trigger the override and added properties are included
trigger_headers
string
Trigger headers object in String format that was passed in upon creation of this pipeline run. Omitted if no trigger_headers object was provided when creating the pipeline run
properties
array
Properties used in this Tekton pipeline run. Not included when fetching the list of pipeline runs
created_at
string
Standard RFC 3339 Date Time String
updated_at
object
Standard RFC 3339 Date Time String
run_url
string
URL for the details page of this pipeline run
error_message
string
Error message that provides details when a pipeline run encounters an error
400 - Malformed request syntax or invalid request body
errors
array
Array of errors
trace
string
Unique error identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline run not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Rerun a pipeline run
POST /tekton_pipelines/{pipeline_id}/pipeline_runs/{id}/rerun
This request reruns a past pipeline run, which is identified by `{id}`, with the same data. Request body isn't allowed
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.pipeline-run.create
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline-run.update
Request
Path Parameters
pipeline_id
Required *
The Tekton pipeline ID
id
Required *
ID of current instance
Query Parameters
Response
201 - Pipeline run detail
id
string
Universally Unique Identifier
href
string
General href URL
user_info
UserInfo
Information about the user that triggered a pipeline run. Only included for pipeline runs that were manually triggered
status
string
Status of the pipeline run
definition_id
string
The aggregated definition ID
definition
RunDefinition
Reference to the pipeline definition of a pipeline run
description
string
Optional description for the created PipelineRun
worker
PipelineRunWorker
Worker details used in this pipeline run
pipeline_id
object
Universally Unique Identifier
pipeline
RunPipeline
Reference to the pipeline to which a pipeline run belongs
listener_name
string
Listener name used to start the run
trigger
Trigger
Tekton pipeline trigger
event_params_blob
string
Event parameters object in String format that was passed in upon creation of this pipeline run, the contents depends on the type of trigger. For example, the Git event payload is included for Git triggers, or in the case of a manual trigger the override and added properties are included
trigger_headers
string
Trigger headers object in String format that was passed in upon creation of this pipeline run. Omitted if no trigger_headers object was provided when creating the pipeline run
properties
array
Properties used in this Tekton pipeline run. Not included when fetching the list of pipeline runs
created_at
string
Standard RFC 3339 Date Time String
updated_at
object
Standard RFC 3339 Date Time String
run_url
string
URL for the details page of this pipeline run
error_message
string
Error message that provides details when a pipeline run encounters an error
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline run not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Get a list of pipeline run log objects
GET /tekton_pipelines/{pipeline_id}/pipeline_runs/{id}/logs
This request fetches a list of log data for a pipeline run identified by `{id}`. The `href` in each log entry can be used to fetch that individual log
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline-run.read
Request
Path Parameters
pipeline_id
Required *
The Tekton pipeline ID
id
Required *
ID of current instance
Query Parameters
Response
200 - List of pipeline run log objects
logs
array
The list of pipeline run log objects
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline run not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Get the log content of a pipeline run step
GET /tekton_pipelines/{pipeline_id}/pipeline_runs/{pipeline_run_id}/logs/{id}
This request retrieves the log content of a pipeline run step, where the step is identified by `{id}`. To get the log ID use the endpoint `/tekton_pipelines/{pipeline_id}/pipeline_runs/{id}/logs`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline-run.read
Request
Path Parameters
pipeline_id
Required *
The Tekton pipeline ID
pipeline_run_id
Required *
The Tekton pipeline run ID
id
Required *
ID of current instance
Query Parameters
Response
200 - Log content of a step
data
string
The raw log content of the step. Only included when fetching an individual log object
id
object
Universally Unique Identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline run logs not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
List pipeline definitions
GET /tekton_pipelines/{pipeline_id}/definitions
This request fetches pipeline definitions, which is a collection of individual definition entries. Each entry consists of a repository url, a repository path and a branch or tag. The referenced repository URL must match the URL of a repository tool integration in the parent toolchain. Obtain the list of integrations from the toolchain API https://cloud.ibm.com/apidocs/toolchain#list-tools. The branch or tag of the definition must match against a corresponding branch or tag in the chosen repository, and the path must match a subfolder in the repository
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.read
Request
Response
200 - List of pipeline definitions
definitions
array
The list of all definitions in the pipeline
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Create a single definition
POST /tekton_pipelines/{pipeline_id}/definitions
This request adds a single definition. The source properties should consist of a repository url, a repository path and a branch or tag. The referenced repository URL must match the URL of a repository tool integration in the parent toolchain. Obtain the list of integrations from the toolchain API https://cloud.ibm.com/apidocs/toolchain#list-tools. The branch or tag of the definition must match against a corresponding branch or tag in the chosen repository, and the path must match a subfolder in the repository
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Request Body
DefinitionPrototype
source
Required *
DefinitionSource
Source repository containing the Tekton pipeline definition
type
Required *
string
The only supported source type is "git", indicating that the source is a git repository
properties
Required *
DefinitionSourceProperties
Properties of the source, which define the URL of the repository and a branch or tag
Response
201 - The added definition
source
DefinitionSource
Source repository containing the Tekton pipeline definition
href
object
General href URL
id
string
The aggregated definition ID
400 - Malformed request syntax or invalid request body
errors
array
Array of errors
trace
string
Unique error identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Retrieve a single definition entry
GET /tekton_pipelines/{pipeline_id}/definitions/{definition_id}
This request fetches a single definition entry, which consists of the definition repository URL, a repository path, and a branch or tag
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.read
Request
Response
200 - The requested definition entry
source
DefinitionSource
Source repository containing the Tekton pipeline definition
href
object
General href URL
id
string
The aggregated definition ID
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Definition not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Edit a single definition entry
PUT /tekton_pipelines/{pipeline_id}/definitions/{definition_id}
This request updates a definition entry identified by `{definition_id}`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Request Body
DefinitionPrototype
source
Required *
DefinitionSource
Source repository containing the Tekton pipeline definition
type
Required *
string
The only supported source type is "git", indicating that the source is a git repository
properties
Required *
DefinitionSourceProperties
Properties of the source, which define the URL of the repository and a branch or tag
Response
200 - Updated definition metadata
source
DefinitionSource
Source repository containing the Tekton pipeline definition
href
object
General href URL
id
string
The aggregated definition ID
400 - Malformed request syntax or invalid request body
errors
array
Array of errors
trace
string
Unique error identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Definition not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Delete a single definition entry
DELETE /tekton_pipelines/{pipeline_id}/definitions/{definition_id}
This request deletes a single definition from the definition list
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Response
204 - Definition deleted
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Definition not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
List the pipeline's environment properties
GET /tekton_pipelines/{pipeline_id}/properties
This request lists the environment properties of the pipeline identified by `{pipeline_id}`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.read
Request
Path Parameters
Query Parameters
name
Filters the collection to resources with the specified property name
type
array
Filters the collection to resources with the specified property type
sort
Sorts the returned properties by name, in ascending order using `name` or in descending order using `-name`
Response
200 - List of pipeline's environment properties
properties
array
Pipeline properties list
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Create a pipeline environment property
POST /tekton_pipelines/{pipeline_id}/properties
This request creates an environment property
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Request Body
PropertyPrototype
name
Required *
string
Property name
value
string
Property value. Any string value is valid
enum
array
Options for `single_select` property type. Only needed when using `single_select` property type
type
Required *
string
Property type
locked
boolean
When true, this property cannot be overridden by a trigger property or at runtime. Attempting to override it will result in run requests being rejected. The default is false.
path
string
A dot notation path for `integration` type properties only, to select a value from the tool integration. If left blank the full tool integration data will be used
Response
201 - Environment property added
name
string
Property name
value
string
Property value. Any string value is valid
href
object
General href URL
enum
array
Options for `single_select` property type. Only needed when using `single_select` property type
type
string
Property type
locked
boolean
When true, this property cannot be overridden by a trigger property or at runtime. Attempting to override it will result in run requests being rejected. The default is false.
path
string
A dot notation path for `integration` type properties only, that selects a value from the tool integration. If left blank the full tool integration data will be used
400 - Malformed request syntax or invalid request body
errors
array
Array of errors
trace
string
Unique error identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Get a pipeline environment property
GET /tekton_pipelines/{pipeline_id}/properties/{property_name}
This request gets the data of an environment property identified by `{property_name}`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.read
Request
Response
200 - Single property
name
string
Property name
value
string
Property value. Any string value is valid
href
object
General href URL
enum
array
Options for `single_select` property type. Only needed when using `single_select` property type
type
string
Property type
locked
boolean
When true, this property cannot be overridden by a trigger property or at runtime. Attempting to override it will result in run requests being rejected. The default is false.
path
string
A dot notation path for `integration` type properties only, that selects a value from the tool integration. If left blank the full tool integration data will be used
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline property not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Replace the value of an environment property
PUT /tekton_pipelines/{pipeline_id}/properties/{property_name}
This request updates the value of an environment property identified by `{property_name}`, its type and name are immutable
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Request Body
PropertyPrototype
name
Required *
string
Property name
value
string
Property value. Any string value is valid
enum
array
Options for `single_select` property type. Only needed when using `single_select` property type
type
Required *
string
Property type
locked
boolean
When true, this property cannot be overridden by a trigger property or at runtime. Attempting to override it will result in run requests being rejected. The default is false.
path
string
A dot notation path for `integration` type properties only, to select a value from the tool integration. If left blank the full tool integration data will be used
Response
200 - Replaced pipeline property
name
string
Property name
value
string
Property value. Any string value is valid
href
object
General href URL
enum
array
Options for `single_select` property type. Only needed when using `single_select` property type
type
string
Property type
locked
boolean
When true, this property cannot be overridden by a trigger property or at runtime. Attempting to override it will result in run requests being rejected. The default is false.
path
string
A dot notation path for `integration` type properties only, that selects a value from the tool integration. If left blank the full tool integration data will be used
400 - Malformed request syntax or invalid request body
errors
array
Array of errors
trace
string
Unique error identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline property not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Delete a single pipeline environment property
DELETE /tekton_pipelines/{pipeline_id}/properties/{property_name}
This request deletes a single pipeline environment property
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Response
204 - Property deleted
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline property not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
List pipeline triggers
GET /tekton_pipelines/{pipeline_id}/triggers
This request lists pipeline triggers for the pipeline identified by `{pipeline_id}`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.read
Request
Path Parameters
Query Parameters
type
Optional filter by "type", accepts a comma separated list of types. Valid types are "manual", "scm", "generic", and "timer"
name
Optional filter by "name", accepts a single string value
event_listener
Optional filter by "event_listener", accepts a single string value
worker.id
Optional filter by "worker.id", accepts a single string value
worker.name
Optional filter by "worker.name", accepts a single string value
disabled
Optional filter by "disabled" state, possible values are "true" or "false"
tags
Optional filter by "tags", accepts a comma separated list of tags. The response lists triggers having at least one matching tag
Response
200 - List of triggers for the pipeline identified by `{pipeline_id}`
triggers
array
Tekton pipeline triggers list
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Create a trigger
POST /tekton_pipelines/{pipeline_id}/triggers
This request creates a trigger
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Request Body
TriggerPrototype
type
Required *
string
Trigger type
name
Required *
string
Trigger name
event_listener
Required *
string
Event listener name. The name of the event listener to which the trigger is associated. The event listeners are defined in the definition repositories of the Tekton pipeline
tags
array
Trigger tags array
worker
object
Specify the worker that is to be used to run the trigger, indicated by a worker object with only the worker ID. If not specified or set as `worker: { id: 'public' }`, the IBM Managed shared workers are used.
id
Required *
string
ID of the worker
max_concurrent_runs
integer
Defines the maximum number of concurrent runs for this trigger. If omitted then the concurrency limit is disabled for this trigger
limit_waiting_runs
boolean
Flag that will limit the trigger to a maximum of one waiting run. A newly triggered run will cause any other waiting run(s) to be automatically cancelled
enabled
boolean
Flag to check if the trigger is enabled. If omitted the trigger is enabled by default
secret
GenericSecret
Only needed for Generic Webhook trigger type. The secret is used to start the Generic Webhook trigger
type
string
Secret type
value
string
Secret value, not needed if secret type is `internal_validation`
source
string
Secret location, not needed if secret type is `internal_validation`
key_name
string
Secret name, not needed if type is `internal_validation`
algorithm
string
Algorithm used for `digest_matches` secret type. Only needed for `digest_matches` secret type
cron
string
Only needed for timer triggers. CRON expression that indicates when this trigger will activate. Maximum frequency is every 5 minutes. The string is based on UNIX crontab syntax: minute, hour, day of month, month, day of week. Example: The CRON expression 0 */2 * * * - translates to - every 2 hours
timezone
object
Timezone string value. Valid timezones are those listed in the IANA timezone database, https://www.iana.org/time-zones
source
TriggerSourcePrototype
Source repository for a Git trigger. Only required for Git triggers. The referenced repository URL must match the URL of a repository tool integration in the parent toolchain. Obtain the list of integrations from the toolchain API https://cloud.ibm.com/apidocs/toolchain#list-tools
type
Required *
string
The only supported source type is "git", indicating that the source is a git repository
properties
Required *
TriggerSourcePropertiesPrototype
Properties of the source, which define the URL of the repository and a branch or pattern
events
Events
Either 'events' or 'filter' is required specifically for Git triggers. Stores a list of events that a Git trigger listens to. Choose one or more from 'push', 'pull_request', and 'pull_request_closed'. If SCM repositories use the 'merge request' term, they correspond to the generic term i.e. 'pull request'
filter
string
Either 'events' or 'filter' can be used. Stores the CEL (Common Expression Language) expression value which is used for event filtering against the Git webhook payloads
favorite
boolean
Mark the trigger as a favorite
enable_events_from_forks
boolean
Only used for SCM triggers. When enabled, pull request events from forks of the selected repository will trigger a pipeline run
disable_draft_events
boolean
Prevent new pipeline runs from being triggered by events from draft pull requests
Response
201 - The created trigger
400 - Malformed request syntax or invalid request body
errors
array
Array of errors
trace
string
Unique error identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Pipeline not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Get a single trigger
GET /tekton_pipelines/{pipeline_id}/triggers/{trigger_id}
This request retrieves a single trigger identified by `{trigger_id}`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.read
Request
Response
200 - the trigger requested
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Trigger not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Edit a trigger
PATCH /tekton_pipelines/{pipeline_id}/triggers/{trigger_id}
This request changes a single field or many fields of the trigger identified by `{trigger_id}`. Note that some fields are immutable, and use `/properties` endpoint to update trigger properties
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Request Body
Response
200 - The updated trigger
400 - Malformed request syntax or invalid request body
errors
array
Array of errors
trace
string
Unique error identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Trigger not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Delete a single trigger
DELETE /tekton_pipelines/{pipeline_id}/triggers/{trigger_id}
This request deletes the trigger identified by `{trigger_id}`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Response
204 - The trigger was deleted
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Trigger not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Duplicate a trigger
POST /tekton_pipelines/{pipeline_id}/triggers/{source_trigger_id}/duplicate
This request duplicates a trigger from an existing trigger identified by `{source_trigger_id}`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Request Body
DuplicateTrigger
name
Required *
string
Trigger name
Response
201 - The created trigger, which is based on duplicating the source trigger's configuration except that some fields are updated to ensure uniqueness
400 - Malformed request syntax or invalid request body
errors
array
Array of errors
trace
string
Unique error identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Trigger not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
List trigger properties
GET /tekton_pipelines/{pipeline_id}/triggers/{trigger_id}/properties
This request lists trigger properties for the trigger identified by `{trigger_id}`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.read
Request
Path Parameters
Query Parameters
name
Filter properties by `name`
type
Filter properties by `type`. Valid types are `secure`, `text`, `integration`, `single_select`, `appconfig`
sort
Sort properties by name. They can be sorted in ascending order using `name` or in descending order using `-name`
Response
200 - List of trigger properties
properties
array
Trigger properties list
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Trigger not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Create a trigger property
POST /tekton_pipelines/{pipeline_id}/triggers/{trigger_id}/properties
This request creates a property in the trigger identified by `{trigger_id}`
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Request Body
TriggerPropertyPrototype
name
Required *
string
Property name
value
string
Property value. Any string value is valid
enum
array
Options for `single_select` property type. Only needed for `single_select` property type
type
Required *
string
Property type
path
string
A dot notation path for `integration` type properties only, to select a value from the tool integration. If left blank the full tool integration data will be used
locked
boolean
When true, this property cannot be overridden at runtime. Attempting to override it will result in run requests being rejected. The default is false.
Response
201 - Trigger property added
name
string
Property name
value
string
Property value. Any string value is valid
href
object
General href URL
enum
array
Options for `single_select` property type. Only needed for `single_select` property type
type
string
Property type
path
string
A dot notation path for `integration` type properties only, that selects a value from the tool integration. If left blank the full tool integration data will be used
locked
boolean
When true, this property cannot be overridden at runtime. Attempting to override it will result in run requests being rejected. The default is false.
400 - Malformed request syntax or invalid request body
errors
array
Array of errors
trace
string
Unique error identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Trigger not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Get a trigger property
GET /tekton_pipelines/{pipeline_id}/triggers/{trigger_id}/properties/{property_name}
This request retrieves a trigger property
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.retrieve
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.read
Request
Response
200 - Trigger property
name
string
Property name
value
string
Property value. Any string value is valid
href
object
General href URL
enum
array
Options for `single_select` property type. Only needed for `single_select` property type
type
string
Property type
path
string
A dot notation path for `integration` type properties only, that selects a value from the tool integration. If left blank the full tool integration data will be used
locked
boolean
When true, this property cannot be overridden at runtime. Attempting to override it will result in run requests being rejected. The default is false.
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Trigger not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Replace a trigger property value
PUT /tekton_pipelines/{pipeline_id}/triggers/{trigger_id}/properties/{property_name}
This request updates a trigger property value, type and name are immutable
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Request Body
TriggerPropertyPrototype
name
Required *
string
Property name
value
string
Property value. Any string value is valid
enum
array
Options for `single_select` property type. Only needed for `single_select` property type
type
Required *
string
Property type
path
string
A dot notation path for `integration` type properties only, to select a value from the tool integration. If left blank the full tool integration data will be used
locked
boolean
When true, this property cannot be overridden at runtime. Attempting to override it will result in run requests being rejected. The default is false.
Response
200 - Edited trigger property
name
string
Property name
value
string
Property value. Any string value is valid
href
object
General href URL
enum
array
Options for `single_select` property type. Only needed for `single_select` property type
type
string
Property type
path
string
A dot notation path for `integration` type properties only, that selects a value from the tool integration. If left blank the full tool integration data will be used
locked
boolean
When true, this property cannot be overridden at runtime. Attempting to override it will result in run requests being rejected. The default is false.
400 - Malformed request syntax or invalid request body
errors
array
Array of errors
trace
string
Unique error identifier
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Trigger not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier
429 -
Delete a trigger property
DELETE /tekton_pipelines/{pipeline_id}/triggers/{trigger_id}/properties/{property_name}
This request deletes a trigger property
Authorization
To call this method, you must be assigned one or more IAM access roles that include the following action.
toolchain.instance.update
Auditing
Calling this method generates the following auditing event.
toolchain.pipeline.update
Request
Response
204 - Property deleted
401 - Authentication error or the IAM bearer token is missing
errors
array
Array of errors
trace
string
Unique error identifier
404 - Trigger not found or authorization failed
errors
array
Array of errors
trace
string
Unique error identifier