mytimestation-api

1.0.2 • Public • Published

mytimestation-api

API wrapper for mytimestation.com

Installation

npm install mytimestation-api --save

Usage

Settings

const settings = {
  utcOffset: -120,         // Timeskew from UTC (default -120)
  department: '0'          // Which department to punch in to (0 default, 1 for IT?)
  email: 'your@email.com', // Email
  password: 'password'     // Password
}

Punch in example

const Timestation = require('mytimestation-api')({
  email: 'your@email.com',
  password: 'password'
});
 
Timestation.login().then(() => {
  console.log('Successfully logged in');
 
  return Timestation.punchIn().then(() => {
    console.log('Successfully punched in');
  });
}).catch(err => {
  console.log('Punch in failed', err);
});

Readme

Keywords

none

Package Sidebar

Install

npm i mytimestation-api

Weekly Downloads

2

Version

1.0.2

License

MIT

Last publish

Collaborators

  • zappen999