node package manager
Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »


Hess Load Account Homepage

Navigate to the account homepage on the the Hess Energy website


npm install -S hess-load-account-homepage


Login with a given username and password. THen call the load account homepage module. If the account homepage is loaded correctly, the module will return a cheerio object of the account homepage html

var performLogin = require('hess-login')
var loadAccountHomepage = require('hess-load-account-homepage')
var username = 'fooUsername'
var password = 'fooPassword'
var currentLogin = {
  username: username,
  password: password
performLogin(currentLogin, function (err, reply) {
  if (err) {
    inspect(err, 'error performing login')
  loadAccountHomepage(jar, function (err, $) {
    if (err) {
      inspect(err, 'error loading account homepage')
    // $ is a cheerio object of the loaded account homepage. 
    inspect('account homepage loaded correctly')


# install development dependencies
npm install
# run tests
npm test