Unfurl-Connect Docs
  • Overview
  • Guides
    • Quickstart
    • Easy Integration
      • Browser Only
      • Client Server
      • Cloud Services
        • Google Cloud Platform
        • Amazon Web Services
      • Mobile
        • Android
        • iOS
    • Branding
    • Self-hosting the IdP
    • Advanced Configuration
  • Extras
    • Roadmap
    • Projects
Powered by GitBook
On this page

Was this helpful?

  1. Guides
  2. Easy Integration

Browser Only

PreviousEasy IntegrationNextClient Server

Last updated 3 years ago

Was this helpful?

Often authentication and authorization are done between client and server. Here we look at ways clients can use Unfurl that do not require the client appincation to have (or simply not use) a server.

Javascript

This popular library for writting oidc clients in javascript only requires basic configuration and a few lines of code -- like so.

import Oidc from 'oidc-client';

const mgr = new Oidc.UserManager({
  authority: 'https://auth.unfurl-connect.com',
  client_id: 'YOUR_CLIENT_ID',
  redirect_uri: 'ONE_OF_YOUR_REDIRECT_URIs',
  response_type: 'code',
  scope: 'openid roles',
  loadUserInfo: true
});
/* Then sign-in like so: */
mgr.signinRedirect({useReplaceToNavigate:true});

However, a full example can be found .

oidc-client.js
here