1.0.13 • Published 12 months ago

chatbot-ui-authjs v1.0.13

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

Chatbot UI Next Auth Extension

This extension provides NextAuth SSO support to Chatbot UI.

Installation

Step 1

The extension comes pre-installed with the base version of Chatbot UI. However, if for any reason you need to re-install this extension, you can do so with npm:

npm i chatbot-ui-authjs@latest

Step 2

Turn on authentication for Chatbot UI by setting the following env variables.

Local Build

Set the following in .env.local.

NEXT_PUBLIC_AUTH_ENABLED=true

Docker Build

Set the following in .env.local and in docker.env:

NEXT_PUBLIC_AUTH_ENABLED=true
NEXTAUTH_URL_INTERNAL=http://chatbot:3000

Steps 3

Add the IDs and client secrets of the providers you want to enable in the env.local file. See below.

Configuration

When using this extension, the following environment variables can be set:

Environment VariableDefault valueDescription
NEXTAUTH_EMAIL_PATTERNThe email regex pattern granted access to chatbot-ui. For example .+@mydomain.com
NEXTAUTH_SECRETNextAuth Settings. See Documentation
NEXTAUTH_URLhttp://localhost:3000NextAuth Settings. See Documentation
NEXTAUTH_URL_INTERNAL(Optional) NextAuth Settings. See Documentation.
\<PROVIDER>_CLIENT_IDProvider OAuth Client ID
\<PROVIDER>_CLIENT_SECRETProvider OAuth Client Secret

Where \<PROVIDER> is one of the following:

  • APPLE
  • AUTH0
  • COGNITO
  • DISCORD
  • FACEBOOK
  • GITHUB
  • GITLAB
  • GOOGLE
  • OKTA
  • REDDIT
  • SALESFORCE
  • SLACK
  • SPOTIFY
  • TWITCH
  • TWITTER

For example, to enable Google and Github authentication, you would add the following to your .env.local file:

GITHUB_CLIENT_ID=xxxxxxxxxxxxx
GITHUB_CLIENT_SECRET=xxxxxxxxxxxxx
GOOGLE_CLIENT_ID=xxxxxxxxxxxxx
GOOGLE_CLIENT_SECRET=xxxxxxxxxxxx
1.0.13

12 months ago

1.0.12

12 months ago

1.0.11

12 months ago

1.0.10

12 months ago

1.0.9

12 months ago

1.0.8

12 months ago

1.0.7

12 months ago

1.0.6

12 months ago

1.0.5

12 months ago

1.0.4

12 months ago

1.0.3

12 months ago

1.0.2

12 months ago

1.0.1

12 months ago

1.0.0

12 months ago