Skip to content

feat: add DeepLink "support"#260

Open
tomasz-pazdziurek-cko wants to merge 1 commit into
masterfrom
feat/apm/part-1
Open

feat: add DeepLink "support"#260
tomasz-pazdziurek-cko wants to merge 1 commit into
masterfrom
feat/apm/part-1

Conversation

@tomasz-pazdziurek-cko

@tomasz-pazdziurek-cko tomasz-pazdziurek-cko commented May 5, 2026

Copy link
Copy Markdown
Contributor

Description

We have recently added support for DeepLink for mobile devices. The "deep_link" URL type is also returned to po.js, but po.js does not support it.

Solution

When received "deep_link", immediately send redirect confirmation with "success": false to the BE to receive a fallback URL from the BE (if possible).

Demo

  • iv_3DJEvdspxJ7BBXlNlGktaYJ8QMIrDQ2N - RevolutPay - supports fallback URL
Screen.Recording.2026-05-05.at.16.40.10.mov
  • iv_3DJFAdspxJeDGFAwzKQwvUaJp1LL3qkH - Sibs MBWay - doesn't support fallback URL, asks the merchant to confirm the payment in the app separately.
Screen.Recording.2026-05-05.at.16.42.29.mov

Checklist

  • I bumped the version of the project using yarn bump-version
  • I have checked the code for any potential issues
  • I tested my changes in the browser

Notes

@tomasz-pazdziurek-cko

Copy link
Copy Markdown
Contributor Author

@tomasz-pazdziurek-cko tomasz-pazdziurek-cko force-pushed the feat/apm/part-1 branch 2 times, most recently from 2a640c1 to 285440d Compare May 5, 2026 14:39
Base automatically changed from test/apm-example-page to master May 6, 2026 07:28
@tomasz-pazdziurek-cko tomasz-pazdziurek-cko force-pushed the feat/apm/part-1 branch 4 times, most recently from 3076a39 to 915b31e Compare May 8, 2026 10:38
@tomasz-pazdziurek-cko tomasz-pazdziurek-cko marked this pull request as ready for review May 8, 2026 13:18
Copilot AI review requested due to automatic review settings July 2, 2026 13:26

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds client-side handling for the new redirect.type = 'deep_link' value returned by the APM backend, and makes the Redirect UI resilient when invoice data is missing (common in some redirect flows).

Changes:

  • Extend APM API redirect typing to include type ('web' | 'deep_link') and confirmation_required.
  • Add APIImpl.sendRedirectResult(success) and trigger it automatically when a deep-link redirect is received.
  • Avoid crashing Redirect view when invoice is absent by falling back to redirect.hint / "Continue" for the button label.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
src/apm/views/Redirect.ts Makes redirect CTA label safe when invoice is not present.
src/apm/API.ts Adds redirect metadata fields, adds a redirect-result POST helper, and initiates fallback flow when receiving deep-link redirects.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/apm/API.ts
@@ -553,6 +567,10 @@ module ProcessOut {
}

if (apiResponse.state === 'NEXT_STEP_REQUIRED' && apiResponse.redirect) {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants