JSPM

  • Created
  • Published
  • Downloads 391
  • Score
    100M100P100Q96180F
  • License MIT

Entity Auth client SDK

Package Exports

  • @entityauth/auth-client

Readme

@entity/auth

TypeScript SDK for Entity Auth.

Install

pnpm add @entity/auth

Usage

import { EntityAuthClient } from '@entity/auth';

const ea = new EntityAuthClient({ baseURL: 'https://api.example.com' });
await ea.register({ email: 'a@b.com', password: 'secret', tenantId: 't1' });
const { accessToken } = await ea.login({ email: 'a@b.com', password: 'secret', tenantId: 't1', platform: 'web' });
await ea.refresh();