How to pass input parameters to Github actions

in Jenkins or Gitlab, to trigger any job or project we can pass parameters like string, integer, bool, choice etc how it can be achieved with github actions yaml file.

Hi @chaitanya-bojja-by,

Glad to see you in Github Community Forum!

In Github action, the workflow is triggered when your operation meets the events which defined in your yaml file. Hence, only when the events supports input, you can transfer the parameters.

You can check the event rest api for confirmation(link here).

For example, if you use repository_dispatch event in workflow yaml, confirmed in rest api, it supports inputs.
You can use two workflow yaml:
1st workflow yaml to send the event with the parameter you want to transfer(the var in data body).
2nd workflow get the var value.

Besides, github actions supports to manually trigger a workflow now, you can set the input in this case, please refer to doc here for more details.

Hope it’s clear and helpful!