Teamcity start build with password parameter

Answered

Hi,

I want to start a build via Teamcity's REST API and pass in a environment parameter that contains a password.

But the environment parameter is not predefined in the build config. Is there a way to set the type of the "unknown" parameter to "password" via REST API so the password is not shown directly in the Teamcity UI?

I tried to pass <property xxx><type>password</type></property> but the "type" attribute seems to have no effect. I tried different things: pass into rawValue, etc...

Would be nice if this would be possbile

Version is: TeamCity Enterprise 2020.1

1 comment
Comment actions Permalink

Hi,

It looks like adding an undefined typed parameter with the REST build trigger isn't currently supported. You would need to first add the parameter, which is supported by REST API as described in the REST API Reference for Typed Parameter Specification. Once the typed parameter is defined in the build configuration, you can then include a custom value along with the REST build trigger and it will be masked in the build log and parameters listing of the build history.

After looking into this, I went ahead created a feature request for you here: https://youtrack.jetbrains.com/issue/TW-69741. Please take a moment to look at this feature request and vote/comment with any additional thoughts you have. By voting for the feature, you will be automatically notified of any updates to the feature request, and comments left on YouTrack go directly to our developers. We use our public YouTrack site to determine which features and enhancements are included in future releases, so any feedback you have is valuable to us.

0

Please sign in to leave a comment.