inputsubmit with choice value in jenkins API
AnsweredHi
Can anyone knows how to give choice value while submitting input through API.
INPUT DEFINITION
PKGAPPROVAL = input id: ######', message: 'Package verification', ok: 'Release!', submitter: ZZZZ,
parameters: [choice(name: 'RELEASE_SCOPE', choices: 'NO\nYES', description: 'Promote Package')]
Im submitting like below
curl -X POST --user $USER:$TOKEN -H $JENKINS_CRUMB -d choices="YES" -d proceed=Release! -d json={} $JENKINS_URL/job/$PIPELINE_NAME/$BUILD_NUMBER/wfapi/inputSubmit?inputId=######
The problem is below:
It is always submitting with default choice value which is NO.
It suppose should be submit with YES.
Note : Default value should not change to YES. User need to change this value, So that the order was given as NO\nYES.
Can I get a solution for this?
-
Hi Jothi,
I believe this is answered in https://stackoverflow.com/a/50606237
1 -
Thanks Denys. Its working after tried the link you suggested.
0
Please sign in to leave a comment.
Comments
2 comments