npm.io
1.2.2 • Published 2 years ago

@brawltracker/brawl-api

Licence
MIT
Version
1.2.2
Deps
1
Size
16 kB
Vulns
0
Weekly
0
Stars
6

Simple API wrapper for Brawl API.

  • No classes, very simple to use
  • Written in TypeScript, with typings included
  • Uses ofetch for requests
  • Includes every API endpoint
  • ESM and CJS support
  • Unit tested

Installation

yarn add @brawltracker/brawl-api
# or
pnpm add @brawltracker/brawl-api
# or
npm install @brawltracker/brawl-api

Usage

import { brawlApi } from "@brawltracker/brawl-api";

const shelly = await brawlApi.brawlers.getBrawler(16000000);

or

import { brawlers } from "@brawltracker/brawl-api";

const shelly = await brawlers.getBrawler(16000000);

Documentation

You can find the documentation here. Everything is exported from the brawlApi object, or you can import the specific endpoint you want to use

Keywords