Query: In CircleCi, how to select parameter values at run time(at the time of triggering the pipeline)
For instance, in Jenkins at the time of building the job, can select parameter values. Suppose I have choice parameter “Browser” with values “Chrome, Firefox, Edge, Safari”. At the time of building the job, using Build with Parameters option I can choose either chrome/Firefox/Edge/Safari.
Is CircleCI provides above mentioned feature/functionality(select parameter values at the time of triggering the pipeline)?
At the moment we don’t have this option via the UI – however, it can be accomplished by setting these parameters as “Pipeline Parameters” and then triggering the build via the API and passing the appropriate values.
We have details on accomplishing that in our pipeline parameters documentation.
If helpful, as an example like your screenshot, it would look like this:
Beyond the above we also have an existing feature request for implementing this via the UI, you can add your vote on that request and you will be notified automatically of any updates.
use case: currently we have couple of upstream projects(xyz, abc … etc.) and all these upstream projects trigger same downstream project to generate reports. Here instead of personal API token, Can i use project API token so that downstream project knows which upstream project(xyz/abc) trigger the build via the API?
Thanks for the reply and good question! Unfortunately though, the project-level API tokens cannot be utilized to generate a new pipeline. This is because we need to associate the pipeline with the actual ‘user’ who triggered it. Even if you end up creating a bot user to do these actions, they still need to be tied to a user instead of a project.
If you needed to verify which project triggered the downstream report you may be able to instead pass a variable or another parameter (especially if you are doing the API trigger upstream).