Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
madhavanmalolan seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
|
Caution Review failedThe pull request is closed. 📝 WalkthroughWalkthroughRestructures documentation: updates JS SDK initialization flow (adds proofRequestOptions, callbacks, redirect handling), adds troubleshooting "anatomy" doc, adjusts troubleshooting pages/metadata, removes some redirect/callback sections from generating-proof, and small text/front-matter edits across troubleshooting docs. Changes
Sequence Diagram(s)sequenceDiagram
participant Client as Client (Browser)
participant Backend as Backend (ReclaimProofRequest.init)
participant Provider as Verification Provider
participant Callback as App Callback URL
rect rgba(200,200,255,0.5)
Client->>Backend: Request proof init (APP_ID, APP_SECRET, PROVIDER_ID, proofRequestOptions)
Backend->>Provider: Create proof request (includes options, params, redirect URLs)
Provider-->>Backend: Proof generated / cancelled (async)
Backend->>Callback: POST success or cancel payload (includes proof / exception metadata)
Backend->>Client: Redirect to success or cancel URL (if set)
end
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested labels
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 4
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
content/docs/js-sdk/preparing-request.mdx (1)
40-59:⚠️ Potential issue | 🟠 MajorFix the sample: options are undeclared and currently ignored.
The snippet assigns to
proofRequestOptionswithout a declaration (throws in strict mode) and initializes twice, so the options never affect the JSON you return.🔧 Suggested fix
- proofRequestOptions = { + const proofRequestOptions = { ..., //other options, if any useAppClip: false, customSharePageUrl: 'https://portal.reclaimprotocol.org' } - const proofRequest = await ReclaimProofRequest.init( - process.env.RECLAIM_APP_ID, - process.env.RECLAIM_APP_SECRET, - providerId, - proofRequestOptions); - - // Initialize SDK with server-side environment variables (secure) - const reclaimProofRequest = await ReclaimProofRequest.init( - process.env.RECLAIM_APP_ID, - process.env.RECLAIM_APP_SECRET, - providerId, - ); + // Initialize SDK with server-side environment variables (secure) + const reclaimProofRequest = await ReclaimProofRequest.init( + process.env.RECLAIM_APP_ID, + process.env.RECLAIM_APP_SECRET, + providerId, + proofRequestOptions, + );
🤖 Fix all issues with AI agents
In `@content/docs/js-sdk/preparing-request.mdx`:
- Line 172: Replace the typo "snipped" with "snippet" in the sentence that reads
"You can disable by removing this configuration from the above snipped :" so it
becomes "You can disable by removing this configuration from the above snippet
:"; update the text in the preparing-request.mdx content where that sentence
appears.
- Around line 94-101: Update the broken analytics-event link in the "Error
Callback URL" section of preparing-request.mdx: replace the href that points to
/troubleshooting/analytics-event#description-of-reclaim_exception-in-metadata
with /troubleshooting/anatomy#description-of-reclaim_exception-in-metadata so
the text around reclaimProofRequest.setErrorCallbackUrl(...) points to the new
anatomy anchor; confirm the anchor name matches the target heading in the
anatomy doc and update the link string accordingly.
- Around line 117-120: The example JavaScript call to
reclaimProofRequest.setCancelRedirectUrl has a missing closing quote on the
string literal; update the example so the URL string is properly terminated (add
the missing closing double-quote before the closing parenthesis) in the
reclaimProofRequest.setCancelRedirectUrl(...) invocation.
In `@content/docs/troubleshooting/anatomy.mdx`:
- Around line 100-103: The "Cancelation" section currently contains a TODO
placeholder; replace that placeholder in the "Cancelation" heading block with a
complete description of the cancel callback payload (fields, types, example
usage and any edge cases) or remove the entire "Cancelation" section until
ready; update the section under the "# Cancelation" heading to include the
cancel callback payload schema and a short example of how to handle the callback
so readers can understand what to expect from the cancel callback payload.
| In-Browser SDK use is available only for users on a premium enterprise plan. Please [contact support](https://t.me/protocolreclaim) for more details. | ||
| </Callout> | ||
|
|
||
| If you don't want to use the in-browser SDK, the users will be asked to install the Reclaim Protocol App/Appclip. You can disable by removing this configuration from the above snipped : |
There was a problem hiding this comment.
Typo: “snipped” → “snippet”.
This reads better and matches standard usage.
✏️ Suggested fix
-You can disable by removing this configuration from the above snipped :
+You can disable by removing this configuration from the above snippet:📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| If you don't want to use the in-browser SDK, the users will be asked to install the Reclaim Protocol App/Appclip. You can disable by removing this configuration from the above snipped : | |
| If you don't want to use the in-browser SDK, the users will be asked to install the Reclaim Protocol App/Appclip. You can disable by removing this configuration from the above snippet: |
🧰 Tools
🪛 LanguageTool
[grammar] ~172-~172: Ensure spelling is correct
Context: ...oving this configuration from the above snipped : js //REMOVE : proofRequestOptions = { ..., //other options, if any useAppClip: false, customSharePageUrl: 'https://portal.reclaimprotocol.org' } const proofRequest = await ReclaimProofRequest.init(appId, appSecret, providerId, proofRequestOptions); [See reference implementation](https://gi...
(QB_NEW_EN_ORTHOGRAPHY_ERROR_IDS_1)
🤖 Prompt for AI Agents
In `@content/docs/js-sdk/preparing-request.mdx` at line 172, Replace the typo
"snipped" with "snippet" in the sentence that reads "You can disable by removing
this configuration from the above snipped :" so it becomes "You can disable by
removing this configuration from the above snippet :"; update the text in the
preparing-request.mdx content where that sentence appears.
Description
Testing (ignore for documentation update)
Type of change
Checklist:
Additional Notes:
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.