0.0.25 • Published 7 months ago
@flaresocial/api v0.0.25
@flaresocial/api
Flare Social API wrapper for javascript.
Installation
npm install --save @flaresocial/api
# or
yarn add @flaresocial/api
# or
pnpm add @flaresocial/api
# or
bun add @flaresocial/apiUsage
// Import the module
import FlareApi from "@flaresocial/api";
// get your token by creating an app, when for calling the api as a user account
// you can get it by logging in or registering
const token = FlareApi.login("usernameOrEmail", "password" /* baseUrl: string */);
// or
const _token = FlareApi.register("username", "email", "password", "Display Name", /* baseUrl: string */); // Display Name is optional
// create a new FlareApi instance:
const flare = new FlareApi(() => token /* baseUrl: string */);
// get the user's profile
const me = await flare.users.getMe();
// get all users
const users = await flare.users.getAll();
// get a user by id
const user = await flare.users.getById(me.id); // or any other user idLicense
This project is licensed under the MIT License
0.0.25
7 months ago
0.0.24
8 months ago
0.0.23
8 months ago
0.0.22
8 months ago
0.0.21
8 months ago
0.0.20
8 months ago
0.0.19
8 months ago
0.0.18
8 months ago
0.0.17
8 months ago
0.0.16
8 months ago
0.0.15
8 months ago
0.0.14
8 months ago
0.0.13
8 months ago
0.0.12
8 months ago
0.0.10
8 months ago
0.0.9
8 months ago
0.0.8
8 months ago
0.0.7
8 months ago
0.0.6
8 months ago
0.0.5
8 months ago
0.0.4
8 months ago
0.0.3
8 months ago
0.0.2
8 months ago
0.0.1
8 months ago