1.0.1 • Published 2 years ago

monkeytypesdk v1.0.1

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

Type-safe, Well tested SDK for Monkeytype.com

Report Bug | Request Feature

Issues License

Table Of Contents

Prerequisites

This is an example of how to list things you need to use the software and how to install them.

  • NodeJS 16 and newer versions

    Installation

  1. Get a free API Key at APE Key section

  2. Install the package via NPM

    npm install monkeytypesdk

    or Yarn

    yarn add monkeytypesdk

    Usage

    const  MonkeyTypeSDK = require('monkeytypesdk').default;
    const  SDK = new  MonkeyTypeSDK({
      apiKey:  'Your API Key',
    });
    
    /* 
      There are 3 categories of functions:
      1. Users
        1.1. users.personalBests
        1.2. users.stats
      2. Leaderboards
        2.1. leaderboards.get
        2.2. leaderboards.getUsersRank
      3. Results
        3.1. results.getLastResult
    */
    
    // For example, to get the personal bests of the current user:
    SDK.users.personalBests({
          mode: 'time',
          mode2: '60'
        }).then(res => {
      console.log(res);
    }).catch(err => {
      console.log(err);
    });

    Contributing

    Contributions are what makes the open source community such a fantastic place to learn, inspire, and create. Any contributions you make are greatly appreciated.

  • If you have suggestions for adding or removing projects, feel free to open an issue to discuss it, or directly create a pull request after you edit the README.md file with necessary changes.
  • Please make sure you check your spelling and grammar.
  • Create individual PR for each suggestion.

    Creating A Pull Request

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

    License

    Distributed under the MIT License. See LICENSE for more information.

    Authors

1.0.1

2 years ago

1.0.0

2 years ago