Class JenkinsAuthentication.Builder

    • Constructor Detail

      • Builder

        public Builder()
    • Method Detail

      • credentials

        public JenkinsAuthentication.Builder credentials​(String usernamePassword)
        Set 'UsernamePassword' credentials.
        Parameters:
        usernamePassword - value to use for 'UsernamePassword' credentials. It can be the username:password in clear text or its base64 encoded value.
        Returns:
        this Builder.
      • apiToken

        public JenkinsAuthentication.Builder apiToken​(String apiTokenCredentials)
        Set 'UsernameApiToken' credentials.
        Parameters:
        apiTokenCredentials - value to use for 'ApiToken' credentials. It can be the username:apiToken in clear text or its base64 encoded value.
        Returns:
        this Builder.
      • build

        public JenkinsAuthentication build()
        Build and instance of JenkinsCredentials.
        Returns:
        instance of JenkinsCredentials.