Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-68292

unable to triggers jenkins job using postman with raw in body of JSON

    • Icon: Bug Bug
    • Resolution: Not A Defect
    • Icon: Major Major
    • other
    • None

      hi, thanks for update in JENKINS-68283.

      using POST method with url http://xxxx:8080/job/jobname/buildwithParameters?

       

      1)i need to choose to body --> raw (then chooose JSON)  and in body i need to give below

       

      {"keyname":"valueofkeyname"}

      ---> 

       

      2)we are not supposed to use body -> x-www-form-urlencoded and enter key and values .

      is point 1 not possible .?

       

      could you pls share curl command to do same

       

       

       

          [JENKINS-68292] unable to triggers jenkins job using postman with raw in body of JSON

          Kalle Niemitalo added a comment - - edited

          Thank you for referring to JENKINS-62823, as that makes it clearer what you are trying to do. I'll remove the jenkinslint-plugin component from this issue because you are asking about remotely triggering builds, not about anything related to the JenkinsLint plugin.

          The https://wiki.jenkins.io/display/JENKINS/Remote+access+API page includes two sample curl commands. Alternatively, you could try the Build Authorization Token Root plugin.

          Please note that, according to the Jira guidelines, you should post support requests to mailing lists or chat, not to Jira. You can also use the Ask a question category on the forum.

          Kalle Niemitalo added a comment - - edited Thank you for referring to JENKINS-62823 , as that makes it clearer what you are trying to do. I'll remove the jenkinslint-plugin component from this issue because you are asking about remotely triggering builds, not about anything related to the JenkinsLint plugin. The https://wiki.jenkins.io/display/JENKINS/Remote+access+API page includes two sample curl commands. Alternatively, you could try the Build Authorization Token Root plugin. Please note that, according to the Jira guidelines , you should post support requests to mailing lists or chat, not to Jira. You can also use the Ask a question category on the forum.

          Markus Winter added a comment -

           
          curl -X POST http://localhost:8080/job/paramtest/build --user user:pwd --data-urlencode json='{"parameter": [

          {"name":"MESSAGE", "value":"123"}

          ]}'

          Markus Winter added a comment -   curl -X POST http://localhost:8080/job/paramtest/build --user user:pwd --data-urlencode json='{"parameter": [ {"name":"MESSAGE", "value":"123"} ]}'

            v2v Victor Martinez
            divyap divya P
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: