Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Programmatically add a second JenkinsBase to a stash webhook #208

Open
SDanS opened this issue Feb 26, 2018 · 0 comments
Open

Programmatically add a second JenkinsBase to a stash webhook #208

SDanS opened this issue Feb 26, 2018 · 0 comments

Comments

@SDanS
Copy link

SDanS commented Feb 26, 2018

We are currently able to programatically add a jenkins webhook to our bitbucket repos. However, we need to add a second jenkins instance to it. Long story short, the api endpoint we are hitting is like this:

https://my.bitbucket.server/rest/api/1.0/projects/someproject/repos/fake-project/settings/hooks/com.nerdwin15.stash-stash-webhook-jenkins:jenkinsPostReceiveHook/enabled

We're using the PUT method.

The data we're passing is like the following:

'{"jenkinsBase":"https://dans.com/","cloneType":"ssh","ignoreCerts":false}

If I add a second jenkinsBase to the data structure above like the following, it only accepts the second value:

'{"jenkinsBase":"https://dans.com/","cloneType":"ssh","ignoreCerts":false,"jenkinsBase":"https://dans1.com","cloneType":"ssh","ignoreCerts":false}'

What method and data structure should I use to add a second jenkinsBase to our webhook for a repo?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant