1.1.3 • Published 2 years ago

valorant-wrapper v1.1.3

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

valorant-wrapper

A wrapper for the third-party valorant-api

How to Use

All endpoints can be accessed off the ValAPI class.

import { ValAPI } from 'valorant-wrapper'; // TS
const { ValAPI } = require('valorant-wrapper'); // JS

This class is static, and thus does not need to be instantiated to access the endpoints. All individual endpoint classes under ValAPI can be imported. To retrieve data from a specific endpoint, specify the class to fetch from in within ValAPI. Within each class exists the available endpoints to call the API. All methods support an optional language and uuid parameter.

Examples

Get a list of all maps

await ValAPI.maps.get();
// Expected Return: Map Array

Get a list of all playable agents

await ValAPI.agents.get({ isPlayableCharacter: true });
// Expected Return: Playable Agent Array

Get a Weapon for a given Weapon UUID

await ValAPI.weapons.get({ uuid: 'WEAPON_UUID' });
// Expected Return: Weapon Object

Get a list of Weapon Skin Chromas

await ValAPI.weapons.getSkinChromas();
// Expected Return: Weapon Skin Chroma Array

Check when a given Event ends

(await ValAPI.get({ uuid: 'EVENT_UUID' })).endTime
// Expected Return: Date

Documentation

Full documentation for the available endpoints and their respective return types can be found on the Valorant API Docs. Type declarations have been included in this package.

1.1.3

2 years ago

1.1.2

2 years ago

1.1.1

2 years ago

1.1.0

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago