how-many-people-are-bouldering
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

How many people are bouldering?

Programmatically find out how many people are in a bouldering gym

Usage

You need node.js and npm

Install with npm install how-many-people-are-bouldering

const Bouldering = require('how-many-people-are-bouldering')

// Bouldering.gyms is an Array of all supported gyms
// you can also find this data in gyms.json
const myFavoriteGym = Bouldering.gyms.find((gym) => gym.name === 'Berlin Magicmountain')

Bouldering.getOccupancy(myFavoriteGym).then((result) => console.log(result))

// Because Berlin Magicmount uses Boulderado's API (myFavoriteGym.api.type === 'boulderado')
// -> the result will be absolute
const exampleAbsoluteResult = {
  type: 'absolute',
  current: 69,
  max: 130,
}
const exampleRelativeResult = {
  type: 'relative',
  percentage: 15,
}

/how-many-people-are-bouldering/

    Package Sidebar

    Install

    npm i how-many-people-are-bouldering

    Weekly Downloads

    14

    Version

    1.0.0

    License

    CC0-1.0

    Unpacked Size

    21.1 kB

    Total Files

    12

    Last publish

    Collaborators

    • gggscript