Starting a job using the API returns 302 instead of 201

This issue is archived. You can view it, but you can't modify it. Learn more

XMLWordPrintable

      Any time a job is started using the `/build` or `/buildWithParameters` URL (either via the job's page itself or via an API call), it always returns a `HTTP 302` response that redirects to the job's page, instead of the correct HTTP 201.

      This behavior contradicts the API documentation itself, which states:

      To programmatically schedule a new build, post to this URL (/build). If the build has parameters, post to this URL (/buildWithParameters) and provide the parameters as form data. Either way, the successful queueing will result in 201 status code with Location HTTP header pointing the URL of the item in the queue.

        1. 302.png
          67 kB
          Jevgeni Nazander

            Assignee:
            Unassigned
            Reporter:
            Jevgeni Nazander
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Archived: