Help
cancel
Showing results for 
Search instead for 
Did you mean: 
Pilot Lvl 1
Message 1 of 3

How to trigger repository_dispatch event for non-default branch?

The Github Actions documentation mentions the `repository_dispatch` event in the External Events section. The table in this sections says that the `GITHUB_REF` points to the "Branch that received dispatch". My question now is: How can I specify the branch when sending the `repository_dispatch` event? The API documentation does not mention any branch related input argument.

 

Thanks!

 

2 Replies
Community Manager
Message 2 of 3

Re: How to trigger repository_dispatch event for non-default branch?

Hi @phil-opp,

 

Thank you for being here! I wish I had better news for you, the `repository_dispatch` only triggers on the master branch, and it is not possible to specify a branch. We have received several pieces of feedback about this limitation and have an internal issue tracking a feature request, to which I've added your feedback. 


Best,
AndreaG

Mark helpful posts with Accept as Solution to help other users locate important info. Don't forget to give Kudos for great content!

Pilot Lvl 1
Message 3 of 3

Re: How to trigger repository_dispatch event for non-default branch?

Thanks for clarifying! Perhaps the documentation at https://help.github.com/en/actions/automating-your-workflow-with-github-actions/events-that-trigger-... should be updated to reflect this (the `GITHUB_REF` column says "Branch that received dispatch" instead of "default branch").