You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
Next: Root
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
The Atlassian Community can help you and your team get more value out of Atlassian products and practices.
I'm running custom pipelines that take variables, and I'd like to be able to retrieve the {key: val} pairs for the variables when fetching a pipeline from the API.
I can see that there's endpoints for repository, workspace and environment variables, but I need the key-value pairs specified when the pipeline is launched.
I've looked through the pipeline response from
GET /2.0/repositories/{workspace}/{repo_slug}/pipelines/{pipeline_uuid}
and step response from
GET /2.0/repositories/{workspace}/{repo_slug}/pipelines/{pipeline_uuid}/steps/{step_uuid}
and they don't seem to be included. Pipeline response does have a 'has_variables' boolean, but I'm not sure if this refers to the custom pipeline variables or other types.
Just want to know if this is possible, as I can work around it otherwise.
Cheers!
I'm afraid that this is not possible with the pipeline or step endpoint.
The values of these variables are visible in the Pipelines log, in the "Build setup", which can be retrieved with the endpoint
GET /2.0/repositories/{workspace}/{repo_slug}/pipelines/{pipeline_uuid}/steps/{step_uuid}/log
You would then need to parse the log to get the value of each variable.
Kind regards,
Theodora
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You are very welcome, please feel free to reach out if you ever need anything else!
Kind regards,
Theodora
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.