I\'m a newbie in Jenkins. I followed this help to implement Jenkins, Github and Webhook.
However, I\'m stuck in this problem. I want to get the payload parameters in Je
Easier way of doing this, without an extra library for parsing JSON, would be using the Generic Webhook Trigger Plugin in Jenkins.
It can resolve any value from the JSON using JSONPath and assign it to variables available in the build.
There are few steps that you should follow:
Configure a web-hook in GitHub by which you will start communicating with Jenkins. This can be easily by going to your GitHub repository --> Setting --> Web-hooks.
Make the entry for content-type as application/x-www-form-encoded.
References: How to process a github webhook payload in Jenkins? https://developer.github.com/webhooks/#payloads