0.1.11 • Published 9 months ago

@pangeacyber/vanilla-js v0.1.11

Weekly downloads
-
License
MIT
Repository
github
Last release
9 months ago

documentation Discourse

Pangea Vanilla Javascript Package

A javascript SDK for using Pangea Client APIs in the browser.

Client Classes

  • AuthNClient: Support for interacting with AuthN v2/client endpoints.
  • AuthNFlowClient: Support for interacting with AuthN v2/flow endpoints.

This package is provided with support for ESM and CommonJS.

Installation

yarn add @pangeacyber/vanilla-js
# or
npm install @pangeacyber/vanilla-js

Usage

AuthNClient

import { AuthConfig, AuthNFlowClient } from "@pangeacyber/vanilla-js";

const config: AuthConfig = {
  clientToken: PANGEA_CLIENT_TOKEN,
  domain: PANGEA_DOMAIN,
  callbackUri: CALLBACK_URI
};

const client = new AuthNClient(config);

# check if a user token is valid
const resp = await client.validate(USER_TOKEN);

AuthNFlowClient

import { AuthConfig, AuthNFlowClient } from "@pangeacyber/vanilla-js";

const config: AuthConfig = {
  clientToken: PANGEA_CLIENT_TOKEN,
  domain: PANGEA_DOMAIN,
  callbackUri: CALLBACK_URI
};

const client = new AuthNFlowClient(config);

# start a auth flow session
const resp = await client.start();
0.1.11

9 months ago

0.1.10

12 months ago

0.1.9

1 year ago

0.1.8

1 year ago

0.1.7

1 year ago

0.1.6

1 year ago

0.1.5

1 year ago

0.1.4

2 years ago

0.1.3

2 years ago

0.1.2

2 years ago

0.1.1

2 years ago

0.1.0

2 years ago

0.0.17

2 years ago

0.0.16

2 years ago

0.0.15

2 years ago

0.0.14

2 years ago

0.0.13

2 years ago

0.0.11

2 years ago

0.0.12

2 years ago

0.0.10

2 years ago

0.0.9

2 years ago

0.0.8

2 years ago

0.0.7

2 years ago

0.0.6

2 years ago

0.0.5

2 years ago

0.0.4

2 years ago

0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago