@spritz-finance/api-client 0.4.12 → 0.4.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -229,7 +229,11 @@ All users must undergo basic identity verification before they can engage with t
229
229
 
230
230
  ### How to Present Verification Flow to the User
231
231
 
232
- Here are some options on how you can present the `verificationUrl` to the user:
232
+ Spritz offers two methods for integrating KYC verification:
233
+
234
+ #### Method 1: Verification URL (Simple Integration)
235
+
236
+ Use the `verificationUrl` for a straightforward integration where Spritz handles the entire verification flow:
233
237
 
234
238
  - **Browser**: Open the URL in a new browser tab.
235
239
  - **In-App**: Embed the URL in an iframe within your application.
@@ -245,6 +249,29 @@ const verifiedCountry = userData.verifiedCountry
245
249
  const canRetryVerification = userData.canRetryVerification
246
250
  ```
247
251
 
252
+ #### Method 2: Verification Token (Advanced Integration)
253
+
254
+ For more control over the verification experience, use the verification token approach with the Plaid Link SDK:
255
+
256
+ ```typescript
257
+ // Get a verification token from Spritz
258
+ const verificationToken = await client.user.getVerificationToken()
259
+
260
+ // Use the token with Plaid Link SDK to create a custom verification flow
261
+ // This allows you to:
262
+ // - Customize the UI/UX of the verification process
263
+ // - Handle callbacks and events directly
264
+ // - Integrate verification seamlessly into your application flow
265
+ ```
266
+
267
+ The verification token method is ideal when you want to:
268
+ - Maintain full control over the user experience
269
+ - Integrate verification directly into your app without redirects
270
+ - Handle verification events and callbacks programmatically
271
+ - Build a native mobile experience using Plaid's mobile SDKs
272
+
273
+ See the [Plaid Link documentation](https://plaid.com/docs/link/) for detailed integration instructions with the verification token.
274
+
248
275
  ## Payment Flow
249
276
 
250
277
  ### Basic payment flow