title: Define credential parameter in parameters in Jenkins declarative pipeline?
body: <p>I Currently using Jenkins Delarative pipeline with a parameterised build</p>
  
  <pre><code>pipeline {
      agent any
      parameters {
          booleanParam(name: 'cleanDB',defaultValue: false,description: 'should clean db ?' )
          string(name: 'host',defaultValue: 'xyx',description: 'DB Host')
      }
      stages {
          stage('Build') {
              steps {
                  sh 'mvn verify'
              }
          }
          stage('Execute') {
              steps {
                  withCredentials([[$class: 'UsernamePasswordMultiBinding', credentialsId: 'CREDENTIALS', usernameVariable: 'USERNAME', passwordVariable: 'PASSWORD']])
                          {
                              sh "ant " +"-Ddb.clean=${params.cleanDB} -Ddb.host=${params.host} -Ddb.userid=$USERNAME \"-Ddb.password=$PASSWORD\" "
                          }
              }
          }
      }
  }
  </code></pre>
  
  <p>when i try to build with parameters it prompts only two param cleanDB,host params.i would like it to also ask which credential parameter to take.it takes only when explicitly added though UI in parameterised build.</p>
  
  <p>so how can i add credential parameter in parameters can any one share an example of defining it in below syntax.</p>
  
  <pre><code>parameters {
          booleanParam(name: 'cleanDB',defaultValue: false,description: 'should clean db ?' )
          string(name: 'host',defaultValue: 'xyx',description: 'DB Host')
  credentialParam(name: 'host',description: 'Credentials')
      }
  </code></pre>