Document creation of Secret File or Secret Text credentials (plain-credentials) plugin via API

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

XMLWordPrintable

      While reading https://github.com/jenkinsci/credentials-plugin/blob/master/docs/user.adoc#creating-a-credentials, I only found documentation of how to possibly create a username + password credentials, but no example of how to create a secret file or secret text credential.

      Googling around, I found

      https://www.linkedin.com/pulse/upload-jenkins-secret-file-credential-via-api-maksym-lushpenko/

      Well, the author also seemed quite frustrated while looking for a solution. But the help of that blog post, I - at least - am able to create a secret file credential.

      But updating it (using the path .../<my_credential_id>/update ) and passing it the same values does not work, although Jenkins is returning a 200 back.

       

      Please properly document, how to create and update a credential of type secret file ( org.jenkinsci.plugins.plaincredentials.impl.FileCredentialsImpl ) and secret text ( org.jenkinsci.plugins.plaincredentials.impl.StringCredentialsImpl ) via the API

       

      My attempts to resolve this via reverse engineering failed so far.

       

      Thanks

      pasche

            Assignee:
            Unassigned
            Reporter:
            Robert
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Archived: