-
Notifications
You must be signed in to change notification settings - Fork 13
docs: Document EU region support and callback URL requirement for JS SDK #116
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,5 @@ | ||
| ## 0.1.0 | ||
|
|
||
| * Added EU region support documentation for JS SDK - use `https://eu.portal.reclaimprotocol.org` as `customSharePageUrl` to automatically route API requests to the EU backend | ||
| * **JS SDK**: When using a regional portal (any `customSharePageUrl` other than `share.reclaimprotocol.org` or `portal.reclaimprotocol.org`), you must now set a callback URL using `setAppCallbackUrl()`. The SDK throws a `CallbackUrlRequiredError` if missing. | ||
| * Added log event type documentation for inapp sdk and inapp react native sdk |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -259,6 +259,27 @@ const proofRequest = await ReclaimProofRequest.init(APP_ID, APP_SECRET, PROVIDER | |
| }); | ||
| ``` | ||
|
|
||
| ## EU Region Support | ||
|
|
||
| To keep data within EU infrastructure, use the EU portal URL: | ||
|
|
||
| ```js | ||
| proofRequestOptions = { | ||
| ..., //other options, if any | ||
| useAppClip: false, | ||
| customSharePageUrl: 'https://eu.portal.reclaimprotocol.org' | ||
| } | ||
| const proofRequest = await ReclaimProofRequest.init(appId, appSecret, providerId, proofRequestOptions); | ||
|
|
||
| // Required: set a callback URL when using regional portals | ||
| proofRequest.setAppCallbackUrl('https://yourbackend.com/reclaim-callback'); | ||
| ``` | ||
|
|
||
| Setting `customSharePageUrl` to the EU portal automatically routes API requests to `https://eu.api.reclaimprotocol.org`. No additional backend configuration needed. | ||
|
|
||
| > [!IMPORTANT] | ||
| > When using a regional portal (any `customSharePageUrl` other than `share.reclaimprotocol.org` or `portal.reclaimprotocol.org`), you must set a callback URL using `setAppCallbackUrl()`. The SDK throws a `CallbackUrlRequiredError` if you don't. | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Citation: Added callback URL requirement based on validation in |
||
|
|
||
| ## Using the in-browser SDK | ||
| <Callout type="warning"> | ||
| In-Browser SDK use is available only for users on a premium enterprise plan. Please [contact support](https://t.me/protocolreclaim) for more details. | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Citation: Based on changes in
src/Reclaim.tsthat add automatic EU backend detection whencustomSharePageUrlcontainseu.portal.reclaimprotocol.org. The SDK sets the backend base URL tohttps://eu.api.reclaimprotocol.orgautomatically.View source