- Get the Text user’s email, account ID, or organization ID.
- Receive an
access_tokenfor API calls, using the implicit grant. - Receive a
codefor the authorization code grant with PKCE, which you then exchange foraccess_tokenandrefresh_token.
access_token (implicit grant) or a code you exchange for access_token and refresh_token (authorization code grant with PKCE).
Implementing Sign in with Text
Step 1: Create an OAuth client
Go to Settings → API access → OAuth clients and create a new OAuth client. Configure:- Display name — a name to identify your OAuth client.
- Redirect URI whitelist — the exact URL of the page where users click Sign in with Text. The button doesn’t work with any other URL.
- Access scopes — the scopes your app needs. See OAuth scopes for the full list.
Step 2: Install the SDK
NPM module installation
NPM module import
Step 3: Add the login button
access_token directly (the implicit grant):
Handle the login button click
response_type: "code" and PKCE enabled, then exchange the returned code yourself:
Handle the login button click, with PKCE
Accounts SDK
The Accounts SDK (@livechat/accounts-sdk) provides the classes and methods used in the Sign in with Text flow. For the full API reference — including AccountsSDK, Popup, Redirect, PKCE configuration, and response formats — see the Accounts SDK documentation.