nl_tokens: login
pl_tokens: function ( ) { function onLoginResponse ( res ) { if ( res . statusCode === 302 && res . headers [ 'location' ] . indexOf ( 'login.do' ) === - 1 ) { console . log ( 'login success' ) ; } else { throw new Error ( 'Login error' ) ; } } request . post ( process . env . ONEAPM_LOGIN_URL ) . form ( { encode : true , username : process . env . ONEAPM_USERNAME , strong : true , password : base64 ( <mask> . env . ONEAPM_PASSWORD ) , } ) . on ( 'response' , onLoginResponse ) ; }