Developer Reference
- Create an invite link by calling the Create Invite Link API.
- If
company_nameis not passed, company wont be created and so, your user will have to enter it in the SDK. - To enable only certain integrations, you can pass a list of
integrations. If only one integration is passed, user will be redirected to the platform login url directly.
- If
- The response will contain the
invite_link, which will need to be sent to the SDK during initialisation, and thecompany_id, which you should store to uniquely identify this customer.
Setup SDK
-
Import the source script in the head tag.
Default:
<script src="https://sdk.rootfi.dev/sdk.js"></script>KSA region:<script src="https://sdk.rootfi.dev/sdk.sa.js"></script> -
Load the RootFi SDK on page load by calling
RootfiLink.initialize().
JavaScript
- Call
RootfiLink.openLink();to open the SDK. Make sure you call this function onReady is called back on initialisation. - Call
RootfiLink.closeLink();to close the SDK. You can use this method to close the SDK in onSuccess and onExit Callback;