feat(deeplinks): add Swap, Rewards, Predict, Earn-musd, Shield, Trending to WHITELISTED_ACTIONS#29264
Conversation
…ing to WHITELISTED_ACTIONS Co-authored-by: Baptiste Marchand <baptiste-marchand@users.noreply.github.com>
… as non-whitelisted action ACTIONS.SWAP was added to WHITELISTED_ACTIONS so tests that expected the interstitial modal to appear for SWAP now use ACTIONS.SEND instead, which remains non-whitelisted. Co-authored-by: Baptiste Marchand <baptiste-marchand@users.noreply.github.com>
…2E tests ACTIONS.SWAP is now whitelisted, so the interstitial modal no longer appears for swap deeplinks. Tests no longer need to handle the 'Proceed with caution' modal before interacting with the swap view. Co-authored-by: Baptiste Marchand <baptiste-marchand@users.noreply.github.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit e31feba. Configure here.
ACTIONS.SWAP is whitelisted so the trusted-source bypass logic was never reached in those tests, making them vacuously pass. Using ACTIONS.SEND (non-whitelisted) ensures the tests genuinely exercise the trusted-in-app-source short-circuit path. Co-authored-by: Baptiste Marchand <baptiste-marchand@users.noreply.github.com>
AI PR Analysis🚫 Merge safe: false | 🟠 Risk: high
AI analysis did not complete. Manual review recommended. |
|
🔍 Smart E2E Test Selection
click to see 🤖 AI reasoning detailsE2E Test Selection: The changes center on the deep link interstitial modal whitelist in
The risk is medium because:
Performance Test Selection: |
|
✅ E2E Fixture Validation — Schema is up to date |




Description
Adds six missing actions to
WHITELISTED_ACTIONSinhandleUniversalLink.tsso that deeplinks to these features bypass the interstitial modal, consistent with how similar actions (e.g.PERPS,BUY,CARD_ONBOARDING) are already handled.Actions added (in
SUPPORTED_ACTIONSorder):SWAP— inserted afterDAPP, beforeWCREWARDS— inserted afterPERPS_ASSET, beforeBUYPREDICT— inserted afterREWARDS, beforeBUYTRENDING— inserted afterSELL_CRYPTOSHIELD— inserted afterTRENDINGEARN_MUSD— inserted afterSHIELDChangelog
CHANGELOG entry:
Related issues
Fixes:
Manual testing steps
Screenshots/Recordings
Before
After
Pre-merge author checklist
Performance checks (if applicable)
trace()for usage andaddTokenfor an exampleFor performance guidelines and tooling, see the Performance Guide.
Pre-merge reviewer checklist
Note
Medium Risk
Changes deep link safety/interstitial behavior by allowing additional actions (including
swap) to bypass the “Proceed with caution” modal, which could affect user protection flows if mis-scoped. Logic is simple but touches a security-adjacent gate used for all universal links.Overview
Updates
handleUniversalLinkto expandWHITELISTED_ACTIONSso deeplinks for Swap, Rewards, Predict, Trending, Shield, and Earn MUSD skip the interstitial modal (while still tracking analytics as a non-interstitial flow).Adjusts tests accordingly: unit tests now use
sendas the representative non-whitelisted action for modal/signature scenarios, and the swap deeplink smoke test no longer expects/dismisses the “Proceed with caution” modal.Reviewed by Cursor Bugbot for commit 8112ffc. Bugbot is set up for automated code reviews on this repo. Configure here.