@basiq/connect-auth v1.1.7
Basiq Connect Component
The Basiq Connect Auth is a ReactJS UI component exposed to partners who prefer to implement the auth flow as an external component with an SMS OTP built in. When rendered, it will take the user through an SMS OTP flow and then proceed to redirect them to the Basiq Consent UI flow to connect their accounts.
Note: This has been offered as an interim solution for partners who require access to v3 of the API before we have released the upgrades to https://connect.basiq.io/
. If you have any questions regarding this, please reach out to support@basiq.io.
Setup
Install
@basiq/connect-auth
and import the component$ npm install @basiq/connect-auth
import { BasiqConnect } from "@basiq/connect-auth";
Generate a new Auth Link, and retrieve the auth link ID from the public URL that is returned.
try { const { data } = await axios.get( `https://au-api.basiq.io/users/{userId}/auth_link`, { method: 'post', headers: { Authorization: `Bearer ${YOUR_SERVER_ACCESS_TOKEN}`, Accept: 'application/json', 'Content-Type': 'application/json', }, } ); let auth_id = data.links.public.replace('https://connect.basiq.io/',''); return auth_id; } catch (error) { console.log(error) }
Drop the component in your code on the page you wish to call it. The component will retrieve the
auth_id
from the URL, so failing to include it there will result in an error. Note that the component is full page and will eventually handle the redirect to the Basiq Consent UI, so it should be rendered on its own page (or conditionally, after appending anauth_link
ID).// Component rendered at /auth-link/:auth_id export default function Auth() { return ( <main> <BasiqConnect /> </main> ); }
Updates
OTP Code Length Increased: The OTP code length has been increased from 4 to 6 characters to enhance security.
Demo
You can see a demo of the Basiq Connect Auth component here.
9 months ago
9 months ago
9 months ago
9 months ago
11 months ago
11 months ago
11 months ago
11 months ago
12 months ago
12 months ago
1 year ago
1 year ago
1 year ago
1 year ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago