1.2.1-x • Published 7 years ago

atbatjs v1.2.1-x

Weekly downloads
-
License
ISC
Repository
-
Last release
7 years ago

no longer working

Due to recent developments at the geeksquad.com website this tool (and others like it) are no longer working. If another source for this data is found in the future I will update it to restore functionality. Until then it is left here for historical purposes.

installation

npm install --save atbatjs

usage

const atbat = require('atbatjs')

// Get list of Agents who are online.
// Gets both green and orange agents, but not
// ones that are offline.
atbat.getFullAgentList( agents => {
	// agents is an array of objects with
	// name and status properties.
	console.log(agents[0].name)    // --> Agent CoolGuy Z.
	console.log(agents[0].status)    // --> Online
})

// Use the other functions to get more info
// about the Agents in the list.  You don't
// have to use them, they are just simple wrappers
// around some simple counting logic.

// Green/Orange counts
let details = atbat.agentListDetails(agentList)
console.log(details.green) // --> 20
console.log(details.orange) // --> 33

// Place in the lineup for a particular Agent
// Indexed from 1 being the first person on page 1.
// There are 12 agents per page.
let place = atbat.agentPlaceInList(agentList, "Agent CoolGuy Z."
console.log(place) // 12, returns 0 if not found.
1.2.1-x

7 years ago

1.2.0

7 years ago

1.1.1

7 years ago

1.1.0

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago