@valapi/auth
TypeScript icon, indicating that this package has built-in type declarations

4.0.0 • Public • Published

Valorant API - Authentication

Profile

Valorant Authentication

Downloads install size Known Vulnerabilities

LICENSE Github Discord


  • @valapi/auth isn't endorsed by Riot Games and doesn't reflect the views or opinions of Riot Games or anyone officially involved in producing or managing Riot Games properties. Riot Games, and all associated properties are trademarks or registered trademarks of Riot Games, Inc.
  • @valapi/auth was created under Riot Games' "Legal Jibber Jabber" policy using assets owned by Riot Games. Riot Games does not endorse or sponsor this project.
  • MIT License

Installation

NPM:

npm install @valapi/auth

PNPM:

pnpm add @valapi/auth

Guide

Full Guide: valapi.github.io

import { AuthClient } from "@valapi/auth";

Client

const authClient = new AuthClient();

Auth

await authClient.login("BestUsername", "SuperSecretPassword");

Subject (PlayerUUID)

const subject = authClient.getSubject();

Cookie

const authClient = await AuthClient.fromCookie(cookie);

Save

const authClient = AuthClient.fromJSON(oldAuthClient.toJSON());

if (Date.now() >= client.getExpirationDate()) {
    await authClient.refresh();
}

/@valapi/auth/

    Package Sidebar

    Install

    npm i @valapi/auth

    Weekly Downloads

    5

    Version

    4.0.0

    License

    MIT

    Unpacked Size

    41.5 kB

    Total Files

    18

    Last publish

    Collaborators

    • ing3kth