Pass webhook POST body to the trigger CI job
Problem to solve
At the moment you can trigger a pipeline in a different project or the same project based on webhooks. The only problem is that the body that get's posted on the trigger gets lost in the process and can't be retrieved from the CI job that get's triggered.
Intended users
Developer
Further details
A use-case for us would be:
On each project we could add a webhook on the merge request events. Within the Settings --> Integration we could add a URL to a different GitLab project, for example https://gitlab.example.com/api/v4/projects/9/ref/master/trigger/pipeline?token=TOKEN.
The trigger job on that project should have the body of the webhook passed into it. So within that job we could analyze the body from the webhook and based on some values to or maintaince tasks or other nice things.
Proposal
Pass the webhook body to the triggered job.
Permissions and Security
N/A
Documentation
N/A
Testing
N/A
What does success look like, and how can we measure that?
The webhook body should be passed to the trigger job