feat(ucs): call pre-authentication during authorize as per connector#9949
Merged
bernard-eugine merged 43 commits intomainfrom Oct 29, 2025
Merged
feat(ucs): call pre-authentication during authorize as per connector#9949bernard-eugine merged 43 commits intomainfrom
bernard-eugine merged 43 commits intomainfrom
Conversation
…low in direct connector flows
…tion from ConnectorSpecification trait
…introduce-new-decide-flow-complete-authorize
…flow-complete-authorize
…-ucs-for-pre-authentication-in-authorize
…-ucs-for-pre-authentication-in-authorize
…-ucs-for-pre-authentication-in-authorize
Base automatically changed from
introduce-new-decide-flow-complete-authorize
to
main
October 24, 2025 08:52
…entication-in-authorize
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #9949 +/- ##
=======================================
Coverage ? 3.92%
=======================================
Files ? 1223
Lines ? 300175
Branches ? 0
=======================================
Hits ? 11795
Misses ? 288380
Partials ? 0 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
jarnura
requested changes
Oct 24, 2025
…entication-in-authorize
jarnura
previously approved these changes
Oct 27, 2025
sai-harsha-vardhan
previously approved these changes
Oct 27, 2025
| } | ||
|
|
||
| /// Performs Payment Pre Authenticate | ||
| pub async fn payment_pre_authenticate( |
Contributor
There was a problem hiding this comment.
We can avoid this duplication by writing a macro expansion for all the operations like Authorize, Get, Pre-Authenticate and all the future flows?
…entication-in-authorize
62f20da
sai-harsha-vardhan
approved these changes
Oct 28, 2025
jarnura
approved these changes
Oct 28, 2025
aadityaguptaa
pushed a commit
that referenced
this pull request
Nov 10, 2025
…9949) Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bot[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Type of Change
Description
This PR introduces a major enhancement to the HyperSwitch payment processing system with the implementation of Unified Connector Service (UCS) Pre-Authentication Integration, fundamentally improving how authentication flows are handled across different payment connectors.
UCS Pre-Authentication Integration
The core of this PR is the implementation of a sophisticated pre-authentication system that integrates with the Unified Connector Service to provide enhanced 3D Secure (3DS) handling and authentication flows. This implementation addresses the growing complexity of payment authentication requirements across different connectors and provides a unified approach to handling pre-authentication challenges.
Key Components:
1. Pre-Authentication Flow Architecture
2. Enhanced Authentication Handling
3. Connector Integration Framework
Technical Implementation:
Core Files Modified:
crates/router/src/core/payments/flows/authorize_flow.rs: Main authorization flow with UCS pre-authentication integrationcrates/router/src/core/unified_connector_service.rs: UCS service integration and pre-authentication handlingcrates/external_services/src/grpc_client/unified_connector_service.rs: gRPC client for UCS communicationcrates/hyperswitch_interfaces/src/unified_connector_service/transformers.rs: Data transformation for UCS requests/responsesAdditional Changes
Motivation and Context
This change is required to address the growing complexity and fragmentation in payment authentication across different connectors. The current payment landscape presents several critical challenges:
Authentication Complexity Explosion:
Regulatory Compliance Pressure:
User Experience Challenges:
Technical Debt and Scalability:
The UCS Pre-Authentication Integration solves these problems by:
This implementation represents a fundamental shift from connector-specific authentication handling to a unified, intelligent system that can adapt to the evolving payment authentication landscape while maintaining backward compatibility and providing a foundation for future enhancements.
How did you test it?
Cannot be tested end to end yet. Since Authenticate, PostAuthenticate and Authorize changes are pending
Checklist
cargo +nightly fmt --allcargo clippy