Add the Strata SDK to your frontend application
Settings
in the sidebar. Click Generate New Keypair
to get a new signing key. Save the private key somewhere secure. You will not be able to see it again.
sub
, iat
, exp
.
external_id
claim. If provided, it will be used as the user / company identifier and takes precedence over the sub
claim.
Here is a sample implementation with a Next.js API endpoint:
strata.authorize
with a signed user jwt. The function call returns a Promise
that resolves when the user successfully completes the auth flow. It fails with an error if the authorization fails or the user closes the window without authorizing your app.