SukiAuthManager from the @suki-sdk/core package. You give it the partnerId and partnerToken Suki assigned to your app. You create this helper once, then pass it to FormFillingClient in JavaScript or to FormFillingProvider in React.
After sign-in works, Suki can show the Form filling experience (the hosted UI where clinicians speak and submit) inside your page. The helper also renews access when it expires. If the ID or token is wrong, or sign-in never finishes, Form filling will not open.
Prerequisites
Before you set upSukiAuthManager, you must have:
- Partner ID (the
partnerIdvalue): Suki gives you this when you complete Partner onboarding. - Partner Token (the
partnerTokenvalue): The access value your program uses for this SDK. Your Suki contact explains how you get it and what it looks like.
Using SukiAuthManager for authentication
Create the helper when your app already knowspartnerId and partnerToken by running the following code:
JavaScript
What SukiAuthManager does
- Checks your settings before Form filling tries to open.
- Signs in to Suki’s platform with your partner details.
- Renews access when the SDK needs a fresh session.
- Lets Suki’s hosted Form filling UI run with the right permissions.
autoRegister defaults to true. When it is true, you must also pass providerName and providerOrgId. Set autoRegister to false unless your integration uses provider auto-registration.Sign in later with login()
You can createSukiAuthManager first and call login() when your app is ready, instead of loginOnInitialize: true.
Next steps
Refer to the Quickstart to createFormFillingClient with your auth manager.