Uploaded image for project: 'Bitbucket Cloud'
  1. Bitbucket Cloud
  2. BCLOUD-23359

Include custom pipeline variables in the pipeline API endpoint

XMLWordPrintable

    • Our product teams collect and evaluate feedback from a number of different sources. To learn more about how we use customer feedback in the planning process, check out our new feature policy.

      Problem Definition

      With custom pipelines, users can define variables whose value is provided at runtime. There is no API endpoint to retrieve the values of these variables.

      Suggested Solution

      Return a custom pipeline's variables and their values for a certain build in this API endpoint:

      https://developer.atlassian.com/cloud/bitbucket/rest/api-group-pipelines/#api-repositories-workspace-repo-slug-pipelines-pipeline-uuid-get

      Workaround

      If you want to retrieve this info via API, you can get the step's log with the following endpoint:

      https://developer.atlassian.com/cloud/bitbucket/rest/api-group-pipelines/#api-repositories-workspace-repo-slug-pipelines-pipeline-uuid-steps-step-uuid-log-get

      And then parse the log to get the values of the variables.

              Unassigned Unassigned
              tboudale Theodora Boudale (Inactive)
              Votes:
              9 Vote for this issue
              Watchers:
              10 Start watching this issue

                Created:
                Updated: