Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

rocketleague.js

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rocketleague.js

Wrapper for rocket league stats.

  • 1.4.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
14
increased by180%
Maintainers
1
Weekly downloads
 
Created
Source

RocketLeague.js

CodeFactor NPM-Version NPM-Downloads Github Stars Issues

This a wrapper/scrapper of the TRNetwork site with Rocket League stats.

There are no dependencies nor API key required.

To install use:

npm i rocketleague.js

Example code: (Feel free to use my steam username for testing)

const { API, PLATFORM } = require('rocketleague.js')

try {
    const user = await API.fetchUser(PLATFORM.Epic, 'iFraan')
    /* Platform can be Steam, Epic, Playstation or Xbox */
    
    console.log('User:', user.getUserinfo())
    /*
    User: {
        platform: 'epic',
        uuid: 'fc0c61fe-8e96-48db-be12-80af22912376',
        name: 'iFraan',
        userid: 'iFraan',
        avatar: null
    }
    */

    console.log('Overview:', user.overview())
    /*
    Overview: {
        wins: 153,
        goals: 268,
        mVPs: 22,
        saves: 128,
        assists: 141,
        shots: 512,
        goalShotRatio: 52.34375,
        score: 29507.94,
        seasonRewardLevel: 0,
        seasonRewardWins: 0,
        tRNRating: 0
    }
    */

    console.log('2v2: ', user.get2v2())
    /*
    2v2: {
        rank: 'Gold I',
        tier: 7,
        division: 2,
        matchesPlayed: 0,
        winStreak: 2,
        rating: 511,
        peakRating: null
    }
    */
    console.log('3v3: ', user.get3v3())
    /*
    3v3: {
        rank: 'Gold I',
        tier: 7,
        division: 2,
        matchesPlayed: 0,
        winStreak: 5,
        rating: 505,
        peakRating: null
    }
    */
    console.log('ALL: ', user.getData())
    /* 
    ALL {
        overview: {
            wins: 153,
            goals: 268,
            mVPs: 22,
            saves: 128,
            assists: 141,
            shots: 512,
            goalShotRatio: 52.34375,
            score: 29507.94,
            seasonRewardLevel: 0,
            seasonRewardWins: 0,
            tRNRating: 0
        },
        gamemodes: {
            'Ranked Duel 1v1': {
                rank: 'Gold II',
                tier: 8,
                division: 1,
                matchesPlayed: 0,
                winStreak: 2,
                rating: 534,
                peakRating: null
            },
            'Ranked Doubles 2v2': {
                rank: 'Gold I',
                tier: 7,
                division: 2,
                matchesPlayed: 0,
                winStreak: 2,
                rating: 511,
                peakRating: null
            },
            'Ranked Standard 3v3': {
                rank: 'Gold I',
                tier: 7,
                division: 2,
                matchesPlayed: 0,
                winStreak: 5,
                rating: 505,
                peakRating: null
            },
            Hoops: {
                rank: 'Gold I',
                tier: 7,
                division: 2,
                matchesPlayed: 0,
                winStreak: 1,
                rating: 507,
                peakRating: null
            },
            Rumble: {
                rank: 'Gold I',
                tier: 7,
                division: 3,
                matchesPlayed: 0,
                winStreak: 1,
                rating: 505,
                peakRating: null
            },
            Dropshot: {
                rank: 'Platinum I',
                tier: 10,
                division: 3,
                matchesPlayed: 0,
                winStreak: 3,
                rating: 641,
                peakRating: null
            },
            'Un-Ranked': {
                rank: 'Unranked',
                tier: 0,
                division: 0,
                matchesPlayed: 0,
                winStreak: 0,
                rating: 411,
                peakRating: null
            }
        }
    }
    */
} catch (e) {
    console.log(e)
    /* Error: We could not find the player [player]. */
}

Disclaimer

This project is fully for educational purposes and if you want to use the rocketleague api in a production/commertial enviroment you should ask for one at Rocket League Support or email the guys at TRNetwork.

Keywords

FAQs

Package last updated on 02 May 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc