title: No such property: api for class: groovy.lang.Binding error
body: <p>Im trying to build a pipeline on Jenkins that runs a command on node and informs me of the following error:</p>
  <pre><code> groovy.lang.MissingPropertyException: No such property: api for class: groovy.lang.Binding
          at groovy.lang.Binding.getVariable(Binding.java:63)
          at org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.SandboxInterceptor.onGetProperty(SandboxInterceptor.java:270)
          at org.kohsuke.groovy.sandbox.impl.Checker$6.call(Checker.java:289)
          at org.kohsuke.groovy.sandbox.impl.Checker.checkedGetProperty(Checker.java:293)
          at com.cloudbees.groovy.cps.sandbox.SandboxInvoker.getProperty(SandboxInvoker.java:29)
          at com.cloudbees.groovy.cps.impl.PropertyAccessBlock.rawGet(PropertyAccessBlock.java:20)
  </code></pre>
  <p>i dont know the node command its an error command or its for another error
  this is de pipeline file:</p>
  <pre><code>def call() {
          pipeline { 
              agent any 
              
              parameters {
                  string(name: 'branch', defaultValue: 'refs/heads/develop', description: 'git branch where fetch sourcecode')
              }
              
              environment {
                  GIT_URL = getGitRepoURL()
                  GIT_CREDENTIALS = '*******'
              }
              
              tools {
                  nodejs &quot;node&quot;
              }
              
              triggers {
                  cron('H 06 * * 1-5')
              }
              
              stages {
                  stage ('Initialize'){
                      steps { 
                          echo 'initializing'
                          deleteDir()
                          bat '''
                              echo &quot;PATH = %PATH%&quot;
                              echo &quot;M2_HOME = %M2_HOME%&quot;
                          ''' 
                      }
                  }
      
                  stage ('Sourcecode'){
                      steps { 
                          echo 'fetching sourcecode from ' + env.GIT_URL
                          checkout([$class: 'GitSCM', branches: [[name: params.branch]], doGenerateSubmoduleConfigurations: false, extensions: [], submoduleCfg: [], userRemoteConfigs: [[credentialsId: env.GIT_CREDENTIALS, url: env.GIT_URL]]])            
                      }
                  }
                  
                  stage ('Execute raml2html'){
                      steps {
                          sh 'cd ..\HelpDevelopsAPI
                          node raml2html -s %WORKSPACE% -c %WORKSPACE%\..\apidef-aqj-commons -o /server/api --cat .*.html --schema /server/schema/%JOB_BASE_NAME% --mock /server/mock/%JOB_BASE_NAME%
                          cd %WORKSPACE%'
                      }
                  }
              }
          }
      }
          
      def getGitRepoURL() {
          String projectName = env.JOB_BASE_NAME
          print 'projectName '+projectName  +'\n'
          String[] projectParts = projectName.tokenize( '-' )
          String bian = projectParts[1]
          String name = projectParts[0]+'-'+projectParts[1]+'-'+projectParts[2]
          echo 'exampleurl'+bian+'/'+name+'.git'
          return 'exapleurl'+bian+'/'+name+'.git'
      }
  </code></pre>