prompt
stringlengths
6
90.9k
response
stringlengths
121
36.1k
metadata
stringlengths
314
42.3k
<!-- Describe your changes in detail --> This PR adds support for payments get intent in v2 using merchant reference id. Note : In a distributed setup we will be having many partition, to access data efficiently we need `partition_key`. For payments partition_key is `payment_intent global-id` . So to get the partition_key, we need to create a `reverse_lookup` table which map `merchant_reference_id+profile` to `payment_intent global-id`. A constraint based mechanism will be implemented on those tables.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Database Layer (Queries & Schema)** - `crates/diesel_models/src/query/payment_intent.rs` **2. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/payments/payment_intent.rs` **3. Core Business Logic** - `crates/router/src/core/payments.rs` **4. Type Definitions** - `crates/router_env/src/logger/types.rs` **5. Utils** - `crates/router/src/routes/lock_utils.rs` **6. Other** - `crates/router/src/db/kafka_store.rs` - `crates/router/src/routes/app.rs` - `crates/router/src/routes/payments.rs` - ... and 2 more files **Code Patterns Applied:** - Implement new functions (8 changes) - Extend existing types with new fields (40 changes) - Modify database queries (3 changes) **Detailed Identifier Changes:** Commit e17ffd12: Files to modify: **crates/diesel_models/src/query/payment_intent.rs** Add: - function: pub::find_by_merchant_reference_id_profile_id **crates/hyperswitch_domain_models/src/payments/payment_intent.rs** Modify existing code **crates/router/src/core/payments.rs** Add: - function: pub::payments_get_intent_using_merchant_reference **crates/router/src/db/kafka_store.rs** Add: - function: private::find_payment_intent_by_merchant_reference_id_profile_id **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/lock_utils.rs** Modify existing code **crates/router/src/routes/payments.rs** Add: - function: pub::payment_get_intent_using_merchant_reference_id **crates/router_env/src/logger/types.rs** Modify existing code **crates/storage_impl/src/mock_db/payment_intent.rs** Add: - function: private::find_payment_intent_by_merchant_reference_id_profile_id **crates/storage_impl/src/payments/payment_intent.rs** Add: - function: private::find_payment_intent_by_merchant_reference_id_profile_id - function: private::find_payment_intent_by_merchant_reference_id_profile_id
{"pr_number": 7123, "pr_title": "feat(core): Add support for v2 payments get intent using merchant reference id", "merged_at": "2025-02-06T15:07:01Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"database": ["crates/diesel_models/src/query/payment_intent.rs"], "domain": ["crates/hyperswitch_domain_models/src/payments/payment_intent.rs"], "core_business": ["crates/router/src/core/payments.rs"], "types": ["crates/router_env/src/logger/types.rs"], "utils": ["crates/router/src/routes/lock_utils.rs"], "other": ["crates/router/src/db/kafka_store.rs", "crates/router/src/routes/app.rs", "crates/router/src/routes/payments.rs", "crates/storage_impl/src/mock_db/payment_intent.rs", "crates/storage_impl/src/payments/payment_intent.rs"]}, "change_types": {"functions_added": 8, "fields_added": 40, "database_queries": 3}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> add three_ds_decision_rule_algorithm to the domain and diesel models of business_profile This is a Micro PR towards three_ds decision rule exemption engine, would be adding support to three_ds decision rules in routing apis in future PRs
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Database Layer (Queries & Schema)** - `crates/diesel_models/src/business_profile.rs` - `crates/diesel_models/src/schema.rs` - `crates/diesel_models/src/schema_v2.rs` **2. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/business_profile.rs` **3. Core Business Logic** - `crates/router/src/core/routing/helpers.rs` **4. Other** - `migrations/2025-05-21-134155_add_three_ds_decision_rule_algorithm_to_business_profile/down.sql` - `migrations/2025-05-21-134155_add_three_ds_decision_rule_algorithm_to_business_profile/up.sql` **Code Patterns Applied:** - Extend existing types with new fields (18 changes) **Detailed Identifier Changes:** Commit c0cda41b: Files to modify: **crates/diesel_models/src/business_profile.rs** Modify existing code **crates/diesel_models/src/schema.rs** Modify existing code **crates/diesel_models/src/schema_v2.rs** Modify existing code **crates/hyperswitch_domain_models/src/business_profile.rs** Modify existing code **crates/router/src/core/routing/helpers.rs** Modify existing code
{"pr_number": 8106, "pr_title": "feat(router): add three_ds_decision_rule_algorithm to the domain and diesel models of business_profile", "merged_at": "2025-05-23T07:46:26Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"database": ["crates/diesel_models/src/business_profile.rs", "crates/diesel_models/src/schema.rs", "crates/diesel_models/src/schema_v2.rs"], "domain": ["crates/hyperswitch_domain_models/src/business_profile.rs"], "core_business": ["crates/router/src/core/routing/helpers.rs"], "other": ["migrations/2025-05-21-134155_add_three_ds_decision_rule_algorithm_to_business_profile/down.sql", "migrations/2025-05-21-134155_add_three_ds_decision_rule_algorithm_to_business_profile/up.sql"]}, "change_types": {"fields_added": 18}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> WASM fixed in Getnet
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/connector_configs/toml/development.toml` - `crates/connector_configs/toml/production.toml` - `crates/connector_configs/toml/sandbox.toml`
{"pr_number": 7564, "pr_title": "fix(connector): WASM fixed in Getnet", "merged_at": "2025-03-19T11:18:51Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"connectors": ["crates/connector_configs/toml/development.toml", "crates/connector_configs/toml/production.toml", "crates/connector_configs/toml/sandbox.toml"]}, "change_types": {}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
<!-- Describe your changes in detail --> 1)Make installment_payment_enabled,recurring_enabled Optional 2) is_frame_redirection_enabled Field Missing in Create Business Profile API Response 3)Move CaptureMethodNotSupported error to 4xx instead of 5xx.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/admin.rs` - `crates/api_models/src/payment_methods.rs` **2. Core Business Logic** - `crates/router/src/core/errors/utils.rs` - `crates/router/src/core/payment_methods/cards.rs` - `crates/router/src/core/payment_methods/tokenize/card_executor.rs` - ... and 3 more files **3. External Connector Integration** - `crates/connector_configs/src/transformer.rs` **4. Type Definitions** - `crates/common_types/src/payment_methods.rs` - `crates/router/src/types/api/admin.rs` - `crates/router/src/types/transformers.rs` **5. Utils** - `crates/kgraph_utils/benches/evaluation.rs` - `crates/kgraph_utils/src/mca.rs` - `crates/payment_methods/src/helpers.rs` **6. Other** - `api-reference-v2/openapi_spec.json` - `api-reference/openapi_spec.json` **Code Patterns Applied:** - Extend existing types with new fields (57 changes) - Add conditional logic for feature flags or filtering (1 changes) **Detailed Identifier Changes:** Commit 171ca3b5: Files to modify: **crates/api_models/src/admin.rs** Modify existing code **crates/api_models/src/payment_methods.rs** Modify existing code **crates/common_types/src/payment_methods.rs** Modify existing code **crates/connector_configs/src/transformer.rs** Modify existing code **crates/kgraph_utils/benches/evaluation.rs** Modify existing code **crates/kgraph_utils/src/mca.rs** Modify existing code **crates/payment_methods/src/helpers.rs** Modify existing code **crates/router/src/core/errors/utils.rs** Modify existing code **crates/router/src/core/payment_methods/cards.rs** Modify existing code **crates/router/src/core/payment_methods/tokenize/card_executor.rs** Modify existing code **crates/router/src/core/payment_methods/tokenize/payment_method_executor.rs** Modify existing code **crates/router/src/core/payment_methods/transformers.rs** Modify existing code **crates/router/src/core/payments/tokenization.rs** Modify existing code **crates/router/src/types/api/admin.rs** Modify existing code **crates/router/src/types/transformers.rs** Modify existing code
{"pr_number": 8201, "pr_title": "feat(core): Make installment_payment_enabled,recurring_enabled Optional", "merged_at": "2025-06-10T11:04:30Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/admin.rs", "crates/api_models/src/payment_methods.rs"], "core_business": ["crates/router/src/core/errors/utils.rs", "crates/router/src/core/payment_methods/cards.rs", "crates/router/src/core/payment_methods/tokenize/card_executor.rs", "crates/router/src/core/payment_methods/tokenize/payment_method_executor.rs", "crates/router/src/core/payment_methods/transformers.rs", "crates/router/src/core/payments/tokenization.rs"], "connectors": ["crates/connector_configs/src/transformer.rs"], "types": ["crates/common_types/src/payment_methods.rs", "crates/router/src/types/api/admin.rs", "crates/router/src/types/transformers.rs"], "utils": ["crates/kgraph_utils/benches/evaluation.rs", "crates/kgraph_utils/src/mca.rs", "crates/payment_methods/src/helpers.rs"], "other": ["api-reference-v2/openapi_spec.json", "api-reference/openapi_spec.json"]}, "change_types": {"fields_added": 57, "conditionals_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Fixes race condition in Worldpay 3DS Device Data Collection (DDC) flow causing `bodyDoesNotMatchSchema` errors. **Changes made:** - Extended DDC timeout from 8s to 10s in client-side JavaScript - Added `ddcProcessed` flag to prevent duplicate submissions on client-side - Reject `collectionReference` submissions when payment is in `AuthenticationPending` state - Fixed CSS media query syntax (`@media (max-width: 600px)`) - Added Cypress test case for both client and server-side race conditions for DDC submissions
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/worldpay.rs` - `crates/hyperswitch_connectors/src/connectors/worldpay/transformers.rs` **2. Tests** - `cypress-tests/cypress/e2e/configs/Payment/Commons.js` - `cypress-tests/cypress/e2e/configs/Payment/Utils.js` - `cypress-tests/cypress/e2e/configs/Payment/WorldPay.js` - ... and 2 more files **3. Other** - `crates/router/src/services/api.rs` **Code Patterns Applied:** - Extend existing types with new fields (126 changes) - Add conditional logic for feature flags or filtering (22 changes) - Modify database queries (2 changes) **Detailed Identifier Changes:** Commit f6cdddcb: Files to modify: **crates/hyperswitch_connectors/src/connectors/worldpay.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/worldpay/transformers.rs** Modify existing code **crates/router/src/services/api.rs** Modify existing code
{"pr_number": 8741, "pr_title": "fix(connector): [Worldpay] handle multiple ddc submission for CompleteAuthorize", "merged_at": "2025-07-29T08:47:11Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "user"]}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/src/connectors/worldpay.rs", "crates/hyperswitch_connectors/src/connectors/worldpay/transformers.rs"], "tests": ["cypress-tests/cypress/e2e/configs/Payment/Commons.js", "cypress-tests/cypress/e2e/configs/Payment/Utils.js", "cypress-tests/cypress/e2e/configs/Payment/WorldPay.js", "cypress-tests/cypress/e2e/spec/Payment/00030-DDCRaceCondition.cy.js", "cypress-tests/cypress/support/commands.js"], "other": ["crates/router/src/services/api.rs"]}, "change_types": {"fields_added": 126, "conditionals_added": 22, "database_queries": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Implement Interac payouts
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/enums.rs` - `crates/api_models/src/payments.rs` - `crates/api_models/src/payouts.rs` **2. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/router_request_types.rs` **3. Core Business Logic** - `crates/router/src/core/payouts.rs` - `crates/router/src/core/utils.rs` **4. External Connector Integration** - `crates/connector_configs/src/connector.rs` - `crates/connector_configs/toml/development.toml` - `crates/connector_configs/toml/production.toml` - ... and 6 more files **5. Other** - `api-reference/v1/openapi_spec_v1.json` - `api-reference/v2/openapi_spec_v2.json` **Code Patterns Applied:** - Define new data structures (3 changes) - Implement new functions (21 changes) - Extend existing types with new fields (102 changes) **Detailed Identifier Changes:** Commit cf30da2d: Files to modify: **crates/api_models/src/enums.rs** Modify existing code **crates/api_models/src/payments.rs** Modify existing code **crates/api_models/src/payouts.rs** Modify existing code **crates/connector_configs/src/connector.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/gigadat.rs** Add: - function: private::get_headers - function: private::get_url - function: private::get_request_body - function: private::build_request - function: private::handle_response - function: private::get_error_response - function: private::get_headers - function: private::get_url - function: private::build_request - function: private::handle_response - function: private::get_error_response - function: private::get_headers - function: private::get_url - function: private::build_request - function: private::handle_response - function: private::get_error_response - impl: impl api::PayoutQuote for Gigadat - impl: impl api::PayoutCreate for Gigadat - impl: impl api::PayoutFulfill for Gigadat - impl: impl ConnectorIntegration<PoQuote, PayoutsData, PayoutsResponseData> for Gigadat - impl: impl ConnectorIntegration<PoCreate, PayoutsData, PayoutsResponseData> for Gigadat - impl: impl ConnectorIntegration<PoFulfill, PayoutsData, PayoutsResponseData> for Gigadat **crates/hyperswitch_connectors/src/connectors/gigadat/transformers.rs** Add: - function: private::try_from - function: private::try_from - struct: pub::GigadatPayoutQuoteRequest - struct: pub::GigadatPayoutResponse - struct: pub::GigadatPayoutData - impl: impl TryFrom<&GigadatRouterData<&PayoutsRouterData<PoQuote>>> for GigadatPayoutQuoteRequest - impl: impl TryFrom<PayoutsResponseRouterData<F, GigadatPayoutResponse>> for PayoutsRouterData<F> **crates/hyperswitch_connectors/src/default_implementations.rs** Modify existing code **crates/hyperswitch_connectors/src/utils.rs** Add: - function: private::get_browser_info **crates/hyperswitch_domain_models/src/router_request_types.rs** Add: - function: private::from - impl: impl From<api_models::payments::BrowserInformation> for BrowserInformation **crates/router/src/core/payouts.rs** Modify existing code **crates/router/src/core/utils.rs** Modify existing code **crates/router/tests/connectors/utils.rs** Modify existing code
{"pr_number": 9566, "pr_title": "feat(connector): [Gigadat] Implement interac payouts", "merged_at": "2025-10-01T09:32:28Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"api_models": ["crates/api_models/src/enums.rs", "crates/api_models/src/payments.rs", "crates/api_models/src/payouts.rs"], "domain": ["crates/hyperswitch_domain_models/src/router_request_types.rs"], "core_business": ["crates/router/src/core/payouts.rs", "crates/router/src/core/utils.rs"], "connectors": ["crates/connector_configs/src/connector.rs", "crates/connector_configs/toml/development.toml", "crates/connector_configs/toml/production.toml", "crates/connector_configs/toml/sandbox.toml", "crates/hyperswitch_connectors/src/connectors/gigadat.rs", "crates/hyperswitch_connectors/src/connectors/gigadat/transformers.rs", "crates/hyperswitch_connectors/src/default_implementations.rs", "crates/hyperswitch_connectors/src/utils.rs", "crates/router/tests/connectors/utils.rs"], "other": ["api-reference/v1/openapi_spec_v1.json", "api-reference/v2/openapi_spec_v2.json"]}, "change_types": {"structs_added": 3, "functions_added": 21, "fields_added": 102, "imports_added": 7}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Refactored customer email and browser information in router data ## Motivation and Context <!-- Why is this change required? What problem does it solve? If it fixes an open issue, please link to the issue here. If you don't have an issue, we'd recommend starting with one first so the PR can focus on the implementation (unless it is an obvious bug or documentation fix that will have little conversation). --> This refactoring provides data to the connector integrations, so that it can be used in connector calls. ## How did you test it? <!-- Did you write an integration/unit/API test to verify the code changes? Or did you test this change manually (provide relevant screenshots)? --> - Confirm Intent API Call for trustpay connector. ``` curl --location 'http://localhost:8080/v2/payments/12345_pay_01945e865f697553bbf0eb847611cfcd/confirm-intent' \ --header 'x-client-secret: 1secret-client-secret' \ --header 'x-profile-id: pro_id' \ --header 'Content-Type: application/json' \ --header 'api-key: api-key' \ --data '{ "payment_method_data": { "card": { "card_number": "4242424242424242", "card_exp_month": "01", "card_exp_year": "25", "card_holder_name": "John Doe", "card_cvc": "100" } }, "payment_method_type": "card", "payment_method_subtype": "credit", "browser_info": { "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36", "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8", "language": "nl-NL", "color_depth": 24, "screen_height": 723, "screen_width": 1536, "time_zone": 0, "java_enabled": true, "java_script_enabled": true, "ip_address": "127.0.0.1" } }' ``` - Response from above call ``` { "id": "12345_pay_01945f254dc27802a54be556c0acab7a", "status": "failed", "amount": { "order_amount": 100, "currency": "USD", "shipping_cost": null, "order_tax_amount": null, "external_tax_calculation": "skip", "surcharge_calculation": "skip", "surcharge_amount": null, "tax_on_surcharge": null, "net_amount": 100, "amount_to_capture": null, "amount_capturable": 0, "amount_captured": null }, "customer_id": "12345_cus_01945f252cb37e20a6fb6105be0c976f", "connector": "trustpay", "client_secret": "12345_pay_01945f254dc27802a54be556c0acab7a_secret_01945f254ddd7cb385275b8d620bbb24", "created": "2025-01-13T10:11:07.869Z", "payment_method_data": { "billing": null }, "payment_method_type": "card", "payment_method_subtype": "credit", "next_action": null, "connector_transaction_id": null, "connector_reference_id": null, "merchant_connector_id": "mca_lZ6moeYo6Ce2vdD01f7s", "browser_info": null, "error": { "code": "4", "message": "The field Reference must be a string with a maximum length of 35.", "unified_code": null, "unified_message": null } } ``` - This refactoring fixes availability of email and browser information fields for trustpay. ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt --all` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed the submitted code - [ ] I added unit tests for my changes where possible
To implement this **payment** feature, you'll need to modify these architectural layers: **1. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/router_request_types.rs` **2. Core Business Logic** - `crates/router/src/core/payments/transformers.rs` **Code Patterns Applied:** - Implement new functions (1 changes) - Extend existing types with new fields (13 changes) **Detailed Identifier Changes:** Commit d35a9222: Files to modify: **crates/hyperswitch_domain_models/src/router_request_types.rs** Add: - function: private::from - impl: impl From<common_utils::types::BrowserInformation> for BrowserInformation **crates/router/src/core/payments/transformers.rs** Modify existing code
{"pr_number": 7034, "pr_title": "Refactor: Customer email and browser Information", "merged_at": "2025-01-21T08:49:43Z", "intent": {"feature_type": "payment", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"domain": ["crates/hyperswitch_domain_models/src/router_request_types.rs"], "core_business": ["crates/router/src/core/payments/transformers.rs"]}, "change_types": {"functions_added": 1, "fields_added": 13}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Modified api key auth to support control over VSAAS operations. The PR provides fine grained control over routes authentication - allowing Platform to perform payments in V1 (MVP case) - disallowing all the operations in v2 - disallowing all other operations other than payments, for platform - context of connected merchant, doing any operation (Checks from the auth, to be added in the next PR, with introduction of new header)
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Other** - `crates/router/src/compatibility/stripe/customers.rs` - `crates/router/src/compatibility/stripe/payment_intents.rs` - `crates/router/src/compatibility/stripe/refunds.rs` - ... and 21 more files **Code Patterns Applied:** - Define new data structures (2 changes) - Extend existing types with new fields (338 changes) - Add conditional logic for feature flags or filtering (3 changes) **Detailed Identifier Changes:** Commit 2a467053: Files to modify: **crates/router/src/compatibility/stripe/customers.rs** Modify existing code **crates/router/src/compatibility/stripe/payment_intents.rs** Modify existing code **crates/router/src/compatibility/stripe/refunds.rs** Modify existing code **crates/router/src/compatibility/stripe/setup_intents.rs** Modify existing code **crates/router/src/routes/blocklist.rs** Modify existing code **crates/router/src/routes/cards_info.rs** Modify existing code **crates/router/src/routes/currency.rs** Modify existing code **crates/router/src/routes/customers.rs** Modify existing code **crates/router/src/routes/disputes.rs** Modify existing code **crates/router/src/routes/ephemeral_key.rs** Modify existing code **crates/router/src/routes/files.rs** Modify existing code **crates/router/src/routes/fraud_check.rs** Modify existing code **crates/router/src/routes/mandates.rs** Modify existing code **crates/router/src/routes/payment_link.rs** Modify existing code **crates/router/src/routes/payment_methods.rs** Modify existing code **crates/router/src/routes/payments.rs** Modify existing code **crates/router/src/routes/payouts.rs** Modify existing code **crates/router/src/routes/pm_auth.rs** Modify existing code **crates/router/src/routes/profiles.rs** Modify existing code **crates/router/src/routes/refunds.rs** Modify existing code **crates/router/src/routes/relay.rs** Modify existing code **crates/router/src/routes/routing.rs** Modify existing code **crates/router/src/routes/verification.rs** Modify existing code **crates/router/src/services/authentication.rs** Remove: - struct: pub::ApiKeyAuth - struct: pub::V2ApiKeyAuth Add: - struct: pub::ApiKeyAuth - struct: pub::V2ApiKeyAuth
{"pr_number": 7593, "pr_title": "feat(vsaas): modify api key auth to support vsaas cases", "merged_at": "2025-04-16T10:50:02Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"other": ["crates/router/src/compatibility/stripe/customers.rs", "crates/router/src/compatibility/stripe/payment_intents.rs", "crates/router/src/compatibility/stripe/refunds.rs", "crates/router/src/compatibility/stripe/setup_intents.rs", "crates/router/src/routes/blocklist.rs", "crates/router/src/routes/cards_info.rs", "crates/router/src/routes/currency.rs", "crates/router/src/routes/customers.rs", "crates/router/src/routes/disputes.rs", "crates/router/src/routes/ephemeral_key.rs", "crates/router/src/routes/files.rs", "crates/router/src/routes/fraud_check.rs", "crates/router/src/routes/mandates.rs", "crates/router/src/routes/payment_link.rs", "crates/router/src/routes/payment_methods.rs", "crates/router/src/routes/payments.rs", "crates/router/src/routes/payouts.rs", "crates/router/src/routes/pm_auth.rs", "crates/router/src/routes/profiles.rs", "crates/router/src/routes/refunds.rs", "crates/router/src/routes/relay.rs", "crates/router/src/routes/routing.rs", "crates/router/src/routes/verification.rs", "crates/router/src/services/authentication.rs"]}, "change_types": {"structs_added": 2, "fields_added": 338, "conditionals_added": 3}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Add the following features in nuvie 1. Google pay decrypt flow S2S 2. Apple pay decrypt flow S2S 3. Google pay encrypt flow 4. Partial Authorization 5. Send shipping address for nuvei (previously not sent) ## Test attachment <details> <summary> <b>APPLE PAY DECRYPT FLOW </b> </summary> # Request ```json { "amount": 1, "currency": "EUR", "confirm": true, // "order_tax_amount": 100, "setup_future_usage": "off_session", // "payment_type":"setup_mandate", "customer_id": "nithxxinn", "return_url": "https://www.google.com", "capture_method": "automatic", "payment_method": "wallet", "payment_method_type": "apple_pay", "authentication_type": "no_three_ds", "description": "hellow world", "billing": { "address": { "zip": "560095", "country": "US", "first_name": "Sakil", "last_name": "Mostak", "line1": "Fasdf", "line2": "Fasdf", "city": "Fasdf" }, "email":"nithingowdan77@gmail.com" }, "browser_info": { "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8", "ip_address": "192.168.1.1", "java_enabled": false, "java_script_enabled": true, "language": "en-US", "color_depth": 24, "screen_height": 1080, "screen_width": 1920, "time_zone": 330, "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36" }, "email": "hello@gmail.com", "payment_method_data": { "wallet": { "apple_pay": { "payment_data": { "application_primary_account_number": "4242424242424242", "application_expiration_month": "09", "application_expiration_year": "30", "application_brand":"VISA", "payment_data": { "online_payment_cryptogram": "ArSx8**************************", "eci_indicator": "7" } }, "payment_method": { "display_name": "Discover 9319", "network": "VISA", "type": "debit" }, "transaction_identifier": "c635c5b3af900d7bd81fecd7028f1262f9d030754ee65ec7afd988a678194751" } } } } ``` # Response ```json { "payment_id": "pay_MgXkheRylOHLMUllc1Mw", "merchant_id": "merchant_1755589543", "status": "succeeded", "amount": 1, "net_amount": 1, "shipping_cost": null, "amount_capturable": 0, "amount_received": 1, "connector": "nuvei", "client_secret": "pay_MgXkheRylOHLMUllc1Mw_secret_swUebKaDNEsP4Qo5BMxe", "created": "2025-08-19T08:05:14.847Z", "currency": "EUR", "customer_id": "nithxxinn", "customer": { "id": "nithxxinn", "name": null, "email": "hello@gmail.com", "phone": null, "phone_country_code": null }, "description": "hellow world", "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": "on_session", "off_session": null, "capture_on": null, "capture_method": "automatic", "payment_method": "wallet", "payment_method_data": { "wallet": { "apple_pay": { "last4": "9319", "card_network": "VISA", "type": "debit" } }, "billing": null }, "payment_token": null, "shipping": null, "billing": { "address": { "city": "Fasdf", "country": "US", "line1": "Fasdf", "line2": "Fasdf", "line3": null, "zip": "560095", "state": null, "first_name": "Sakil", "last_name": "Mostak", "origin_zip": null }, "phone": null, "email": "nithin*****@gmail.com" }, "order_details": null, "email": "hello@gmail.com", "name": null, "phone": null, "return_url": "https://www.google.com/", "authentication_type": "no_three_ds", "statement_descriptor_name": null, "statement_descriptor_suffix": null, "next_action": null, "cancellation_reason": null, "error_code": null, "error_message": null, "unified_code": null, "unified_message": null, "payment_experience": null, "payment_method_type": "apple_pay", "connector_label": null, "business_country": null, "business_label": "default", "business_sub_label": null, "allowed_payment_method_types": null, "ephemeral_key": { "customer_id": "nithxxinn", "created_at": 1755590714, "expires": 1755594314, "secret": "epk_ad5c941cff3a4404ab38dee084e575d0" }, "manual_retry_allowed": false, "connector_transaction_id": "8110000000012650848", "frm_message": null, "metadata": null, "connector_metadata": null, "feature_metadata": { "redirect_response": null, "search_tags": null, "apple_pay_recurring_details": null, "gateway_system": "direct" }, "reference_id": "8027431111", "payment_link": null, "profile_id": "pro_o6xLMNfkFwAWH1U1zimF", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_8DFDwR4GryN3qQQOh8bq", "incremental_authorization_allowed": false, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2025-08-19T08:20:14.847Z", "fingerprint": null, "browser_info": { "language": "en-US", "time_zone": 330, "ip_address": "192.168.1.1", "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36", "color_depth": 24, "java_enabled": false, "screen_width": 1920, "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8", "screen_height": 1080, "java_script_enabled": true }, "payment_channel": null, "payment_method_id": null, "network_transaction_id": null, "payment_method_status": null, "updated": "2025-08-19T08:05:17.249Z", "split_payments": null, "frm_metadata": null, "extended_authorization_applied": null, "capture_before": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": null, "card_discovery": null, "force_3ds_challenge": false, "force_3ds_challenge_trigger": false, "issuer_error_code": null, "issuer_error_message": null, "is_iframe_redirection_enabled": null, "whole_connector_response": null, "enable_partial_authorization": null } ``` </details> <details> <summary> Google pay Decrypt </summary> ## Request ```json { "amount": 1, "currency": "EUR", "confirm": true, "customer_id": "nithxxinn", "return_url": "https://www.google.com", "capture_method": "automatic", "payment_method": "wallet", "payment_method_type": "google_pay", "authentication_type": "no_three_ds", "description": "hellow world", "billing": { "address": { "zip": "560095", "country": "UA", "first_name": "Sakil", "last_name": "Mostak", "line1": "Fasdf", "line2": "Fasdf", "city": "Fasdf" }, "email":"test@gmail.com" }, "browser_info": { "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8", "ip_address": "192.168.1.1", "java_enabled": false, "java_script_enabled": true, "language": "en-US", "color_depth": 24, "screen_height": 1080, "screen_width": 1920, "time_zone": 330, "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36" }, "email": "hello@gmail.com", "payment_method_data": { "wallet": { "google_pay": { "type": "CARD", "tokenization_data": { "application_primary_account_number": "4761344136141390", "card_exp_month": "12", "card_exp_year": "25", "cryptogram": "ejJR********************U=", "eci_indicator": "5" }, "info": { "card_details": "Discover 9319", "card_network": "VISA" }, "description": "something" } } } } ``` Response ```json { "payment_id": "pay_0i5TBkizYCY8JIwAPB1H", "merchant_id": "merchant_1755589543", "status": "succeeded", "amount": 1, "net_amount": 1, "shipping_cost": null, "amount_capturable": 0, "amount_received": 1, "connector": "nuvei", "client_secret": "pay_0i5TBkizYCY8JIwAPB1H_secret_7O5zdgMiNJxFdZolSjIJ", "created": "2025-08-19T08:07:18.648Z", "currency": "EUR", "customer_id": "nithxxinn", "customer": { "id": "nithxxinn", "name": null, "email": "hello@gmail.com", "phone": null, "phone_country_code": null }, "description": "hellow world", "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": null, "off_session": null, "capture_on": null, "capture_method": "automatic", "payment_method": "wallet", "payment_method_data": { "wallet": { "google_pay": { "last4": "Discover 9319", "card_network": "VISA", "type": "CARD" } }, "billing": null }, "payment_token": null, "shipping": null, "billing": { "address": { "city": "Fasdf", "country": "UA", "line1": "Fasdf", "line2": "Fasdf", "line3": null, "zip": "560095", "state": null, "first_name": "Sakil", "last_name": "Mostak", "origin_zip": null }, "phone": null, "email": "test@gmail.com" }, "order_details": null, "email": "hello@gmail.com", "name": null, "phone": null, "return_url": "https://www.google.com/", "authentication_type": "no_three_ds", "statement_descriptor_name": null, "statement_descriptor_suffix": null, "next_action": null, "cancellation_reason": null, "error_code": null, "error_message": null, "unified_code": null, "unified_message": null, "payment_experience": null, "payment_method_type": "google_pay", "connector_label": null, "business_country": null, "business_label": "default", "business_sub_label": null, "allowed_payment_method_types": null, "ephemeral_key": { "customer_id": "nithxxinn", "created_at": 1755590838, "expires": 1755594438, "secret": "epk_8d9994d7f5594c2a8fb10ebf6c3fdc27" }, "manual_retry_allowed": false, "connector_transaction_id": "8110000000012650994", "frm_message": null, "metadata": null, "connector_metadata": null, "feature_metadata": { "redirect_response": null, "search_tags": null, "apple_pay_recurring_details": null, "gateway_system": "direct" }, "reference_id": "8027476111", "payment_link": null, "profile_id": "pro_o6xLMNfkFwAWH1U1zimF", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_8DFDwR4GryN3qQQOh8bq", "incremental_authorization_allowed": false, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2025-08-19T08:22:18.648Z", "fingerprint": null, "browser_info": { "language": "en-US", "time_zone": 330, "ip_address": "192.168.1.1", "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36", "color_depth": 24, "java_enabled": false, "screen_width": 1920, "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8", "screen_height": 1080, "java_script_enabled": true }, "payment_channel": null, "payment_method_id": null, "network_transaction_id": null, "payment_method_status": null, "updated": "2025-08-19T08:07:21.259Z", "split_payments": null, "frm_metadata": null, "extended_authorization_applied": null, "capture_before": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": null, "card_discovery": null, "force_3ds_challenge": false, "force_3ds_challenge_trigger": false, "issuer_error_code": null, "issuer_error_message": null, "is_iframe_redirection_enabled": null, "whole_connector_response": null, "enable_partial_authorization": null } ``` </details> <details> <summary> GOOGLE PAY DIRECT </summary> ```js const tokenizationSpecification = { type: "PAYMENT_GATEWAY", parameters: { "gateway": "nuveidigital", "gatewayMerchantId": "googletest" } }; ``` ## Request ```json { "amount": 1, "currency": "EUR", "confirm": true, "customer_id": "nithxxinn", "return_url": "https://www.google.com", "capture_method": "automatic", "payment_method": "wallet", "payment_method_type": "google_pay", "authentication_type": "no_three_ds", "description": "hellow world", "billing": { "address": { "zip": "560095", "country": "UA", "first_name": "Sakil", "last_name": "Mostak", "line1": "Fasdf", "line2": "Fasdf", "city": "Fasdf" }, "email":"nithin@test.com" }, "browser_info": { "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8", "ip_address": "192.168.1.1", "java_enabled": false, "java_script_enabled": true, "language": "en-US", "color_depth": 24, "screen_height": 1080, "screen_width": 1920, "time_zone": 330, "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36" }, "email": "hello@gmail.com", "payment_method_data": { "wallet": { "google_pay": { "description": "SG Visa Success: Visa •••• 1390", "info": { "assuranceDetails": { "account_verified": true, "card_holder_authenticated": false }, "card_details": "1390", "card_network": "VISA" }, "tokenization_data": { "token": "{\"signature\":\"MEUCIG7saL2k07Szf8ezokemD5jAJTwpcWwpy+ajTJot7u+nAiEAzvcuwAoj47r8oMh3a6eUKeZB2lFyDLEzZt2R2lpezo0\\u003d\",\"intermediateSigningKey\":{\"signedKey\":\"{\\\"keyValue\\\":\\\"MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE9ByUUgcs6d9rtJA3svCKaGZQjfsbMQAAwWZ6YNIpJkg/NR9HAkMT1sdhkKMRxtcFp1k5y01dr/JpEU2Pj3XyYw\\\\u003d\\\\u003d\\\",\\\"keyExpiration\\\":\\\"1756245691797\\\"}\",\"signatures\":[\"MEQCIFAS8NBh7J4rz00iRDjScYizAfRV+pVnCfsmsFgrehMVAiBpxHFUu6wG3UVNhDMmudb6sZeZHXDJonLkkKOWgzN4TA\\u003d\\u003d\"]},\"protocolVersion\":\"ECv2\",\"signedMessage\":\"{\\\"encryptedMessage\\\":\\\"hJxayhOT/y4ekX9Ub14X6nl7Xm0h3b1nu8FKv7WDulloondBA+kk9sYnNomQx+ZPANrGES4CBGbmptqW5gR6TjdvENXbSUrTjzU8k++Klw/AwAJBcID+dL+EgyIvgmqIYesLyKzITkZr9zSxtd0zuB9ewcta8gHgBzlZmJSWmdvanv4xiBQgjriKolnw4IiOXXAzN+X0GGXkPqcQnlLIrUzjn/9oCgwhFDltl1EJjkUH8Ji2Rzx62FUexxY6RHHrkoq3pCoirc+KNRXPu3+gC06iloRTR48gmmayFKH5s3Kyw0j9Oypu7fx/AgSqrFKkFzVUmCV0yLwGQSI2vyVdKOFLgLay8dDbEHKvF5X+ZP7diunVh0QwZUTT7yRmgyQUaZAbQhd+uRHrev6SYXcmWdSu8E+8H6A7jtITaZN2eHI7u9ciW82/AcIx3gPkTocKGyXdYRB07+GaFIqyWwxT+9TwLW49oq7hbj978APK1vy4f8x6v2h1tCj6StH6md7xJpn+U47n8rKmJhQiXqRyzfKFcCekndvs0YpgEVbcoZEKKl0E\\\",\\\"ephemeralPublicKey\\\":\\\"BKvkUFUZmpa0BgifTbr2ZTNBK7D74Fg8RMsk2Txta+Vf+vX1/BZLUaITfjpgJ5Xqt3rz+AmrkFe+XRvT5E4R7nc\\\\u003d\\\",\\\"tag\\\":\\\"cGNVu61W/PvTC89JXVMUcsKaZIOpt92oexc+aztsKqw\\\\u003d\\\"}\"}", "type": "PAYMENT_GATEWAY" }, "type": "CARD" } }} } ``` ## response ```json { "payment_id": "pay_UGldGh1QW8CTJJJ22CMJ", "merchant_id": "merchant_1755589543", "status": "succeeded", "amount": 1, "net_amount": 1, "shipping_cost": null, "amount_capturable": 0, "amount_received": 1, "connector": "nuvei", "client_secret": "pay_UGldGh1QW8CTJJJ22CMJ_secret_nKqyqNJ02RgcaMsBBz51", "created": "2025-08-19T09:08:25.037Z", "currency": "EUR", "customer_id": "nithxxinn", "customer": { "id": "nithxxinn", "name": null, "email": "hello@gmail.com", "phone": null, "phone_country_code": null }, "description": "hellow world", "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": null, "off_session": null, "capture_on": null, "capture_method": "automatic", "payment_method": "wallet", "payment_method_data": { "wallet": { "google_pay": { "last4": "1390", "card_network": "VISA", "type": "CARD" } }, "billing": null }, "payment_token": null, "shipping": null, "billing": { "address": { "city": "Fasdf", "country": "UA", "line1": "Fasdf", "line2": "Fasdf", "line3": null, "zip": "560095", "state": null, "first_name": "Sakil", "last_name": "Mostak", "origin_zip": null }, "phone": null, "email": "nithin@test.com" }, "order_details": null, "email": "hello@gmail.com", "name": null, "phone": null, "return_url": "https://www.google.com/", "authentication_type": "no_three_ds", "statement_descriptor_name": null, "statement_descriptor_suffix": null, "next_action": null, "cancellation_reason": null, "error_code": null, "error_message": null, "unified_code": null, "unified_message": null, "payment_experience": null, "payment_method_type": "google_pay", "connector_label": null, "business_country": null, "business_label": "default", "business_sub_label": null, "allowed_payment_method_types": null, "ephemeral_key": { "customer_id": "nithxxinn", "created_at": 1755594505, "expires": 1755598105, "secret": "epk_d3dbd5a8b4c04958b6fb4c959cbc67a1" }, "manual_retry_allowed": false, "connector_transaction_id": "8110000000012655452", "frm_message": null, "metadata": null, "connector_metadata": null, "feature_metadata": { "redirect_response": null, "search_tags": null, "apple_pay_recurring_details": null, "gateway_system": "direct" }, "reference_id": "8029357111", "payment_link": null, "profile_id": "pro_o6xLMNfkFwAWH1U1zimF", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_8DFDwR4GryN3qQQOh8bq", "incremental_authorization_allowed": false, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2025-08-19T09:23:25.037Z", "fingerprint": null, "browser_info": { "language": "en-US", "time_zone": 330, "ip_address": "192.168.1.1", "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36", "color_depth": 24, "java_enabled": false, "screen_width": 1920, "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8", "screen_height": 1080, "java_script_enabled": true }, "payment_channel": null, "payment_method_id": null, "network_transaction_id": null, "payment_method_status": null, "updated": "2025-08-19T09:08:29.510Z", "split_payments": null, "frm_metadata": null, "extended_authorization_applied": null, "capture_before": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": null, "card_discovery": null, "force_3ds_challenge": false, "force_3ds_challenge_trigger": false, "issuer_error_code": null, "issuer_error_message": null, "is_iframe_redirection_enabled": null, "whole_connector_response": null, "enable_partial_authorization": null } ``` </details> <details> <summary>Partial auth </summary> ## Request ```json { "amount": 300, "currency": "EUR", "confirm": true, "customer_id": "nithxxinn", "return_url": "https://www.google.com", "capture_method": "automatic", "enable_partial_authorization":true, "payment_method": "card", "payment_method_type": "credit", "authentication_type": "no_three_ds", "description": "hellow world", "billing": { "address": { "zip": "560095", "country": "US", "first_name": "Sakil", "last_name": "Mostak", "line1": "Fasdf", "line2": "Fasdf", "city": "Fasdf" }, "email":"nithin@gmail.com" }, "browser_info": { "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8", "ip_address": "192.168.1.1", "java_enabled": false, "java_script_enabled": true, "language": "en-US", "color_depth": 24, "screen_height": 1080, "screen_width": 1920, "time_zone": 330, "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36" }, "email": "hello@gmail.com", "payment_method_data": { "card": { "card_number": "4531739335817394", "card_exp_month": "01", "card_exp_year": "2026", "card_holder_name": "John Smith", "card_cvc": "100" } } } ``` ## Response ```json { "payment_id": "pay_hieZ9MkK4v1qbqiXKEor", "merchant_id": "merchant_1755589543", "status": "partially_captured", "amount": 300, "net_amount": 300, "shipping_cost": null, "amount_capturable": 300, "amount_received": 150, "connector": "nuvei", "client_secret": "pay_hieZ9MkK4v1qbqiXKEor_secret_KN9DE1LjGlbxEIDGpzFT", "created": "2025-08-19T09:21:17.091Z", "currency": "EUR", "customer_id": "nithxxinn", "customer": { "id": "nithxxinn", "name": null, "email": "hello@gmail.com", "phone": null, "phone_country_code": null }, "description": "hellow world", "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": null, "off_session": null, "capture_on": null, "capture_method": "automatic", "payment_method": "card", "payment_method_data": { "card": { "last4": "7394", "card_type": null, "card_network": null, "card_issuer": null, "card_issuing_country": null, "card_isin": "453173", "card_extended_bin": null, "card_exp_month": "01", "card_exp_year": "2026", "card_holder_name": "John Smith", "payment_checks": { "avs_description": null, "avs_result_code": "", "cvv_2_reply_code": "", "cvv_2_description": null, "merchant_advice_code": "", "merchant_advice_code_description": null }, "authentication_data": { "challengePreferenceReason": "12" } }, "billing": null }, "payment_token": "token_7PrpuuSVcta1g2qFHYtC", "shipping": null, "billing": { "address": { "city": "Fasdf", "country": "US", "line1": "Fasdf", "line2": "Fasdf", "line3": null, "zip": "560095", "state": null, "first_name": "Sakil", "last_name": "Mostak", "origin_zip": null }, "phone": null, "email": "nithin@gmail.com" }, "order_details": null, "email": "hello@gmail.com", "name": null, "phone": null, "return_url": "https://www.google.com/", "authentication_type": "no_three_ds", "statement_descriptor_name": null, "statement_descriptor_suffix": null, "next_action": null, "cancellation_reason": null, "error_code": null, "error_message": null, "unified_code": null, "unified_message": null, "payment_experience": null, "payment_method_type": "credit", "connector_label": null, "business_country": null, "business_label": "default", "business_sub_label": null, "allowed_payment_method_types": null, "ephemeral_key": { "customer_id": "nithxxinn", "created_at": 1755595277, "expires": 1755598877, "secret": "epk_8003507abbdb427788e1fa089e75c59c" }, "manual_retry_allowed": false, "connector_transaction_id": "8110000000012656330", "frm_message": null, "metadata": null, "connector_metadata": null, "feature_metadata": { "redirect_response": null, "search_tags": null, "apple_pay_recurring_details": null, "gateway_system": "direct" }, "reference_id": "8029726111", "payment_link": null, "profile_id": "pro_o6xLMNfkFwAWH1U1zimF", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_8DFDwR4GryN3qQQOh8bq", "incremental_authorization_allowed": false, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2025-08-19T09:36:17.091Z", "fingerprint": null, "browser_info": { "language": "en-US", "time_zone": 330, "ip_address": "192.168.1.1", "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36", "color_depth": 24, "java_enabled": false, "screen_width": 1920, "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8", "screen_height": 1080, "java_script_enabled": true }, "payment_channel": null, "payment_method_id": null, "network_transaction_id": null, "payment_method_status": null, "updated": "2025-08-19T09:21:19.648Z", "split_payments": null, "frm_metadata": null, "extended_authorization_applied": null, "capture_before": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": null, "card_discovery": "manual", "force_3ds_challenge": false, "force_3ds_challenge_trigger": false, "issuer_error_code": null, "issuer_error_message": null, "is_iframe_redirection_enabled": null, "whole_connector_response": null, "enable_partial_authorization": true } ``` ## partial-auth manual payment response ```json { "payment_id": "pay_t82V58k4cohYq87gBvGL", "merchant_id": "merchant_1755675958", "status": "partially_authorized_and_requires_capture", "amount": 300, "net_amount": 300, "shipping_cost": null, "amount_capturable": 150, "amount_received": null, "connector": "nuvei", "client_secret": "pay_t82V58k4cohYq87gBvGL_secret_CHN75ZbLuZWVBKYTITqg", "created": "2025-08-21T08:37:13.180Z", "currency": "EUR", "customer_id": "nithxxinn", "customer": { "id": "nithxxinn", "name": null, "email": "hello@gmail.com", "phone": null, "phone_country_code": null }, "description": "hellow world", "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": null, "off_session": null, "capture_on": null, "capture_method": "manual", "payment_method": "card", "payment_method_data": { "card": { "last4": "7394", "card_type": null, "card_network": null, "card_issuer": null, "card_issuing_country": null, "card_isin": "453173", "card_extended_bin": null, "card_exp_month": "01", "card_exp_year": "2026", "card_holder_name": "John Smith", "payment_checks": { "avs_description": null, "avs_result_code": "", "cvv_2_reply_code": "", "cvv_2_description": null, "merchant_advice_code": "", "merchant_advice_code_description": null }, "authentication_data": { "challengePreferenceReason": "12" } }, "billing": null }, "payment_token": "token_yUVtqVsfxyKqmAM4fl1H", "shipping": null, "billing": { "address": { "city": "Fasdf", "country": "US", "line1": "Fasdf", "line2": "Fasdf", "line3": null, "zip": "560095", "state": null, "first_name": "Sakil", "last_name": "Mostak", "origin_zip": null }, "phone": null, "email": null }, "order_details": null, "email": "hello@gmail.com", "name": null, "phone": null, "return_url": "https://www.google.com/", "authentication_type": "no_three_ds", "statement_descriptor_name": null, "statement_descriptor_suffix": null, "next_action": null, "cancellation_reason": null, "error_code": null, "error_message": null, "unified_code": null, "unified_message": null, "payment_experience": null, "payment_method_type": "credit", "connector_label": null, "business_country": null, "business_label": "default", "business_sub_label": null, "allowed_payment_method_types": null, "ephemeral_key": { "customer_id": "nithxxinn", "created_at": 1755765433, "expires": 1755769033, "secret": "epk_c7ea65af285e4db69a3bd6fbcb553bf4" }, "manual_retry_allowed": false, "connector_transaction_id": "8110000000012833076", "frm_message": null, "metadata": null, "connector_metadata": null, "feature_metadata": { "redirect_response": null, "search_tags": null, "apple_pay_recurring_details": null, "gateway_system": "direct" }, "reference_id": "8101170111", "payment_link": null, "profile_id": "pro_8OqPL5PekR8mRXU8WZZs", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_48b4pLXImpTC9wJALk91", "incremental_authorization_allowed": false, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2025-08-21T08:52:13.180Z", "fingerprint": null, "browser_info": { "language": "en-US", "time_zone": 330, "ip_address": "192.168.1.1", "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36", "color_depth": 24, "java_enabled": false, "screen_width": 1920, "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8", "screen_height": 1080, "java_script_enabled": true }, "payment_channel": null, "payment_method_id": null, "network_transaction_id": null, "payment_method_status": null, "updated": "2025-08-21T08:37:15.983Z", "split_payments": null, "frm_metadata": null, "extended_authorization_applied": null, "capture_before": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": null, "card_discovery": "manual", "force_3ds_challenge": false, "force_3ds_challenge_trigger": false, "issuer_error_code": null, "issuer_error_message": null, "is_iframe_redirection_enabled": null, "whole_connector_response": null, "enable_partial_authorization": true } ```
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/nuvei.rs` - `crates/hyperswitch_connectors/src/connectors/nuvei/transformers.rs` - `crates/router/src/types/api/connector_mapping.rs` - ... and 1 more files **2. Type Definitions** - `crates/router/src/types/api/feature_matrix.rs` **Code Patterns Applied:** - Define new data structures (9 changes) - Implement new functions (14 changes) - Extend existing types with new fields (164 changes) - Add conditional logic for feature flags or filtering (3 changes) **Detailed Identifier Changes:** Commit 049e6b57: Files to modify: **crates/hyperswitch_connectors/src/connectors/nuvei.rs** Remove: - struct: pub::Nuvei Add: - function: pub::new - struct: pub::Nuvei - impl: impl Nuvei **crates/hyperswitch_connectors/src/connectors/nuvei/transformers.rs** Add: - function: private::get_is_partial_approval - function: private::get_minor_amount_required - function: private::get_is_partial_approval - function: private::from - function: private::from - struct: pub::ShippingAddress - struct: private::GooglePayCamelCase - struct: private::GooglePayInfoCamelCase - struct: private::GooglePayAssuranceDetailsCamelCase - struct: private::GooglePayTokenizationDataCamelCase - struct: private::ApplePayCamelCase - struct: private::ApplePayPaymentMethodCamelCase - enum: pub::PartialApprovalFlag - impl: impl From<bool> for PartialApprovalFlag - impl: impl From<&Address> for ShippingAddress **crates/router/src/types/api/connector_mapping.rs** Modify existing code **crates/router/src/types/api/feature_matrix.rs** Modify existing code **crates/router/tests/connectors/nuvei.rs** Modify existing code
{"pr_number": 8985, "pr_title": "feat(nuvei): Googlepay , applepay and partial authorization integration for nuvei", "merged_at": "2025-08-22T12:06:10Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/src/connectors/nuvei.rs", "crates/hyperswitch_connectors/src/connectors/nuvei/transformers.rs", "crates/router/src/types/api/connector_mapping.rs", "crates/router/tests/connectors/nuvei.rs"], "types": ["crates/router/src/types/api/feature_matrix.rs"]}, "change_types": {"structs_added": 9, "functions_added": 14, "enums_added": 1, "fields_added": 164, "imports_added": 2, "conditionals_added": 3}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail -->
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/subscription.rs` **2. Database Layer (Queries & Schema)** - `crates/diesel_models/src/invoice.rs` **3. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/business_profile.rs` - `crates/hyperswitch_domain_models/src/errors/api_error_response.rs` - `crates/hyperswitch_domain_models/src/router_data_v2/flow_common_types.rs` - ... and 1 more files **4. Core Business Logic** - `crates/router/src/core/subscription.rs` **5. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/chargebee.rs` - `crates/hyperswitch_connectors/src/connectors/chargebee/transformers.rs` - `crates/hyperswitch_connectors/src/connectors/recurly.rs` - ... and 3 more files **6. Type Definitions** - `crates/router_env/src/logger/types.rs` **7. Utils** - `crates/router/src/routes/lock_utils.rs` **8. Other** - `crates/hyperswitch_interfaces/src/api/subscriptions_v2.rs` - `crates/hyperswitch_interfaces/src/conversion_impls.rs` - `crates/router/src/compatibility/stripe/errors.rs` - ... and 2 more files **Code Patterns Applied:** - Define new data structures (13 changes) - Implement new functions (19 changes) - Extend existing types with new fields (213 changes) - Add conditional logic for feature flags or filtering (2 changes) - Modify database queries (1 changes) **Detailed Identifier Changes:** Commit f02d1803: Files to modify: **crates/api_models/src/subscription.rs** Add: - function: pub::get_item_price_id - function: pub::get_billing_address - struct: pub::PaymentDetails - struct: pub::PaymentResponseData - struct: pub::ConfirmSubscriptionRequest - struct: pub::ConfirmSubscriptionResponse - struct: pub::Invoice - impl: impl ConfirmSubscriptionRequest - impl: impl ApiEventMetric for ConfirmSubscriptionRequest - impl: impl ApiEventMetric for ConfirmSubscriptionResponse **crates/diesel_models/src/invoice.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/chargebee.rs** Add: - impl: impl ConnectorIntegrationV2< CreateConnectorCustomer, SubscriptionCustomerData, ConnectorCustomerData, PaymentsResponseData, > for Chargebee **crates/hyperswitch_connectors/src/connectors/chargebee/transformers.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/recurly.rs** Add: - impl: impl api::subscriptions_v2::SubscriptionConnectorCustomerV2 for Recurly - impl: impl ConnectorIntegrationV2< CreateConnectorCustomer, SubscriptionCustomerData, ConnectorCustomerData, PaymentsResponseData, > for Recurly **crates/hyperswitch_domain_models/src/business_profile.rs** Add: - function: pub::get_billing_processor_id **crates/hyperswitch_domain_models/src/errors/api_error_response.rs** Modify existing code **crates/hyperswitch_domain_models/src/router_data_v2/flow_common_types.rs** Remove: - struct: pub::SubscriptionCreateData - struct: pub::GetSubscriptionPlansData - struct: pub::GetSubscriptionPlanPricesData Add: - struct: pub::SubscriptionCustomerData - struct: pub::SubscriptionCreateData - struct: pub::GetSubscriptionPlansData - struct: pub::GetSubscriptionPlanPricesData **crates/hyperswitch_domain_models/src/router_response_types/subscriptions.rs** Add: - function: private::from - impl: impl From<SubscriptionStatus> for api_models::subscription::SubscriptionStatus **crates/hyperswitch_interfaces/src/api/subscriptions_v2.rs** Add: - trait: private::SubscriptionConnectorCustomerV2 **crates/hyperswitch_interfaces/src/conversion_impls.rs** Modify existing code **crates/router/src/compatibility/stripe/errors.rs** Modify existing code **crates/router/src/core/subscription.rs** Add: - function: pub::confirm_subscription - function: pub::new - function: pub::find_subscription - function: private::generate_response - function: private::update_subscription_status - function: pub::get_billing_handler - function: pub::get_invoice_handler - function: pub::create_invoice_entry - function: pub::create_cit_payment - function: pub::create_invoice_record_back_job - function: pub::create_customer_on_connector - function: pub::create_subscription_on_connector - function: private::call_connector - function: private::build_router_data - struct: pub::SubscriptionHandler - struct: pub::SubscriptionWithHandler - struct: pub::BillingHandler - struct: pub::InvoiceHandler - impl: impl SubscriptionHandler - impl: impl SubscriptionWithHandler<'a> - impl: impl InvoiceHandler - impl: impl BillingHandler **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/lock_utils.rs** Modify existing code **crates/router/src/routes/subscription.rs** Add: - function: pub::confirm_subscription **crates/router/tests/connectors/utils.rs** Modify existing code **crates/router_env/src/logger/types.rs** Modify existing code
{"pr_number": 9353, "pr_title": "feat(subscriptions): Add Subscription confirm handler", "merged_at": "2025-09-25T16:22:29Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/subscription.rs"], "database": ["crates/diesel_models/src/invoice.rs"], "domain": ["crates/hyperswitch_domain_models/src/business_profile.rs", "crates/hyperswitch_domain_models/src/errors/api_error_response.rs", "crates/hyperswitch_domain_models/src/router_data_v2/flow_common_types.rs", "crates/hyperswitch_domain_models/src/router_response_types/subscriptions.rs"], "core_business": ["crates/router/src/core/subscription.rs"], "connectors": ["crates/hyperswitch_connectors/src/connectors/chargebee.rs", "crates/hyperswitch_connectors/src/connectors/chargebee/transformers.rs", "crates/hyperswitch_connectors/src/connectors/recurly.rs", "crates/router/tests/connectors/utils.rs", "migrations/2025-09-23-112547_add_billing_processor_in_connector_type/down.sql", "migrations/2025-09-23-112547_add_billing_processor_in_connector_type/up.sql"], "types": ["crates/router_env/src/logger/types.rs"], "utils": ["crates/router/src/routes/lock_utils.rs"], "other": ["crates/hyperswitch_interfaces/src/api/subscriptions_v2.rs", "crates/hyperswitch_interfaces/src/conversion_impls.rs", "crates/router/src/compatibility/stripe/errors.rs", "crates/router/src/routes/app.rs", "crates/router/src/routes/subscription.rs"]}, "change_types": {"structs_added": 13, "functions_added": 19, "fields_added": 213, "imports_added": 8, "conditionals_added": 2, "database_queries": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Earlier a connector was occurring twice while doing a session token call for wallets. This PR fixes merchant payment method list to retain a mca based on connector_name and mca_id. So that with every distinct mca_id the connector is listed just once for wallets.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/payment_methods.rs` **2. Core Business Logic** - `crates/router/src/core/payment_methods/cards.rs` - `crates/router/src/core/payments.rs` **Code Patterns Applied:** - Extend existing types with new fields (2 changes) - Add conditional logic for feature flags or filtering (1 changes) **Detailed Identifier Changes:** Commit 842c4a2f: Files to modify: **crates/api_models/src/payment_methods.rs** Modify existing code **crates/router/src/core/payment_methods/cards.rs** Modify existing code **crates/router/src/core/payments.rs** Modify existing code
{"pr_number": 6408, "pr_title": "fix(payment_methods): fix merchant payment method list to retain a mca based on connector_name and mca_id", "merged_at": "2024-10-24T15:05:19Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/payment_methods.rs"], "core_business": ["crates/router/src/core/payment_methods/cards.rs", "crates/router/src/core/payments.rs"]}, "change_types": {"fields_added": 2, "conditionals_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> reordered v2 migrations folders. * All misplaced v2 migrations are moved to `v2_compatible_migrations` directory. * Removed `Add not null` constraints to newly added v2 columns. * `v2_migrations` directory will only contain queries for dropping deprecated v1 columns and tables. And queries to update primary_key constraints on v2 columns. This set of migration will only be run after v1 is deprecated.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Database Layer (Queries & Schema)** - `crates/diesel_models/src/business_profile.rs` - `crates/diesel_models/src/customers.rs` - `crates/diesel_models/src/lib.rs` - ... and 5 more files **2. External Connector Integration** - `v2_migrations/2025-02-24-053820_add_billing_processor_value_to_connector_type_enum/down.sql` - `v2_migrations/2025-02-24-053820_add_billing_processor_value_to_connector_type_enum/up.sql` - `v2_migrations/2025-05-30-103514_add_connector_request_reference_id_in_payment_attempt/down.sql` - ... and 1 more files **3. Other** - `crates/common_enums/src/enums.rs` - `v2_migrations/2025-01-17-042122_add_feature_metadata_in_payment_attempt/down.sql` - `v2_migrations/2025-01-17-042122_add_feature_metadata_in_payment_attempt/up.sql` - ... and 21 more files **Code Patterns Applied:** - Define new data structures (3 changes) - Implement new functions (6 changes) - Extend existing types with new fields (41 changes) - Modify database queries (2 changes) **Detailed Identifier Changes:** Commit c573f611: Files to modify: **crates/common_enums/src/enums.rs** Modify existing code **crates/diesel_models/src/business_profile.rs** Modify existing code **crates/diesel_models/src/customers.rs** Modify existing code **crates/diesel_models/src/lib.rs** Add: - function: pub::into_inner - function: private::build - function: pub::into_inner - function: private::build - struct: pub::RequiredFromNullable - struct: pub::RequiredFromNullableWithDefault - impl: impl RequiredFromNullable<T> - impl: impl Queryable<Nullable<ST>, DB> for RequiredFromNullable<T> - impl: impl RequiredFromNullableWithDefault<T> - impl: impl Queryable<Nullable<ST>, DB> for RequiredFromNullableWithDefault<T> **crates/diesel_models/src/merchant_connector_account.rs** Modify existing code **crates/diesel_models/src/payment_attempt.rs** Modify existing code **crates/diesel_models/src/payment_intent.rs** Modify existing code **crates/diesel_models/src/refund.rs** Modify existing code **crates/diesel_models/src/schema_v2.rs** Modify existing code
{"pr_number": 8671, "pr_title": "chore: reorder v2 migrations folders", "merged_at": "2025-08-05T08:25:35Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"database": ["crates/diesel_models/src/business_profile.rs", "crates/diesel_models/src/customers.rs", "crates/diesel_models/src/lib.rs", "crates/diesel_models/src/merchant_connector_account.rs", "crates/diesel_models/src/payment_attempt.rs", "crates/diesel_models/src/payment_intent.rs", "crates/diesel_models/src/refund.rs", "crates/diesel_models/src/schema_v2.rs"], "connectors": ["v2_migrations/2025-02-24-053820_add_billing_processor_value_to_connector_type_enum/down.sql", "v2_migrations/2025-02-24-053820_add_billing_processor_value_to_connector_type_enum/up.sql", "v2_migrations/2025-05-30-103514_add_connector_request_reference_id_in_payment_attempt/down.sql", "v2_migrations/2025-05-30-103514_add_connector_request_reference_id_in_payment_attempt/up.sql"], "other": ["crates/common_enums/src/enums.rs", "v2_migrations/2025-01-17-042122_add_feature_metadata_in_payment_attempt/down.sql", "v2_migrations/2025-01-17-042122_add_feature_metadata_in_payment_attempt/up.sql", "v2_compatible_migrations/2025-02-10-101458_create_index_payment_attempt_payment_id/down.sql", "v2_migrations/2025-02-10-101458_create_index_payment_attempt_payment_id/up.sql", "v2_migrations/2025-03-19-080705_payment-method-subtype-optional/down.sql", "v2_migrations/2025-03-19-080705_payment-method-subtype-optional/up.sql", "v2_migrations/2025-03-25-074512_payment-method-subtype-mandatory/down.sql", "v2_migrations/2025-03-25-074512_payment-method-subtype-mandatory/up.sql", "v2_migrations/2025-04-02-051959_add_network_error_info_in_payment_attempt/down.sql", "v2_migrations/2025-04-02-051959_add_network_error_info_in_payment_attempt/up.sql", "v2_migrations/2025-04-08-101702_add_recovery_algorithm_column_in_business_profile/down.sql", "v2_migrations/2025-04-08-101702_add_recovery_algorithm_column_in_business_profile/up.sql", "v2_migrations/2025-04-25-105138_tokenization_service_creation/down.sql", "v2_migrations/2025-04-25-105138_tokenization_service_creation/up.sql", "v2_compatible_migrations/2025-07-16-035805_add_index_on_mca_for_profile_id/down.sql", "v2_compatible_migrations/2025-07-16-035805_add_index_on_mca_for_profile_id/up.sql", "v2_migrations/2024-08-28-081837_add_not_null_constraints_to_v2_columns/down.sql", "v2_migrations/2024-08-28-081837_add_not_null_constraints_to_v2_columns/up.sql", "v2_migrations/2024-08-28-081838_update_v2_primary_key_constraints/down.sql", "v2_migrations/2024-08-28-081838_update_v2_primary_key_constraints/up.sql", "v2_migrations/2025-01-13-081847_drop_v1_columns/down.sql", "v2_migrations/2025-01-13-081847_drop_v1_columns/up.sql", "v2_migrations/2025-02-10-101458_create_index_payment_attempt_payment_id/down.sql"]}, "change_types": {"structs_added": 3, "functions_added": 6, "fields_added": 41, "imports_added": 8, "database_queries": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Return redacted customer response instead of error when querying deleted customers. ## Motivation and Context Upon merging this PR, the API will return deleted Customer with redacted values instead of error. https://github.com/juspay/hyperswitch/issues/7126 ## How did you test it? - Create Customer API Call ``` curl --location 'http://localhost:8080/customers' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --data-raw '{ "email": "guest@example.com", "name": "John Doe", "phone": "999999999", "phone_country_code": "+65", "description": "First customer", "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "joseph", "last_name": "Doe" }, "metadata": { "udf1": "value1", "new_customer": "true", "login_date": "2019-09-10T10:11:12Z" } }' ``` - Delete API Call for same customer ``` curl --location --request DELETE 'http://localhost:8080/customers/cus_vl2xIM4vJGaOVanI9rLl' \ --header 'Accept: application/json' \ --header 'api-key: *****' ``` - Retrieve Customer API call for the same customer ``` curl --location 'http://localhost:8080/customers/cus_PEkI9z16lQRq2xAXOol5' \ --header 'Accept: application/json' \ --header 'api-key: dev_CN6BIH4qBtQTtH3smdKKJEwcyuaxiQgu9Yv6houFWmaOmgjhLtSNOGFLEDagthEZ' ``` - Response from the above API Call ``` {"customer_id":"cus_PEkI9z16lQRq2xAXOol5","name":"Redacted","email":"Redacted","phone":"Redacted","phone_country_code":"Redacted","description":"Redacted","address":{"city":"Redacted","country":"US","line1":"Redacted","line2":"Redacted","line3":"Redacted","zip":"Redacted","state":"Redacted","first_name":"Redacted","last_name":"Redacted"},"created_at":"2025-01-28T07:15:35.740Z","metadata":{"udf1":"value1","new_customer":"true","login_date":"2019-09-10T10:11:12Z"},"default_payment_method_id":null} ``` ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt --all` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed the submitted code - [ ] I added unit tests for my changes where possible
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/router/src/core/customers.rs` **Detailed Identifier Changes:** Commit 97e9270e: Files to modify: **crates/router/src/core/customers.rs** Modify existing code
{"pr_number": 7122, "pr_title": "refactor(customer): return redacted customer instead of error", "merged_at": "2025-02-06T15:04:45Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment"]}, "hierarchy": {"core_business": ["crates/router/src/core/customers.rs"]}, "change_types": {}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Main pr - https://github.com/juspay/hyperswitch/pull/7004
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/router/src/core/payment_methods/cards.rs` **Detailed Identifier Changes:** Commit df67b9d7: Files to modify: **crates/router/src/core/payment_methods/cards.rs** Modify existing code
{"pr_number": 7012, "pr_title": "fix: consider status of payment method before filtering wallets in list pm", "merged_at": "2025-01-09T07:49:41Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"core_business": ["crates/router/src/core/payment_methods/cards.rs"]}, "change_types": {}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> - Added RoutingApproach column in Payment attempt - Added RoutingApproach as a filter and dimension in payment analytics - Added routing metric endpoints DB queries - ```sql CREATE TYPE "RoutingApproach" AS ENUM ( 'success_rate_exploitation', 'success_rate_exploration', 'contract_based_routing', 'debit_routing', 'rule_based_routing', 'volume_based_routing', 'default_fallback' ); ALTER TABLE payment_attempt ADD COLUMN IF NOT EXISTS routing_approach "RoutingApproach"; ```
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/analytics/payments.rs` **2. Database Layer (Queries & Schema)** - `crates/analytics/src/query.rs` - `crates/diesel_models/src/enums.rs` - `crates/diesel_models/src/payment_attempt.rs` - ... and 2 more files **3. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/payments/payment_attempt.rs` **4. Core Business Logic** - `crates/analytics/src/core.rs` - `crates/analytics/src/payments/core.rs` - `crates/router/src/core/debit_routing.rs` - ... and 8 more files **5. External Connector Integration** - `crates/analytics/src/payments/metrics/connector_success_rate.rs` - `crates/analytics/src/payments/metrics/sessionized_metrics/connector_success_rate.rs` **6. Type Definitions** - `crates/analytics/src/payments/types.rs` - `crates/analytics/src/types.rs` - `crates/router/src/types/storage/payment_attempt.rs` **7. Utils** - `crates/analytics/src/utils.rs` - `crates/router/src/utils/user/sample_data.rs` **8. Other** - `crates/analytics/docs/clickhouse/scripts/payment_attempts.sql` - `crates/analytics/src/payments/distribution.rs` - `crates/analytics/src/payments/distribution/payment_error_message.rs` - ... and 26 more files **Code Patterns Applied:** - Implement new functions (14 changes) - Extend existing types with new fields (87 changes) - Add conditional logic for feature flags or filtering (2 changes) - Modify database queries (3 changes) **Detailed Identifier Changes:** Commit a3cc44c6: Files to modify: **crates/analytics/src/core.rs** Modify existing code **crates/analytics/src/payments/core.rs** Modify existing code **crates/analytics/src/payments/distribution.rs** Modify existing code **crates/analytics/src/payments/distribution/payment_error_message.rs** Modify existing code **crates/analytics/src/payments/filters.rs** Modify existing code **crates/analytics/src/payments/metrics.rs** Modify existing code **crates/analytics/src/payments/metrics/avg_ticket_size.rs** Modify existing code **crates/analytics/src/payments/metrics/connector_success_rate.rs** Modify existing code **crates/analytics/src/payments/metrics/payment_count.rs** Modify existing code **crates/analytics/src/payments/metrics/payment_processed_amount.rs** Modify existing code **crates/analytics/src/payments/metrics/payment_success_count.rs** Modify existing code **crates/analytics/src/payments/metrics/retries_count.rs** Modify existing code **crates/analytics/src/payments/metrics/sessionized_metrics/avg_ticket_size.rs** Modify existing code **crates/analytics/src/payments/metrics/sessionized_metrics/connector_success_rate.rs** Modify existing code **crates/analytics/src/payments/metrics/sessionized_metrics/failure_reasons.rs** Modify existing code **crates/analytics/src/payments/metrics/sessionized_metrics/payment_count.rs** Modify existing code **crates/analytics/src/payments/metrics/sessionized_metrics/payment_processed_amount.rs** Modify existing code **crates/analytics/src/payments/metrics/sessionized_metrics/payment_success_count.rs** Modify existing code **crates/analytics/src/payments/metrics/sessionized_metrics/payments_distribution.rs** Modify existing code **crates/analytics/src/payments/metrics/sessionized_metrics/retries_count.rs** Modify existing code **crates/analytics/src/payments/metrics/sessionized_metrics/success_rate.rs** Modify existing code **crates/analytics/src/payments/metrics/success_rate.rs** Modify existing code **crates/analytics/src/payments/types.rs** Modify existing code **crates/analytics/src/query.rs** Modify existing code **crates/analytics/src/sqlx.rs** Modify existing code **crates/analytics/src/types.rs** Modify existing code **crates/analytics/src/utils.rs** Modify existing code **crates/api_models/src/analytics/payments.rs** Modify existing code **crates/common_enums/src/enums.rs** Add: - function: pub::from_decision_engine_approach - enum: pub::RoutingApproach - impl: impl RoutingApproach **crates/diesel_models/src/enums.rs** Modify existing code **crates/diesel_models/src/payment_attempt.rs** Modify existing code **crates/diesel_models/src/schema.rs** Modify existing code **crates/diesel_models/src/user/sample_data.rs** Modify existing code **crates/hyperswitch_domain_models/src/payments/payment_attempt.rs** Modify existing code **crates/router/src/analytics.rs** Modify existing code **crates/router/src/core/debit_routing.rs** Modify existing code **crates/router/src/core/payments.rs** Add: - function: private::set_routing_approach_in_attempt - function: private::set_routing_approach_in_attempt - function: private::set_routing_approach_in_attempt - function: private::set_routing_approach_in_attempt **crates/router/src/core/payments/helpers.rs** Modify existing code **crates/router/src/core/payments/operations/payment_confirm.rs** Modify existing code **crates/router/src/core/payments/operations/payment_create.rs** Modify existing code **crates/router/src/core/payments/retry.rs** Modify existing code **crates/router/src/core/payments/routing.rs** Modify existing code **crates/router/src/core/payments/routing/utils.rs** Add: - function: private::from - impl: impl From<RoutingApproach> for common_enums::RoutingApproach **crates/router/src/core/routing/helpers.rs** Modify existing code **crates/router/src/services/kafka/payment_attempt.rs** Modify existing code **crates/router/src/services/kafka/payment_attempt_event.rs** Modify existing code **crates/router/src/types/storage/payment_attempt.rs** Modify existing code **crates/router/src/utils/user/sample_data.rs** Modify existing code **crates/storage_impl/src/mock_db/payment_attempt.rs** Modify existing code **crates/storage_impl/src/payments/payment_attempt.rs** Modify existing code
{"pr_number": 8408, "pr_title": "feat(analytics): Add RoutingApproach filter in payment analytics", "merged_at": "2025-06-23T17:55:20Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "merchant", "user"]}, "hierarchy": {"api_models": ["crates/api_models/src/analytics/payments.rs"], "database": ["crates/analytics/src/query.rs", "crates/diesel_models/src/enums.rs", "crates/diesel_models/src/payment_attempt.rs", "crates/diesel_models/src/schema.rs", "crates/diesel_models/src/user/sample_data.rs"], "domain": ["crates/hyperswitch_domain_models/src/payments/payment_attempt.rs"], "core_business": ["crates/analytics/src/core.rs", "crates/analytics/src/payments/core.rs", "crates/router/src/core/debit_routing.rs", "crates/router/src/core/payments.rs", "crates/router/src/core/payments/helpers.rs", "crates/router/src/core/payments/operations/payment_confirm.rs", "crates/router/src/core/payments/operations/payment_create.rs", "crates/router/src/core/payments/retry.rs", "crates/router/src/core/payments/routing.rs", "crates/router/src/core/payments/routing/utils.rs", "crates/router/src/core/routing/helpers.rs"], "connectors": ["crates/analytics/src/payments/metrics/connector_success_rate.rs", "crates/analytics/src/payments/metrics/sessionized_metrics/connector_success_rate.rs"], "types": ["crates/analytics/src/payments/types.rs", "crates/analytics/src/types.rs", "crates/router/src/types/storage/payment_attempt.rs"], "utils": ["crates/analytics/src/utils.rs", "crates/router/src/utils/user/sample_data.rs"], "other": ["crates/analytics/docs/clickhouse/scripts/payment_attempts.sql", "crates/analytics/src/payments/distribution.rs", "crates/analytics/src/payments/distribution/payment_error_message.rs", "crates/analytics/src/payments/filters.rs", "crates/analytics/src/payments/metrics.rs", "crates/analytics/src/payments/metrics/avg_ticket_size.rs", "crates/analytics/src/payments/metrics/payment_count.rs", "crates/analytics/src/payments/metrics/payment_processed_amount.rs", "crates/analytics/src/payments/metrics/payment_success_count.rs", "crates/analytics/src/payments/metrics/retries_count.rs", "crates/analytics/src/payments/metrics/sessionized_metrics/avg_ticket_size.rs", "crates/analytics/src/payments/metrics/sessionized_metrics/failure_reasons.rs", "crates/analytics/src/payments/metrics/sessionized_metrics/payment_count.rs", "crates/analytics/src/payments/metrics/sessionized_metrics/payment_processed_amount.rs", "crates/analytics/src/payments/metrics/sessionized_metrics/payment_success_count.rs", "crates/analytics/src/payments/metrics/sessionized_metrics/payments_distribution.rs", "crates/analytics/src/payments/metrics/sessionized_metrics/retries_count.rs", "crates/analytics/src/payments/metrics/sessionized_metrics/success_rate.rs", "crates/analytics/src/payments/metrics/success_rate.rs", "crates/analytics/src/sqlx.rs", "crates/common_enums/src/enums.rs", "crates/router/src/analytics.rs", "crates/router/src/services/kafka/payment_attempt.rs", "crates/router/src/services/kafka/payment_attempt_event.rs", "crates/storage_impl/src/mock_db/payment_attempt.rs", "crates/storage_impl/src/payments/payment_attempt.rs", "migrations/2025-06-19-124558_add_routing_approach_to_attempt/down.sql", "migrations/2025-06-19-124558_add_routing_approach_to_attempt/up.sql", "v2_migrations/2025-01-13-081847_drop_v1_columns/up.sql"]}, "change_types": {"functions_added": 14, "enums_added": 1, "fields_added": 87, "imports_added": 1, "conditionals_added": 2, "database_queries": 3}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Enhanced Billwerk Connector in cypress for Comprehensive Testing. ## How did you test it? <img width="515" alt="Billwerk" src="https://github.com/user-attachments/assets/feb4d3ec-b263-4143-ba0b-2d5b4db61ea9" /> 1.Savecard flow is not working (on_session & off_session) both throwing no eligible connector error 2.zero auth mandates not throwing an validation error 3.Payment method list is always empty ## Checklist <!-- Put an `x` in the boxes that apply --> - [ ] I formatted the code `cargo +nightly fmt --all` - [ ] I addressed lints thrown by `cargo clippy` - [ ] I reviewed the submitted code - [ ] I added unit tests for my changes where possible
To implement this **payment** feature, you'll need to modify these architectural layers: **1. Tests** - `cypress-tests/cypress/e2e/configs/Payment/Billwerk.js` - `cypress-tests/cypress/e2e/configs/Payment/Utils.js` **Code Patterns Applied:** - Extend existing types with new fields (653 changes)
{"pr_number": 8397, "pr_title": "ci(cypress): Add billwerk connector test in cypress", "merged_at": "2025-06-20T11:28:25Z", "intent": {"feature_type": "payment", "action": "add_feature", "entities": ["payment", "user", "connector"]}, "hierarchy": {"tests": ["cypress-tests/cypress/e2e/configs/Payment/Billwerk.js", "cypress-tests/cypress/e2e/configs/Payment/Utils.js"]}, "change_types": {"fields_added": 653}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
This PR exposes three configurations for payment links 1. `payment_form_header_text` - for rendering a header text for payment links 2. `payment_form_label_type` - for specifying the type of payment form labels (floating / above / never) 3. `show_card_terms` - for controlling visibility of the terms for cards (auto / always / never)
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/admin.rs` - `crates/api_models/src/payments.rs` **2. Database Layer (Queries & Schema)** - `crates/diesel_models/src/business_profile.rs` - `crates/diesel_models/src/payment_intent.rs` **3. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/lib.rs` **4. Core Business Logic** - `crates/router/src/core/payment_link.rs` - `crates/router/src/core/payment_link/payment_link_initiate/payment_link_initiator.js` - `crates/router/src/core/payment_link/payment_link_initiate/secure_payment_link_initiator.js` - ... and 1 more files **5. Type Definitions** - `crates/router/src/types/transformers.rs` **6. Other** - `api-reference-v2/openapi_spec.json` - `api-reference/openapi_spec.json` - `crates/common_enums/src/enums/ui.rs` - ... and 3 more files **Code Patterns Applied:** - Extend existing types with new fields (47 changes) - Add conditional logic for feature flags or filtering (8 changes) **Detailed Identifier Changes:** Commit b475171d: Files to modify: **crates/api_models/src/admin.rs** Modify existing code **crates/api_models/src/payments.rs** Modify existing code **crates/common_enums/src/enums/ui.rs** Add: - enum: pub::PaymentLinkSdkLabelType - enum: pub::PaymentLinkShowSdkTerms **crates/diesel_models/src/business_profile.rs** Modify existing code **crates/diesel_models/src/payment_intent.rs** Modify existing code **crates/hyperswitch_domain_models/src/lib.rs** Modify existing code **crates/openapi/src/openapi.rs** Modify existing code **crates/openapi/src/openapi_v2.rs** Modify existing code **crates/router/src/core/payment_link.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Modify existing code **crates/router/src/routes/customers.rs** Modify existing code **crates/router/src/types/transformers.rs** Modify existing code
{"pr_number": 7742, "pr_title": "feat(payment_link): expose configurations for payment links", "merged_at": "2025-04-09T07:47:51Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/admin.rs", "crates/api_models/src/payments.rs"], "database": ["crates/diesel_models/src/business_profile.rs", "crates/diesel_models/src/payment_intent.rs"], "domain": ["crates/hyperswitch_domain_models/src/lib.rs"], "core_business": ["crates/router/src/core/payment_link.rs", "crates/router/src/core/payment_link/payment_link_initiate/payment_link_initiator.js", "crates/router/src/core/payment_link/payment_link_initiate/secure_payment_link_initiator.js", "crates/router/src/core/payments/transformers.rs"], "types": ["crates/router/src/types/transformers.rs"], "other": ["api-reference-v2/openapi_spec.json", "api-reference/openapi_spec.json", "crates/common_enums/src/enums/ui.rs", "crates/openapi/src/openapi.rs", "crates/openapi/src/openapi_v2.rs", "crates/router/src/routes/customers.rs"]}, "change_types": {"enums_added": 2, "fields_added": 47, "conditionals_added": 8}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> We are removing `merchant_reference_id` from all API updates, due to possible bugs on merchant side db and HS db as there might be mismatch in their's and our's db records. This exists only in customers and refunds v2 apis, a separate PR has been implemented for refunds update, and this PR is for customers v2 update api. It was noticed that in the current implementation of customers v2 update flow, the `merchant_reference_id` field is being accepted by the API but it was never updated in the db. In this PR we are removing `merchant_reference_id` from being accepted in the customers v2 update request.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/customers.rs` **2. Other** - `api-reference-v2/openapi_spec.json` **Detailed Identifier Changes:** Commit d6ad8522: Files to modify: **crates/api_models/src/customers.rs** Remove: - function: pub::get_merchant_reference_id
{"pr_number": 7879, "pr_title": "refactor(customers_v2): Remove merchant reference id from v2 customer update", "merged_at": "2025-06-09T07:54:14Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/customers.rs"], "other": ["api-reference-v2/openapi_spec.json"]}, "change_types": {}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> This pull request introduces significant changes to the Wise connector in the `crates/router` module, focusing on the integration of a new amount conversion utility and refactoring to utilize a new `WiseRouterData` struct. The changes enhance how amounts are handled and improve the overall structure and clarity of the code.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/router/src/connector/wise.rs` - `crates/router/src/connector/wise/transformers.rs` - `crates/router/tests/connectors/wise.rs` **2. Type Definitions** - `crates/router/src/types/api.rs` **Code Patterns Applied:** - Define new data structures (2 changes) - Implement new functions (4 changes) - Extend existing types with new fields (9 changes) **Detailed Identifier Changes:** Commit 1ba3d84d: Files to modify: **crates/router/src/connector/wise.rs** Remove: - struct: pub::Wise Add: - function: pub::new - struct: pub::Wise - impl: impl Wise **crates/router/src/connector/wise/transformers.rs** Add: - function: private::from - struct: pub::WiseRouterData - impl: impl From<(MinorUnit, T)> for WiseRouterData<T> **crates/router/src/types/api.rs** Modify existing code **crates/router/tests/connectors/wise.rs** Modify existing code
{"pr_number": 6469, "pr_title": "refactor(connector): Added amount conversion framework to Wise.", "merged_at": "2024-11-07T07:36:11Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["connector"]}, "hierarchy": {"connectors": ["crates/router/src/connector/wise.rs", "crates/router/src/connector/wise/transformers.rs", "crates/router/tests/connectors/wise.rs"], "types": ["crates/router/src/types/api.rs"]}, "change_types": {"structs_added": 2, "functions_added": 4, "fields_added": 9, "imports_added": 3}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Added support for making the sdk session token call. The following features are not included: 1. Session routing 2. Session surcharge Will be taken up in a different PR.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/events/payment.rs` - `crates/api_models/src/payments.rs` **2. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/merchant_connector_account.rs` - `crates/hyperswitch_domain_models/src/payments.rs` **3. Core Business Logic** - `crates/router/src/core/payments.rs` - `crates/router/src/core/payments/flows/session_flow.rs` - `crates/router/src/core/payments/operations.rs` - ... and 6 more files **4. Type Definitions** - `crates/common_utils/src/types.rs` **5. Utils** - `crates/common_utils/src/macros.rs` **6. Other** - `api-reference-v2/openapi_spec.json` - `crates/router/src/routes/app.rs` - `crates/router/src/routes/payments.rs` **Code Patterns Applied:** - Define new data structures (2 changes) - Implement new functions (32 changes) - Extend existing types with new fields (175 changes) - Add conditional logic for feature flags or filtering (4 changes) - Modify database queries (6 changes) **Detailed Identifier Changes:** Commit 707f48ce: Files to modify: **crates/api_models/src/events/payment.rs** Modify existing code **crates/api_models/src/payments.rs** Add: - struct: pub::PaymentsSessionResponse **crates/common_utils/src/macros.rs** Modify existing code **crates/common_utils/src/types.rs** Modify existing code **crates/hyperswitch_domain_models/src/merchant_connector_account.rs** Remove: - function: pub::new - function: pub::is_merchant_connector_account_id_in_connector_mandate_details - struct: pub::MerchantConnectorAccounts - impl: impl MerchantConnectorAccounts Add: - function: pub::get_metadata - function: pub::get_parsed_payment_methods_enabled **crates/hyperswitch_domain_models/src/payments.rs** Modify existing code **crates/router/src/core/payments.rs** Add: - function: pub::call_multiple_connectors_service - mod: pub::session_operation **crates/router/src/core/payments/flows/session_flow.rs** Modify existing code **crates/router/src/core/payments/operations.rs** Add: - mod: pub::payment_session_intent **crates/router/src/core/payments/operations/payment_create_intent.rs** Modify existing code **crates/router/src/core/payments/operations/payment_get_intent.rs** Modify existing code **crates/router/src/core/payments/operations/payment_response.rs** Modify existing code **crates/router/src/core/payments/operations/payment_session_intent.rs** Add: - function: private::validate_status_for_operation - function: private::to_validate_request - function: private::to_get_tracker - function: private::to_domain - function: private::to_validate_request - function: private::to_get_tracker - function: private::to_domain - function: private::get_trackers - function: private::validate_request - function: private::get_customer_details - function: private::make_pm_data - function: private::perform_routing - function: private::guard_payment_against_blocklist - function: private::from - struct: pub::PaymentSessionIntent - impl: impl ValidateStatusForOperation for PaymentSessionIntent - impl: impl Operation<F, PaymentsSessionRequest> for &PaymentSessionIntent - impl: impl Operation<F, PaymentsSessionRequest> for PaymentSessionIntent - impl: impl GetTracker<F, payments::PaymentIntentData<F>, PaymentsSessionRequest> for PaymentSessionIntent - impl: impl ValidateRequest<F, PaymentsSessionRequest, payments::PaymentIntentData<F>> for PaymentSessionIntent - impl: impl Domain<F, PaymentsSessionRequest, payments::PaymentIntentData<F>> for PaymentSessionIntent - impl: impl From<api_models::enums::PaymentMethodType> for api::GetToken **crates/router/src/core/payments/session_operation.rs** Add: - function: pub::payments_session_core - function: pub::payments_session_operation_core **crates/router/src/core/payments/transformers.rs** Add: - function: pub::construct_payment_router_data_for_sdk_session - function: private::generate_response - impl: impl ToResponse<F, D, Op> for api::PaymentsSessionResponse **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/payments.rs** Add: - function: private::get_locking_input - impl: impl GetLockingInput for payment_types::PaymentsSessionRequest
{"pr_number": 6502, "pr_title": "feat: add support for sdk session call in v2", "merged_at": "2024-11-28T10:28:43Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "merchant", "user"]}, "hierarchy": {"api_models": ["crates/api_models/src/events/payment.rs", "crates/api_models/src/payments.rs"], "domain": ["crates/hyperswitch_domain_models/src/merchant_connector_account.rs", "crates/hyperswitch_domain_models/src/payments.rs"], "core_business": ["crates/router/src/core/payments.rs", "crates/router/src/core/payments/flows/session_flow.rs", "crates/router/src/core/payments/operations.rs", "crates/router/src/core/payments/operations/payment_create_intent.rs", "crates/router/src/core/payments/operations/payment_get_intent.rs", "crates/router/src/core/payments/operations/payment_response.rs", "crates/router/src/core/payments/operations/payment_session_intent.rs", "crates/router/src/core/payments/session_operation.rs", "crates/router/src/core/payments/transformers.rs"], "types": ["crates/common_utils/src/types.rs"], "utils": ["crates/common_utils/src/macros.rs"], "other": ["api-reference-v2/openapi_spec.json", "crates/router/src/routes/app.rs", "crates/router/src/routes/payments.rs"]}, "change_types": {"structs_added": 2, "functions_added": 32, "fields_added": 175, "imports_added": 22, "conditionals_added": 4, "database_queries": 6}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> add `click_to_pay` block in payments sessions response if enabled
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/payments.rs` **2. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/payments.rs` **3. Core Business Logic** - `crates/router/src/core/payments.rs` **4. Other** - `api-reference-v2/openapi_spec.json` - `api-reference/openapi_spec.json` - `crates/openapi/src/openapi.rs` - ... and 2 more files **Code Patterns Applied:** - Define new data structures (2 changes) - Implement new functions (1 changes) - Extend existing types with new fields (34 changes) - Add conditional logic for feature flags or filtering (2 changes) **Detailed Identifier Changes:** Commit 5aa8ea03: Files to modify: **crates/api_models/src/payments.rs** Modify existing code **crates/hyperswitch_domain_models/src/payments.rs** Add: - struct: pub::ClickToPayMetaData **crates/openapi/src/openapi.rs** Modify existing code **crates/openapi/src/openapi_v2.rs** Modify existing code **crates/router/src/consts.rs** Modify existing code **crates/router/src/core/payments.rs** Add: - function: pub::get_session_token_for_click_to_pay
{"pr_number": 6829, "pr_title": "feat(router): add `click_to_pay` block in payments sessions response if enabled", "merged_at": "2024-12-13T11:04:09Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "session"]}, "hierarchy": {"api_models": ["crates/api_models/src/payments.rs"], "domain": ["crates/hyperswitch_domain_models/src/payments.rs"], "core_business": ["crates/router/src/core/payments.rs"], "other": ["api-reference-v2/openapi_spec.json", "api-reference/openapi_spec.json", "crates/openapi/src/openapi.rs", "crates/openapi/src/openapi_v2.rs", "crates/router/src/consts.rs"]}, "change_types": {"structs_added": 2, "functions_added": 1, "fields_added": 34, "imports_added": 3, "conditionals_added": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> resolve spell check fail introduced by the following PR: https://github.com/juspay/hyperswitch/pull/7300
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Configuration Files** - `.typos.toml`
{"pr_number": 7342, "pr_title": "fix(router): resolve spell check for state introduced for ISO representation", "merged_at": "2025-02-24T08:12:39Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"config": [".typos.toml"]}, "change_types": {}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
## Type of Change
To implement this **payment** feature, you'll need to modify these architectural layers: **1. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/router_request_types.rs` - `crates/hyperswitch_domain_models/src/router_response_types.rs` **2. Core Business Logic** - `crates/router/src/core/payments/customers.rs` - `crates/router/src/core/payments/operations/payment_response.rs` **3. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/authorizedotnet/transformers.rs` - `crates/hyperswitch_connectors/src/connectors/chargebee.rs` - `crates/hyperswitch_connectors/src/connectors/chargebee/transformers.rs` - ... and 9 more files **4. Type Definitions** - `crates/hyperswitch_interfaces/src/types.rs` **5. Other** - `crates/hyperswitch_interfaces/src/api/subscriptions.rs` - `crates/hyperswitch_interfaces/src/api/subscriptions_v2.rs` **Code Patterns Applied:** - Define new data structures (4 changes) - Implement new functions (11 changes) - Extend existing types with new fields (61 changes) - Add conditional logic for feature flags or filtering (2 changes) **Detailed Identifier Changes:** Commit e6706187: Files to modify: **crates/hyperswitch_connectors/src/connectors/authorizedotnet/transformers.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/chargebee.rs** Add: - function: private::get_headers - function: private::get_url - function: private::get_content_type - function: private::get_request_body - function: private::build_request - function: private::handle_response - function: private::get_error_response - impl: impl ConnectorCustomer for Chargebee - impl: impl ConnectorIntegration<CreateConnectorCustomer, ConnectorCustomerData, PaymentsResponseData> for Chargebee **crates/hyperswitch_connectors/src/connectors/chargebee/transformers.rs** Add: - function: private::try_from - function: private::try_from - struct: pub::ChargebeeCustomerCreateRequest - struct: pub::ChargebeeCustomerCreateResponse - struct: pub::ChargebeeCustomerDetails - impl: impl TryFrom<&ChargebeeRouterData<&hyperswitch_domain_models::types::ConnectorCustomerRouterData>> for ChargebeeCustomerCreateRequest - impl: impl TryFrom< ResponseRouterData< CreateConnectorCustomer, ChargebeeCustomerCreateResponse, ConnectorCustomerData, PaymentsResponseData, >, > for hyperswitch_domain_models::types::ConnectorCustomerRouterData **crates/hyperswitch_connectors/src/connectors/dwolla.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/facilitapay/transformers.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/gocardless/transformers.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/hyperswitch_vault/transformers.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/stax/transformers.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/stripe/transformers.rs** Modify existing code **crates/hyperswitch_connectors/src/default_implementations.rs** Modify existing code **crates/hyperswitch_domain_models/src/router_request_types.rs** Modify existing code **crates/hyperswitch_domain_models/src/router_response_types.rs** Add: - function: pub::new_with_customer_id - function: pub::new - struct: pub::ConnectorCustomerResponseData - impl: impl ConnectorCustomerResponseData **crates/hyperswitch_interfaces/src/api/subscriptions.rs** Remove: - trait: pub::Subscriptions Add: - trait: pub::Subscriptions - trait: pub::ConnectorCustomer **crates/hyperswitch_interfaces/src/api/subscriptions_v2.rs** Remove: - trait: pub::SubscriptionsV2 Add: - trait: pub::SubscriptionsV2 **crates/hyperswitch_interfaces/src/types.rs** Modify existing code **crates/router/src/core/payments/customers.rs** Modify existing code **crates/router/src/core/payments/operations/payment_response.rs** Modify existing code **crates/router/tests/connectors/stax.rs** Modify existing code **crates/router/tests/connectors/utils.rs** Modify existing code
{"pr_number": 9304, "pr_title": "feat(connector): Create Customer for Chargebee", "merged_at": "2025-09-18T14:29:16Z", "intent": {"feature_type": "payment", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"domain": ["crates/hyperswitch_domain_models/src/router_request_types.rs", "crates/hyperswitch_domain_models/src/router_response_types.rs"], "core_business": ["crates/router/src/core/payments/customers.rs", "crates/router/src/core/payments/operations/payment_response.rs"], "connectors": ["crates/hyperswitch_connectors/src/connectors/authorizedotnet/transformers.rs", "crates/hyperswitch_connectors/src/connectors/chargebee.rs", "crates/hyperswitch_connectors/src/connectors/chargebee/transformers.rs", "crates/hyperswitch_connectors/src/connectors/dwolla.rs", "crates/hyperswitch_connectors/src/connectors/facilitapay/transformers.rs", "crates/hyperswitch_connectors/src/connectors/gocardless/transformers.rs", "crates/hyperswitch_connectors/src/connectors/hyperswitch_vault/transformers.rs", "crates/hyperswitch_connectors/src/connectors/stax/transformers.rs", "crates/hyperswitch_connectors/src/connectors/stripe/transformers.rs", "crates/hyperswitch_connectors/src/default_implementations.rs", "crates/router/tests/connectors/stax.rs", "crates/router/tests/connectors/utils.rs"], "types": ["crates/hyperswitch_interfaces/src/types.rs"], "other": ["crates/hyperswitch_interfaces/src/api/subscriptions.rs", "crates/hyperswitch_interfaces/src/api/subscriptions_v2.rs"]}, "change_types": {"structs_added": 4, "functions_added": 11, "fields_added": 61, "imports_added": 7, "conditionals_added": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
This PR adds an Audit event for the PaymentApprove operation.
To implement this **payment** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/router/src/core/payments/operations/payment_approve.rs` **2. Other** - `crates/router/src/events/audit_events.rs` **Code Patterns Applied:** - Extend existing types with new fields (1 changes) **Detailed Identifier Changes:** Commit 6823418e: Files to modify: **crates/router/src/core/payments/operations/payment_approve.rs** Modify existing code **crates/router/src/events/audit_events.rs** Modify existing code
{"pr_number": 6432, "pr_title": "feat(payments): Add audit events for PaymentApprove update", "merged_at": "2024-11-08T10:20:37Z", "intent": {"feature_type": "payment", "action": "add_feature", "entities": ["payment"]}, "hierarchy": {"core_business": ["crates/router/src/core/payments/operations/payment_approve.rs"], "other": ["crates/router/src/events/audit_events.rs"]}, "change_types": {"fields_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> connector integration template code for chargebee.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/router/src/core/payments/connector_integration_v2_impls.rs` - `crates/router/src/core/payments/flows.rs` **2. External Connector Integration** - `crates/common_enums/src/connector_enums.rs` - `crates/hyperswitch_connectors/src/connectors.rs` - `crates/hyperswitch_connectors/src/connectors/chargebee.rs` - ... and 9 more files **3. Type Definitions** - `crates/router/src/types/api.rs` - `crates/router/src/types/transformers.rs` **4. Tests** - `config/deployments/integration_test.toml` - `loadtest/config/development.toml` **5. Configuration Files** - `config/config.example.toml` - `config/deployments/production.toml` - `config/deployments/sandbox.toml` - ... and 3 more files **Code Patterns Applied:** - Define new data structures (10 changes) - Implement new functions (78 changes) - Extend existing types with new fields (153 changes) **Detailed Identifier Changes:** Commit ad5491f1: Files to modify: **crates/common_enums/src/connector_enums.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors.rs** Add: - mod: pub::chargebee **crates/hyperswitch_connectors/src/connectors/chargebee.rs** Add: - function: pub::new - function: private::build_headers - function: private::id - function: private::get_currency_unit - function: private::common_get_content_type - function: private::base_url - function: private::get_auth_header - function: private::build_error_response - function: private::get_headers - function: private::get_content_type - function: private::get_url - function: private::get_request_body - function: private::build_request - function: private::handle_response - function: private::get_error_response - function: private::get_headers - function: private::get_content_type - function: private::get_url - function: private::build_request - function: private::handle_response - function: private::get_error_response - function: private::get_headers - function: private::get_content_type - function: private::get_url - function: private::get_request_body - function: private::build_request - function: private::handle_response - function: private::get_error_response - function: private::get_headers - function: private::get_content_type - function: private::get_url - function: private::get_request_body - function: private::build_request - function: private::handle_response - function: private::get_error_response - function: private::get_headers - function: private::get_content_type - function: private::get_url - function: private::build_request - function: private::handle_response - function: private::get_error_response - function: private::get_webhook_object_reference_id - function: private::get_webhook_event_type - function: private::get_webhook_resource_object - struct: pub::Chargebee - impl: impl Chargebee - impl: impl api::Payment for Chargebee - impl: impl api::PaymentSession for Chargebee - impl: impl api::ConnectorAccessToken for Chargebee - impl: impl api::MandateSetup for Chargebee - impl: impl api::PaymentAuthorize for Chargebee - impl: impl api::PaymentSync for Chargebee - impl: impl api::PaymentCapture for Chargebee - impl: impl api::PaymentVoid for Chargebee - impl: impl api::Refund for Chargebee - impl: impl api::RefundExecute for Chargebee - impl: impl api::RefundSync for Chargebee - impl: impl api::PaymentToken for Chargebee - impl: impl ConnectorIntegration<PaymentMethodToken, PaymentMethodTokenizationData, PaymentsResponseData> for Chargebee - impl: impl ConnectorCommonExt<Flow, Request, Response> for Chargebee - impl: impl ConnectorCommon for Chargebee - impl: impl ConnectorValidation for Chargebee - impl: impl ConnectorIntegration<Session, PaymentsSessionData, PaymentsResponseData> for Chargebee - impl: impl ConnectorIntegration<AccessTokenAuth, AccessTokenRequestData, AccessToken> for Chargebee - impl: impl ConnectorIntegration<SetupMandate, SetupMandateRequestData, PaymentsResponseData> for Chargebee - impl: impl ConnectorIntegration<Authorize, PaymentsAuthorizeData, PaymentsResponseData> for Chargebee - impl: impl ConnectorIntegration<PSync, PaymentsSyncData, PaymentsResponseData> for Chargebee - impl: impl ConnectorIntegration<Capture, PaymentsCaptureData, PaymentsResponseData> for Chargebee - impl: impl ConnectorIntegration<Void, PaymentsCancelData, PaymentsResponseData> for Chargebee - impl: impl ConnectorIntegration<Execute, RefundsData, RefundsResponseData> for Chargebee - impl: impl ConnectorIntegration<RSync, RefundsData, RefundsResponseData> for Chargebee - impl: impl webhooks::IncomingWebhook for Chargebee - impl: impl ConnectorSpecifications for Chargebee - mod: pub::transformers **crates/hyperswitch_connectors/src/connectors/chargebee/transformers.rs** Add: - function: private::from - function: private::try_from - function: private::try_from - function: private::from - function: private::try_from - function: private::try_from - function: private::from - function: private::try_from - function: private::try_from - struct: pub::ChargebeeRouterData - struct: pub::ChargebeePaymentsRequest - struct: pub::ChargebeeCard - struct: pub::ChargebeeAuthType - struct: pub::ChargebeePaymentsResponse - struct: pub::ChargebeeRefundRequest - struct: pub::RefundResponse - struct: pub::ChargebeeErrorResponse - enum: pub::ChargebeePaymentStatus - enum: pub::RefundStatus - impl: impl From<(StringMinorUnit, T)> for ChargebeeRouterData<T> - impl: impl TryFrom<&ChargebeeRouterData<&PaymentsAuthorizeRouterData>> for ChargebeePaymentsRequest - impl: impl TryFrom<&ConnectorAuthType> for ChargebeeAuthType - impl: impl From<ChargebeePaymentStatus> for common_enums::AttemptStatus - impl: impl TryFrom<ResponseRouterData<F, ChargebeePaymentsResponse, T, PaymentsResponseData>> for RouterData<F, T, PaymentsResponseData> - impl: impl TryFrom<&ChargebeeRouterData<&RefundsRouterData<F>>> for ChargebeeRefundRequest - impl: impl From<RefundStatus> for enums::RefundStatus - impl: impl TryFrom<RefundsResponseRouterData<Execute, RefundResponse>> for RefundsRouterData<Execute> - impl: impl TryFrom<RefundsResponseRouterData<RSync, RefundResponse>> for RefundsRouterData<RSync> **crates/hyperswitch_connectors/src/default_implementations.rs** Modify existing code **crates/hyperswitch_connectors/src/default_implementations_v2.rs** Modify existing code **crates/hyperswitch_interfaces/src/configs.rs** Modify existing code **crates/router/src/connector.rs** Modify existing code **crates/router/src/core/payments/connector_integration_v2_impls.rs** Modify existing code **crates/router/src/core/payments/flows.rs** Modify existing code **crates/router/src/types/api.rs** Modify existing code **crates/router/src/types/transformers.rs** Modify existing code **crates/router/tests/connectors/chargebee.rs** Add: - function: private::get_data - function: private::get_auth_token - function: private::get_name - function: private::get_default_payment_info - function: private::payment_method_details - function: private::should_only_authorize_payment - function: private::should_capture_authorized_payment - function: private::should_partially_capture_authorized_payment - function: private::should_sync_authorized_payment - function: private::should_void_authorized_payment - function: private::should_refund_manually_captured_payment - function: private::should_partially_refund_manually_captured_payment - function: private::should_sync_manually_captured_refund - function: private::should_make_payment - function: private::should_sync_auto_captured_payment - function: private::should_refund_auto_captured_payment - function: private::should_partially_refund_succeeded_payment - function: private::should_refund_succeeded_payment_multiple_times - function: private::should_sync_refund - function: private::should_fail_payment_for_incorrect_cvc - function: private::should_fail_payment_for_invalid_exp_month - function: private::should_fail_payment_for_incorrect_expiry_year - function: private::should_fail_void_payment_for_auto_capture - function: private::should_fail_capture_for_invalid_payment - function: private::should_fail_for_refund_amount_higher_than_payment_amount - struct: private::ChargebeeTest - impl: impl ConnectorActions for ChargebeeTest - impl: impl utils::Connector for ChargebeeTest **crates/router/tests/connectors/main.rs** Add: - mod: private::chargebee **crates/test_utils/src/connector_auth.rs** Modify existing code
{"pr_number": 7036, "pr_title": "feat(connector): add template code for chargebee", "merged_at": "2025-01-29T11:46:59Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["connector"]}, "hierarchy": {"core_business": ["crates/router/src/core/payments/connector_integration_v2_impls.rs", "crates/router/src/core/payments/flows.rs"], "connectors": ["crates/common_enums/src/connector_enums.rs", "crates/hyperswitch_connectors/src/connectors.rs", "crates/hyperswitch_connectors/src/connectors/chargebee.rs", "crates/hyperswitch_connectors/src/connectors/chargebee/transformers.rs", "crates/hyperswitch_connectors/src/default_implementations.rs", "crates/hyperswitch_connectors/src/default_implementations_v2.rs", "crates/router/src/connector.rs", "crates/router/tests/connectors/chargebee.rs", "crates/router/tests/connectors/main.rs", "crates/router/tests/connectors/sample_auth.toml", "crates/test_utils/src/connector_auth.rs", "scripts/add_connector.sh"], "types": ["crates/router/src/types/api.rs", "crates/router/src/types/transformers.rs"], "tests": ["config/deployments/integration_test.toml", "loadtest/config/development.toml"], "config": ["config/config.example.toml", "config/deployments/production.toml", "config/deployments/sandbox.toml", "config/development.toml", "config/docker_compose.toml", "crates/hyperswitch_interfaces/src/configs.rs"]}, "change_types": {"structs_added": 10, "functions_added": 78, "enums_added": 2, "fields_added": 153, "imports_added": 20}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail -->
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/user_role.rs` **2. Core Business Logic** - `crates/router/src/core/user_role.rs` **3. External Connector Integration** - `crates/router/src/routes/connector_onboarding.rs` - `crates/router/src/routes/verify_connector.rs` **4. Other** - `crates/common_enums/src/enums.rs` - `crates/router/src/analytics.rs` - `crates/router/src/routes/admin.rs` - ... and 25 more files **Code Patterns Applied:** - Define new data structures (2 changes) - Implement new functions (22 changes) - Extend existing types with new fields (259 changes) **Detailed Identifier Changes:** Commit 4a0afb82: Files to modify: **crates/api_models/src/user_role.rs** Remove: - enum: pub::ParentGroup **crates/common_enums/src/enums.rs** Add: - enum: pub::ParentGroup - enum: pub::Resource - enum: pub::PermissionScope **crates/router/src/analytics.rs** Modify existing code **crates/router/src/core/user_role.rs** Modify existing code **crates/router/src/routes/admin.rs** Modify existing code **crates/router/src/routes/api_keys.rs** Modify existing code **crates/router/src/routes/blocklist.rs** Modify existing code **crates/router/src/routes/connector_onboarding.rs** Modify existing code **crates/router/src/routes/customers.rs** Modify existing code **crates/router/src/routes/disputes.rs** Modify existing code **crates/router/src/routes/mandates.rs** Modify existing code **crates/router/src/routes/payment_methods.rs** Modify existing code **crates/router/src/routes/payments.rs** Modify existing code **crates/router/src/routes/payouts.rs** Modify existing code **crates/router/src/routes/profiles.rs** Modify existing code **crates/router/src/routes/recon.rs** Modify existing code **crates/router/src/routes/refunds.rs** Modify existing code **crates/router/src/routes/routing.rs** Modify existing code **crates/router/src/routes/user.rs** Modify existing code **crates/router/src/routes/user_role.rs** Modify existing code **crates/router/src/routes/verification.rs** Modify existing code **crates/router/src/routes/verify_connector.rs** Modify existing code **crates/router/src/routes/webhook_events.rs** Modify existing code **crates/router/src/services/authentication.rs** Modify existing code **crates/router/src/services/authorization.rs** Remove: - function: pub::check_entity **crates/router/src/services/authorization/info.rs** Modify existing code **crates/router/src/services/authorization/permission_groups.rs** Add: - function: private::scope - function: private::parent - function: private::resources - function: private::accessible_groups - function: private::resources - trait: pub::PermissionGroupExt - trait: pub::ParentGroupExt - impl: impl PermissionGroupExt for PermissionGroup - impl: impl ParentGroupExt for ParentGroup **crates/router/src/services/authorization/permissions.rs** Remove: - enum: pub::Permission **crates/router/src/services/authorization/roles.rs** Modify existing code **crates/router_derive/src/lib.rs** Add: - function: pub::generate_permissions **crates/router_derive/src/macros.rs** Add: - mod: pub::generate_permissions **crates/router_derive/src/macros/generate_permissions.rs** Add: - function: private::parse - function: private::parse - function: private::parse_label_with_punctuated_data - function: pub::generate_permissions_inner - struct: private::ResourceInput - struct: private::Input - impl: impl Parse for Input - impl: impl Parse for ResourceInput
{"pr_number": 6394, "pr_title": "feat(authz): Create a permission generator", "merged_at": "2024-10-24T14:36:07Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "merchant", "user"]}, "hierarchy": {"api_models": ["crates/api_models/src/user_role.rs"], "core_business": ["crates/router/src/core/user_role.rs"], "connectors": ["crates/router/src/routes/connector_onboarding.rs", "crates/router/src/routes/verify_connector.rs"], "other": ["crates/common_enums/src/enums.rs", "crates/router/src/analytics.rs", "crates/router/src/routes/admin.rs", "crates/router/src/routes/api_keys.rs", "crates/router/src/routes/blocklist.rs", "crates/router/src/routes/customers.rs", "crates/router/src/routes/disputes.rs", "crates/router/src/routes/mandates.rs", "crates/router/src/routes/payment_methods.rs", "crates/router/src/routes/payments.rs", "crates/router/src/routes/payouts.rs", "crates/router/src/routes/profiles.rs", "crates/router/src/routes/recon.rs", "crates/router/src/routes/refunds.rs", "crates/router/src/routes/routing.rs", "crates/router/src/routes/user.rs", "crates/router/src/routes/user_role.rs", "crates/router/src/routes/verification.rs", "crates/router/src/routes/webhook_events.rs", "crates/router/src/services/authentication.rs", "crates/router/src/services/authorization.rs", "crates/router/src/services/authorization/info.rs", "crates/router/src/services/authorization/permission_groups.rs", "crates/router/src/services/authorization/permissions.rs", "crates/router/src/services/authorization/roles.rs", "crates/router_derive/src/lib.rs", "crates/router_derive/src/macros.rs", "crates/router_derive/src/macros/generate_permissions.rs"]}, "change_types": {"structs_added": 2, "functions_added": 22, "enums_added": 4, "fields_added": 259, "imports_added": 16}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> This PR adds the payment methods session endpoints. - Create a payment method session - Retrieve a payment method session - List the payment methods for a payment method session - Update a saved payment method using the payment method session ## Motivation and Context <!-- Why is this change required? What problem does it solve? If it fixes an open issue, please link to the issue here. If you don't have an issue, we'd recommend starting with one first so the PR can focus on the implementation (unless it is an obvious bug or documentation fix that will have little conversation). --> These endpoints are used to list the saved payment methods of the customer and also to add a new payment method. ## How did you test it? <!-- Did you write an integration/unit/API test to verify the code changes? Or did you test this change manually (provide relevant screenshots)? --> - Create a customer ```bash curl --location 'http://localhost:8080/v2/customers' \ --header 'x-profile-id: pro_UrFvAE8xRpWRzWGh4jQl' \ --header 'Content-Type: application/json' \ --header 'api-key: dev_i5uKeLHzSyBhhYevUsPMm27DV5tz6wBrcMAyg9gpCoxUgaSZOLDcOu4dw9FzC7t2' \ --data-raw '{ "merchant_reference_id": "customer_1737964636", "name": "John Doe", "email": "guest@example.com", "phone": "999999999", "phone_country_code": "+65", "description": "First customer", "default_billing_address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "joseph", "last_name": "Doe" }, "default_shipping_address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "joseph", "last_name": "Doe" }, "metadata": { "udf1": "value1", "new_customer": "true", "login_date": "2019-09-10T10:11:12Z" } }' ``` - Create a payment method ( make sure if you are trying it on local, you have the locker setup ) ```bash curl --location 'http://localhost:8080/v2/payment-methods' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'X-Profile-Id: pro_Fk6kw8fzPZmZl2f730zh' \ --header 'api-key: dev_ZNc8i2UIurfLRh1HEc5i2CxOuvzCb26cuNGYHxeWzzuMvod0xIrVT3Kt7y3ieIw9' \ --data '{ "customer_id": "12345_cus_0194abb4c1b277e3a6b45551089cfd9e", "payment_method_type": "card", "payment_method_subtype": "credit", "payment_method_data": { "card": { "card_number": "4242424242424242", "card_exp_month": "02", "card_exp_year": "2025", "card_holder_name": "joseph Doe" } } }' ``` - Create a merchant connector account with some payment methods enabled ```bash curl --location 'http://localhost:8080/v2/connector-accounts' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'x-merchant-id: cloth_seller_F3lF6vY9qhm6CMSpBZli' \ --header 'x-profile-id: pro_Fk6kw8fzPZmZl2f730zh' \ --header 'api-key: test_admin' \ --data '{ "connector_type": "payment_processor", "connector_name": "stripe", "connector_account_details": { "auth_type": "HeaderKey", "api_key": "{{connector_api_key}}" }, "payment_methods_enabled": [ { "payment_method_type": "card", "payment_method_subtypes": [ { "payment_method_subtype": "credit", "payment_experience": null, "card_networks": [ "Visa", "Mastercard" ], "accepted_currencies": null, "accepted_countries": null, "minimum_amount": -1, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": true }, { "payment_method_subtype": "debit", "payment_experience": null, "card_networks": [ "Visa", "Mastercard" ], "accepted_currencies": null, "accepted_countries": null, "minimum_amount": -1, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": true } ] } ], "metadata": { "status_url": "https://2753-2401-4900-1cb8-2ff9-24dd-1ccf-ed12-b464.in.ngrok.io/webhooks/merchant_1678699058/globalpay", "account_name": "transaction_processing", "pricing_type": "fixed_price", "acquirer_bin": "438309", "acquirer_merchant_id": "00002000000" }, "frm_configs": null, "connector_webhook_details": { "merchant_secret": "" }, "profile_id": "pro_Fk6kw8fzPZmZl2f730zh" }' ``` - Create a payment method session for the customer ```bash curl --location 'http://localhost:8080/v2/payment-methods-session' \ --header 'x-profile-id: pro_xRLWRVTRCiA19cUJiISK' \ --header 'Content-Type: application/json' \ --header 'Authorization: api-key=dev_LbbvTZ2wfCGaO83BX3ywPgbenSsjKp2TGjkam9sXoWyDaAHqGCq6AUZKjuk1Ii5T' \ --data-raw '{ "customer_id": "12345_cus_0194bbe7403b72e0a4e1cc604db9ba6f", "billing": { "address": { "first_name": "John", "last_name": "Dough" }, "email": "example@example.com" } }' ``` - Retrieve the payment method session using the payment method session ```bash curl --location 'http://localhost:8080/v2/payment-methods-session/12345_pms_0194bbed44fc7ee1b08c649cdeaf1381' \ --header 'x-profile-id: pro_xRLWRVTRCiA19cUJiISK' \ --header 'Authorization: publishable-key=pk_dev_0156facfc6cd420b8f5146e4b980272f,client-secret=cs_0194bbed44fc7ee1b08c64ae9be8ed9a' ``` - List the payment methods for the session ```bash curl --location 'http://localhost:8080/v2/payment-methods-session/12345_pms_0194bbed44fc7ee1b08c649cdeaf1381/list-payment-methods' \ --header 'x-profile-id: pro_xRLWRVTRCiA19cUJiISK' \ --header 'Authorization: publishable-key=pk_dev_0156facfc6cd420b8f5146e4b980272f,client-secret=cs_0194bbed44fc7ee1b08c64ae9be8ed9a' ``` - Response ```json { "payment_methods_enabled": [ { "payment_method_type": "card", "payment_method_subtype": "credit", "required_fields": [ { "required_field": "payment_method_data.card.card_number", "display_name": "card_number", "field_type": "user_card_number", "value": null }, { "required_field": "payment_method_data.card.card_exp_year", "display_name": "card_exp_year", "field_type": "user_card_expiry_year", "value": null }, { "required_field": "payment_method_data.card.card_cvc", "display_name": "card_cvc", "field_type": "user_card_cvc", "value": null }, { "required_field": "payment_method_data.card.card_exp_month", "display_name": "card_exp_month", "field_type": "user_card_expiry_month", "value": null } ] }, { "payment_method_type": "card", "payment_method_subtype": "debit", "required_fields": [] } ], "customer_payment_methods": [ { "id": "12345_pm_0194abb4d9bc735292e1f5682da787ff", "customer_id": "12345_cus_0194abb4c1b277e3a6b45551089cfd9e", "payment_method_type": "card", "payment_method_subtype": "credit", "recurring_enabled": true, "payment_method_data": { "card": { "issuer_country": null, "last4_digits": "4242", "expiry_month": "02", "expiry_year": "2025", "card_holder_name": "joseph Doe", "card_fingerprint": null, "nick_name": null, "card_network": null, "card_isin": null, "card_issuer": null, "card_type": null, "saved_to_locker": true } }, "bank": null, "created": "2025-01-28T06:59:03.754Z", "requires_cvv": true, "last_used_at": "2025-01-28T06:59:03.754Z", "is_default": false, "billing": null } ] } ``` ## Update the saved payment method, can update only card nickname and card holder name for now. - Using the saved payment method using the payment method session ```bash curl --location --request PUT 'http://localhost:8080/v2/payment-methods-session/12345_pms_0194bbed44fc7ee1b08c649cdeaf1381/update-saved-payment-method' \ --header 'x-profile-id: pro_xRLWRVTRCiA19cUJiISK' \ --header 'Content-Type: application/json' \ --header 'Authorization: publishable-key=pk_dev_0156facfc6cd420b8f5146e4b980272f,client-secret=cs_0194bbed44fc7ee1b08c64ae9be8ed9a' \ --data '{ "payment_method_id": "12345_pm_0194b1ecabc172e28aeb71f70a4daba3", "payment_method_data": { "card": { "card_holder_name": "Narayan Bhat" } } }' ``` - Response ```json { "id": "12345_pm_0194b1ecabc172e28aeb71f70a4daba3", "merchant_id": "cloth_seller_UglVvGAf3zzfNzzt2QMC", "customer_id": "12345_cus_0194b1ec3c0472a2a579e435d24819bc", "payment_method_type": "card", "payment_method_subtype": "credit", "recurring_enabled": false, "created": "2025-01-29T11:57:45.282Z", "last_used_at": "2025-01-29T11:57:45.282Z", "payment_method_data": { "card": { "issuer_country": null, "last4_digits": "4242", "expiry_month": "02", "expiry_year": "2025", "card_holder_name": "Narayan Bhat", "card_fingerprint": null, "nick_name": null, "card_network": null, "card_isin": null, "card_issuer": null, "card_type": null, "saved_to_locker": true } } } ``` ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt --all` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed the submitted code
To implement this **payment** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/customers.rs` - `crates/api_models/src/ephemeral_key.rs` - `crates/api_models/src/events.rs` - ... and 4 more files **2. Database Layer (Queries & Schema)** - `crates/diesel_models/src/customers.rs` - `crates/diesel_models/src/ephemeral_key.rs` - `crates/diesel_models/src/lib.rs` - ... and 1 more files **3. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/customer.rs` - `crates/hyperswitch_domain_models/src/payment_methods.rs` **4. Core Business Logic** - `crates/router/src/core/payment_methods.rs` - `crates/router/src/core/payment_methods/cards.rs` - `crates/router/src/core/payment_methods/surcharge_decision_configs.rs` - ... and 4 more files **5. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/deutschebank.rs` **6. Type Definitions** - `crates/common_types/src/payment_methods.rs` - `crates/common_utils/src/types/authentication.rs` - `crates/router/src/types/storage/ephemeral_key.rs` - ... and 1 more files **7. Utils** - `crates/common_utils/src/crypto.rs` - `crates/common_utils/src/events.rs` - `crates/common_utils/src/id_type.rs` - ... and 5 more files **8. Configuration Files** - `config/development.toml` **9. Other** - `api-reference-v2/api-reference/customers/customers--list-saved-payment-methods.mdx` - `api-reference-v2/api-reference/payment-method-session/payment-method-session--create.mdx` - `api-reference-v2/api-reference/payment-method-session/payment-method-session--list-payment-methods.mdx` - ... and 20 more files **Code Patterns Applied:** - Define new data structures (17 changes) - Implement new functions (77 changes) - Extend existing types with new fields (270 changes) - Add conditional logic for feature flags or filtering (7 changes) **Detailed Identifier Changes:** Commit 96153824: Files to modify: **crates/api_models/src/customers.rs** Modify existing code **crates/api_models/src/ephemeral_key.rs** Remove: - struct: pub::EphemeralKeyCreateRequest Add: - struct: pub::ClientSecretCreateRequest - enum: pub::ResourceId **crates/api_models/src/events.rs** Add: - function: private::get_api_event_type - function: private::get_api_event_type - impl: impl ApiEventMetric for PaymentMethodIntentConfirmInternal - impl: impl ApiEventMetric for PaymentMethodSessionRequest - impl: impl ApiEventMetric for PaymentMethodsSessionResponse **crates/api_models/src/events/payment.rs** Remove: - impl: impl ApiEventMetric for PaymentsResponse Add: - impl: impl ApiEventMetric for payments::PaymentsResponse **crates/api_models/src/payment_methods.rs** Add: - function: private::from - struct: pub::PaymentMethodIntentConfirmInternal - struct: pub::PaymentMethodSessionRequest - struct: pub::PaymentMethodSessionUpdateSavedPaymentMethod - struct: pub::PaymentMethodsSessionResponse - impl: impl From<PaymentMethodIntentConfirmInternal> for PaymentMethodIntentConfirm **crates/api_models/src/payments.rs** Modify existing code **crates/api_models/src/webhooks.rs** Modify existing code **crates/common_enums/src/enums.rs** Add: - enum: pub::TokenizationType - enum: pub::NetworkTokenizationToggle **crates/common_types/src/payment_methods.rs** Add: - struct: pub::NetworkTokenization - struct: pub::PspTokenization **crates/common_utils/src/crypto.rs** Add: - function: pub::map **crates/common_utils/src/events.rs** Modify existing code **crates/common_utils/src/id_type.rs** Remove: - mod: private::ephemeral_key Add: - mod: private::client_secret **crates/common_utils/src/id_type/client_secret.rs** Add: - function: private::get_api_event_type - function: pub::generate_redis_key - impl: impl crate::events::ApiEventMetric for ClientSecretId - impl: impl ClientSecretId **crates/common_utils/src/id_type/ephemeral_key.rs** Remove: - function: private::get_api_event_type - function: pub::generate_redis_key - impl: impl crate::events::ApiEventMetric for EphemeralKeyId - impl: impl EphemeralKeyId **crates/common_utils/src/id_type/global_id.rs** Modify existing code **crates/common_utils/src/id_type/global_id/payment_methods.rs** Add: - function: pub::generate - function: pub::get_string_repr - function: pub::get_redis_key - function: private::get_api_event_type - function: private::build - function: private::to_sql - function: private::from_sql - struct: pub::GlobalPaymentMethodSessionId - enum: pub::GlobalPaymentMethodSessionIdError - impl: impl GlobalPaymentMethodSessionId - impl: impl crate::events::ApiEventMetric for GlobalPaymentMethodSessionId - impl: impl diesel::Queryable<diesel::sql_types::Text, DB> for GlobalPaymentMethodSessionId - impl: impl diesel::serialize::ToSql<diesel::sql_types::Text, DB> for GlobalPaymentMethodSessionId - impl: impl diesel::deserialize::FromSql<diesel::sql_types::Text, DB> for GlobalPaymentMethodSessionId **crates/common_utils/src/types/authentication.rs** Add: - function: pub::to_str - enum: pub::ResourceId - impl: impl ResourceId **crates/diesel_models/src/customers.rs** Modify existing code **crates/diesel_models/src/ephemeral_key.rs** Remove: - struct: pub::EphemeralKeyTypeNew - enum: pub::ResourceType Add: - struct: pub::ClientSecretTypeNew **crates/diesel_models/src/lib.rs** Add: - mod: pub::payment_methods_session **crates/diesel_models/src/payment_methods_session.rs** Add: - struct: pub::PaymentMethodsSession **crates/hyperswitch_connectors/src/connectors/deutschebank.rs** Modify existing code **crates/hyperswitch_domain_models/src/customer.rs** Modify existing code **crates/hyperswitch_domain_models/src/payment_methods.rs** Add: - function: private::convert - function: private::convert_back - function: private::construct_new - struct: pub::PaymentMethodsSession - impl: impl super::behaviour::Conversion for PaymentMethodsSession **crates/openapi/src/openapi_v2.rs** Modify existing code **crates/openapi/src/routes/payment_method.rs** Add: - function: pub::payment_method_session_create - function: pub::payment_method_session_retrieve - function: pub::payment_method_session_list_payment_methods **crates/router/src/consts.rs** Modify existing code **crates/router/src/core/payment_methods.rs** Remove: - function: pub::payment_method_intent_confirm - function: private::perform_filtering - function: pub::list_payment_methods_enabled - function: pub::create_payment_method_in_db - trait: private::PerformFilteringOnEnabledPaymentMethods Add: - function: private::perform_filtering - function: private::encrypt_data - function: pub::payment_methods_session_create - function: pub::payment_methods_session_retrieve - function: pub::payment_methods_session_update_payment_method - trait: private::EncryptableData - impl: impl PerformFilteringOnEnabledPaymentMethods for hyperswitch_domain_models::merchant_connector_account::FlattenedPaymentMethodsEnabled - impl: impl EncryptableData for payment_methods::PaymentMethodSessionRequest **crates/router/src/core/payment_methods/cards.rs** Modify existing code **crates/router/src/core/payment_methods/surcharge_decision_configs.rs** Remove: - function: pub::perform_surcharge_decision_management_for_saved_cards **crates/router/src/core/payment_methods/transformers.rs** Add: - function: private::foreign_try_from - function: private::foreign_from - impl: impl transformers::ForeignTryFrom<domain::PaymentMethod> for api::CustomerPaymentMethod - impl: impl transformers::ForeignFrom<( hyperswitch_domain_models::payment_methods::PaymentMethodsSession, Secret<String>, )> for api_models::payment_methods::PaymentMethodsSessionResponse **crates/router/src/core/payments/helpers.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Modify existing code **crates/router/src/core/routing/helpers.rs** Modify existing code **crates/router/src/db.rs** Add: - mod: pub::payment_method_session **crates/router/src/db/ephemeral_key.rs** Remove: - function: private::get_ephemeral_key - function: private::delete_ephemeral_key - function: private::create_ephemeral_key - function: private::get_ephemeral_key Add: - function: private::get_ephemeral_key - function: private::delete_ephemeral_key - function: private::delete_client_secret - function: private::create_client_secret - function: private::get_client_secret - trait: pub::ClientSecretInterface **crates/router/src/db/kafka_store.rs** Remove: - function: private::create_ephemeral_key - function: private::get_ephemeral_key Add: - function: private::create_client_secret - function: private::get_client_secret - function: private::insert_payment_methods_session - function: private::get_payment_methods_session - impl: impl db::payment_method_session::PaymentMethodsSessionInterface for KafkaStore - impl: impl db::payment_method_session::PaymentMethodsSessionInterface for KafkaStore **crates/router/src/db/payment_method_session.rs** Add: - function: private::insert_payment_methods_session - function: private::get_payment_methods_session - function: private::insert_payment_methods_session - function: private::get_payment_methods_session - trait: pub::PaymentMethodsSessionInterface - trait: pub::PaymentMethodsSessionInterface - impl: impl PaymentMethodsSessionInterface for crate::services::Store - impl: impl PaymentMethodsSessionInterface for Store - impl: impl PaymentMethodsSessionInterface for MockDb - impl: impl PaymentMethodsSessionInterface for MockDb - mod: private::storage **crates/router/src/lib.rs** Modify existing code **crates/router/src/routes.rs** Modify existing code **crates/router/src/routes/app.rs** Add: - function: pub::server - struct: pub::PaymentMethodsSession - impl: impl PaymentMethodsSession **crates/router/src/routes/customers.rs** Modify existing code **crates/router/src/routes/ephemeral_key.rs** Add: - function: pub::ephemeral_key_delete **crates/router/src/routes/lock_utils.rs** Modify existing code **crates/router/src/routes/payment_methods.rs** Add: - function: private::get_api_event_type - function: pub::payment_method_session_update_saved_payment_method **crates/router/src/services/authentication.rs** Remove: - function: private::authenticate_and_fetch - function: pub::is_ephemeral_or_publishible_auth - impl: impl AuthenticateAndFetch<AuthenticationData, A> for EphemeralKeyAuth Add: - function: pub::get_auth_string_from_header - function: private::authenticate_and_fetch - function: private::authenticate_and_fetch - function: pub::api_or_client_auth - struct: pub::V2ApiKeyAuth - struct: pub::V2ClientAuth - impl: impl AuthenticateAndFetch<AuthenticationData, A> for V2ApiKeyAuth - impl: impl AuthenticateAndFetch<AuthenticationData, A> for V2ClientAuth **crates/router/src/types/storage/ephemeral_key.rs** Modify existing code **crates/router_env/src/logger/types.rs** Modify existing code
{"pr_number": 7107, "pr_title": "feat(payment_methods_session_v2): add payment methods session endpoints", "merged_at": "2025-02-11T12:32:02Z", "intent": {"feature_type": "payment", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/customers.rs", "crates/api_models/src/ephemeral_key.rs", "crates/api_models/src/events.rs", "crates/api_models/src/events/payment.rs", "crates/api_models/src/payment_methods.rs", "crates/api_models/src/payments.rs", "crates/api_models/src/webhooks.rs"], "database": ["crates/diesel_models/src/customers.rs", "crates/diesel_models/src/ephemeral_key.rs", "crates/diesel_models/src/lib.rs", "crates/diesel_models/src/payment_methods_session.rs"], "domain": ["crates/hyperswitch_domain_models/src/customer.rs", "crates/hyperswitch_domain_models/src/payment_methods.rs"], "core_business": ["crates/router/src/core/payment_methods.rs", "crates/router/src/core/payment_methods/cards.rs", "crates/router/src/core/payment_methods/surcharge_decision_configs.rs", "crates/router/src/core/payment_methods/transformers.rs", "crates/router/src/core/payments/helpers.rs", "crates/router/src/core/payments/transformers.rs", "crates/router/src/core/routing/helpers.rs"], "connectors": ["crates/hyperswitch_connectors/src/connectors/deutschebank.rs"], "types": ["crates/common_types/src/payment_methods.rs", "crates/common_utils/src/types/authentication.rs", "crates/router/src/types/storage/ephemeral_key.rs", "crates/router_env/src/logger/types.rs"], "utils": ["crates/common_utils/src/crypto.rs", "crates/common_utils/src/events.rs", "crates/common_utils/src/id_type.rs", "crates/common_utils/src/id_type/client_secret.rs", "crates/common_utils/src/id_type/ephemeral_key.rs", "crates/common_utils/src/id_type/global_id.rs", "crates/common_utils/src/id_type/global_id/payment_methods.rs", "crates/router/src/routes/lock_utils.rs"], "config": ["config/development.toml"], "other": ["api-reference-v2/api-reference/customers/customers--list-saved-payment-methods.mdx", "api-reference-v2/api-reference/payment-method-session/payment-method-session--create.mdx", "api-reference-v2/api-reference/payment-method-session/payment-method-session--list-payment-methods.mdx", "api-reference-v2/api-reference/payment-method-session/payment-method-session--retrieve.mdx", "api-reference-v2/api-reference/payment-method-session/payment-method-session--update-a-saved-payment-method.mdx", "api-reference-v2/api-reference/payment-methods/payment-methods--payment-methods-list.mdx", "api-reference-v2/mint.json", "api-reference-v2/openapi_spec.json", "crates/common_enums/src/enums.rs", "crates/openapi/src/openapi_v2.rs", "crates/openapi/src/routes/payment_method.rs", "crates/router/src/consts.rs", "crates/router/src/db.rs", "crates/router/src/db/ephemeral_key.rs", "crates/router/src/db/kafka_store.rs", "crates/router/src/db/payment_method_session.rs", "crates/router/src/lib.rs", "crates/router/src/routes.rs", "crates/router/src/routes/app.rs", "crates/router/src/routes/customers.rs", "crates/router/src/routes/ephemeral_key.rs", "crates/router/src/routes/payment_methods.rs", "crates/router/src/services/authentication.rs"]}, "change_types": {"structs_added": 17, "functions_added": 77, "enums_added": 5, "fields_added": 270, "imports_added": 31, "conditionals_added": 7}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Currently in external 3ds authentication if we cancel a txn in acs bank page it is not getting handled gracefully rather its throwing an error stating failed to fetch authentication value from temp locker. ## How did you test it? <!-- Did you write an integration/unit/API test to verify the code changes? Or did you test this change manually (provide relevant screenshots)? --> Enable Juspay Threeds server in sandbox, once acs bank page opens click on cancel it should result in failed transaction. Create merchant connector account ```shell curl --location 'localhost:8080/account/sahkal11/connectors' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: dev_Ln1VBidiPjZkR3OuxhdgOAMfwZ7atLwUDLPylBG22x9pnERlTCpvs18nnEkGqlCM' \ --data ' { "connector_type": "authentication_processor", "connector_name": "juspaythreedsserver", "connector_account_details": { "auth_type": "NoKey" }, "test_mode": true, "disabled": false, "metadata": { "merchant_category_code": "5411", "merchant_country_code": "840", "merchant_name": "Dummy Merchant", "endpoint_prefix": "flowbird", "three_ds_requestor_name": "juspay-prev", "three_ds_requestor_id": "juspay-prev", "pull_mechanism_for_external_3ds_enabled": false, "acquirer_bin":"400000", "acquirer_merchant_id":"00002000000", "acquirer_country_code": "356" } } ' ``` Enable authentication service ```shell curl --location 'localhost:8080/configs/' \ --header 'Content-Type: application/json' \ --header 'api-key: test_admin' \ --data '{ "key": "merchants_eligible_for_authentication_service", "value": "[\"sahkal11\"]" }' ``` Business profile update ```shell curl --location 'localhost:8080/account/sahkal11/business_profile/pro_IsxHaxNh6DOI25odFqHJ' \ --header 'Content-Type: application/json' \ --header 'api-key: dev_Ln1VBidiPjZkR3OuxhdgOAMfwZ7atLwUDLPylBG22x9pnERlTCpvs18nnEkGqlCM' \ --data ' { "is_click_to_pay_enabled": true, "authentication_product_ids": {"click_to_pay": "mca_OqBRdcToAauJFZ08i9iI"}, "authentication_connector_details": { "authentication_connectors": ["juspaythreedsserver"], "three_ds_requestor_url": "https://google.com" }, "merchant_country_code": "004", "merchant_category_code": "5411" } ' ``` Payments Create ``` curl --location 'localhost:8080/payments' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: dev_Ln1VBidiPjZkR3OuxhdgOAMfwZ7atLwUDLPylBG22x9pnERlTCpvs18nnEkGqlCM' \ --data-raw '{ "amount": 10, "currency": "EUR", "confirm": false, "capture_method": "automatic", "capture_on": "2022-09-10T10:11:12Z", "psd2_sca_exemption_type": "low_value", "customer_id": "StripeCustomer", "email": "guest@example.com", "name": "John Doe", "phone": "999999999", "phone_country_code": "+65", "description": "Its my first payment request", "authentication_type": "three_ds", "return_url": "https://duck.com", "billing": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "CA", "zip": "94122", "country": "US", "first_name": "PiX" }, "phone": { "number": "123456789", "country_code": "12" } }, "shipping": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "CA", "zip": "94122", "country": "US", "first_name": "PiX" }, "phone": { "number": "123456789", "country_code": "12" } }, "request_external_three_ds_authentication": true, "statement_descriptor_name": "joseph", "statement_descriptor_suffix": "JS", "metadata": { "udf1": "value1", "new_customer": "true", "login_date": "2019-09-10T10:11:12Z" } }' ``` Payments Confirm ``` curl --location 'localhost:8080/payments/pay_Qbd9wicL1LXDa99P9wVk/confirm' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: dev_Ln1VBidiPjZkR3OuxhdgOAMfwZ7atLwUDLPylBG22x9pnERlTCpvs18nnEkGqlCM' \ --data '{ "browser_info": { "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36", "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8", "language": "nl-NL", "color_depth": 24, "screen_height": 723, "screen_width": 1536, "time_zone": 0, "java_enabled": true, "java_script_enabled": true, "ip_address": "115.99.183.2" }, "payment_method": "card", "payment_method_data": { "card": { "card_number": "5522604003479299", "card_exp_month": "06", "card_exp_year": "30", "card_holder_name": "sahkal poddar", "card_cvc": "909" } } }' ``` BRW authenticate ```shell curl --location 'localhost:8080/payments/pay_Qbd9wicL1LXDa99P9wVk/3ds/authentication' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: pk_dev_c5c226cace0b4d98b8f29407cd025440' \ --data '{ "client_secret": "pay_Qbd9wicL1LXDa99P9wVk_secret_5qzmt3NQLZR7GyKNpzZW", "device_channel": "BRW", "threeds_method_comp_ind": "Y" }' ``` ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt --all` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed the submitted code - [ ] I added unit tests for my changes where possible
To implement this **payment** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/router/src/core/payments/operations/payment_confirm.rs` **2. Other** - `crates/common_enums/src/enums.rs` **Code Patterns Applied:** - Implement new functions (1 changes) - Extend existing types with new fields (1 changes)
{"pr_number": 9769, "pr_title": "fix(router): Added authentication success check for fetching authentication value", "merged_at": "2025-10-16T12:06:01Z", "intent": {"feature_type": "payment", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"core_business": ["crates/router/src/core/payments/operations/payment_confirm.rs"], "other": ["crates/common_enums/src/enums.rs"]}, "change_types": {"functions_added": 1, "fields_added": 1}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
Hotfix for https://github.com/juspay/hyperswitch/pull/7211
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/fiuu.rs` - `crates/hyperswitch_connectors/src/connectors/fiuu/transformers.rs` **Code Patterns Applied:** - Extend existing types with new fields (6 changes) **Detailed Identifier Changes:** Commit 135465ef: Files to modify: **crates/hyperswitch_connectors/src/connectors/fiuu.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/fiuu/transformers.rs** Modify existing code
{"pr_number": 7231, "pr_title": "fix(connector): [fiuu] update PSync and webhooks response", "merged_at": "2025-02-10T12:37:44Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["connector"]}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/src/connectors/fiuu.rs", "crates/hyperswitch_connectors/src/connectors/fiuu/transformers.rs"]}, "change_types": {"fields_added": 6}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> This PR adds version column to the organisation.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Database Layer (Queries & Schema)** - `crates/diesel_models/Cargo.toml` - `crates/diesel_models/src/organization.rs` - `crates/diesel_models/src/schema.rs` - ... and 1 more files **2. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/Cargo.toml` - `crates/hyperswitch_domain_models/src/business_profile.rs` - `crates/hyperswitch_domain_models/src/consts.rs` - ... and 2 more files **3. Core Business Logic** - `crates/router/src/core/admin.rs` - `crates/router/src/core/api_keys.rs` - `crates/router/src/core/customers.rs` - ... and 12 more files **4. External Connector Integration** - `crates/router/src/db/merchant_connector_account.rs` **5. Type Definitions** - `crates/common_types/src/consts.rs` - `crates/common_types/src/lib.rs` **6. Configuration Files** - `crates/scheduler/Cargo.toml` **7. Other** - `Cargo.lock` - `crates/scheduler/src/db/process_tracker.rs` - `migrations/2025-03-04-053541_add_api_version_to_organization/down.sql` - ... and 1 more files **Code Patterns Applied:** - Extend existing types with new fields (28 changes) - Modify database queries (1 changes) **Detailed Identifier Changes:** Commit bfb6f59a: Files to modify: **crates/common_types/src/consts.rs** Modify existing code **crates/common_types/src/lib.rs** Add: - mod: pub::consts **crates/diesel_models/src/organization.rs** Modify existing code **crates/diesel_models/src/schema.rs** Modify existing code **crates/diesel_models/src/schema_v2.rs** Modify existing code **crates/hyperswitch_domain_models/src/business_profile.rs** Modify existing code **crates/hyperswitch_domain_models/src/consts.rs** Modify existing code **crates/hyperswitch_domain_models/src/customer.rs** Modify existing code **crates/hyperswitch_domain_models/src/merchant_account.rs** Modify existing code **crates/router/src/core/admin.rs** Modify existing code **crates/router/src/core/api_keys.rs** Modify existing code **crates/router/src/core/customers.rs** Modify existing code **crates/router/src/core/payment_methods.rs** Modify existing code **crates/router/src/core/payment_methods/cards.rs** Modify existing code **crates/router/src/core/payment_methods/tokenize/card_executor.rs** Modify existing code **crates/router/src/core/payment_methods/vault.rs** Modify existing code **crates/router/src/core/payments.rs** Modify existing code **crates/router/src/core/payments/helpers.rs** Modify existing code **crates/router/src/core/payouts.rs** Modify existing code **crates/router/src/core/payouts/helpers.rs** Modify existing code **crates/router/src/core/pm_auth.rs** Modify existing code **crates/router/src/core/refunds.rs** Modify existing code **crates/router/src/core/revenue_recovery.rs** Modify existing code **crates/router/src/core/webhooks/outgoing.rs** Modify existing code **crates/router/src/db/merchant_connector_account.rs** Modify existing code **crates/scheduler/src/db/process_tracker.rs** Modify existing code
{"pr_number": 7418, "pr_title": "refactor(organization): add api version column", "merged_at": "2025-03-28T08:05:54Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["user"]}, "hierarchy": {"database": ["crates/diesel_models/Cargo.toml", "crates/diesel_models/src/organization.rs", "crates/diesel_models/src/schema.rs", "crates/diesel_models/src/schema_v2.rs"], "domain": ["crates/hyperswitch_domain_models/Cargo.toml", "crates/hyperswitch_domain_models/src/business_profile.rs", "crates/hyperswitch_domain_models/src/consts.rs", "crates/hyperswitch_domain_models/src/customer.rs", "crates/hyperswitch_domain_models/src/merchant_account.rs"], "core_business": ["crates/router/src/core/admin.rs", "crates/router/src/core/api_keys.rs", "crates/router/src/core/customers.rs", "crates/router/src/core/payment_methods.rs", "crates/router/src/core/payment_methods/cards.rs", "crates/router/src/core/payment_methods/tokenize/card_executor.rs", "crates/router/src/core/payment_methods/vault.rs", "crates/router/src/core/payments.rs", "crates/router/src/core/payments/helpers.rs", "crates/router/src/core/payouts.rs", "crates/router/src/core/payouts/helpers.rs", "crates/router/src/core/pm_auth.rs", "crates/router/src/core/refunds.rs", "crates/router/src/core/revenue_recovery.rs", "crates/router/src/core/webhooks/outgoing.rs"], "connectors": ["crates/router/src/db/merchant_connector_account.rs"], "types": ["crates/common_types/src/consts.rs", "crates/common_types/src/lib.rs"], "config": ["crates/scheduler/Cargo.toml"], "other": ["Cargo.lock", "crates/scheduler/src/db/process_tracker.rs", "migrations/2025-03-04-053541_add_api_version_to_organization/down.sql", "migrations/2025-03-04-053541_add_api_version_to_organization/up.sql"]}, "change_types": {"fields_added": 28, "imports_added": 1, "database_queries": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Added support for xdel if redis client uses legacy version https://github.com/juspay/hyperswitch/issues/8389
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Other** - `crates/drainer/src/handler.rs` - `crates/drainer/src/metrics.rs` - `crates/drainer/src/services.rs` - ... and 1 more files **Code Patterns Applied:** - Implement new functions (2 changes) - Extend existing types with new fields (4 changes) - Add conditional logic for feature flags or filtering (2 changes) **Detailed Identifier Changes:** Commit 3d085abf: Files to modify: **crates/drainer/src/handler.rs** Modify existing code **crates/drainer/src/metrics.rs** Modify existing code **crates/drainer/src/services.rs** Add: - function: pub::use_legacy_version **crates/drainer/src/stream.rs** Add: - function: pub::delete_from_stream
{"pr_number": 8515, "pr_title": "fix: replace xtrim with xdel to support older redis version", "merged_at": "2025-07-29T10:59:44Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"other": ["crates/drainer/src/handler.rs", "crates/drainer/src/metrics.rs", "crates/drainer/src/services.rs", "crates/drainer/src/stream.rs"]}, "change_types": {"functions_added": 2, "fields_added": 4, "conditionals_added": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
This PR includes changes to make billing details related fields optional during batched operation of data migration.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/payment_methods.rs` **2. Core Business Logic** - `crates/payment_methods/src/core/migration/payment_methods.rs` **Code Patterns Applied:** - Implement new functions (3 changes) - Extend existing types with new fields (31 changes) - Add conditional logic for feature flags or filtering (3 changes) **Detailed Identifier Changes:** Commit dee5d0c5: Files to modify: **crates/api_models/src/payment_methods.rs** Add: - function: private::create_address - function: private::create_phone - function: private::create_billing - impl: impl PaymentMethodRecord **crates/payment_methods/src/core/migration/payment_methods.rs** Modify existing code
{"pr_number": 8438, "pr_title": "refactor: make billing details optional during data migration", "merged_at": "2025-06-24T17:23:39Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/payment_methods.rs"], "core_business": ["crates/payment_methods/src/core/migration/payment_methods.rs"]}, "change_types": {"functions_added": 3, "fields_added": 31, "conditionals_added": 3}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Added Google Pay Predecrypt Flow
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/router/src/core/payments.rs` **2. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/checkout/transformers.rs` **3. Tests** - `config/deployments/integration_test.toml` - `loadtest/config/development.toml` **4. Configuration Files** - `config/config.example.toml` - `config/deployments/production.toml` - `config/deployments/sandbox.toml` - ... and 3 more files **Code Patterns Applied:** - Define new data structures (1 changes) - Implement new functions (2 changes) - Extend existing types with new fields (17 changes) - Add conditional logic for feature flags or filtering (1 changes) **Detailed Identifier Changes:** Commit 96e44a75: Files to modify: **crates/hyperswitch_connectors/src/connectors/checkout/transformers.rs** Modify existing code **crates/router/src/configs/settings.rs** Add: - enum: pub::GooglePayPreDecryptFlow **crates/router/src/core/payments.rs** Modify existing code
{"pr_number": 9130, "pr_title": "feat(connector): [Checkout] Add Google Pay Predecrypt Flow", "merged_at": "2025-09-26T08:09:57Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"core_business": ["crates/router/src/core/payments.rs"], "connectors": ["crates/hyperswitch_connectors/src/connectors/checkout/transformers.rs"], "tests": ["config/deployments/integration_test.toml", "loadtest/config/development.toml"], "config": ["config/config.example.toml", "config/deployments/production.toml", "config/deployments/sandbox.toml", "config/development.toml", "config/docker_compose.toml", "crates/router/src/configs/settings.rs"]}, "change_types": {"structs_added": 1, "functions_added": 2, "enums_added": 1, "fields_added": 17, "conditionals_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> This PR will make connector_view group accessible by operation groups. This PR will also change the permission of connector_retrieve API from connector_read to connector_write as it contains sensitive data.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Other** - `crates/router/src/routes/admin.rs` - `crates/router/src/services/authorization/permission_groups.rs` **Code Patterns Applied:** - Extend existing types with new fields (1 changes) **Detailed Identifier Changes:** Commit 6081283a: Files to modify: **crates/router/src/routes/admin.rs** Modify existing code **crates/router/src/services/authorization/permission_groups.rs** Modify existing code
{"pr_number": 6792, "pr_title": "refactor(authz): Make connector list accessible by operation groups", "merged_at": "2024-12-16T09:22:57Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["merchant", "user", "connector"]}, "hierarchy": {"other": ["crates/router/src/routes/admin.rs", "crates/router/src/services/authorization/permission_groups.rs"]}, "change_types": {"fields_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> ## Overview of the Three Crates
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/smithy-core/Cargo.toml` - `crates/smithy-core/src/generator.rs` - `crates/smithy-core/src/lib.rs` - ... and 1 more files **2. Configuration Files** - `crates/smithy-generator/Cargo.toml` - `crates/smithy/Cargo.toml` **3. Other** - `Cargo.lock` - `crates/smithy-generator/build.rs` - `crates/smithy-generator/src/main.rs` - ... and 1 more files **Code Patterns Applied:** - Define new data structures (10 changes) - Implement new functions (42 changes) - Extend existing types with new fields (126 changes) - Add conditional logic for feature flags or filtering (94 changes) - Modify database queries (1 changes) **Detailed Identifier Changes:** Commit 0baae338: Files to modify: **crates/smithy-core/src/generator.rs** Add: - function: pub::new - function: pub::add_model - function: pub::generate_idl - function: private::generate_shape_definition - function: private::resolve_type - function: private::trait_to_string - function: private::default - struct: pub::SmithyGenerator - impl: impl SmithyGenerator - impl: impl Default for SmithyGenerator **crates/smithy-core/src/lib.rs** Add: - mod: pub::generator - mod: pub::types **crates/smithy-core/src/types.rs** Add: - function: pub::resolve_type_and_generate_shapes - function: private::extract_generic_inner_type - function: private::parse_map_types - struct: pub::SmithyModel - struct: pub::SmithyMember - struct: pub::SmithyEnumValue - struct: pub::SmithyField - struct: pub::SmithyEnumVariant - enum: pub::SmithyShape - enum: pub::SmithyTrait - enum: pub::SmithyConstraint - trait: pub::SmithyModelGenerator **crates/smithy-generator/build.rs** Add: - function: private::main - function: private::run_build - function: private::get_workspace_root - function: private::scan_crate_for_smithy_models - function: private::scan_directory - function: private::scan_rust_file - function: private::is_valid_rust_identifier - function: private::create_module_path - function: private::generate_model_registry - struct: private::SmithyModelInfo **crates/smithy-generator/src/main.rs** Add: - function: private::main **crates/smithy/src/lib.rs** Add: - function: pub::derive_smithy_model - function: private::generate_smithy_impl - function: private::generate_struct_impl - function: private::generate_enum_impl - function: private::extract_namespace_and_mixin - function: private::extract_fields - function: private::extract_enum_variants - function: private::parse_serde_attributes - function: private::parse_serde_enum_attributes - function: private::transform_variant_name - function: private::to_snake_case - function: private::to_camel_case - function: private::to_kebab_case - function: private::to_screaming_snake_case - function: private::parse_smithy_field_attributes - function: private::extract_documentation - function: private::parse_range - function: private::parse_length - struct: private::SmithyFieldAttributes - struct: private::SerdeAttributes - struct: private::SerdeEnumAttributes
{"pr_number": 9249, "pr_title": "feat(framework): Added smithy, smithy-core and smithy-generator crates", "merged_at": "2025-09-26T08:06:07Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment"]}, "hierarchy": {"core_business": ["crates/smithy-core/Cargo.toml", "crates/smithy-core/src/generator.rs", "crates/smithy-core/src/lib.rs", "crates/smithy-core/src/types.rs"], "config": ["crates/smithy-generator/Cargo.toml", "crates/smithy/Cargo.toml"], "other": ["Cargo.lock", "crates/smithy-generator/build.rs", "crates/smithy-generator/src/main.rs", "crates/smithy/src/lib.rs"]}, "change_types": {"structs_added": 10, "functions_added": 42, "enums_added": 3, "fields_added": 126, "imports_added": 14, "conditionals_added": 94, "database_queries": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> `customer_user_agent` column in `mandate` table has a `255` character length limit. Lately, there have been increased number of `5xx` errors due to the values in `customer_user_agent` column hitting that limit. This PR addresses this by introducing a new column `customer_device_user_agent` with `TEXT` type in the `mandate` table and also adds `customer_user_agent` as a fallback. Generate and run migrations: v1: ```sh just resurrect just migrate diesel migration generate <file-name> vi up.sql vi down.sql just migrate ``` v2: ```sh just resurrect just migrate_v2 diesel migration generate <file-name> --migration-dir v2_migrations --config-file diesel_v2.toml vi up.sql vi down.sql just migrate_v2 ```
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Database Layer (Queries & Schema)** - `crates/diesel_models/src/mandate.rs` - `crates/diesel_models/src/schema.rs` - `crates/diesel_models/src/schema_v2.rs` **2. Core Business Logic** - `crates/router/src/core/payments/helpers.rs` **3. Type Definitions** - `crates/router/src/types/api/mandates.rs` **4. Other** - `crates/router/src/db/mandate.rs` - `migrations/2025-07-24-081357_customer_user_agent_extended/down.sql` - `migrations/2025-07-24-081357_customer_user_agent_extended/up.sql` **Code Patterns Applied:** - Extend existing types with new fields (7 changes) **Detailed Identifier Changes:** Commit b74c1e91: Files to modify: **crates/diesel_models/src/mandate.rs** Modify existing code **crates/diesel_models/src/schema.rs** Modify existing code **crates/diesel_models/src/schema_v2.rs** Modify existing code **crates/router/src/core/payments/helpers.rs** Modify existing code **crates/router/src/db/mandate.rs** Modify existing code **crates/router/src/types/api/mandates.rs** Modify existing code
{"pr_number": 8616, "pr_title": "refactor(schema): add a new column for storing large customer user agents in mandate table", "merged_at": "2025-07-25T09:48:06Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"database": ["crates/diesel_models/src/mandate.rs", "crates/diesel_models/src/schema.rs", "crates/diesel_models/src/schema_v2.rs"], "core_business": ["crates/router/src/core/payments/helpers.rs"], "types": ["crates/router/src/types/api/mandates.rs"], "other": ["crates/router/src/db/mandate.rs", "migrations/2025-07-24-081357_customer_user_agent_extended/down.sql", "migrations/2025-07-24-081357_customer_user_agent_extended/up.sql"]}, "change_types": {"fields_added": 7}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> populate `profile_id` in for the HeaderAuth of v1 And also this pr involves the changes to unmask the profile id that is sent in the headers.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Tests** - `config/deployments/integration_test.toml` - `loadtest/config/development.toml` **2. Configuration Files** - `config/deployments/production.toml` - `config/deployments/sandbox.toml` - `config/development.toml` - ... and 1 more files **3. Other** - `crates/router/src/services/authentication.rs` **Code Patterns Applied:** - Extend existing types with new fields (2 changes) **Detailed Identifier Changes:** Commit 10a43370: Files to modify: **crates/router/src/services/authentication.rs** Modify existing code
{"pr_number": 6936, "pr_title": "fix(router): populate `profile_id` in for the HeaderAuth of v1", "merged_at": "2024-12-26T10:49:20Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"tests": ["config/deployments/integration_test.toml", "loadtest/config/development.toml"], "config": ["config/deployments/production.toml", "config/deployments/sandbox.toml", "config/development.toml", "config/docker_compose.toml"], "other": ["crates/router/src/services/authentication.rs"]}, "change_types": {"fields_added": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> - Store the user query and response from the ai service for the analysis. - Allow the api only for internal user
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/chat.rs` - `crates/api_models/src/events/chat.rs` **2. Database Layer (Queries & Schema)** - `crates/diesel_models/src/hyperswitch_ai_interaction.rs` - `crates/diesel_models/src/lib.rs` - `crates/diesel_models/src/query.rs` - ... and 4 more files **3. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/chat.rs` **4. Core Business Logic** - `crates/router/src/core/chat.rs` - `crates/router/src/core/errors/chat.rs` **5. Type Definitions** - `crates/router/src/types/storage.rs` - `crates/router/src/types/storage/hyperswitch_ai_interaction.rs` - `crates/router_env/src/logger/types.rs` **6. Utils** - `crates/common_utils/src/consts.rs` - `crates/router/src/routes/lock_utils.rs` - `crates/router/src/utils.rs` - ... and 1 more files **7. Tests** - `loadtest/config/development.toml` **8. Configuration Files** - `config/config.example.toml` - `config/deployments/env_specific.toml` - `config/development.toml` - ... and 3 more files **9. Other** - `crates/router/src/db.rs` - `crates/router/src/db/hyperswitch_ai_interaction.rs` - `crates/router/src/db/kafka_store.rs` - ... and 5 more files **Code Patterns Applied:** - Define new data structures (5 changes) - Implement new functions (15 changes) - Extend existing types with new fields (119 changes) - Add conditional logic for feature flags or filtering (3 changes) - Modify database queries (2 changes) **Detailed Identifier Changes:** Commit 8ed3f7db: Files to modify: **crates/api_models/src/chat.rs** Add: - struct: pub::ChatListRequest - struct: pub::ChatConversation - struct: pub::ChatListResponse **crates/api_models/src/events/chat.rs** Modify existing code **crates/common_utils/src/consts.rs** Modify existing code **crates/diesel_models/src/hyperswitch_ai_interaction.rs** Add: - struct: pub::HyperswitchAiInteraction - struct: pub::HyperswitchAiInteractionNew **crates/diesel_models/src/lib.rs** Add: - mod: pub::hyperswitch_ai_interaction **crates/diesel_models/src/query.rs** Add: - mod: pub::hyperswitch_ai_interaction **crates/diesel_models/src/query/hyperswitch_ai_interaction.rs** Add: - function: pub::insert - function: pub::filter_by_optional_merchant_id - impl: impl HyperswitchAiInteractionNew - impl: impl HyperswitchAiInteraction **crates/diesel_models/src/query/utils.rs** Add: - function: private::get_local_unique_key - impl: impl CompositeKey for <schema::hyperswitch_ai_interaction::table as diesel::Table>::PrimaryKey **crates/diesel_models/src/schema.rs** Modify existing code **crates/diesel_models/src/schema_v2.rs** Modify existing code **crates/hyperswitch_domain_models/src/chat.rs** Modify existing code **crates/router/src/configs/secrets_transformers.rs** Add: - function: private::convert_to_raw_secret - impl: impl SecretsHandler for settings::ChatSettings **crates/router/src/configs/settings.rs** Modify existing code **crates/router/src/core/chat.rs** Modify existing code **crates/router/src/core/errors/chat.rs** Modify existing code **crates/router/src/db.rs** Add: - mod: pub::hyperswitch_ai_interaction **crates/router/src/db/hyperswitch_ai_interaction.rs** Add: - function: private::insert_hyperswitch_ai_interaction - function: private::list_hyperswitch_ai_interactions - function: private::insert_hyperswitch_ai_interaction - function: private::list_hyperswitch_ai_interactions - trait: pub::HyperswitchAiInteractionInterface - impl: impl HyperswitchAiInteractionInterface for Store - impl: impl HyperswitchAiInteractionInterface for MockDb **crates/router/src/db/kafka_store.rs** Add: - function: private::insert_hyperswitch_ai_interaction - function: private::list_hyperswitch_ai_interactions - impl: impl HyperswitchAiInteractionInterface for KafkaStore **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/chat.rs** Add: - function: pub::get_all_conversations **crates/router/src/routes/lock_utils.rs** Modify existing code **crates/router/src/types/storage.rs** Add: - mod: pub::hyperswitch_ai_interaction **crates/router/src/types/storage/hyperswitch_ai_interaction.rs** Modify existing code **crates/router/src/utils.rs** Add: - mod: pub::chat **crates/router/src/utils/chat.rs** Add: - function: pub::construct_hyperswitch_ai_interaction **crates/router_env/src/logger/types.rs** Modify existing code **crates/storage_impl/src/mock_db.rs** Modify existing code
{"pr_number": 8831, "pr_title": "feat: add hyperswitch ai chats table", "merged_at": "2025-09-16T09:14:36Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "merchant", "user"]}, "hierarchy": {"api_models": ["crates/api_models/src/chat.rs", "crates/api_models/src/events/chat.rs"], "database": ["crates/diesel_models/src/hyperswitch_ai_interaction.rs", "crates/diesel_models/src/lib.rs", "crates/diesel_models/src/query.rs", "crates/diesel_models/src/query/hyperswitch_ai_interaction.rs", "crates/diesel_models/src/query/utils.rs", "crates/diesel_models/src/schema.rs", "crates/diesel_models/src/schema_v2.rs"], "domain": ["crates/hyperswitch_domain_models/src/chat.rs"], "core_business": ["crates/router/src/core/chat.rs", "crates/router/src/core/errors/chat.rs"], "types": ["crates/router/src/types/storage.rs", "crates/router/src/types/storage/hyperswitch_ai_interaction.rs", "crates/router_env/src/logger/types.rs"], "utils": ["crates/common_utils/src/consts.rs", "crates/router/src/routes/lock_utils.rs", "crates/router/src/utils.rs", "crates/router/src/utils/chat.rs"], "tests": ["loadtest/config/development.toml"], "config": ["config/config.example.toml", "config/deployments/env_specific.toml", "config/development.toml", "config/docker_compose.toml", "crates/router/src/configs/secrets_transformers.rs", "crates/router/src/configs/settings.rs"], "other": ["crates/router/src/db.rs", "crates/router/src/db/hyperswitch_ai_interaction.rs", "crates/router/src/db/kafka_store.rs", "crates/router/src/routes/app.rs", "crates/router/src/routes/chat.rs", "crates/storage_impl/src/mock_db.rs", "migrations/2025-07-21-120614_add_table_for_hyperswitch_ai_interactions/down.sql", "migrations/2025-07-21-120614_add_table_for_hyperswitch_ai_interactions/up.sql"]}, "change_types": {"structs_added": 5, "functions_added": 15, "fields_added": 119, "imports_added": 31, "conditionals_added": 3, "database_queries": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
This PR updates the migration flow around card validation to skip card expiry validation for `PayPal` and `SamsungPay` - these payment methods do not have the linked card's expiry details.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/payment_methods/src/core/migration/payment_methods.rs` **Code Patterns Applied:** - Extend existing types with new fields (1 changes) - Add conditional logic for feature flags or filtering (1 changes) **Detailed Identifier Changes:** Commit 04578801: Files to modify: **crates/payment_methods/src/core/migration/payment_methods.rs** Modify existing code
{"pr_number": 9131, "pr_title": "feat(migration): perform card validation only for allowed payment methods", "merged_at": "2025-09-03T13:04:56Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"core_business": ["crates/payment_methods/src/core/migration/payment_methods.rs"]}, "change_types": {"fields_added": 1, "conditionals_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> This PR reduces build jobs to 3 to see if it helps pass Cypress CI checks
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Tests** - `.github/workflows/cypress-tests-runner.yml` **Code Patterns Applied:** - Extend existing types with new fields (1 changes)
{"pr_number": 6453, "pr_title": "ci(cypress): reduce cargo build jobs to 3", "merged_at": "2024-10-28T15:05:23Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"tests": [".github/workflows/cypress-tests-runner.yml"]}, "change_types": {"fields_added": 1}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
This PR fixes the state update for `payout_attempt` where latest status resides. This fixes the bug mentioned in https://github.com/juspay/hyperswitch/issues/9278
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/router/src/core/webhooks/incoming.rs` **Code Patterns Applied:** - Extend existing types with new fields (2 changes) **Detailed Identifier Changes:** Commit 2fe6cdd5: Files to modify: **crates/router/src/core/webhooks/incoming.rs** Modify existing code
{"pr_number": 9283, "pr_title": "fix(payout): send latest status in outgoing webhook notifications during IncomingWebhook flow", "merged_at": "2025-09-07T14:38:56Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "merchant", "order"]}, "hierarchy": {"core_business": ["crates/router/src/core/webhooks/incoming.rs"]}, "change_types": {"fields_added": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> The S3 Source File Name in Postman Collection Runner Workflow has been changed because the Connector Auth File has been updated.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Configuration Files** - `.github/workflows/postman-collection-runner.yml` **Code Patterns Applied:** - Extend existing types with new fields (1 changes)
{"pr_number": 7637, "pr_title": "chore(ci): update postman ci credentials", "merged_at": "2025-03-27T12:12:57Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["connector"]}, "hierarchy": {"config": [".github/workflows/postman-collection-runner.yml"]}, "change_types": {"fields_added": 1}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
<!-- Describe your changes in detail --> This PR modifies authentication queries to improve the way we distinguish between authentication flows. Previously, `trans_status` was used for this purpose, but it has now been replaced with `authentication_type`, which more explicitly differentiates between **frictionless flow** and **challenge flow**. Additionally, this PR introduces support for **authentication report generation**, similar to the existing reports for payments, refunds, and disputes. ## Key Changes
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/analytics/auth_events.rs` - `crates/api_models/src/analytics/sdk_events.rs` **2. Database Layer (Queries & Schema)** - `crates/analytics/src/query.rs` **3. Core Business Logic** - `crates/analytics/src/auth_events/core.rs` **4. Other** - `crates/analytics/src/auth_events/filters.rs` - `crates/analytics/src/auth_events/metrics.rs` - `crates/analytics/src/auth_events/metrics/authentication_attempt_count.rs` - ... and 12 more files **Code Patterns Applied:** - Define new data structures (1 changes) - Implement new functions (3 changes) - Extend existing types with new fields (36 changes) - Add conditional logic for feature flags or filtering (1 changes) - Modify database queries (1 changes) **Detailed Identifier Changes:** Commit 9683b2a8: Files to modify: **crates/analytics/src/auth_events/core.rs** Modify existing code **crates/analytics/src/auth_events/filters.rs** Modify existing code **crates/analytics/src/auth_events/metrics.rs** Modify existing code **crates/analytics/src/auth_events/metrics/authentication_attempt_count.rs** Modify existing code **crates/analytics/src/auth_events/metrics/authentication_count.rs** Modify existing code **crates/analytics/src/auth_events/metrics/authentication_error_message.rs** Modify existing code **crates/analytics/src/auth_events/metrics/authentication_funnel.rs** Modify existing code **crates/analytics/src/auth_events/metrics/authentication_success_count.rs** Modify existing code **crates/analytics/src/auth_events/metrics/challenge_attempt_count.rs** Modify existing code **crates/analytics/src/auth_events/metrics/challenge_flow_count.rs** Modify existing code **crates/analytics/src/auth_events/metrics/challenge_success_count.rs** Modify existing code **crates/analytics/src/auth_events/metrics/frictionless_flow_count.rs** Modify existing code **crates/analytics/src/auth_events/metrics/frictionless_success_count.rs** Modify existing code **crates/analytics/src/lib.rs** Modify existing code **crates/analytics/src/query.rs** Modify existing code **crates/analytics/src/sqlx.rs** Modify existing code **crates/api_models/src/analytics/auth_events.rs** Add: - struct: pub::AuthenticationFunnel **crates/api_models/src/analytics/sdk_events.rs** Modify existing code **crates/router/src/analytics.rs** Add: - function: pub::generate_merchant_authentication_report - function: pub::generate_org_authentication_report - function: pub::generate_profile_authentication_report
{"pr_number": 7483, "pr_title": "feat(analytics): modified authentication queries and added generate report for authentications", "merged_at": "2025-03-12T11:35:14Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "merchant", "user"]}, "hierarchy": {"api_models": ["crates/api_models/src/analytics/auth_events.rs", "crates/api_models/src/analytics/sdk_events.rs"], "database": ["crates/analytics/src/query.rs"], "core_business": ["crates/analytics/src/auth_events/core.rs"], "other": ["crates/analytics/src/auth_events/filters.rs", "crates/analytics/src/auth_events/metrics.rs", "crates/analytics/src/auth_events/metrics/authentication_attempt_count.rs", "crates/analytics/src/auth_events/metrics/authentication_count.rs", "crates/analytics/src/auth_events/metrics/authentication_error_message.rs", "crates/analytics/src/auth_events/metrics/authentication_funnel.rs", "crates/analytics/src/auth_events/metrics/authentication_success_count.rs", "crates/analytics/src/auth_events/metrics/challenge_attempt_count.rs", "crates/analytics/src/auth_events/metrics/challenge_flow_count.rs", "crates/analytics/src/auth_events/metrics/challenge_success_count.rs", "crates/analytics/src/auth_events/metrics/frictionless_flow_count.rs", "crates/analytics/src/auth_events/metrics/frictionless_success_count.rs", "crates/analytics/src/lib.rs", "crates/analytics/src/sqlx.rs", "crates/router/src/analytics.rs"]}, "change_types": {"structs_added": 1, "functions_added": 3, "fields_added": 36, "imports_added": 9, "conditionals_added": 1, "database_queries": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Add amount, currency and email to paze session response
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/payments.rs` **2. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/router_request_types.rs` **3. Core Business Logic** - `crates/router/src/core/payments/flows/session_flow.rs` - `crates/router/src/core/payments/transformers.rs` **4. Other** - `api-reference-v2/openapi_spec.json` - `api-reference/openapi_spec.json` **Code Patterns Applied:** - Extend existing types with new fields (8 changes) **Detailed Identifier Changes:** Commit a3ea62f8: Files to modify: **crates/api_models/src/payments.rs** Modify existing code **crates/hyperswitch_domain_models/src/router_request_types.rs** Modify existing code **crates/router/src/core/payments/flows/session_flow.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Modify existing code
{"pr_number": 6412, "pr_title": "feat: Add amount, currency and email to paze session response", "merged_at": "2024-10-25T13:52:21Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "session", "token"]}, "hierarchy": {"api_models": ["crates/api_models/src/payments.rs"], "domain": ["crates/hyperswitch_domain_models/src/router_request_types.rs"], "core_business": ["crates/router/src/core/payments/flows/session_flow.rs", "crates/router/src/core/payments/transformers.rs"], "other": ["api-reference-v2/openapi_spec.json", "api-reference/openapi_spec.json"]}, "change_types": {"fields_added": 8}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
In this PR, we have added integrity checks for Authorize, Capture, Refund and RSync flows for Xendit Connector Also, moved the integrity functions from `crates/router/src/connector/utils.rs` to `crates/hyperswitch_connectors/src/utils.rs`. Thereby also changing the imports in `Stripe.rs`. What is an integrity check? A scenario where there is a discrepancy between the amount sent in the request and the amount received from the connector, which is checked during response handling.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/xendit.rs` - `crates/hyperswitch_connectors/src/connectors/xendit/transformers.rs` - `crates/hyperswitch_connectors/src/utils.rs` - ... and 1 more files **Code Patterns Applied:** - Implement new functions (4 changes) - Extend existing types with new fields (31 changes) **Detailed Identifier Changes:** Commit caa07235: Files to modify: **crates/hyperswitch_connectors/src/connectors/xendit.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/xendit/transformers.rs** Modify existing code **crates/hyperswitch_connectors/src/utils.rs** Remove: - function: pub::get_refund_integrity_object - function: pub::get_capture_integrity_object - function: pub::get_sync_integrity_object - function: pub::get_authorise_integrity_object Add: - function: pub::get_authorise_integrity_object - function: pub::get_sync_integrity_object - function: pub::get_capture_integrity_object - function: pub::get_refund_integrity_object **crates/router/src/connector/utils.rs** Modify existing code
{"pr_number": 8049, "pr_title": "feat(connector): [XENDIT] Added Integrity Check for Authorize, Capture, Refund & RSync flows", "merged_at": "2025-05-23T09:53:17Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/src/connectors/xendit.rs", "crates/hyperswitch_connectors/src/connectors/xendit/transformers.rs", "crates/hyperswitch_connectors/src/utils.rs", "crates/router/src/connector/utils.rs"]}, "change_types": {"functions_added": 4, "fields_added": 31, "imports_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
- This PR adds support for updating the retry Algorithm from Monitoring to Smart , once the threshold is reached - It also adds support in the process tracker workflow for revenue recovery , to consume schedule time for retry based on different retry algorithms
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Database Layer (Queries & Schema)** - `crates/diesel_models/src/business_profile.rs` **2. Core Business Logic** - `crates/router/src/core/admin.rs` - `crates/router/src/core/errors.rs` - `crates/router/src/core/files.rs` - ... and 3 more files **3. Type Definitions** - `crates/router/src/types/storage/revenue_recovery.rs` **4. Tests** - `config/deployments/integration_test.toml` **5. Configuration Files** - `config/config.example.toml` - `config/deployments/production.toml` - `config/deployments/sandbox.toml` - ... and 4 more files **6. Other** - `crates/common_enums/src/enums.rs` - `crates/router/src/workflows/revenue_recovery.rs` **Code Patterns Applied:** - Define new data structures (1 changes) - Implement new functions (4 changes) - Extend existing types with new fields (24 changes) - Add conditional logic for feature flags or filtering (1 changes) **Detailed Identifier Changes:** Commit 151b57fa: Files to modify: **crates/common_enums/src/enums.rs** Modify existing code **crates/diesel_models/src/business_profile.rs** Add: - function: pub::has_exceeded_monitoring_threshold - impl: impl RevenueRecoveryAlgorithmData **crates/router/src/configs/secrets_transformers.rs** Modify existing code **crates/router/src/configs/settings.rs** Modify existing code **crates/router/src/core/admin.rs** Add: - function: pub::update_revenue_recovery_algorithm_under_profile **crates/router/src/core/errors.rs** Modify existing code **crates/router/src/core/files.rs** Modify existing code **crates/router/src/core/revenue_recovery.rs** Modify existing code **crates/router/src/core/revenue_recovery/types.rs** Modify existing code **crates/router/src/core/webhooks/recovery_incoming.rs** Add: - function: private::handle_monitoring_threshold **crates/router/src/types/storage/revenue_recovery.rs** Add: - function: pub::get_schedule_time_based_on_retry_type - struct: pub::RevenueRecoverySettings - impl: impl RevenueRecoveryPaymentData **crates/router/src/workflows/revenue_recovery.rs** Modify existing code
{"pr_number": 7915, "pr_title": "feat(reveue_recovery): Add support for multiple retry algorithms in revenue recovery workflow", "merged_at": "2025-05-20T13:04:35Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["user", "connector"]}, "hierarchy": {"database": ["crates/diesel_models/src/business_profile.rs"], "core_business": ["crates/router/src/core/admin.rs", "crates/router/src/core/errors.rs", "crates/router/src/core/files.rs", "crates/router/src/core/revenue_recovery.rs", "crates/router/src/core/revenue_recovery/types.rs", "crates/router/src/core/webhooks/recovery_incoming.rs"], "types": ["crates/router/src/types/storage/revenue_recovery.rs"], "tests": ["config/deployments/integration_test.toml"], "config": ["config/config.example.toml", "config/deployments/production.toml", "config/deployments/sandbox.toml", "config/development.toml", "config/docker_compose.toml", "crates/router/src/configs/secrets_transformers.rs", "crates/router/src/configs/settings.rs"], "other": ["crates/common_enums/src/enums.rs", "crates/router/src/workflows/revenue_recovery.rs"]}, "change_types": {"structs_added": 1, "functions_added": 4, "fields_added": 24, "imports_added": 7, "conditionals_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Context - Cybersource payments via Netcetera are failing for a France based acquirer in prod, the PR provides fix for the same by introducing field **_consumerAuthenticationInformation. effectiveAuthenticationType_** and making sure **_consumerAuthenticationInformation.specificationVersion** is sent.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/router_request_types.rs` **2. Core Business Logic** - `crates/router/src/core/payments/types.rs` **3. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/cybersource/transformers.rs` **Code Patterns Applied:** - Implement new functions (1 changes) - Extend existing types with new fields (14 changes) **Detailed Identifier Changes:** Commit 6ff75754: Files to modify: **crates/hyperswitch_connectors/src/connectors/cybersource/transformers.rs** Add: - enum: pub::EffectiveAuthenticationType **crates/hyperswitch_domain_models/src/router_request_types.rs** Modify existing code **crates/router/src/core/payments/types.rs** Modify existing code
{"pr_number": 8768, "pr_title": "feat(connector): [cybersource] add changes for field CybersourceConsumerAuthInformation", "merged_at": "2025-07-31T09:51:22Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"domain": ["crates/hyperswitch_domain_models/src/router_request_types.rs"], "core_business": ["crates/router/src/core/payments/types.rs"], "connectors": ["crates/hyperswitch_connectors/src/connectors/cybersource/transformers.rs"]}, "change_types": {"functions_added": 1, "enums_added": 1, "fields_added": 14}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> This PR introduces the capability to send the Merchant Order Reference ID to the Unified Connector Service (UCS) as part of gRPC request headers. This enhancement allows the UCS to be aware of the merchant's original identifier for a transaction, which can be crucial for tracking, reconciliation, and reporting purposes.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/payments.rs` - `crates/hyperswitch_domain_models/src/router_request_types.rs` **2. Core Business Logic** - `crates/router/src/core/payments.rs` - `crates/router/src/core/payments/flows/authorize_flow.rs` - `crates/router/src/core/payments/flows/external_proxy_flow.rs` - ... and 5 more files **3. External Connector Integration** - `crates/external_services/src/grpc_client/unified_connector_service.rs` **4. Type Definitions** - `crates/common_utils/src/ucs_types.rs` - `crates/router/src/types/transformers.rs` **5. Utils** - `crates/common_utils/src/lib.rs` **6. Other** - `crates/external_services/src/grpc_client.rs` - `crates/external_services/src/lib.rs` - `crates/router/src/lib.rs` **Code Patterns Applied:** - Implement new functions (1 changes) - Extend existing types with new fields (7 changes) - Add conditional logic for feature flags or filtering (2 changes) **Detailed Identifier Changes:** Commit 261bed2d: Files to modify: **crates/common_utils/src/lib.rs** Remove: - mod: pub::hashing - mod: pub::metrics Add: - mod: pub::hashing - mod: pub::metrics - mod: pub::ucs_types **crates/common_utils/src/ucs_types.rs** Add: - function: pub::get_string_repr - enum: pub::UcsReferenceId - impl: impl UcsReferenceId **crates/external_services/src/grpc_client.rs** Modify existing code **crates/external_services/src/grpc_client/unified_connector_service.rs** Modify existing code **crates/external_services/src/lib.rs** Modify existing code **crates/hyperswitch_domain_models/src/payments.rs** Modify existing code **crates/hyperswitch_domain_models/src/router_request_types.rs** Modify existing code **crates/router/src/core/payments.rs** Modify existing code **crates/router/src/core/payments/flows/authorize_flow.rs** Modify existing code **crates/router/src/core/payments/flows/external_proxy_flow.rs** Modify existing code **crates/router/src/core/payments/flows/psync_flow.rs** Modify existing code **crates/router/src/core/payments/flows/setup_mandate_flow.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Modify existing code **crates/router/src/core/unified_connector_service.rs** Modify existing code **crates/router/src/core/unified_connector_service/transformers.rs** Modify existing code **crates/router/src/lib.rs** Modify existing code **crates/router/src/types/transformers.rs** Modify existing code
{"pr_number": 9352, "pr_title": "feat(ucs): transmit merchant order reference id to unified connector service", "merged_at": "2025-09-18T08:51:58Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"domain": ["crates/hyperswitch_domain_models/src/payments.rs", "crates/hyperswitch_domain_models/src/router_request_types.rs"], "core_business": ["crates/router/src/core/payments.rs", "crates/router/src/core/payments/flows/authorize_flow.rs", "crates/router/src/core/payments/flows/external_proxy_flow.rs", "crates/router/src/core/payments/flows/psync_flow.rs", "crates/router/src/core/payments/flows/setup_mandate_flow.rs", "crates/router/src/core/payments/transformers.rs", "crates/router/src/core/unified_connector_service.rs", "crates/router/src/core/unified_connector_service/transformers.rs"], "connectors": ["crates/external_services/src/grpc_client/unified_connector_service.rs"], "types": ["crates/common_utils/src/ucs_types.rs", "crates/router/src/types/transformers.rs"], "utils": ["crates/common_utils/src/lib.rs"], "other": ["crates/external_services/src/grpc_client.rs", "crates/external_services/src/lib.rs", "crates/router/src/lib.rs"]}, "change_types": {"functions_added": 1, "enums_added": 1, "fields_added": 7, "imports_added": 12, "conditionals_added": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> The length of receipt for Trustpay order request should not exceed 35 characters. So added generate_connector_request_reference_id specific to trustpay which generates less than 35 charcters.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/trustpay.rs` **Code Patterns Applied:** - Implement new functions (1 changes) - Extend existing types with new fields (2 changes) **Detailed Identifier Changes:** Commit 041656ec: Files to modify: **crates/hyperswitch_connectors/src/connectors/trustpay.rs** Add: - function: private::generate_connector_request_reference_id
{"pr_number": 8925, "pr_title": "fix(trustpay): add connector request reference ID generation for v2", "merged_at": "2025-09-10T08:51:15Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/src/connectors/trustpay.rs"]}, "change_types": {"functions_added": 1, "fields_added": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Paystack EFT flow (Payments, PSync, Refunds, RSync, Webhooks).
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/connector_configs/toml/development.toml` - `crates/connector_configs/toml/production.toml` - `crates/connector_configs/toml/sandbox.toml` - ... and 2 more files **Code Patterns Applied:** - Define new data structures (11 changes) - Implement new functions (10 changes) - Extend existing types with new fields (126 changes) - Add conditional logic for feature flags or filtering (1 changes)
{"pr_number": 7286, "pr_title": "feat(connector): [PAYSTACK] EFT Payment Flows", "merged_at": "2025-03-03T14:28:32Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/connector_configs/toml/development.toml", "crates/connector_configs/toml/production.toml", "crates/connector_configs/toml/sandbox.toml", "crates/hyperswitch_connectors/src/connectors/paystack.rs", "crates/hyperswitch_connectors/src/connectors/paystack/transformers.rs"]}, "change_types": {"structs_added": 11, "functions_added": 10, "enums_added": 6, "fields_added": 126, "imports_added": 5, "conditionals_added": 1}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
<!-- Describe your changes in detail --> Added trustpay in authentication providers config
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Tests** - `config/deployments/integration_test.toml` **2. Configuration Files** - `config/deployments/production.toml` - `config/deployments/sandbox.toml` - `config/development.toml` - ... and 1 more files
{"pr_number": 8622, "pr_title": "fix(connector): Add Trustpay in Authentication Providers Config", "merged_at": "2025-07-22T12:49:13Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["user", "session", "card"]}, "hierarchy": {"tests": ["config/deployments/integration_test.toml"], "config": ["config/deployments/production.toml", "config/deployments/sandbox.toml", "config/development.toml", "config/docker_compose.toml"]}, "change_types": {}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
<!-- Describe your changes in detail --> This PR adds support for API Event Metric logging, the events will be logged to clickhouse when a request/response is triggered. In refunds v2, it will be for requests and responses for 4 apis 1. Refunds Create 2. Refunds Metadata Update 3. Refunds Retrieve 4. Refunds List
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/events/refund.rs` **2. Database Layer (Queries & Schema)** - `crates/diesel_models/src/refund.rs` **3. Core Business Logic** - `crates/router/src/core/refunds_v2.rs` **4. Utils** - `crates/common_utils/src/events.rs` **5. Other** - `crates/router/src/routes/refunds.rs` **Code Patterns Applied:** - Extend existing types with new fields (8 changes) **Detailed Identifier Changes:** Commit bc4bab93: Files to modify: **crates/api_models/src/events/refund.rs** Remove: - function: private::get_api_event_type - impl: impl ApiEventMetric for refunds::RefundsCreateRequest **crates/common_utils/src/events.rs** Modify existing code **crates/diesel_models/src/refund.rs** Modify existing code **crates/router/src/core/refunds_v2.rs** Modify existing code **crates/router/src/routes/refunds.rs** Modify existing code
{"pr_number": 8041, "pr_title": "Refactor(refunds_v2): Refactor api event metric for refunds v2 apis", "merged_at": "2025-05-27T07:22:39Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["refund"]}, "hierarchy": {"api_models": ["crates/api_models/src/events/refund.rs"], "database": ["crates/diesel_models/src/refund.rs"], "core_business": ["crates/router/src/core/refunds_v2.rs"], "utils": ["crates/common_utils/src/events.rs"], "other": ["crates/router/src/routes/refunds.rs"]}, "change_types": {"fields_added": 8}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Revert [7610](https://github.com/juspay/hyperswitch/pull/7610)
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/connector_configs/toml/production.toml` - `crates/hyperswitch_connectors/src/connectors/noon.rs` - `crates/hyperswitch_connectors/src/connectors/noon/transformers.rs` - ... and 1 more files **2. Tests** - `config/deployments/integration_test.toml` - `loadtest/config/development.toml` **3. Configuration Files** - `config/config.example.toml` - `config/deployments/production.toml` - `config/deployments/sandbox.toml` - ... and 2 more files **Code Patterns Applied:** - Implement new functions (1 changes) - Extend existing types with new fields (1 changes) **Detailed Identifier Changes:** Commit 776bde00: Files to modify: **crates/hyperswitch_connectors/src/connectors/noon.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/noon/transformers.rs** Remove: - function: private::try_from - function: private::try_from - struct: pub::NoonPaymentsCompleteAuthorizeRequest - struct: pub::NoonCompleteOrder - struct: pub::NoonCompletePaymentData - struct: pub::NoonData - struct: pub::NoonQueryData - struct: pub::PaypalQueryData - struct: pub::NoonPaypalResponse - struct: pub::NoonPaypalResponseResult - struct: pub::NoonPaypalPaymentData - struct: pub::PaypalData - enum: pub::NoonPaymentMethodType - enum: pub::NoonAuthPaymentResponse - impl: impl TryFrom<&NoonRouterData<&PaymentsCompleteAuthorizeRouterData>> for NoonPaymentsCompleteAuthorizeRequest - impl: impl TryFrom<ResponseRouterData<F, NoonPaypalResponse, T, PaymentsResponseData>> for RouterData<F, T, PaymentsResponseData> **crates/hyperswitch_connectors/src/default_implementations.rs** Modify existing code
{"pr_number": 7864, "pr_title": "fix(connector): revert noon-paypal", "merged_at": "2025-04-22T11:39:01Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/connector_configs/toml/production.toml", "crates/hyperswitch_connectors/src/connectors/noon.rs", "crates/hyperswitch_connectors/src/connectors/noon/transformers.rs", "crates/hyperswitch_connectors/src/default_implementations.rs"], "tests": ["config/deployments/integration_test.toml", "loadtest/config/development.toml"], "config": ["config/config.example.toml", "config/deployments/production.toml", "config/deployments/sandbox.toml", "config/development.toml", "config/docker_compose.toml"]}, "change_types": {"functions_added": 1, "fields_added": 1, "imports_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Instead of using a forked repo to support empty payloads in josekit's JWT implementation, switch to using the josekit JWS directly, which supports empty payloads.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/Cargo.toml` - `crates/hyperswitch_connectors/src/connectors/nomupay.rs` **2. Other** - `Cargo.lock` **Detailed Identifier Changes:** Commit b1628f79: Files to modify: **crates/hyperswitch_connectors/src/connectors/nomupay.rs** Modify existing code
{"pr_number": 8183, "pr_title": "fix(connector): removed forked josekit dependency from payout connector Nomupay", "merged_at": "2025-06-10T07:09:21Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "merchant", "user"]}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/Cargo.toml", "crates/hyperswitch_connectors/src/connectors/nomupay.rs"], "other": ["Cargo.lock"]}, "change_types": {}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Fix save card flow for braintree , earlier we were passing on_session for off_session flow
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Tests** - `cypress-tests/cypress/e2e/configs/Payment/Braintree.js` **Code Patterns Applied:** - Extend existing types with new fields (11 changes)
{"pr_number": 9435, "pr_title": "ci(cypress): fix braintree connector", "merged_at": "2025-09-18T11:59:06Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["user", "session", "card"]}, "hierarchy": {"tests": ["cypress-tests/cypress/e2e/configs/Payment/Braintree.js"]}, "change_types": {"fields_added": 11}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
adding `stripe` in connector list for network transaction id.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Configuration Files** - `config/deployments/production.toml`
{"pr_number": 7096, "pr_title": "chore: add stripe to network transaction id support", "merged_at": "2025-01-28T20:16:00Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["connector", "transaction"]}, "hierarchy": {"config": ["config/deployments/production.toml"]}, "change_types": {}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
<!-- Describe your changes in detail --> This PR addresses the clippy lints occurring due to new rust version 1.87.0 https://rust-lang.github.io/rust-clippy/master/index.html
To implement this **connector_integration** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/router/src/core/payments/helpers.rs` **2. Utils** - `crates/kgraph_utils/src/error.rs` - `crates/kgraph_utils/src/transformers.rs` **3. Other** - `crates/external_services/src/email/ses.rs` - `crates/masking/src/serde.rs` - `crates/router/src/bin/router.rs` **Code Patterns Applied:** - Add conditional logic for feature flags or filtering (1 changes) **Detailed Identifier Changes:** Commit fab9f5ee: Files to modify: **crates/external_services/src/email/ses.rs** Modify existing code **crates/kgraph_utils/src/error.rs** Modify existing code **crates/kgraph_utils/src/transformers.rs** Modify existing code **crates/masking/src/serde.rs** Modify existing code **crates/router/src/bin/router.rs** Modify existing code **crates/router/src/core/payments/helpers.rs** Modify existing code
{"pr_number": 8130, "pr_title": "chore: address Rust 1.87.0 clippy lints", "merged_at": "2025-05-27T10:37:27Z", "intent": {"feature_type": "connector_integration", "action": "add_feature", "entities": ["user"]}, "hierarchy": {"core_business": ["crates/router/src/core/payments/helpers.rs"], "utils": ["crates/kgraph_utils/src/error.rs", "crates/kgraph_utils/src/transformers.rs"], "other": ["crates/external_services/src/email/ses.rs", "crates/masking/src/serde.rs", "crates/router/src/bin/router.rs"]}, "change_types": {"conditionals_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Updated the outdated/incorrect base urls for some connectors with the new ones.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/chargebee.rs` **2. Configuration Files** - `config/deployments/production.toml` **Detailed Identifier Changes:** Commit 0250f169: Files to modify: **crates/hyperswitch_connectors/src/connectors/chargebee.rs** Modify existing code
{"pr_number": 7582, "pr_title": "refactor(configs): prod base url updated for connectors", "merged_at": "2025-04-30T10:46:14Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "connector"]}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/src/connectors/chargebee.rs"], "config": ["config/deployments/production.toml"]}, "change_types": {}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> add template code for katapult
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/connector_endpoints.rs` **2. External Connector Integration** - `crates/connector_configs/src/connector.rs` - `crates/connector_configs/toml/development.toml` - `crates/connector_configs/toml/production.toml` - ... and 11 more files **3. Tests** - `config/deployments/integration_test.toml` - `loadtest/config/development.toml` **4. Configuration Files** - `config/config.example.toml` - `config/deployments/production.toml` - `config/deployments/sandbox.toml` - ... and 2 more files **Code Patterns Applied:** - Define new data structures (10 changes) - Implement new functions (83 changes) - Extend existing types with new fields (163 changes) **Detailed Identifier Changes:** Commit c6e4e720: Files to modify: **crates/connector_configs/src/connector.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors.rs** Add: - mod: pub::katapult **crates/hyperswitch_connectors/src/connectors/katapult.rs** Add: - function: pub::new - function: private::build_headers - function: private::id - function: private::get_currency_unit - function: private::common_get_content_type - function: private::base_url - function: private::get_auth_header - function: private::build_error_response - function: private::validate_mandate_payment - function: private::validate_psync_reference_id - function: private::get_headers - function: private::get_content_type - function: private::get_url - function: private::get_request_body - function: private::build_request - function: private::handle_response - function: private::get_error_response - function: private::get_headers - function: private::get_content_type - function: private::get_url - function: private::build_request - function: private::handle_response - function: private::get_error_response - function: private::get_headers - function: private::get_content_type - function: private::get_url - function: private::get_request_body - function: private::build_request - function: private::handle_response - function: private::get_error_response - function: private::get_headers - function: private::get_content_type - function: private::get_url - function: private::get_request_body - function: private::build_request - function: private::handle_response - function: private::get_error_response - function: private::get_headers - function: private::get_content_type - function: private::get_url - function: private::build_request - function: private::handle_response - function: private::get_error_response - function: private::get_webhook_object_reference_id - function: private::get_webhook_event_type - function: private::get_webhook_resource_object - function: private::get_connector_about - function: private::get_supported_payment_methods - function: private::get_supported_webhook_flows - struct: pub::Katapult - impl: impl Katapult - impl: impl api::Payment for Katapult - impl: impl api::PaymentSession for Katapult - impl: impl api::ConnectorAccessToken for Katapult - impl: impl api::MandateSetup for Katapult - impl: impl api::PaymentAuthorize for Katapult - impl: impl api::PaymentSync for Katapult - impl: impl api::PaymentCapture for Katapult - impl: impl api::PaymentVoid for Katapult - impl: impl api::Refund for Katapult - impl: impl api::RefundExecute for Katapult - impl: impl api::RefundSync for Katapult - impl: impl api::PaymentToken for Katapult - impl: impl ConnectorIntegration<PaymentMethodToken, PaymentMethodTokenizationData, PaymentsResponseData> for Katapult - impl: impl ConnectorCommonExt<Flow, Request, Response> for Katapult - impl: impl ConnectorCommon for Katapult - impl: impl ConnectorValidation for Katapult - impl: impl ConnectorIntegration<Session, PaymentsSessionData, PaymentsResponseData> for Katapult - impl: impl ConnectorIntegration<AccessTokenAuth, AccessTokenRequestData, AccessToken> for Katapult - impl: impl ConnectorIntegration<SetupMandate, SetupMandateRequestData, PaymentsResponseData> for Katapult - impl: impl ConnectorIntegration<Authorize, PaymentsAuthorizeData, PaymentsResponseData> for Katapult - impl: impl ConnectorIntegration<PSync, PaymentsSyncData, PaymentsResponseData> for Katapult - impl: impl ConnectorIntegration<Capture, PaymentsCaptureData, PaymentsResponseData> for Katapult - impl: impl ConnectorIntegration<Void, PaymentsCancelData, PaymentsResponseData> for Katapult - impl: impl ConnectorIntegration<Execute, RefundsData, RefundsResponseData> for Katapult - impl: impl ConnectorIntegration<RSync, RefundsData, RefundsResponseData> for Katapult - impl: impl webhooks::IncomingWebhook for Katapult - impl: impl ConnectorSpecifications for Katapult - mod: pub::transformers **crates/hyperswitch_connectors/src/connectors/katapult/transformers.rs** Add: - function: private::from - function: private::try_from - function: private::try_from - function: private::from - function: private::try_from - function: private::try_from - function: private::from - function: private::try_from - function: private::try_from - struct: pub::KatapultRouterData - struct: pub::KatapultPaymentsRequest - struct: pub::KatapultCard - struct: pub::KatapultAuthType - struct: pub::KatapultPaymentsResponse - struct: pub::KatapultRefundRequest - struct: pub::RefundResponse - struct: pub::KatapultErrorResponse - enum: pub::KatapultPaymentStatus - enum: pub::RefundStatus - impl: impl From<(StringMinorUnit, T)> for KatapultRouterData<T> - impl: impl TryFrom<&KatapultRouterData<&PaymentsAuthorizeRouterData>> for KatapultPaymentsRequest - impl: impl TryFrom<&ConnectorAuthType> for KatapultAuthType - impl: impl From<KatapultPaymentStatus> for common_enums::AttemptStatus - impl: impl TryFrom<ResponseRouterData<F, KatapultPaymentsResponse, T, PaymentsResponseData>> for RouterData<F, T, PaymentsResponseData> - impl: impl TryFrom<&KatapultRouterData<&RefundsRouterData<F>>> for KatapultRefundRequest - impl: impl From<RefundStatus> for enums::RefundStatus - impl: impl TryFrom<RefundsResponseRouterData<Execute, RefundResponse>> for RefundsRouterData<Execute> - impl: impl TryFrom<RefundsResponseRouterData<RSync, RefundResponse>> for RefundsRouterData<RSync> **crates/hyperswitch_connectors/src/default_implementations.rs** Modify existing code **crates/hyperswitch_connectors/src/default_implementations_v2.rs** Modify existing code **crates/hyperswitch_domain_models/src/connector_endpoints.rs** Modify existing code **crates/router/src/connector.rs** Modify existing code **crates/router/tests/connectors/katapult.rs** Add: - function: private::get_data - function: private::get_auth_token - function: private::get_name - function: private::get_default_payment_info - function: private::payment_method_details - function: private::should_only_authorize_payment - function: private::should_capture_authorized_payment - function: private::should_partially_capture_authorized_payment - function: private::should_sync_authorized_payment - function: private::should_void_authorized_payment - function: private::should_refund_manually_captured_payment - function: private::should_partially_refund_manually_captured_payment - function: private::should_sync_manually_captured_refund - function: private::should_make_payment - function: private::should_sync_auto_captured_payment - function: private::should_refund_auto_captured_payment - function: private::should_partially_refund_succeeded_payment - function: private::should_refund_succeeded_payment_multiple_times - function: private::should_sync_refund - function: private::should_fail_payment_for_incorrect_cvc - function: private::should_fail_payment_for_invalid_exp_month - function: private::should_fail_payment_for_incorrect_expiry_year - function: private::should_fail_void_payment_for_auto_capture - function: private::should_fail_capture_for_invalid_payment - function: private::should_fail_for_refund_amount_higher_than_payment_amount - struct: private::KatapultTest - impl: impl ConnectorActions for KatapultTest - impl: impl utils::Connector for KatapultTest **crates/router/tests/connectors/main.rs** Add: - mod: private::katapult **crates/test_utils/src/connector_auth.rs** Modify existing code
{"pr_number": 8783, "pr_title": "feat(connector): [katapult]add template code for katapult", "merged_at": "2025-07-31T11:50:55Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"domain": ["crates/hyperswitch_domain_models/src/connector_endpoints.rs"], "connectors": ["crates/connector_configs/src/connector.rs", "crates/connector_configs/toml/development.toml", "crates/connector_configs/toml/production.toml", "crates/connector_configs/toml/sandbox.toml", "crates/hyperswitch_connectors/src/connectors.rs", "crates/hyperswitch_connectors/src/connectors/katapult.rs", "crates/hyperswitch_connectors/src/connectors/katapult/transformers.rs", "crates/hyperswitch_connectors/src/default_implementations.rs", "crates/hyperswitch_connectors/src/default_implementations_v2.rs", "crates/router/src/connector.rs", "crates/router/tests/connectors/katapult.rs", "crates/router/tests/connectors/main.rs", "crates/test_utils/src/connector_auth.rs", "scripts/add_connector.sh"], "tests": ["config/deployments/integration_test.toml", "loadtest/config/development.toml"], "config": ["config/config.example.toml", "config/deployments/production.toml", "config/deployments/sandbox.toml", "config/development.toml", "config/docker_compose.toml"]}, "change_types": {"structs_added": 10, "functions_added": 83, "enums_added": 2, "fields_added": 163, "imports_added": 22}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail -->
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/admin.rs` **2. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/merchant_account.rs` - `crates/hyperswitch_domain_models/src/router_data.rs` **3. Core Business Logic** - `crates/router/src/core/payments/transformers.rs` **4. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/worldpayvantiv/transformers.rs` **5. Other** - `api-reference/v1/openapi_spec_v1.json` - `api-reference/v2/openapi_spec_v2.json` **Code Patterns Applied:** - Implement new functions (2 changes) - Extend existing types with new fields (6 changes) - Modify database queries (1 changes) **Detailed Identifier Changes:** Commit ff14b7ca: Files to modify: **crates/api_models/src/admin.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/worldpayvantiv/transformers.rs** Modify existing code **crates/hyperswitch_domain_models/src/merchant_account.rs** Add: - function: pub::get_merchant_details - function: pub::get_merchant_tax_registration_id **crates/hyperswitch_domain_models/src/router_data.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Modify existing code
{"pr_number": 8992, "pr_title": "feat(core): Add Merchant Tax ID in Merchant Profile ", "merged_at": "2025-09-01T11:02:55Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "merchant", "user"]}, "hierarchy": {"api_models": ["crates/api_models/src/admin.rs"], "domain": ["crates/hyperswitch_domain_models/src/merchant_account.rs", "crates/hyperswitch_domain_models/src/router_data.rs"], "core_business": ["crates/router/src/core/payments/transformers.rs"], "connectors": ["crates/hyperswitch_connectors/src/connectors/worldpayvantiv/transformers.rs"], "other": ["api-reference/v1/openapi_spec_v1.json", "api-reference/v2/openapi_spec_v2.json"]}, "change_types": {"functions_added": 2, "fields_added": 6, "database_queries": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Worldpayvantiv supports non 3ds payments. Recurring payments are not supported. Mandate using PMID failing because of the missing connector id - which is expected. But throws an unexpected error <img width="416" alt="Screenshot 2025-06-04 at 11 31 41 AM" src="https://github.com/user-attachments/assets/50300d8f-03ba-452f-8567-3a9c3ccbd3f8" /> ## How did you test it? <!-- <img width="416" alt="Screenshot 2025-06-04 at 11 31 41 AM" src="https://github.com/user-attachments/assets/a2df3fa4-11cd-42da-9a53-3dc67e9afd07" /> Did you write an integration/unit/API test to verify the code changes? Or did you test this change manually (provide relevant screenshots)? --> <img width="802" alt="Screenshot 2025-06-04 at 11 21 09 AM" src="https://github.com/user-attachments/assets/670d33d1-81fe-480f-baa0-d36b5d32bc82" /> ## Checklist <!-- Put an `x` in the boxes that apply --> - [ ] I formatted the code `cargo +nightly fmt --all` - [ ] I addressed lints thrown by `cargo clippy` - [ ] I reviewed the submitted code - [ ] I added unit tests for my changes where possible
To implement this **payment** feature, you'll need to modify these architectural layers: **1. Tests** - `cypress-tests/cypress/e2e/configs/Payment/Utils.js` - `cypress-tests/cypress/e2e/configs/Payment/Worldpayvantiv.js` **Code Patterns Applied:** - Extend existing types with new fields (367 changes)
{"pr_number": 8234, "pr_title": "feat(cypress): [worldpayvantiv] add cypress test", "merged_at": "2025-07-07T12:53:33Z", "intent": {"feature_type": "payment", "action": "add_feature", "entities": ["payment", "user", "connector"]}, "hierarchy": {"tests": ["cypress-tests/cypress/e2e/configs/Payment/Utils.js", "cypress-tests/cypress/e2e/configs/Payment/Worldpayvantiv.js"]}, "change_types": {"fields_added": 367}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
<!-- Describe your changes in detail --> Add cardbrand union fetch logic for click to pay session response Previously for click to pay card brands was needed to be configured via dashboard in click to pay connector create tab, with this change we will provide card brands as a union of all card networks under active payment processor ## How did you test it? <!-- Did you write an integration/unit/API test to verify the code changes? Or did you test this change manually (provide relevant screenshots)? --> Create Payment connectors that supports click to pay Lets take the example of adyen and cybersource in adyen configure card network as ["Visa", "Mastercard"] and in cybersource configure card network as ["American_Express"] ```shell curl --location 'http://localhost:8080/account/sahkal/connectors' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: dev_Yo6nUGV4YXm5VBniRWzk7w3gd8z7qIodkbIYZOqkxf7wfrUpWrDYcIJdpeYnDZcX' \ --data ' { "connector_type": "payment_processor", "connector_name": "adyen", "connector_account_details": { "auth_type": "SignatureKey", "api_key": "API-KEY", "key1": "KEY1", "api_secret": "API-SECRET" }, "test_mode": true, "disabled": false, "payment_methods_enabled": [ { "payment_method": "card", "payment_method_types": [ { "payment_method_type": "credit", "card_networks": [ "Visa", "Mastercard" ], "minimum_amount": 1, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": true }, { "payment_method_type": "debit", "card_networks": [ "Visa", "Mastercard" ], "minimum_amount": 1, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": true } ] } ], "metadata": { "city": "NY", "unit": "245", "live_endpoint_prefix": "vsfbjh" }, "connector_webhook_details": { "merchant_secret": "556B655EBE2F2F0912F6DBC893C23C8A30F5F5293746B80114844AB30549E2AB" }, "business_country": "US", "business_label": "default" } ' ``` CYBERSOURCE ``` curl --location 'http://localhost:8080/account/sahkal/connectors' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: dev_m0TdtUXCOCjuHAx86maD6MNJ0OAnmSYY3cnXHAZUclbMdN5Vy7C1wnq6mDFyNwBs' \ --data ' { "connector_type": "payment_processor", "connector_name": "cybersource", "connector_account_details": { "auth_type": "SignatureKey", "api_secret": "API-SECRET", "api_key": "API-KEY", "key1": "KET1" }, "test_mode": true, "disabled": false, "payment_methods_enabled": [ { "payment_method": "card", "payment_method_types": [ { "payment_method_type": "credit", "card_networks": [ "AmericanExpress" ], "minimum_amount": 1, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": true }, { "payment_method_type": "debit", "card_networks": [ "Visa", "Mastercard" ], "minimum_amount": 1, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": true } ] } ], "metadata": { "city": "NY", "unit": "245", "live_endpoint_prefix": "vsfbjh" }, "connector_webhook_details": { "merchant_secret": "MERCHANT-SECRET" } } ' ``` CTP_MASTERCARD ```shell curl --location 'http://localhost:8080/account/sahkal/connectors' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: dev_m0TdtUXCOCjuHAx86maD6MNJ0OAnmSYY3cnXHAZUclbMdN5Vy7C1wnq6mDFyNwBs' \ --data '{ "connector_type": "authentication_processor", "connector_name": "ctp_mastercard", "connector_account_details": { "auth_type": "HeaderKey", "api_key": "API-KEY" }, "test_mode": true, "disabled": false, "payment_methods_enabled": [ { "payment_method": "card", "payment_method_types": [ { "payment_method_type": "credit", "card_networks": [ "Visa", "Mastercard" ], "minimum_amount": 1, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": true }, { "payment_method_type": "debit", "card_networks": [ "Visa", "Mastercard" ], "minimum_amount": 1, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": true } ] } ], "connector_webhook_details": { "merchant_secret": "MERCHANT-SECRET" }, "business_country": "US", "business_label": "default", "metadata": { "dpa_id": "DPA-ID", "dpa_name": "TestMerchant", "locale": "en_AU", "card_brands": [ "mastercard", "visa" ], "acquirer_bin": "545301", "acquirer_merchant_id": "SRC3DS", "merchant_category_code": "0001", "merchant_country_code": "US", "dpa_client_id": "TestMerchant" } } ' ``` update business profile ```shell curl --location 'http://localhost:8080/account/sahkal/business_profile/pro_7TUGcXiWxKKIE5nV0n53' \ --header 'Content-Type: application/json' \ --header 'api-key: dev_Yo6nUGV4YXm5VBniRWzk7w3gd8z7qIodkbIYZOqkxf7wfrUpWrDYcIJdpeYnDZcX' \ --data '{ "is_click_to_pay_enabled": true, "authentication_product_ids": {"click_to_pay": "mca_lChk9Kk2GUHabZjoQYOu"} }' ``` Create a payment ```shell curl --location 'http://localhost:8080/payments' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: dev_Yo6nUGV4YXm5VBniRWzk7w3gd8z7qIodkbIYZOqkxf7wfrUpWrDYcIJdpeYnDZcX' \ --data-raw ' { "amount": 100, "currency": "USD", "confirm": false, "browser_info": { "user_agent": "Mozilla\/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/70.0.3538.110 Safari\/537.36", "accept_header": "text\/html,application\/xhtml+xml,application\/xml;q=0.9,image\/webp,image\/apng,*\/*;q=0.8", "language": "nl-NL", "color_depth": 24, "screen_height": 723, "screen_width": 1536, "time_zone": 0, "java_enabled": true, "java_script_enabled": true, "ip_address": "125.0.0.1" }, "email": "guest@example.com", "name": "John Doe", "phone": "999999999", "phone_country_code": "+65" } ' ``` do session call ```shell curl --location 'http://localhost:8080/payments/session_tokens' \ --header 'Content-Type: application/json' \ --header 'api-key: pk_dev_220c67f397a446a5bd74670be511dc22' \ --data '{ "payment_id": "pay_psophzCF50w1qjRjKR1O", "wallets": [], "client_secret": "pay_psophzCF50w1qjRjKR1O_secret_WUPOg3OCoQX1lcRHHCYk" }' ``` Response ```shell { "payment_id": "pay_psophzCF50w1qjRjKR1O", "client_secret": "pay_psophzCF50w1qjRjKR1O_secret_WUPOg3OCoQX1lcRHHCYk", "session_token": [ { "wallet_name": "click_to_pay", "dpa_id": "DPA-ID", "dpa_name": "TestMerchant", "locale": "en_AU", "card_brands": [ "AmericanExpress", "Mastercard", "Visa" ], "acquirer_bin": "545301", "acquirer_merchant_id": "SRC3DS", "merchant_category_code": "0001", "merchant_country_code": "US", "transaction_amount": "1.00", "transaction_currency_code": "USD", "phone_number": "999999999", "email": "guest@example.com", "phone_country_code": "+65", "provider": "mastercard", "dpa_client_id": null } ] } ``` card brands should contain union of card brands supported via both cybersource and adyen ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt --all` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed the submitted code - [ ] I added unit tests for my changes where possible
To implement this **payment** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/payments.rs` **2. Database Layer (Queries & Schema)** - `crates/diesel_models/src/query/merchant_connector_account.rs` **3. Core Business Logic** - `crates/router/src/core/payments.rs` **4. External Connector Integration** - `crates/connector_configs/toml/development.toml` - `crates/connector_configs/toml/production.toml` - `crates/connector_configs/toml/sandbox.toml` - ... and 1 more files **5. Configuration Files** - `config/deployments/production.toml` - `config/deployments/sandbox.toml` - `config/development.toml` - ... and 3 more files **6. Other** - `api-reference-v2/openapi_spec.json` - `api-reference/openapi_spec.json` - `crates/router/src/db/kafka_store.rs` **Code Patterns Applied:** - Define new data structures (2 changes) - Implement new functions (4 changes) - Extend existing types with new fields (17 changes) - Add conditional logic for feature flags or filtering (3 changes) - Modify database queries (4 changes) **Detailed Identifier Changes:** Commit d2ff66bb: Files to modify: **crates/api_models/src/payments.rs** Modify existing code **crates/diesel_models/src/query/merchant_connector_account.rs** Add: - function: pub::list_enabled_by_profile_id **crates/router/src/configs/secrets_transformers.rs** Modify existing code **crates/router/src/configs/settings.rs** Add: - function: private::deserialize_connector_list - struct: pub::AuthenticationProviders - struct: private::Wrapper **crates/router/src/core/payments.rs** Add: - function: private::get_card_brands_based_on_active_merchant_connector_account **crates/router/src/db/kafka_store.rs** Modify existing code **crates/router/src/db/merchant_connector_account.rs** Modify existing code
{"pr_number": 7858, "pr_title": "feat(core): Add cardbrand union fetch logic for click to pay session response", "merged_at": "2025-04-28T12:21:01Z", "intent": {"feature_type": "payment", "action": "add_feature", "entities": ["payment", "merchant", "user"]}, "hierarchy": {"api_models": ["crates/api_models/src/payments.rs"], "database": ["crates/diesel_models/src/query/merchant_connector_account.rs"], "core_business": ["crates/router/src/core/payments.rs"], "connectors": ["crates/connector_configs/toml/development.toml", "crates/connector_configs/toml/production.toml", "crates/connector_configs/toml/sandbox.toml", "crates/router/src/db/merchant_connector_account.rs"], "config": ["config/deployments/production.toml", "config/deployments/sandbox.toml", "config/development.toml", "config/docker_compose.toml", "crates/router/src/configs/secrets_transformers.rs", "crates/router/src/configs/settings.rs"], "other": ["api-reference-v2/openapi_spec.json", "api-reference/openapi_spec.json", "crates/router/src/db/kafka_store.rs"]}, "change_types": {"structs_added": 2, "functions_added": 4, "fields_added": 17, "imports_added": 1, "conditionals_added": 3, "database_queries": 4}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Generally in case of external payments we don't get the network error code and error messages from the billing connector. Since this data is important we need to fetch them using Psync call for the Payment connectors and update our payment attempts. In this PR we have added support for Psync in record attempt flow .
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/payments.rs` **2. Core Business Logic** - `crates/router/src/core/payments.rs` - `crates/router/src/core/payments/operations/payment_attempt_record.rs` **Code Patterns Applied:** - Extend existing types with new fields (22 changes) **Detailed Identifier Changes:** Commit 60835abe: Files to modify: **crates/hyperswitch_domain_models/src/payments.rs** Modify existing code **crates/router/src/core/payments.rs** Modify existing code **crates/router/src/core/payments/operations/payment_attempt_record.rs** Modify existing code
{"pr_number": 7855, "pr_title": "feat(core): add psync support for recovery external payments", "merged_at": "2025-05-12T14:30:04Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"domain": ["crates/hyperswitch_domain_models/src/payments.rs"], "core_business": ["crates/router/src/core/payments.rs", "crates/router/src/core/payments/operations/payment_attempt_record.rs"]}, "change_types": {"fields_added": 22}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Fetch email from customer email whenever billing email is not present for payment request
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/router/src/connector/adyen/transformers.rs` **Code Patterns Applied:** - Implement new functions (1 changes) - Extend existing types with new fields (2 changes) **Detailed Identifier Changes:** Commit 9998c557: Files to modify: **crates/router/src/connector/adyen/transformers.rs** Add: - function: private::get_optional_shopper_email
{"pr_number": 6676, "pr_title": "feat(connector): [Adyen] Fetch email from customer email for payment request", "merged_at": "2024-11-29T10:28:36Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment"]}, "hierarchy": {"connectors": ["crates/router/src/connector/adyen/transformers.rs"]}, "change_types": {"functions_added": 1, "fields_added": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
- Accept merchant_connector_credentials in the Request Body of payments and psync - Add a new POST endpoint `payments_status_with_gateway_creds` - Add merchant_reference_id in payments response
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/payments.rs` **2. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/customer.rs` - `crates/hyperswitch_domain_models/src/merchant_connector_account.rs` - `crates/hyperswitch_domain_models/src/payments.rs` - ... and 2 more files **3. Core Business Logic** - `crates/router/src/core/fraud_check/flows/checkout_flow.rs` - `crates/router/src/core/fraud_check/flows/record_return.rs` - `crates/router/src/core/fraud_check/flows/sale_flow.rs` - ... and 32 more files **4. Other** - `api-reference/v2/openapi_spec_v2.json` - `crates/openapi/src/openapi_v2.rs` - `crates/router/src/routes/app.rs` - ... and 1 more files **Code Patterns Applied:** - Define new data structures (2 changes) - Implement new functions (23 changes) - Extend existing types with new fields (130 changes) - Add conditional logic for feature flags or filtering (2 changes) **Detailed Identifier Changes:** Commit b8b19605: Files to modify: **crates/api_models/src/payments.rs** Add: - struct: pub::MerchantConnectorDetails - struct: pub::PaymentsStatusRequest **crates/hyperswitch_domain_models/src/customer.rs** Modify existing code **crates/hyperswitch_domain_models/src/merchant_connector_account.rs** Add: - function: pub::get_connector_account_details - function: pub::is_disabled - function: pub::get_metadata - function: pub::get_id - function: pub::get_mca_id - function: pub::get_connector_name - function: pub::get_inner_db_merchant_connector_account - enum: pub::MerchantConnectorAccountTypeDetails - impl: impl MerchantConnectorAccountTypeDetails **crates/hyperswitch_domain_models/src/payments.rs** Modify existing code **crates/hyperswitch_domain_models/src/payments/payment_attempt.rs** Modify existing code **crates/hyperswitch_domain_models/src/revenue_recovery.rs** Modify existing code **crates/openapi/src/openapi_v2.rs** Modify existing code **crates/router/src/core/fraud_check/flows/checkout_flow.rs** Modify existing code **crates/router/src/core/fraud_check/flows/record_return.rs** Modify existing code **crates/router/src/core/fraud_check/flows/sale_flow.rs** Modify existing code **crates/router/src/core/fraud_check/flows/transaction_flow.rs** Modify existing code **crates/router/src/core/payment_methods.rs** Modify existing code **crates/router/src/core/payment_methods/vault.rs** Modify existing code **crates/router/src/core/payments.rs** Add: - function: pub::internal_payments_operation_core **crates/router/src/core/payments/customers.rs** Modify existing code **crates/router/src/core/payments/flows.rs** Modify existing code **crates/router/src/core/payments/flows/approve_flow.rs** Modify existing code **crates/router/src/core/payments/flows/authorize_flow.rs** Modify existing code **crates/router/src/core/payments/flows/cancel_flow.rs** Modify existing code **crates/router/src/core/payments/flows/capture_flow.rs** Modify existing code **crates/router/src/core/payments/flows/complete_authorize_flow.rs** Modify existing code **crates/router/src/core/payments/flows/incremental_authorization_flow.rs** Modify existing code **crates/router/src/core/payments/flows/post_session_tokens_flow.rs** Modify existing code **crates/router/src/core/payments/flows/psync_flow.rs** Modify existing code **crates/router/src/core/payments/flows/reject_flow.rs** Modify existing code **crates/router/src/core/payments/flows/session_flow.rs** Modify existing code **crates/router/src/core/payments/flows/session_update_flow.rs** Modify existing code **crates/router/src/core/payments/flows/setup_mandate_flow.rs** Modify existing code **crates/router/src/core/payments/flows/update_metadata_flow.rs** Modify existing code **crates/router/src/core/payments/helpers.rs** Remove: - function: pub::get_inner_db_merchant_connector_account Add: - function: pub::get_connector_data_from_request **crates/router/src/core/payments/operations.rs** Add: - function: private::get_connector_from_request **crates/router/src/core/payments/operations/payment_confirm_intent.rs** Add: - function: private::get_connector_from_request **crates/router/src/core/payments/operations/payment_get.rs** Add: - function: private::get_connector_from_request **crates/router/src/core/payments/operations/proxy_payments_intent.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Modify existing code **crates/router/src/core/payments/vault_session.rs** Modify existing code **crates/router/src/core/payouts/helpers.rs** Modify existing code **crates/router/src/core/revenue_recovery/api.rs** Modify existing code **crates/router/src/core/utils.rs** Modify existing code **crates/router/src/core/webhooks/incoming_v2.rs** Modify existing code **crates/router/src/core/webhooks/recovery_incoming.rs** Modify existing code **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/payments.rs** Add: - function: pub::payments_status_with_gateway_creds
{"pr_number": 8199, "pr_title": "feat(core): accept merchant_connector_details in Payments and Psync flow", "merged_at": "2025-06-17T15:54:49Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/payments.rs"], "domain": ["crates/hyperswitch_domain_models/src/customer.rs", "crates/hyperswitch_domain_models/src/merchant_connector_account.rs", "crates/hyperswitch_domain_models/src/payments.rs", "crates/hyperswitch_domain_models/src/payments/payment_attempt.rs", "crates/hyperswitch_domain_models/src/revenue_recovery.rs"], "core_business": ["crates/router/src/core/fraud_check/flows/checkout_flow.rs", "crates/router/src/core/fraud_check/flows/record_return.rs", "crates/router/src/core/fraud_check/flows/sale_flow.rs", "crates/router/src/core/fraud_check/flows/transaction_flow.rs", "crates/router/src/core/payment_methods.rs", "crates/router/src/core/payment_methods/vault.rs", "crates/router/src/core/payments.rs", "crates/router/src/core/payments/customers.rs", "crates/router/src/core/payments/flows.rs", "crates/router/src/core/payments/flows/approve_flow.rs", "crates/router/src/core/payments/flows/authorize_flow.rs", "crates/router/src/core/payments/flows/cancel_flow.rs", "crates/router/src/core/payments/flows/capture_flow.rs", "crates/router/src/core/payments/flows/complete_authorize_flow.rs", "crates/router/src/core/payments/flows/incremental_authorization_flow.rs", "crates/router/src/core/payments/flows/post_session_tokens_flow.rs", "crates/router/src/core/payments/flows/psync_flow.rs", "crates/router/src/core/payments/flows/reject_flow.rs", "crates/router/src/core/payments/flows/session_flow.rs", "crates/router/src/core/payments/flows/session_update_flow.rs", "crates/router/src/core/payments/flows/setup_mandate_flow.rs", "crates/router/src/core/payments/flows/update_metadata_flow.rs", "crates/router/src/core/payments/helpers.rs", "crates/router/src/core/payments/operations.rs", "crates/router/src/core/payments/operations/payment_confirm_intent.rs", "crates/router/src/core/payments/operations/payment_get.rs", "crates/router/src/core/payments/operations/proxy_payments_intent.rs", "crates/router/src/core/payments/transformers.rs", "crates/router/src/core/payments/vault_session.rs", "crates/router/src/core/payouts/helpers.rs", "crates/router/src/core/revenue_recovery.rs", "crates/router/src/core/revenue_recovery/api.rs", "crates/router/src/core/utils.rs", "crates/router/src/core/webhooks/incoming_v2.rs", "crates/router/src/core/webhooks/recovery_incoming.rs"], "other": ["api-reference/v2/openapi_spec_v2.json", "crates/openapi/src/openapi_v2.rs", "crates/router/src/routes/app.rs", "crates/router/src/routes/payments.rs"]}, "change_types": {"structs_added": 2, "functions_added": 23, "enums_added": 1, "fields_added": 130, "imports_added": 6, "conditionals_added": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> klarna in router crate uses to_state_code in branch hotfix-2025.02.05, thus, to_state_code implementation needs to be present in router as well
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/router/src/connector/utils.rs` **Code Patterns Applied:** - Implement new functions (4 changes) - Add conditional logic for feature flags or filtering (1 changes) **Detailed Identifier Changes:** Commit 7691108e: Files to modify: **crates/router/src/connector/utils.rs** Add: - function: private::to_state_code - function: private::to_state_code_as_optional
{"pr_number": 7293, "pr_title": "fix(utils): add to_state_code to router crate", "merged_at": "2025-02-17T18:21:13Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"connectors": ["crates/router/src/connector/utils.rs"]}, "change_types": {"functions_added": 4, "conditionals_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
If there's no connector customer present corresponding to the customer_id of hyperswitch, then it throws a missing required field error. This shouldn't happen.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/stripe/transformers.rs` **2. Other** - `api-reference-v2/openapi_spec.json` **Code Patterns Applied:** - Extend existing types with new fields (1 changes) **Detailed Identifier Changes:** Commit c3a7f5c4: Files to modify: **crates/hyperswitch_connectors/src/connectors/stripe/transformers.rs** Modify existing code
{"pr_number": 8309, "pr_title": "fix(connector): [STRIPE] Throwing Missing Required Field Error if connector_customer is not present", "merged_at": "2025-06-10T15:09:01Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/src/connectors/stripe/transformers.rs"], "other": ["api-reference-v2/openapi_spec.json"]}, "change_types": {"fields_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> - Consistently use kebab case in endpoint URLs - Use plural form of resources in URLs, i.e. instead of `/v2/organization`, use `/v2/organizations` Renamed (current version removed) endpoints: `/v2/organization` -> `/v2/organizations` `/v2/routing-algorithm` -> `/v2/routing-algorithms` `/v2/payment-methods-session` -> `/v2/payment-method-sessions` (refunds) `/update_metadata` -> `update-metadata` Duplicated (current version not removed) endpoints: `/v2/user` -> `/v2/users` `/create_merchant` -> `/create-merchant` `/v2/process_tracker/revenue_recovery_workflow` -> `/v2/process-trackers/revenue-recovery-workflow` `/list_attempts` -> `/list-attempts`
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/hyperswitch_vault.rs` **2. Tests** - `cypress-tests-v2/cypress/support/commands.js` **3. Other** - `api-reference/v2/openapi_spec_v2.json` - `api-reference/v2/organization/organization--create.mdx` - `api-reference/v2/organization/organization--merchant-account--list.mdx` - ... and 19 more files **Code Patterns Applied:** - Define new data structures (3 changes) - Implement new functions (2 changes) **Detailed Identifier Changes:** Commit db147646: Files to modify: **crates/hyperswitch_connectors/src/connectors/hyperswitch_vault.rs** Modify existing code **crates/openapi/src/routes/organization.rs** Modify existing code **crates/openapi/src/routes/payment_method.rs** Modify existing code **crates/openapi/src/routes/refunds.rs** Modify existing code **crates/openapi/src/routes/revenue_recovery.rs** Modify existing code **crates/openapi/src/routes/routing.rs** Modify existing code **crates/router/src/lib.rs** Modify existing code **crates/router/src/routes.rs** Modify existing code **crates/router/src/routes/app.rs** Remove: - struct: pub::User Add: - function: pub::server - function: pub::server - struct: pub::User - struct: pub::ProcessTrackerDeprecated - impl: impl User - impl: impl ProcessTrackerDeprecated
{"pr_number": 8630, "pr_title": "fix(router): Make v2 endpoints follow standard naming conventions", "merged_at": "2025-07-21T15:41:20Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/src/connectors/hyperswitch_vault.rs"], "tests": ["cypress-tests-v2/cypress/support/commands.js"], "other": ["api-reference/v2/openapi_spec_v2.json", "api-reference/v2/organization/organization--create.mdx", "api-reference/v2/organization/organization--merchant-account--list.mdx", "api-reference/v2/organization/organization--retrieve.mdx", "api-reference/v2/organization/organization--update.mdx", "api-reference/v2/payment-method-session/payment-method-session--confirm-a-payment-method-session.mdx", "api-reference/v2/payment-method-session/payment-method-session--create.mdx", "api-reference/v2/payment-method-session/payment-method-session--delete-a-saved-payment-method.mdx", "api-reference/v2/payment-method-session/payment-method-session--list-payment-methods.mdx", "api-reference/v2/payment-method-session/payment-method-session--retrieve.mdx", "api-reference/v2/payment-method-session/payment-method-session--update-a-saved-payment-method.mdx", "api-reference/v2/revenue-recovery/revenue-recovery--retrieve.mdx", "api-reference/v2/routing/routing--create.mdx", "api-reference/v2/routing/routing--retrieve.mdx", "crates/openapi/src/routes/organization.rs", "crates/openapi/src/routes/payment_method.rs", "crates/openapi/src/routes/refunds.rs", "crates/openapi/src/routes/revenue_recovery.rs", "crates/openapi/src/routes/routing.rs", "crates/router/src/lib.rs", "crates/router/src/routes.rs", "crates/router/src/routes/app.rs"]}, "change_types": {"structs_added": 3, "functions_added": 2, "imports_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Fix required fileds for wallet mandate payments for cybersource and bank of america.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/router/src/configs/defaults/payment_connector_required_fields.rs` **Code Patterns Applied:** - Extend existing types with new fields (8 changes) **Detailed Identifier Changes:** Commit 1fc94105: Files to modify: **crates/router/src/configs/defaults/payment_connector_required_fields.rs** Modify existing code
{"pr_number": 6911, "pr_title": "fix(connector): [Cybersource] fix the required fields for wallet mandate payments", "merged_at": "2024-12-23T09:38:59Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/router/src/configs/defaults/payment_connector_required_fields.rs"]}, "change_types": {"fields_added": 8}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Add tenant id in dummy connector requests ## Motivation and Context <!-- Why is this change required? What problem does it solve? If it fixes an open issue, please link to the issue here. If you don't have an issue, we'd recommend starting with one first so the PR can focus on the implementation (unless it is an obvious bug or documentation fix that will have little conversation). --> Dummy connector calls `http://localhost:8080` plus respective endpoints. But when multi tenancy is enabled app server expects the requests to have `x-tenant-id` header in the request. Absence of this would call the dummy connector requests to fail. This PR addresses that ## How did you test it? <!-- Did you write an integration/unit/API test to verify the code changes? Or did you test this change manually (provide relevant screenshots)? --> 1. Create `stripe_test` PaymentsConnector ```bash curl --location 'http://localhost:8080/account/1736322673/connectors' \ --header 'cache-control: no-cache' \ --header 'content-type: application/json' \ --header 'x-tenant-id: public' \ --header 'api-key: test_admin' \ --data '{ "connector_type": "payment_processor", "connector_name": "stripe_test", "connector_label": "stripe_test_default", "disabled": false, "test_mode": true, "payment_methods_enabled": [ { "payment_method": "card", "payment_method_types": [ { "payment_method_type": "debit", "card_networks": [ "Mastercard" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "debit", "card_networks": [ "Visa" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "debit", "card_networks": [ "Interac" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "debit", "card_networks": [ "AmericanExpress" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "debit", "card_networks": [ "JCB" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "debit", "card_networks": [ "DinersClub" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "debit", "card_networks": [ "Discover" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "debit", "card_networks": [ "CartesBancaires" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "debit", "card_networks": [ "UnionPay" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "credit", "card_networks": [ "Mastercard" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "credit", "card_networks": [ "Visa" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "credit", "card_networks": [ "Interac" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "credit", "card_networks": [ "AmericanExpress" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "credit", "card_networks": [ "JCB" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "credit", "card_networks": [ "DinersClub" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "credit", "card_networks": [ "Discover" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "credit", "card_networks": [ "CartesBancaires" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false }, { "payment_method_type": "credit", "card_networks": [ "UnionPay" ], "minimum_amount": 0, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": false } ] } ], "metadata": {}, "connector_account_details": { "api_key": "test_key", "auth_type": "HeaderKey" }, "additional_merchant_data": null, "status": "active", "pm_auth_config": null, "connector_wallets_details": null }' ``` 2. Create a Payment with `stripe_test` as the connector ```bash curl --location 'http://localhost:8080/payments' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'x-tenant-id: public' \ --header 'api-key: dev_Pkb2Z4Lk00hQnSOtWXWxGL7NjZ41ySJ1KRLrmMRnbNCChaPnj0m8Uc9EnYE9SW86' \ --data-raw '{ "amount": 600, "currency": "USD", "confirm": true, "capture_method": "automatic", "customer_id": "HScustomer1234", "email": "p143@example.com", "amount_to_capture": 600, "description": "Its my first payment request", "capture_on": "2022-09-10T10:11:12Z", "return_url": "https://google.com", "name": "Preetam", "phone": "999999999", "setup_future_usage": "off_session", "connector": ["stripe_test"], "phone_country_code": "+65", "authentication_type": "three_ds", "payment_method": "card", "payment_method_type": "debit", "payment_method_data": { "card": { "card_number": "4111111111111111", "card_exp_month": "03", "card_exp_year": "2030", "card_holder_name": "joseph Doe", "card_cvc": "737" } }, "browser_info": { "user_agent": "Mozilla\/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/70.0.3538.110 Safari\/537.36", "accept_header": "text\/html,application\/xhtml+xml,application\/xml;q=0.9,image\/webp,image\/apng,*\/*;q=0.8", "language": "nl-NL", "color_depth": 24, "screen_height": 723, "screen_width": 1536, "time_zone": 0, "java_enabled": true, "java_script_enabled": true, "ip_address": "128.0.0.1" }, "billing": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "preetam", "last_name": "revankar" }, "phone": { "number": "8056594427", "country_code": "+91" } }, "shipping": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "joseph", "last_name": "Doe" }, "phone": { "number": "8056594427", "country_code": "+91" } }, "order_details": [ { "product_name": "Apple iphone 15", "quantity": 1, "amount": 6540, "account_name": "transaction_processing" } ], "statement_descriptor_name": "joseph", "statement_descriptor_suffix": "JS", "metadata": { "udf1": "value1", "new_customer": "true", "login_date": "2019-09-10T10:11:12Z" } }' ``` This should return status code 200 <img width="1284" alt="Screenshot 2025-01-08 at 1 32 46 PM" src="https://github.com/user-attachments/assets/6863c4fb-534c-4b64-9ceb-dcf216e163ee" /> ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt --all` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed the submitted code
To implement this **payment** feature, you'll need to modify these architectural layers: **1. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/router_data.rs` - `crates/hyperswitch_domain_models/src/router_data_v2.rs` **2. Core Business Logic** - `crates/router/src/core/authentication.rs` - `crates/router/src/core/authentication/transformers.rs` - `crates/router/src/core/fraud_check/flows/checkout_flow.rs` - ... and 16 more files **3. External Connector Integration** - `crates/router/src/connector/dummyconnector.rs` - `crates/router/src/types/api/verify_connector.rs` - `crates/router/src/types/api/verify_connector/paypal.rs` - ... and 2 more files **4. Type Definitions** - `crates/router/src/types.rs` **5. Other** - `crates/router/src/services/conversion_impls.rs` **Code Patterns Applied:** - Extend existing types with new fields (62 changes) **Detailed Identifier Changes:** Commit 9c983b68: Files to modify: **crates/hyperswitch_domain_models/src/router_data.rs** Modify existing code **crates/hyperswitch_domain_models/src/router_data_v2.rs** Modify existing code **crates/router/src/connector/dummyconnector.rs** Modify existing code **crates/router/src/core/authentication.rs** Modify existing code **crates/router/src/core/authentication/transformers.rs** Modify existing code **crates/router/src/core/fraud_check/flows/checkout_flow.rs** Modify existing code **crates/router/src/core/fraud_check/flows/fulfillment_flow.rs** Modify existing code **crates/router/src/core/fraud_check/flows/record_return.rs** Modify existing code **crates/router/src/core/fraud_check/flows/sale_flow.rs** Modify existing code **crates/router/src/core/fraud_check/flows/transaction_flow.rs** Modify existing code **crates/router/src/core/mandate.rs** Modify existing code **crates/router/src/core/mandate/utils.rs** Modify existing code **crates/router/src/core/payments/helpers.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Modify existing code **crates/router/src/core/payouts.rs** Modify existing code **crates/router/src/core/relay/utils.rs** Modify existing code **crates/router/src/core/unified_authentication_service.rs** Modify existing code **crates/router/src/core/unified_authentication_service/utils.rs** Modify existing code **crates/router/src/core/utils.rs** Modify existing code **crates/router/src/core/webhooks/incoming.rs** Modify existing code **crates/router/src/core/webhooks/incoming_v2.rs** Modify existing code **crates/router/src/core/webhooks/utils.rs** Modify existing code **crates/router/src/services/conversion_impls.rs** Modify existing code **crates/router/src/types.rs** Modify existing code **crates/router/src/types/api/verify_connector.rs** Modify existing code **crates/router/src/types/api/verify_connector/paypal.rs** Modify existing code **crates/router/tests/connectors/aci.rs** Modify existing code **crates/router/tests/connectors/utils.rs** Modify existing code
{"pr_number": 7008, "pr_title": "fix(dummyconnector): add tenant id in dummyconnector requests", "merged_at": "2025-01-09T09:39:26Z", "intent": {"feature_type": "payment", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"domain": ["crates/hyperswitch_domain_models/src/router_data.rs", "crates/hyperswitch_domain_models/src/router_data_v2.rs"], "core_business": ["crates/router/src/core/authentication.rs", "crates/router/src/core/authentication/transformers.rs", "crates/router/src/core/fraud_check/flows/checkout_flow.rs", "crates/router/src/core/fraud_check/flows/fulfillment_flow.rs", "crates/router/src/core/fraud_check/flows/record_return.rs", "crates/router/src/core/fraud_check/flows/sale_flow.rs", "crates/router/src/core/fraud_check/flows/transaction_flow.rs", "crates/router/src/core/mandate.rs", "crates/router/src/core/mandate/utils.rs", "crates/router/src/core/payments/helpers.rs", "crates/router/src/core/payments/transformers.rs", "crates/router/src/core/payouts.rs", "crates/router/src/core/relay/utils.rs", "crates/router/src/core/unified_authentication_service.rs", "crates/router/src/core/unified_authentication_service/utils.rs", "crates/router/src/core/utils.rs", "crates/router/src/core/webhooks/incoming.rs", "crates/router/src/core/webhooks/incoming_v2.rs", "crates/router/src/core/webhooks/utils.rs"], "connectors": ["crates/router/src/connector/dummyconnector.rs", "crates/router/src/types/api/verify_connector.rs", "crates/router/src/types/api/verify_connector/paypal.rs", "crates/router/tests/connectors/aci.rs", "crates/router/tests/connectors/utils.rs"], "types": ["crates/router/src/types.rs"], "other": ["crates/router/src/services/conversion_impls.rs"]}, "change_types": {"fields_added": 62, "imports_added": 3}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
HOTFIX PR <!-- Describe your changes in detail --> Update metadata gives `500` error for other connectors than stripe Change this to `400` - Base pr : https://github.com/juspay/hyperswitch/pull/7984
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/router/src/core/payments/flows/update_metadata_flow.rs` - `crates/router/src/core/payments/transformers.rs` **Code Patterns Applied:** - Implement new functions (1 changes) - Extend existing types with new fields (60 changes) **Detailed Identifier Changes:** Commit 900fe338: Files to modify: **crates/router/src/core/payments/flows/update_metadata_flow.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Add: - function: pub::construct_payment_router_data_for_update_metadata
{"pr_number": 7986, "pr_title": "fix(update_metadata): Update Metadata for any connectors other than stripe gives 500 error", "merged_at": "2025-05-08T11:04:03Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "order", "connector"]}, "hierarchy": {"core_business": ["crates/router/src/core/payments/flows/update_metadata_flow.rs", "crates/router/src/core/payments/transformers.rs"]}, "change_types": {"functions_added": 1, "fields_added": 60}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
This PR enables country Malaysia for processing APay and GPay transactions via Fiuu
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Tests** - `config/deployments/integration_test.toml` **2. Configuration Files** - `config/deployments/production.toml` - `config/deployments/sandbox.toml` - `config/development.toml`
{"pr_number": 7182, "pr_title": "chore(connectors): [fiuu] update pm_filters for apple pay and google pay", "merged_at": "2025-02-06T15:20:10Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["user", "transaction"]}, "hierarchy": {"tests": ["config/deployments/integration_test.toml"], "config": ["config/deployments/production.toml", "config/deployments/sandbox.toml", "config/development.toml"]}, "change_types": {}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
<!-- Describe your changes in detail --> This PR introduces an API to list all payment attempts associated with a given intent_id.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/events/payment.rs` - `crates/api_models/src/payments.rs` **2. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/payments.rs` - `crates/hyperswitch_domain_models/src/router_flow_types/payments.rs` **3. Core Business Logic** - `crates/router/src/core/payments.rs` - `crates/router/src/core/payments/operations.rs` - `crates/router/src/core/payments/operations/payment_attempt_list.rs` - ... and 1 more files **4. Type Definitions** - `crates/router/src/types/api/payments.rs` - `crates/router_env/src/logger/types.rs` **5. Utils** - `crates/router/src/routes/lock_utils.rs` **6. Other** - `api-reference/v2/openapi_spec_v2.json` - `crates/openapi/src/openapi_v2.rs` - `crates/router/src/routes/app.rs` - ... and 1 more files **Code Patterns Applied:** - Define new data structures (5 changes) - Implement new functions (66 changes) - Extend existing types with new fields (91 changes) **Detailed Identifier Changes:** Commit 7943fb4b: Files to modify: **crates/api_models/src/events/payment.rs** Add: - function: private::get_api_event_type - function: private::get_api_event_type - impl: impl ApiEventMetric for PaymentAttemptListRequest - impl: impl ApiEventMetric for PaymentAttemptListResponse **crates/api_models/src/payments.rs** Add: - struct: pub::PaymentAttemptListRequest - struct: pub::PaymentAttemptListResponse **crates/hyperswitch_domain_models/src/payments.rs** Add: - struct: pub::PaymentAttemptListData **crates/hyperswitch_domain_models/src/router_flow_types/payments.rs** Add: - struct: pub::PaymentGetListAttempts **crates/openapi/src/openapi_v2.rs** Modify existing code **crates/router/src/core/payments.rs** Add: - function: pub::payments_attempt_operation_core - function: pub::payments_list_attempts_using_payment_intent_id - function: private::list_payments_attempts - function: private::list_payments_attempts - function: private::list_payments_attempts - function: private::list_payments_attempts - function: private::get_payment_attempt - function: private::list_payments_attempts - function: private::get_client_secret - function: private::get_payment_intent - function: private::get_payment_method_info - function: private::get_mandate_id - function: private::get_address - function: private::get_creds_identifier - function: private::get_token - function: private::get_multiple_capture_data - function: private::get_payment_link_data - function: private::get_ephemeral_key - function: private::get_setup_mandate - function: private::get_poll_config - function: private::get_authentication - function: private::get_frm_message - function: private::get_refunds - function: private::get_disputes - function: private::get_authorizations - function: private::get_attempts - function: private::get_recurring_details - function: private::get_payment_intent_profile_id - function: private::get_currency - function: private::get_amount - function: private::get_payment_attempt_connector - function: private::get_merchant_connector_id_in_attempt - function: private::get_connector_customer_id - function: private::get_billing_address - function: private::get_payment_method_data - function: private::get_sessions_token - function: private::get_token_data - function: private::get_mandate_connector - function: private::get_force_sync - function: private::get_capture_method - function: private::get_optional_payment_attempt - function: private::get_all_keys_required - function: private::get_whole_connector_response - function: private::get_pre_routing_result - function: private::get_merchant_connector_details - function: private::get_optional_external_vault_session_details - impl: impl OperationSessionGetters<F> for PaymentAttemptListData<F> **crates/router/src/core/payments/operations.rs** Remove: - mod: pub::proxy_payments_intent Add: - mod: pub::payment_attempt_list - mod: pub::proxy_payments_intent **crates/router/src/core/payments/operations/payment_attempt_list.rs** Add: - function: private::to_validate_request - function: private::to_get_tracker - function: private::to_domain - function: private::to_update_tracker - function: private::to_validate_request - function: private::to_get_tracker - function: private::to_domain - function: private::to_update_tracker - function: private::get_trackers - function: private::update_trackers - function: private::validate_request - function: private::get_customer_details - function: private::make_pm_data - function: private::perform_routing - function: private::guard_payment_against_blocklist - struct: pub::PaymentGetListAttempts - impl: impl Operation<F, PaymentAttemptListRequest> for &PaymentGetListAttempts - impl: impl Operation<F, PaymentAttemptListRequest> for PaymentGetListAttempts - impl: impl GetTracker<F, payments::PaymentAttemptListData<F>, PaymentAttemptListRequest> for PaymentGetListAttempts - impl: impl UpdateTracker<F, payments::PaymentAttemptListData<F>, PaymentAttemptListRequest> for PaymentGetListAttempts - impl: impl ValidateRequest<F, PaymentAttemptListRequest, payments::PaymentAttemptListData<F>> for PaymentGetListAttempts - impl: impl Domain<F, PaymentAttemptListRequest, payments::PaymentAttemptListData<F>> for PaymentGetListAttempts **crates/router/src/core/payments/transformers.rs** Add: - function: private::generate_response - impl: impl ToResponse<F, D, Op> for api::PaymentAttemptListResponse **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/lock_utils.rs** Modify existing code **crates/router/src/routes/payments.rs** Add: - function: pub::list_payment_attempts **crates/router/src/types/api/payments.rs** Modify existing code **crates/router_env/src/logger/types.rs** Modify existing code
{"pr_number": 8368, "pr_title": "feat(router): Add v2 endpoint to list payment attempts by intent_id", "merged_at": "2025-06-20T06:58:02Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "merchant", "order"]}, "hierarchy": {"api_models": ["crates/api_models/src/events/payment.rs", "crates/api_models/src/payments.rs"], "domain": ["crates/hyperswitch_domain_models/src/payments.rs", "crates/hyperswitch_domain_models/src/router_flow_types/payments.rs"], "core_business": ["crates/router/src/core/payments.rs", "crates/router/src/core/payments/operations.rs", "crates/router/src/core/payments/operations/payment_attempt_list.rs", "crates/router/src/core/payments/transformers.rs"], "types": ["crates/router/src/types/api/payments.rs", "crates/router_env/src/logger/types.rs"], "utils": ["crates/router/src/routes/lock_utils.rs"], "other": ["api-reference/v2/openapi_spec_v2.json", "crates/openapi/src/openapi_v2.rs", "crates/router/src/routes/app.rs", "crates/router/src/routes/payments.rs"]}, "change_types": {"structs_added": 5, "functions_added": 66, "fields_added": 91, "imports_added": 7}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Updated the readme and local setup guide to add the new script
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Other** - `README.md` - `docs/try_local_system.md`
{"pr_number": 7839, "pr_title": "docs: update the setup docs", "merged_at": "2025-04-24T07:56:02Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"other": ["README.md", "docs/try_local_system.md"]}, "change_types": {}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
<!-- Describe your changes in detail --> There was a trailing whitespace in `postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication `. Because of which there was an error when attempting to clone the repo in other systems like Windows etc. Removed this trailing whitespace.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Tests** - `postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Confirm/event.test.js` - `postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Create/event.test.js` - `postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Retrieve after confirm/event.test.js` **2. Other** - `postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /.meta.json` - `postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Confirm/.event.meta.json` - `postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Confirm/event.prerequest.js` - ... and 9 more files
{"pr_number": 9578, "pr_title": "fix(postman): [ARCHIPEL] Remove Trailing Whitespace", "merged_at": "2025-10-07T17:32:55Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "user"]}, "hierarchy": {"tests": ["postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Confirm/event.test.js", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Create/event.test.js", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Retrieve after confirm/event.test.js"], "other": ["postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /.meta.json", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Confirm/.event.meta.json", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Confirm/event.prerequest.js", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Confirm/request.json", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Confirm/response.json", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Create/.event.meta.json", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Create/event.prerequest.js", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Create/request.json", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Create/response.json", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Retrieve after confirm/.event.meta.json", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Retrieve after confirm/request.json", "postman/collection-dir/archipel/Flow Testcases/Happy Cases/Scenario10-Create 3DS payment without external 3ds authentication /Payments - Retrieve after confirm/response.json"]}, "change_types": {}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
<!-- Describe your changes in detail --> The merchant domain url is only required in case of samsung pay payments on web. While processing payments on app the merchant domain is not required. Hence mandate the merchant domain only if the `x-client-platform` is `web`
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/payments.rs` **2. Core Business Logic** - `crates/router/src/core/payments/flows/session_flow.rs` **3. Other** - `api-reference-v2/openapi_spec.json` - `api-reference/openapi_spec.json` **Code Patterns Applied:** - Extend existing types with new fields (1 changes) **Detailed Identifier Changes:** Commit ba6f7a81: Files to modify: **crates/api_models/src/payments.rs** Modify existing code **crates/router/src/core/payments/flows/session_flow.rs** Modify existing code
{"pr_number": 6362, "pr_title": "fix(router): make `x_merchant_domain` as required value only for session call done on web", "merged_at": "2024-10-19T14:22:39Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/payments.rs"], "core_business": ["crates/router/src/core/payments/flows/session_flow.rs"], "other": ["api-reference-v2/openapi_spec.json", "api-reference/openapi_spec.json"]}, "change_types": {"fields_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> This PR introduces improvements to the **Customer page API**: Added **search bar functionality** to filter customers by `customer_id`. These changes enhance API usability and improve performance when handling large customer datasets.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/customers.rs` **2. Database Layer (Queries & Schema)** - `crates/diesel_models/src/query/customers.rs` **3. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/customer.rs` **4. Core Business Logic** - `crates/router/src/core/customers.rs` - `crates/router/src/core/locker_migration.rs` **Code Patterns Applied:** - Implement new functions (1 changes) - Extend existing types with new fields (9 changes) - Add conditional logic for feature flags or filtering (2 changes) - Modify database queries (7 changes) **Detailed Identifier Changes:** Commit e186a0f4: Files to modify: **crates/api_models/src/customers.rs** Modify existing code **crates/diesel_models/src/query/customers.rs** Modify existing code **crates/hyperswitch_domain_models/src/customer.rs** Modify existing code **crates/router/src/core/customers.rs** Modify existing code **crates/router/src/core/locker_migration.rs** Modify existing code
{"pr_number": 9619, "pr_title": "Feat(Customer): Added search Feature to the Customer Page", "merged_at": "2025-10-03T10:06:30Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "user"]}, "hierarchy": {"api_models": ["crates/api_models/src/customers.rs"], "database": ["crates/diesel_models/src/query/customers.rs"], "domain": ["crates/hyperswitch_domain_models/src/customer.rs"], "core_business": ["crates/router/src/core/customers.rs", "crates/router/src/core/locker_migration.rs"]}, "change_types": {"functions_added": 1, "fields_added": 9, "conditionals_added": 2, "database_queries": 7}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
#### **POST** `/user/role/v2` - Creates a role using `parent_groups` (with `name` + `scopes`) instead of granular `groups`. - Internally maps `parent_groups` + `scopes` to existing granular permissions for DB storage.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/events/user_role.rs` - `crates/api_models/src/user_role/role.rs` **2. Core Business Logic** - `crates/router/src/core/user_role.rs` - `crates/router/src/core/user_role/role.rs` **3. Type Definitions** - `crates/router_env/src/logger/types.rs` **4. Utils** - `crates/router/src/routes/lock_utils.rs` - `crates/router/src/utils/user_role.rs` **5. Other** - `crates/common_enums/src/enums.rs` - `crates/router/src/routes/app.rs` - `crates/router/src/routes/user_role.rs` - ... and 1 more files **Code Patterns Applied:** - Define new data structures (5 changes) - Implement new functions (8 changes) - Extend existing types with new fields (55 changes) - Add conditional logic for feature flags or filtering (9 changes) - Modify database queries (12 changes) **Detailed Identifier Changes:** Commit e3c46b7d: Files to modify: **crates/api_models/src/events/user_role.rs** Modify existing code **crates/api_models/src/user_role/role.rs** Remove: - struct: pub::ListRolesRequest Add: - struct: pub::CreateRoleV2Request - struct: pub::ParentGroupInfoRequest - struct: pub::ListRolesQueryParams - struct: pub::GetParentGroupsInfoQueryParams - enum: pub::ListRolesResponse **crates/common_enums/src/enums.rs** Modify existing code **crates/router/src/core/user_role.rs** Modify existing code **crates/router/src/core/user_role/role.rs** Add: - function: pub::create_role_v2 **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/lock_utils.rs** Modify existing code **crates/router/src/routes/user_role.rs** Add: - function: pub::create_role_v2 **crates/router/src/services/authorization/permission_groups.rs** Modify existing code **crates/router/src/utils/user_role.rs** Add: - function: pub::parent_group_info_request_to_permission_groups - function: pub::permission_groups_to_parent_group_info **crates/router_env/src/logger/types.rs** Modify existing code
{"pr_number": 8896, "pr_title": "refactor(user_roles): implement parent group info based role APIs", "merged_at": "2025-08-22T14:03:34Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/events/user_role.rs", "crates/api_models/src/user_role/role.rs"], "core_business": ["crates/router/src/core/user_role.rs", "crates/router/src/core/user_role/role.rs"], "types": ["crates/router_env/src/logger/types.rs"], "utils": ["crates/router/src/routes/lock_utils.rs", "crates/router/src/utils/user_role.rs"], "other": ["crates/common_enums/src/enums.rs", "crates/router/src/routes/app.rs", "crates/router/src/routes/user_role.rs", "crates/router/src/services/authorization/permission_groups.rs"]}, "change_types": {"structs_added": 5, "functions_added": 8, "enums_added": 1, "fields_added": 55, "imports_added": 4, "conditionals_added": 9, "database_queries": 12}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
ORIGINAL PR:https://github.com/juspay/hyperswitch/pull/9253
To implement this **unknown** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/authorizedotnet/transformers.rs` **Code Patterns Applied:** - Extend existing types with new fields (12 changes) **Detailed Identifier Changes:** Commit 77c7ec33: Files to modify: **crates/hyperswitch_connectors/src/connectors/authorizedotnet/transformers.rs** Modify existing code
{"pr_number": 9276, "pr_title": "fix(connector): Revert [AUTHORIZEDOTNET] customer id population fixed in authorize flow", "merged_at": "2025-09-04T11:07:11Z", "intent": {"feature_type": "unknown", "action": "unknown", "entities": []}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/src/connectors/authorizedotnet/transformers.rs"]}, "change_types": {"fields_added": 12}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
bumping tonic version from 0.12 to 0.13
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Configuration Files** - `crates/external_services/Cargo.toml` **2. Other** - `Cargo.lock` - `crates/external_services/build.rs` - `crates/external_services/src/grpc_client.rs` **Code Patterns Applied:** **Detailed Identifier Changes:** Commit 9e435929: Files to modify: **crates/external_services/build.rs** Modify existing code **crates/external_services/src/grpc_client.rs** Modify existing code
{"pr_number": 8461, "pr_title": "build(deps): bump tonic version from 0.12 to 0.13", "merged_at": "2025-06-26T06:26:30Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["user"]}, "hierarchy": {"config": ["crates/external_services/Cargo.toml"], "other": ["Cargo.lock", "crates/external_services/build.rs", "crates/external_services/src/grpc_client.rs"]}, "change_types": {"imports_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Implement payments sync for v2. Using this endpoint the status of the payment can be retrieved and also synced with the connector. ## Motivation and Context <!-- Why is this change required? What problem does it solve? If it fixes an open issue, please link to the issue here. If you don't have an issue, we'd recommend starting with one first so the PR can focus on the implementation (unless it is an obvious bug or documentation fix that will have little conversation). --> ## How did you test it? <!-- Did you write an integration/unit/API test to verify the code changes? Or did you test this change manually (provide relevant screenshots)? --> - Create a payment ```bash curl --location 'http://localhost:8080/v2/payments/create-intent' \ --header 'api-key: dev_5BpYAlWiFrmujr10auC6jj48LPGkN7vMJYXv7hKTuLVRLSEt0BancBwWgfzAELii' \ --header 'Content-Type: application/json' \ --header 'x-profile-id: pro_NZsp8AqhIFzKshd7BxX4' \ --data '{ "amount_details": { "order_amount": 100, "currency": "USD" } }' ``` ```json { "id": "12345_pay_01931afcc2667a839d75d2e760b99d1e", "status": "requires_payment_method", "amount_details": { "order_amount": 100, "currency": "USD", "shipping_cost": null, "order_tax_amount": null, "skip_external_tax_calculation": "Skip", "skip_surcharge_calculation": "Skip", "surcharge_amount": null, "tax_on_surcharge": null }, "client_secret": "12345_pay_01931afcc2667a839d75d2e760b99d1e_secret_01931afcc2667a839d75d2f412de1c77", "merchant_reference_id": null, "routing_algorithm_id": null, "capture_method": "automatic", "authentication_type": "no_three_ds", "billing": null, "shipping": null, "customer_id": null, "customer_present": "Present", "description": null, "return_url": null, "setup_future_usage": "on_session", "apply_mit_exemption": "Skip", "statement_descriptor": null, "order_details": null, "allowed_payment_method_types": null, "metadata": null, "connector_metadata": null, "feature_metadata": null, "payment_link_enabled": "Skip", "payment_link_config": null, "request_incremental_authorization": "default", "expires_on": "2024-11-11T11:44:52.743Z", "frm_metadata": null, "request_external_three_ds_authentication": "Skip" } ``` - Confirm the payment ```bash curl --location 'http://localhost:8080/v2/payments/12345_pay_0192d87d5bfc72e2bd4985b52eb608b5/confirm-intent' \ --header 'x-profile-id: pro_NZsp8AqhIFzKshd7BxX4' \ --header 'x-client-secret: 12345_pay_0192d87d5bfc72e2bd4985b52eb608b5_secret_0192d87d5bfc72e2bd4985c73c6ae36d' \ --header 'Content-Type: application/json' \ --header 'api-key: pk_dev_d48019a209df4d5d8567c9e5d2bdc5af' \ --data '{ "payment_method_data": { "card": { "card_number": "4242424242424242", "card_exp_month": "01", "card_exp_year": "27", "card_holder_name": "John Doe", "card_cvc": "100" } }, "payment_method_type": "card", "payment_method_subtype": "credit" }' ``` ```json { "id": "12345_pay_01931afcc2667a839d75d2e760b99d1e", "status": "succeeded", "amount": { "order_amount": 100, "currency": "USD", "shipping_cost": null, "order_tax_amount": null, "skip_external_tax_calculation": "Skip", "skip_surcharge_calculation": "Skip", "surcharge_amount": null, "tax_on_surcharge": null, "net_amount": 100, "amount_to_capture": null, "amount_capturable": 0, "amount_captured": null }, "connector": "stripe", "client_secret": "12345_pay_01931afcc2667a839d75d2e760b99d1e_secret_01931afcc2667a839d75d2f412de1c77", "created": "2024-11-11T11:29:52.743Z", "payment_method_data": null, "payment_method_type": "card", "payment_method_subtype": "credit", "next_action": null, "connector_transaction_id": "pi_3QJvocIVaesDjvMP0szRoodA", "connector_reference_id": null, "merchant_connector_id": "mca_It087vhsTsNtgtnTnYd6", "browser_info": null, "error": null } ``` - Retrieve the payment ```bash curl --location 'http://localhost:8080/v2/payments/12345_pay_0192d87d5bfc72e2bd4985b52eb608b5' \ --header 'x-profile-id: pro_NZsp8AqhIFzKshd7BxX4' \ --header 'x-client-secret: 12345_pay_0192d87d5bfc72e2bd4985b52eb608b5_secret_0192d87d5bfc72e2bd4985c73c6ae36d' \ --header 'Content-Type: application/json' \ --header 'api-key: pk_dev_d48019a209df4d5d8567c9e5d2bdc5af' ``` ```json { "id": "12345_pay_01931afcc2667a839d75d2e760b99d1e", "status": "succeeded", "amount": { "order_amount": 100, "currency": "USD", "shipping_cost": null, "order_tax_amount": null, "skip_external_tax_calculation": "Skip", "skip_surcharge_calculation": "Skip", "surcharge_amount": null, "tax_on_surcharge": null, "net_amount": 100, "amount_to_capture": null, "amount_capturable": 0, "amount_captured": null }, "connector": "stripe", "client_secret": "12345_pay_01931afcc2667a839d75d2e760b99d1e_secret_01931afcc2667a839d75d2f412de1c77", "created": "2024-11-11T11:29:52.743Z", "payment_method_data": null, "payment_method_type": "card", "payment_method_subtype": "credit", "connector_transaction_id": "pi_3QJvocIVaesDjvMP0szRoodA", "connector_reference_id": null, "merchant_connector_id": "mca_It087vhsTsNtgtnTnYd6", "browser_info": null, "error": null } ``` ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt --all` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed the submitted code
To implement this **payment** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/events/payment.rs` - `crates/api_models/src/payments.rs` **2. Database Layer (Queries & Schema)** - `crates/diesel_models/src/kv.rs` - `crates/diesel_models/src/payment_attempt.rs` - `crates/diesel_models/src/payment_intent.rs` - ... and 3 more files **3. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/merchant_connector_account.rs` - `crates/hyperswitch_domain_models/src/payments.rs` - `crates/hyperswitch_domain_models/src/payments/payment_attempt.rs` - ... and 3 more files **4. Core Business Logic** - `crates/router/src/core/authentication/utils.rs` - `crates/router/src/core/fraud_check/flows/checkout_flow.rs` - `crates/router/src/core/fraud_check/flows/record_return.rs` - ... and 25 more files **5. Type Definitions** - `crates/common_utils/src/types.rs` - `crates/router/src/types/api.rs` - `crates/router/src/types/transformers.rs` **6. Other** - `api-reference-v2/openapi_spec.json` - `crates/common_enums/src/enums.rs` - `crates/common_enums/src/transformers.rs` - ... and 17 more files **Code Patterns Applied:** - Define new data structures (4 changes) - Implement new functions (130 changes) - Extend existing types with new fields (454 changes) - Modify database queries (3 changes) **Detailed Identifier Changes:** Commit 42bdf47f: Files to modify: **crates/api_models/src/events/payment.rs** Add: - function: private::get_api_event_type - impl: impl ApiEventMetric for super::PaymentsRetrieveResponse **crates/api_models/src/payments.rs** Add: - struct: pub::PaymentsRetrieveRequest - struct: pub::PaymentsRetrieveResponse **crates/common_enums/src/enums.rs** Add: - function: pub::should_force_sync_with_connector - impl: impl IntentStatus **crates/common_enums/src/transformers.rs** Add: - function: private::from - impl: impl From<AttemptStatus> for IntentStatus **crates/common_utils/src/types.rs** Add: - function: pub::wrap - function: pub::into_inner **crates/diesel_models/src/kv.rs** Modify existing code **crates/diesel_models/src/payment_attempt.rs** Add: - enum: pub::RedirectForm **crates/diesel_models/src/payment_intent.rs** Modify existing code **crates/diesel_models/src/query/payment_attempt.rs** Modify existing code **crates/diesel_models/src/query/payment_intent.rs** Modify existing code **crates/diesel_models/src/schema_v2.rs** Modify existing code **crates/hyperswitch_domain_models/src/merchant_connector_account.rs** Add: - function: pub::is_disabled - function: pub::get_connector_account_details **crates/hyperswitch_domain_models/src/payments.rs** Add: - struct: pub::PaymentStatusData **crates/hyperswitch_domain_models/src/payments/payment_attempt.rs** Modify existing code **crates/hyperswitch_domain_models/src/payments/payment_intent.rs** Remove: - function: private::from - impl: impl From<PaymentIntentUpdate> for PaymentIntentUpdateInternal - impl: impl From<PaymentIntentUpdate> for DieselPaymentIntentUpdate Add: - impl: impl From<PaymentIntentUpdate> for diesel_models::PaymentIntentUpdateInternal **crates/hyperswitch_domain_models/src/router_data.rs** Add: - function: private::get_payment_intent_update - function: private::get_payment_attempt_update - function: private::get_payment_intent_update - function: private::get_payment_attempt_update - trait: pub::TrackerPostUpdateObjects - impl: impl TrackerPostUpdateObjects< router_flow_types::Authorize, router_request_types::PaymentsAuthorizeData, > for RouterData< router_flow_types::Authorize, router_request_types::PaymentsAuthorizeData, router_response_types::PaymentsResponseData, > - impl: impl TrackerPostUpdateObjects<router_flow_types::PSync, router_request_types::PaymentsSyncData> for RouterData< router_flow_types::PSync, router_request_types::PaymentsSyncData, router_response_types::PaymentsResponseData, > **crates/hyperswitch_domain_models/src/router_response_types.rs** Add: - function: private::from - function: private::from - impl: impl From<RedirectForm> for diesel_models::payment_attempt::RedirectForm - impl: impl From<diesel_models::payment_attempt::RedirectForm> for RedirectForm **crates/router/src/compatibility/stripe/payment_intents.rs** Modify existing code **crates/router/src/compatibility/stripe/setup_intents.rs** Modify existing code **crates/router/src/core/authentication/utils.rs** Modify existing code **crates/router/src/core/fraud_check/flows/checkout_flow.rs** Modify existing code **crates/router/src/core/fraud_check/flows/record_return.rs** Modify existing code **crates/router/src/core/fraud_check/flows/sale_flow.rs** Modify existing code **crates/router/src/core/fraud_check/flows/transaction_flow.rs** Modify existing code **crates/router/src/core/payments.rs** Add: - function: private::get_optional_payment_attempt - function: private::get_optional_payment_attempt - function: private::get_optional_payment_attempt - function: private::get_payment_attempt - function: private::get_payment_intent - function: private::get_payment_method_info - function: private::get_mandate_id - function: private::get_address - function: private::get_creds_identifier - function: private::get_token - function: private::get_multiple_capture_data - function: private::get_payment_link_data - function: private::get_ephemeral_key - function: private::get_setup_mandate - function: private::get_poll_config - function: private::get_authentication - function: private::get_frm_message - function: private::get_refunds - function: private::get_disputes - function: private::get_authorizations - function: private::get_attempts - function: private::get_recurring_details - function: private::get_payment_intent_profile_id - function: private::get_currency - function: private::get_amount - function: private::get_payment_attempt_connector - function: private::get_billing_address - function: private::get_payment_method_data - function: private::get_sessions_token - function: private::get_token_data - function: private::get_mandate_connector - function: private::get_force_sync - function: private::get_capture_method - function: private::get_optional_payment_attempt - function: private::set_payment_intent - function: private::set_payment_attempt - function: private::set_payment_method_data - function: private::set_payment_method_id_in_attempt - function: private::set_email_if_not_present - function: private::set_pm_token - function: private::set_connector_customer_id - function: private::push_sessions_token - function: private::set_surcharge_details - function: private::set_merchant_connector_id_in_attempt - function: private::set_frm_message - function: private::set_payment_intent_status - function: private::set_authentication_type_in_attempt - function: private::set_recurring_mandate_payment_data - function: private::set_mandate_id - function: private::set_setup_future_usage_in_payment_intent - function: private::set_connector_in_payment_attempt - impl: impl OperationSessionGetters<F> for PaymentStatusData<F> - impl: impl OperationSessionSetters<F> for PaymentStatusData<F> **crates/router/src/core/payments/flows.rs** Modify existing code **crates/router/src/core/payments/flows/approve_flow.rs** Add: - function: private::construct_router_data **crates/router/src/core/payments/flows/authorize_flow.rs** Modify existing code **crates/router/src/core/payments/flows/cancel_flow.rs** Add: - function: private::construct_router_data **crates/router/src/core/payments/flows/capture_flow.rs** Add: - function: private::construct_router_data **crates/router/src/core/payments/flows/complete_authorize_flow.rs** Add: - function: private::construct_router_data **crates/router/src/core/payments/flows/incremental_authorization_flow.rs** Add: - function: private::construct_router_data **crates/router/src/core/payments/flows/post_session_tokens_flow.rs** Add: - function: private::construct_router_data **crates/router/src/core/payments/flows/psync_flow.rs** Add: - function: private::construct_router_data - function: private::get_merchant_recipient_data - impl: impl ConstructFlowSpecificData<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> for hyperswitch_domain_models::payments::PaymentStatusData<api::PSync> **crates/router/src/core/payments/flows/reject_flow.rs** Add: - function: private::construct_router_data **crates/router/src/core/payments/flows/session_flow.rs** Add: - function: private::construct_router_data **crates/router/src/core/payments/flows/session_update_flow.rs** Add: - function: private::construct_router_data **crates/router/src/core/payments/flows/setup_mandate_flow.rs** Add: - function: private::construct_router_data **crates/router/src/core/payments/operations.rs** Remove: - function: private::get_customer_details Add: - trait: pub::CallConnector - trait: pub::ShouldCallConnector - mod: pub::payment_get **crates/router/src/core/payments/operations/payment_confirm_intent.rs** Modify existing code **crates/router/src/core/payments/operations/payment_create_intent.rs** Modify existing code **crates/router/src/core/payments/operations/payment_get.rs** Add: - function: private::validate_status_for_operation - function: private::to_validate_request - function: private::to_get_tracker - function: private::to_domain - function: private::to_update_tracker - function: private::to_validate_request - function: private::to_get_tracker - function: private::to_domain - function: private::to_update_tracker - function: private::validate_request - function: private::get_trackers - function: private::get_customer_details - function: private::make_pm_data - function: private::perform_routing - function: private::update_trackers - struct: pub::PaymentGet - impl: impl ValidateStatusForOperation for PaymentGet - impl: impl Operation<F, PaymentsRetrieveRequest> for &PaymentGet - impl: impl Operation<F, PaymentsRetrieveRequest> for PaymentGet - impl: impl ValidateRequest<F, PaymentsRetrieveRequest, PaymentStatusData<F>> for PaymentGet - impl: impl GetTracker<F, PaymentStatusData<F>, PaymentsRetrieveRequest> for PaymentGet - impl: impl Domain<F, PaymentsRetrieveRequest, PaymentStatusData<F>> for PaymentGet - impl: impl UpdateTracker<F, PaymentStatusData<F>, PaymentsRetrieveRequest> for PaymentGet **crates/router/src/core/payments/operations/payment_get_intent.rs** Modify existing code **crates/router/src/core/payments/operations/payment_response.rs** Add: - function: private::to_post_update_tracker - impl: impl Operation<F, types::PaymentsSyncData> for PaymentResponse **crates/router/src/core/payments/retry.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Add: - function: pub::construct_router_data_for_psync - function: private::generate_response - function: private::foreign_from - impl: impl ToResponse<F, D, Op> for api_models::payments::PaymentsRetrieveResponse - impl: impl ForeignFrom<( &hyperswitch_domain_models::payments::AmountDetails, Option<&hyperswitch_domain_models::payments::payment_attempt::AttemptAmountDetails>, )> for api_models::payments::ConfirmIntentAmountDetailsResponse **crates/router/src/core/payouts.rs** Add: - function: pub::complete_payout_retrieve **crates/router/src/db/kafka_store.rs** Modify existing code **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/payments.rs** Add: - function: pub::payment_status **crates/router/src/routes/routing.rs** Modify existing code **crates/router/src/services/authentication.rs** Remove: - function: private::get_client_secret - struct: pub::ApiKeyAuthV2 - impl: impl ClientSecretFetch for payments::PaymentsRetrieveRequest Add: - function: private::get_client_secret - impl: impl ClientSecretFetch for payments::PaymentsRetrieveRequest **crates/router/src/types/api.rs** Modify existing code **crates/router/src/types/transformers.rs** Modify existing code **crates/storage_impl/src/mock_db/payment_attempt.rs** Modify existing code **crates/storage_impl/src/mock_db/payment_intent.rs** Add: - function: private::update_payment_intent **crates/storage_impl/src/payments/payment_attempt.rs** Modify existing code **crates/storage_impl/src/payments/payment_intent.rs** Add: - function: private::update_payment_intent
{"pr_number": 6464, "pr_title": "feat(payment_v2): implement payments sync ", "merged_at": "2024-11-11T14:06:06Z", "intent": {"feature_type": "payment", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/events/payment.rs", "crates/api_models/src/payments.rs"], "database": ["crates/diesel_models/src/kv.rs", "crates/diesel_models/src/payment_attempt.rs", "crates/diesel_models/src/payment_intent.rs", "crates/diesel_models/src/query/payment_attempt.rs", "crates/diesel_models/src/query/payment_intent.rs", "crates/diesel_models/src/schema_v2.rs"], "domain": ["crates/hyperswitch_domain_models/src/merchant_connector_account.rs", "crates/hyperswitch_domain_models/src/payments.rs", "crates/hyperswitch_domain_models/src/payments/payment_attempt.rs", "crates/hyperswitch_domain_models/src/payments/payment_intent.rs", "crates/hyperswitch_domain_models/src/router_data.rs", "crates/hyperswitch_domain_models/src/router_response_types.rs"], "core_business": ["crates/router/src/core/authentication/utils.rs", "crates/router/src/core/fraud_check/flows/checkout_flow.rs", "crates/router/src/core/fraud_check/flows/record_return.rs", "crates/router/src/core/fraud_check/flows/sale_flow.rs", "crates/router/src/core/fraud_check/flows/transaction_flow.rs", "crates/router/src/core/payments.rs", "crates/router/src/core/payments/flows.rs", "crates/router/src/core/payments/flows/approve_flow.rs", "crates/router/src/core/payments/flows/authorize_flow.rs", "crates/router/src/core/payments/flows/cancel_flow.rs", "crates/router/src/core/payments/flows/capture_flow.rs", "crates/router/src/core/payments/flows/complete_authorize_flow.rs", "crates/router/src/core/payments/flows/incremental_authorization_flow.rs", "crates/router/src/core/payments/flows/post_session_tokens_flow.rs", "crates/router/src/core/payments/flows/psync_flow.rs", "crates/router/src/core/payments/flows/reject_flow.rs", "crates/router/src/core/payments/flows/session_flow.rs", "crates/router/src/core/payments/flows/session_update_flow.rs", "crates/router/src/core/payments/flows/setup_mandate_flow.rs", "crates/router/src/core/payments/operations.rs", "crates/router/src/core/payments/operations/payment_confirm_intent.rs", "crates/router/src/core/payments/operations/payment_create_intent.rs", "crates/router/src/core/payments/operations/payment_get.rs", "crates/router/src/core/payments/operations/payment_get_intent.rs", "crates/router/src/core/payments/operations/payment_response.rs", "crates/router/src/core/payments/retry.rs", "crates/router/src/core/payments/transformers.rs", "crates/router/src/core/payouts.rs"], "types": ["crates/common_utils/src/types.rs", "crates/router/src/types/api.rs", "crates/router/src/types/transformers.rs"], "other": ["api-reference-v2/openapi_spec.json", "crates/common_enums/src/enums.rs", "crates/common_enums/src/transformers.rs", "crates/router/src/compatibility/stripe/payment_intents.rs", "crates/router/src/compatibility/stripe/setup_intents.rs", "crates/router/src/db/kafka_store.rs", "crates/router/src/routes/app.rs", "crates/router/src/routes/payments.rs", "crates/router/src/routes/routing.rs", "crates/router/src/services/authentication.rs", "crates/storage_impl/src/mock_db/payment_attempt.rs", "crates/storage_impl/src/mock_db/payment_intent.rs", "crates/storage_impl/src/payments/payment_attempt.rs", "crates/storage_impl/src/payments/payment_intent.rs", "v2_migrations/2024-08-28-081721_add_v2_columns/down.sql", "v2_migrations/2024-08-28-081721_add_v2_columns/up.sql", "v2_migrations/2024-08-28-081838_update_v2_primary_key_constraints/down.sql", "v2_migrations/2024-08-28-081838_update_v2_primary_key_constraints/up.sql", "v2_migrations/2024-10-08-081847_drop_v1_columns/down.sql", "v2_migrations/2024-10-08-081847_drop_v1_columns/up.sql"]}, "change_types": {"structs_added": 4, "functions_added": 130, "enums_added": 1, "fields_added": 454, "imports_added": 25, "database_queries": 3}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> This PR contains support for db calls that are used in refunds v2 core flows for non kv config. There are 2 ways that HS use to interact with DB, using KV and without KV. In code we represent it by `kv_store` feature flag.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Other** - `crates/router/src/db/refund.rs` **Code Patterns Applied:** - Implement new functions (4 changes) - Extend existing types with new fields (13 changes) **Detailed Identifier Changes:** Commit e6482fbe: Files to modify: **crates/router/src/db/refund.rs** Add: - function: private::find_refund_by_id - function: private::update_refund - function: private::filter_refund_by_constraints - function: private::get_total_count_of_refunds
{"pr_number": 7987, "pr_title": "refactor(refunds_v2): Add feature flags and db methods to non kv config", "merged_at": "2025-06-03T08:51:28Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "merchant", "user"]}, "hierarchy": {"other": ["crates/router/src/db/refund.rs"]}, "change_types": {"functions_added": 4, "fields_added": 13, "imports_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Fixed customer ID population in the Authorize flow. - Previously, when passing customer details for normal payments, the createConnectorCustomer flow correctly created the customer. - However, in the `Authorize` flow, we were passing the payment_id as the customer_id. If the length validation failed, a random string was being passed instead. - This resulted in a random string always being sent as the customer_id, which caused a new customer to be created on Authorize.NET’s dashboard for every transaction. - As a result, duplicate customers were being created. Fix: - Updated the flow to pass the correct customer_id in the customer details instead of payment_id. - This prevents duplicate customer creation on Authorize.NET.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/authorizedotnet/transformers.rs` **Code Patterns Applied:** - Extend existing types with new fields (12 changes) - Add conditional logic for feature flags or filtering (4 changes) **Detailed Identifier Changes:** Commit 60ef06e8: Files to modify: **crates/hyperswitch_connectors/src/connectors/authorizedotnet/transformers.rs** Modify existing code
{"pr_number": 9079, "pr_title": "fix(connector): [AUTHORIZEDOTNET] customer id population fixed in authorize flow", "merged_at": "2025-08-29T10:41:40Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/src/connectors/authorizedotnet/transformers.rs"]}, "change_types": {"fields_added": 12, "conditionals_added": 4}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Updated the create_platform endpoint in api-reference docs Previously the endpoint was: ```bash /create_platform ``` Updated the endpoint now to: ```bash /user/create_platform ```
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Other** - `api-reference/v1/openapi_spec_v1.json` - `api-reference/v1/platform/platform--create.mdx` - `crates/openapi/src/routes/platform.rs` **Detailed Identifier Changes:** Commit 8dc4061f: Files to modify: **crates/openapi/src/routes/platform.rs** Modify existing code
{"pr_number": 8782, "pr_title": "fix(openapi): update create_platform endpoint in api-reference docs", "merged_at": "2025-07-30T06:57:15Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["user"]}, "hierarchy": {"other": ["api-reference/v1/openapi_spec_v1.json", "api-reference/v1/platform/platform--create.mdx", "crates/openapi/src/routes/platform.rs"]}, "change_types": {}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> This PR implements **V2 UCS (Unified Connector Service) Integration** for authorization and synchronization flows, building upon the existing V1 UCS integration (PR#[8280](https://github.com/juspay/hyperswitch/pull/8280)), with enhanced V2 schema support according to updated gRPC contract. **Key Features Implemented:** 1. **Authorization Flow (Payments)**: Full V2 schema support for payment authorization 2. **PSync Flow**: Payment status synchronization through UCS V2 3. **UPI Payment Method**: Support for UPI Collect payment method 4. **Enhanced Response Handling**: Improved status mapping and error handling 5. **Address Transformation Fix**: Better handling of optional address fields **Key Changes from V1 to V2:** 1. **Updated gRPC Schema**: - Migrated from `PaymentsAuthorizeRequest` to `PaymentServiceAuthorizeRequest` - Added `PaymentServiceGetRequest` for PSync flow - Enhanced field structure for better type safety 2. **New Payment Methods**: - Added UPI Collect payment method support - Proper VPA ID extraction and handling 3. **Enhanced Transformers**: - Updated transformers for authorization and sync flows - Improved card details, address structure, and payment method handling - Fixed address transformation to handle None values gracefully 4. **V2 Flow Architecture**: - Refactored payment flow to separate UCS prerequisites and decision logic - Added PSync flow integration through UCS - Feature flag protection for clean V1/V2 separation 5. **Improved Response Handling**: - Enhanced response parsing with new identifier structure - Added support for more payment states (Started, AuthenticationSuccessful, Authorizing, etc.) - Better error handling and status mapping **V2 Architecture Flow:** V2 Payment Request → call_connector_service_prerequisites() → decide_unified_connector_service_call() → ├── UCS Available → V2 Transformers → gRPC Call → V2 Response Handling └── UCS Unavailable → Traditional Connector Flow (Fallback) V2 PSync Request → call_unified_connector_service() → ├── UCS Available → V2 PSync Transformer → gRPC Get Call → Status Response └── UCS Unavailable → Traditional Connector Sync Flow **Key Technical Improvements:** - **Refactored Payment Functions**: Split `call_connector_service()` into `call_connector_service_prerequisites()` and `decide_unified_connector_service_call()` for better separation of concerns - **Enhanced V2 Transformers**: Updated card data transformation, address structure, and authentication data handling - **PSync Flow Integration**: Added complete payment synchronization support through UCS - **UPI Payment Support**: Added UPI Collect payment method with VPA ID handling - **Improved Error Handling**: Better response parsing with new identifier structure - **Customer ID Support**: Added customer ID mapping in V2 transformer implementation - **Enhanced Authentication**: Added tenant_id and merchant_id to ConnectorAuthMetadata **Files Modified:** - `crates/router/Cargo.toml` - Updated rust-grpc-client dependency to main branch - `crates/router/src/core/payments.rs` - Refactored UCS integration with V2 prerequisite and decision functions - `crates/router/src/core/payments/flows/authorize_flow.rs` - Updated to use `PaymentServiceAuthorizeRequest` - `crates/router/src/core/payments/flows/psync_flow.rs` - Added UCS V2 support for payment synchronization - `crates/router/src/core/payments/transformers.rs` - Added V2 PaymentsAuthorizeData transformer implementation and customer_id support - `crates/router/src/core/unified_connector_service/` - Updated transformers and response handlers for V2 schema - `crates/router/src/core/unified_connector_service.rs` - Added UPI payment method support and enhanced response handling - `crates/router/src/core/unified_connector_service/transformers.rs` - Major updates for V2 gRPC schema compatibility - `crates/external_services/src/grpc_client/unified_connector_service.rs` - Added payment get operations support ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/environment variables <!-- Provide links to the files with corresponding changes. Following are the paths where you can find config files: 1. `config` 2. `crates/router/src/configs` 3. `loadtest/config` --> ## Motivation and Context <!-- Why is this change required? What problem does it solve? If it fixes an open issue, please link to the issue here. If you don't have an issue, we'd recommend starting with one first so the PR can focus on the implementation (unless it is an obvious bug or documentation fix that will have little conversation). --> **V2 UCS Integration Evolution:** This change builds upon the existing V1 UCS integration to support the updated V2 gRPC schema and enhanced payment flow architecture. Key motivations: **Schema Evolution:** - **Updated gRPC Contracts**: V2 introduces improved field structures for better type safety and extensibility - **Enhanced Data Models**: New card details structure, improved address handling, and better identifier management - **Backward Compatibility**: V2 implementation maintains compatibility while leveraging new schema features **Feature Additions:** - **PSync Flow Support**: Enables payment status synchronization through UCS, reducing direct connector calls - **UPI Payment Method**: Adds support for popular Indian payment method through unified interface - **Enhanced Status Handling**: More granular payment states for better payment lifecycle tracking **Architectural Improvements:** - **Separation of Concerns**: Split monolithic UCS functions into prerequisite preparation and decision logic phases - **Better Feature Flag Management**: Clean V1/V2 separation using `#[cfg(feature = "v2")]` prevents conflicts - **Enhanced Error Handling**: Improved response parsing and identifier handling for better reliability - **Maintainability**: Cleaner code structure for easier debugging and future enhancements **Business Value:** - **Future-Proofing**: V2 schema supports upcoming UCS enhancements and new payment flows - **Improved Reliability**: Better error handling and response parsing reduces failure rates - **Enhanced Developer Experience**: Cleaner API interfaces and better type safety - **Operational Excellence**: Maintains existing rollout controls while improving monitoring capabilities - **Broader Payment Support**: UPI integration opens up access to Indian market payment preferences ## How did you test it? <!-- Did you write an integration/unit/API test to verify the code changes? Or did you test this change manually (provide relevant screenshots)? -->
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Domain Models (Business Logic Types)** - `crates/hyperswitch_domain_models/src/merchant_connector_account.rs` **2. Core Business Logic** - `crates/router/src/core/payments.rs` - `crates/router/src/core/payments/flows.rs` - `crates/router/src/core/payments/flows/authorize_flow.rs` - ... and 4 more files **3. External Connector Integration** - `crates/external_services/src/grpc_client/unified_connector_service.rs` **4. Type Definitions** - `crates/router/src/types.rs` **5. Configuration Files** - `crates/external_services/Cargo.toml` - `crates/router/Cargo.toml` **6. Other** - `Cargo.lock` **Code Patterns Applied:** - Implement new functions (12 changes) - Extend existing types with new fields (162 changes) - Add conditional logic for feature flags or filtering (10 changes) **Detailed Identifier Changes:** Commit ae9feca8: Files to modify: **crates/external_services/src/grpc_client/unified_connector_service.rs** Add: - function: pub::payment_get **crates/hyperswitch_domain_models/src/merchant_connector_account.rs** Modify existing code **crates/router/src/core/payments.rs** Modify existing code **crates/router/src/core/payments/flows.rs** Modify existing code **crates/router/src/core/payments/flows/authorize_flow.rs** Modify existing code **crates/router/src/core/payments/flows/psync_flow.rs** Add: - function: private::call_unified_connector_service **crates/router/src/core/payments/transformers.rs** Modify existing code **crates/router/src/core/unified_connector_service.rs** Modify existing code **crates/router/src/core/unified_connector_service/transformers.rs** Add: - function: private::foreign_try_from - impl: impl ForeignTryFrom<&RouterData<PSync, PaymentsSyncData, PaymentsResponseData>> for payments_grpc::PaymentServiceGetRequest **crates/router/src/types.rs** Modify existing code
{"pr_number": 8439, "pr_title": "feat(core): Hyperswitch <|> UCS integration v2", "merged_at": "2025-07-11T14:44:46Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"domain": ["crates/hyperswitch_domain_models/src/merchant_connector_account.rs"], "core_business": ["crates/router/src/core/payments.rs", "crates/router/src/core/payments/flows.rs", "crates/router/src/core/payments/flows/authorize_flow.rs", "crates/router/src/core/payments/flows/psync_flow.rs", "crates/router/src/core/payments/transformers.rs", "crates/router/src/core/unified_connector_service.rs", "crates/router/src/core/unified_connector_service/transformers.rs"], "connectors": ["crates/external_services/src/grpc_client/unified_connector_service.rs"], "types": ["crates/router/src/types.rs"], "config": ["crates/external_services/Cargo.toml", "crates/router/Cargo.toml"], "other": ["Cargo.lock"]}, "change_types": {"functions_added": 12, "fields_added": 162, "imports_added": 3, "conditionals_added": 10}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Changed the Unified Connector Service gRPC Client config to accept the entire base url instead of host and port. ## What is Unified Connector Service? The Unified Connector Service is a __gRPC-based microservice__ that acts as an intermediary layer between Hyperswitch and payment connectors. Here are its key characteristics:
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/external_services/src/grpc_client/unified_connector_service.rs` **2. Configuration Files** - `config/config.example.toml` - `config/deployments/env_specific.toml` - `config/development.toml` **Code Patterns Applied:** - Extend existing types with new fields (1 changes) **Detailed Identifier Changes:** Commit 988c1707: Files to modify: **crates/external_services/src/grpc_client/unified_connector_service.rs** Modify existing code
{"pr_number": 8587, "pr_title": "feat(external_services): Fixed Url for Unified Connector Service gRPC Client", "merged_at": "2025-08-05T08:54:50Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/external_services/src/grpc_client/unified_connector_service.rs"], "config": ["config/config.example.toml", "config/deployments/env_specific.toml", "config/development.toml"]}, "change_types": {"fields_added": 1, "imports_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> This PR integrates the decision engine config APIs The integration sits in the dynamic routing config flows. Based on ENV, if decision engine is enabled, we would call DE instead of Dynamo.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/open_router.rs` - `crates/api_models/src/routing.rs` **2. Core Business Logic** - `crates/router/src/core/admin.rs` - `crates/router/src/core/payments/routing.rs` - `crates/router/src/core/payments/routing/utils.rs` - ... and 2 more files **3. Other** - `api-reference/openapi_spec.json` - `crates/openapi/src/openapi.rs` **Code Patterns Applied:** - Define new data structures (8 changes) - Implement new functions (20 changes) - Extend existing types with new fields (104 changes) - Add conditional logic for feature flags or filtering (26 changes) - Modify database queries (2 changes) **Detailed Identifier Changes:** Commit d41f6538: Files to modify: **crates/api_models/src/open_router.rs** Add: - function: pub::update - function: pub::update - function: pub::update - function: pub::update - struct: pub::DecisionEngineConfigSetupRequest - struct: pub::DecisionEngineSuccessRateData - struct: pub::DecisionEngineSRSubLevelInputConfig - struct: pub::DecisionEngineGatewayWiseExtraScore - struct: pub::DecisionEngineEliminationData - struct: pub::MerchantAccount - struct: pub::FetchRoutingConfig - enum: pub::DecisionEngineConfigVariant - enum: pub::AlgorithmType - impl: impl DecisionEngineSuccessRateData - impl: impl DecisionEngineSRSubLevelInputConfig - impl: impl DecisionEngineGatewayWiseExtraScore - impl: impl DecisionEngineEliminationData **crates/api_models/src/routing.rs** Add: - function: pub::open_router_config_default - function: pub::get_decision_engine_configs - function: pub::open_router_config_default **crates/openapi/src/openapi.rs** Modify existing code **crates/router/src/core/admin.rs** Modify existing code **crates/router/src/core/payments/routing.rs** Modify existing code **crates/router/src/core/payments/routing/utils.rs** Add: - function: private::send_decision_engine_request - impl: impl DecisionEngineApiHandler for EuclidApiClient **crates/router/src/core/routing.rs** Modify existing code **crates/router/src/core/routing/helpers.rs** Add: - function: pub::enable_decision_engine_dynamic_routing_setup - function: pub::update_decision_engine_dynamic_routing_setup - function: pub::disable_decision_engine_dynamic_routing_setup - function: pub::create_decision_engine_merchant - function: pub::delete_decision_engine_merchant
{"pr_number": 8044, "pr_title": "feat(dynamic_routing): Decision engine config API integration ", "merged_at": "2025-05-22T18:43:29Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/open_router.rs", "crates/api_models/src/routing.rs"], "core_business": ["crates/router/src/core/admin.rs", "crates/router/src/core/payments/routing.rs", "crates/router/src/core/payments/routing/utils.rs", "crates/router/src/core/routing.rs", "crates/router/src/core/routing/helpers.rs"], "other": ["api-reference/openapi_spec.json", "crates/openapi/src/openapi.rs"]}, "change_types": {"structs_added": 8, "functions_added": 20, "enums_added": 2, "fields_added": 104, "imports_added": 4, "conditionals_added": 26, "database_queries": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Previously we were pushing the Dynamic routing metrics to Prometheus, but due to high cardinality of some values(payment_id) we were not able to add that in our attributes, hence we are pushing this after creating a new table in our Database (dynamic_routing_stats). The further enhancement will be done in this track: https://github.com/juspay/hyperswitch/issues/6756
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/routing.rs` **2. Database Layer (Queries & Schema)** - `crates/diesel_models/src/dynamic_routing_stats.rs` - `crates/diesel_models/src/enums.rs` - `crates/diesel_models/src/lib.rs` - ... and 4 more files **3. Core Business Logic** - `crates/router/src/core/routing/helpers.rs` **4. Type Definitions** - `crates/router/src/types/storage.rs` - `crates/router/src/types/storage/dynamic_routing_stats.rs` **5. Other** - `crates/common_enums/src/enums.rs` - `crates/router/src/db.rs` - `crates/router/src/db/dynamic_routing_stats.rs` - ... and 2 more files **Code Patterns Applied:** - Define new data structures (2 changes) - Implement new functions (5 changes) - Extend existing types with new fields (46 changes) **Detailed Identifier Changes:** Commit 5918014d: Files to modify: **crates/api_models/src/routing.rs** Modify existing code **crates/common_enums/src/enums.rs** Modify existing code **crates/diesel_models/src/dynamic_routing_stats.rs** Add: - struct: pub::DynamicRoutingStatsNew - struct: pub::DynamicRoutingStats **crates/diesel_models/src/enums.rs** Modify existing code **crates/diesel_models/src/lib.rs** Add: - mod: pub::dynamic_routing_stats **crates/diesel_models/src/query.rs** Add: - mod: pub::dynamic_routing_stats **crates/diesel_models/src/query/dynamic_routing_stats.rs** Add: - function: pub::insert - impl: impl DynamicRoutingStatsNew **crates/diesel_models/src/schema.rs** Modify existing code **crates/diesel_models/src/schema_v2.rs** Modify existing code **crates/router/src/core/routing/helpers.rs** Modify existing code **crates/router/src/db.rs** Add: - mod: pub::dynamic_routing_stats **crates/router/src/db/dynamic_routing_stats.rs** Add: - function: private::insert_dynamic_routing_stat_entry - function: private::insert_dynamic_routing_stat_entry - function: private::insert_dynamic_routing_stat_entry - trait: pub::DynamicRoutingStatsInterface - impl: impl DynamicRoutingStatsInterface for Store - impl: impl DynamicRoutingStatsInterface for MockDb - impl: impl DynamicRoutingStatsInterface for KafkaStore **crates/router/src/types/storage.rs** Add: - mod: pub::dynamic_routing_stats **crates/router/src/types/storage/dynamic_routing_stats.rs** Modify existing code
{"pr_number": 6723, "pr_title": "feat(dynamic_routing): analytics improvement using separate postgres table", "merged_at": "2024-12-07T09:31:44Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "merchant", "user"]}, "hierarchy": {"api_models": ["crates/api_models/src/routing.rs"], "database": ["crates/diesel_models/src/dynamic_routing_stats.rs", "crates/diesel_models/src/enums.rs", "crates/diesel_models/src/lib.rs", "crates/diesel_models/src/query.rs", "crates/diesel_models/src/query/dynamic_routing_stats.rs", "crates/diesel_models/src/schema.rs", "crates/diesel_models/src/schema_v2.rs"], "core_business": ["crates/router/src/core/routing/helpers.rs"], "types": ["crates/router/src/types/storage.rs", "crates/router/src/types/storage/dynamic_routing_stats.rs"], "other": ["crates/common_enums/src/enums.rs", "crates/router/src/db.rs", "crates/router/src/db/dynamic_routing_stats.rs", "migrations/2024-12-02-095127_add_new_table_dynamic_routing_stats/down.sql", "migrations/2024-12-02-095127_add_new_table_dynamic_routing_stats/up.sql"]}, "change_types": {"structs_added": 2, "functions_added": 5, "fields_added": 46, "imports_added": 14}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Enable L2l3 config for integ NO test needed. Just enabling config
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Tests** - `config/deployments/integration_test.toml`
{"pr_number": 9538, "pr_title": "fix(l2l3): enable l2l3 for integ", "merged_at": "2025-09-25T17:55:49Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"tests": ["config/deployments/integration_test.toml"]}, "change_types": {}, "has_identifier_data": false, "commits_matched": 0, "match_method": "none"}
<!-- Describe your changes in detail --> Added Getnet, Hipay, Klarna, Moneris, Opennode in feature matrix API
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/getnet.rs` - `crates/hyperswitch_connectors/src/connectors/hipay.rs` - `crates/hyperswitch_connectors/src/connectors/klarna.rs` - ... and 2 more files **2. Tests** - `config/deployments/integration_test.toml` - `loadtest/config/development.toml` **3. Configuration Files** - `config/config.example.toml` - `config/deployments/production.toml` - `config/deployments/sandbox.toml` - ... and 2 more files **Code Patterns Applied:** - Implement new functions (15 changes) - Extend existing types with new fields (55 changes) **Detailed Identifier Changes:** Commit 69ba651a: Files to modify: **crates/hyperswitch_connectors/src/connectors/getnet.rs** Remove: - function: private::validate_connector_against_payment_request - impl: impl ConnectorSpecifications for Getnet Add: - function: private::get_connector_about - function: private::get_supported_payment_methods - function: private::get_supported_webhook_flows - impl: impl ConnectorSpecifications for Getnet **crates/hyperswitch_connectors/src/connectors/hipay.rs** Remove: - function: private::validate_connector_against_payment_request - impl: impl ConnectorValidation for Hipay - impl: impl ConnectorSpecifications for Hipay Add: - function: private::get_connector_about - function: private::get_supported_payment_methods - function: private::get_supported_webhook_flows - impl: impl ConnectorValidation for Hipay - impl: impl ConnectorSpecifications for Hipay **crates/hyperswitch_connectors/src/connectors/klarna.rs** Remove: - function: private::validate_connector_against_payment_request - impl: impl ConnectorValidation for Klarna - impl: impl ConnectorSpecifications for Klarna Add: - function: private::get_connector_about - function: private::get_supported_payment_methods - function: private::get_supported_webhook_flows - impl: impl ConnectorValidation for Klarna - impl: impl ConnectorSpecifications for Klarna **crates/hyperswitch_connectors/src/connectors/moneris.rs** Remove: - function: private::validate_connector_against_payment_request - impl: impl ConnectorSpecifications for Moneris Add: - function: private::get_connector_about - function: private::get_supported_payment_methods - function: private::get_supported_webhook_flows - impl: impl ConnectorSpecifications for Moneris **crates/hyperswitch_connectors/src/connectors/opennode.rs** Remove: - impl: impl ConnectorSpecifications for Opennode Add: - function: private::get_connector_about - function: private::get_supported_payment_methods - function: private::get_supported_webhook_flows - impl: impl ConnectorSpecifications for Opennode
{"pr_number": 7873, "pr_title": "feat(connector): [GETNET,HIPAY,KLARNA,MONERIS,OPENNODE] add in feature matrix api", "merged_at": "2025-04-25T09:54:28Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "refund"]}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/src/connectors/getnet.rs", "crates/hyperswitch_connectors/src/connectors/hipay.rs", "crates/hyperswitch_connectors/src/connectors/klarna.rs", "crates/hyperswitch_connectors/src/connectors/moneris.rs", "crates/hyperswitch_connectors/src/connectors/opennode.rs"], "tests": ["config/deployments/integration_test.toml", "loadtest/config/development.toml"], "config": ["config/config.example.toml", "config/deployments/production.toml", "config/deployments/sandbox.toml", "config/development.toml", "config/docker_compose.toml"]}, "change_types": {"functions_added": 15, "fields_added": 55, "imports_added": 11}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Removed all the openapi references to `RefundAggregateResponse`. 1. Removed `ToSchema` trait for `RefundAggregateResponse`. 2. Removed references from `openapi` and `openapi_v2` to `RefundAggregateResponse`. 3. Generated new `openapi_spec` file based on the above changes.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/refunds.rs` **2. Other** - `api-reference-v2/openapi_spec.json` - `api-reference/openapi_spec.json` - `crates/openapi/src/openapi.rs` - ... and 1 more files **Detailed Identifier Changes:** Commit 449c9cfe: Files to modify: **crates/api_models/src/refunds.rs** Modify existing code **crates/openapi/src/openapi.rs** Modify existing code **crates/openapi/src/openapi_v2.rs** Modify existing code
{"pr_number": 6405, "pr_title": "fix(refunds): remove to schema from refund aggregate response and exclude it from open api documentation", "merged_at": "2024-11-05T09:26:13Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["user", "refund"]}, "hierarchy": {"api_models": ["crates/api_models/src/refunds.rs"], "other": ["api-reference-v2/openapi_spec.json", "api-reference/openapi_spec.json", "crates/openapi/src/openapi.rs", "crates/openapi/src/openapi_v2.rs"]}, "change_types": {}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Populate `shipping_cost` in payment response
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/payments.rs` **2. Core Business Logic** - `crates/router/src/core/payments/transformers.rs` **3. Tests** - `crates/router/tests/payments.rs` - `crates/router/tests/payments2.rs` **4. Other** - `api-reference-v2/openapi_spec.json` - `api-reference/openapi_spec.json` **Code Patterns Applied:** - Extend existing types with new fields (7 changes) **Detailed Identifier Changes:** Commit 368e6b53: Files to modify: **crates/api_models/src/payments.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Modify existing code **crates/router/tests/payments.rs** Modify existing code **crates/router/tests/payments2.rs** Modify existing code
{"pr_number": 6351, "pr_title": "refactor(core): populate shipping_cost in payment response", "merged_at": "2024-10-18T13:44:03Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/payments.rs"], "core_business": ["crates/router/src/core/payments/transformers.rs"], "tests": ["crates/router/tests/payments.rs", "crates/router/tests/payments2.rs"], "other": ["api-reference-v2/openapi_spec.json", "api-reference/openapi_spec.json"]}, "change_types": {"fields_added": 7}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Add configs for calculate job
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/router/src/core/revenue_recovery.rs` - `crates/router/src/core/revenue_recovery/types.rs` **2. Type Definitions** - `crates/router/src/types/storage/revenue_recovery.rs` **3. Configuration Files** - `config/config.example.toml` - `config/deployments/env_specific.toml` - `config/development.toml` - ... and 1 more files **4. Other** - `crates/router/src/workflows/revenue_recovery.rs` **Code Patterns Applied:** - Extend existing types with new fields (9 changes) **Detailed Identifier Changes:** Commit 8ce36a2f: Files to modify: **crates/router/src/core/revenue_recovery.rs** Modify existing code **crates/router/src/core/revenue_recovery/types.rs** Modify existing code **crates/router/src/types/storage/revenue_recovery.rs** Modify existing code **crates/router/src/workflows/revenue_recovery.rs** Modify existing code
{"pr_number": 9106, "pr_title": "refactor(revenue_recovery): Add configs for calculate job", "merged_at": "2025-08-29T15:31:36Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": []}, "hierarchy": {"core_business": ["crates/router/src/core/revenue_recovery.rs", "crates/router/src/core/revenue_recovery/types.rs"], "types": ["crates/router/src/types/storage/revenue_recovery.rs"], "config": ["config/config.example.toml", "config/deployments/env_specific.toml", "config/development.toml", "config/docker_compose.toml"], "other": ["crates/router/src/workflows/revenue_recovery.rs"]}, "change_types": {"fields_added": 9}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> This pull request refactors the `DebitRoutingOutput` structure to introduce a new `CoBadgedCardNetworksInfo` type, enhancing the representation of co-badged card networks by including additional metadata such as saving percentages. It also updates related methods and structures to align with this change.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/open_router.rs` **2. Core Business Logic** - `crates/router/src/core/debit_routing.rs` **Code Patterns Applied:** - Define new data structures (1 changes) - Implement new functions (1 changes) - Extend existing types with new fields (6 changes) **Detailed Identifier Changes:** Commit 639b92c1: Files to modify: **crates/api_models/src/open_router.rs** Add: - function: pub::get_co_badged_card_networks - struct: pub::CoBadgedCardNetworksInfo - impl: impl DebitRoutingOutput **crates/router/src/core/debit_routing.rs** Modify existing code
{"pr_number": 8388, "pr_title": "refactor(routing): add support to accept the `saving_percentage` in decision engine response", "merged_at": "2025-06-20T13:28:33Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"api_models": ["crates/api_models/src/open_router.rs"], "core_business": ["crates/router/src/core/debit_routing.rs"]}, "change_types": {"structs_added": 1, "functions_added": 1, "fields_added": 6}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
`payment_link` currently comes as null in psync response, even if payment link exists for the particular payment id <img width="1284" alt="Screenshot 2025-01-29 at 15 50 02" src="https://github.com/user-attachments/assets/9c4d3fad-9b02-43d8-91f8-8ef946c6dc62" />
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Core Business Logic** - `crates/router/src/core/payments.rs` - `crates/router/src/core/payments/operations/payment_status.rs` **Code Patterns Applied:** - Implement new functions (1 changes) - Extend existing types with new fields (5 changes) **Detailed Identifier Changes:** Commit 94ffcd63: Files to modify: **crates/router/src/core/payments.rs** Add: - function: pub::get_payment_link_response_from_id **crates/router/src/core/payments/operations/payment_status.rs** Modify existing code Commit af65e27b: Files to modify: **crates/router/src/core/payments.rs** Add: - function: pub::get_payment_link_response_from_id **crates/router/src/core/payments/operations/payment_status.rs** Modify existing code Commit 8917235b: Files to modify: **crates/router/src/core/payments.rs** Add: - function: pub::get_payment_link_response_from_id **crates/router/src/core/payments/operations/payment_status.rs** Modify existing code
{"pr_number": 7137, "pr_title": "fix(core): Add payment_link_data in PaymentData for Psync", "merged_at": "2025-02-05T15:08:58Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["payment", "user", "connector"]}, "hierarchy": {"core_business": ["crates/router/src/core/payments.rs", "crates/router/src/core/payments/operations/payment_status.rs"]}, "change_types": {"functions_added": 1, "fields_added": 5}, "has_identifier_data": true, "commits_matched": 3, "match_method": "pr_number"}
The current description for refund - list is incorrect. Newer one looks more apt.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. Other** - `api-reference/openapi_spec.json` - `crates/openapi/src/routes/refunds.rs` **Detailed Identifier Changes:** Commit 8954e8a2: Files to modify: **crates/openapi/src/routes/refunds.rs** Modify existing code
{"pr_number": 6443, "pr_title": "fix(docs): incorrect description for refund api", "merged_at": "2024-12-10T11:02:10Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["refund"]}, "hierarchy": {"other": ["api-reference/openapi_spec.json", "crates/openapi/src/routes/refunds.rs"]}, "change_types": {}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> For one connector alone to hard code success with a particular failure card
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/router/src/routes/dummy_connector/utils.rs` **Code Patterns Applied:** - Extend existing types with new fields (2 changes) - Add conditional logic for feature flags or filtering (1 changes) **Detailed Identifier Changes:** Commit 69ab2553: Files to modify: **crates/router/src/routes/dummy_connector/utils.rs** Modify existing code
{"pr_number": 8469, "pr_title": "feat(dummy_connector): allow a dummy connector to succeed a failed card", "merged_at": "2025-07-01T12:31:18Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/router/src/routes/dummy_connector/utils.rs"]}, "change_types": {"fields_added": 2, "imports_added": 1, "conditionals_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Added Google Pay Payment Method
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/connector_configs/toml/development.toml` - `crates/connector_configs/toml/production.toml` - `crates/connector_configs/toml/sandbox.toml` - ... and 3 more files **2. Tests** - `config/deployments/integration_test.toml` - `loadtest/config/development.toml` **3. Configuration Files** - `config/config.example.toml` - `config/deployments/production.toml` - `config/deployments/sandbox.toml` - ... and 2 more files **Code Patterns Applied:** - Define new data structures (2 changes) - Implement new functions (6 changes) - Extend existing types with new fields (27 changes) **Detailed Identifier Changes:** Commit 434e7a7a: Files to modify: **crates/hyperswitch_connectors/src/connectors/barclaycard.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/barclaycard/transformers.rs** Add: - function: private::from - struct: pub::GooglePayPaymentInformation - enum: pub::PaymentSolution - impl: impl From<PaymentSolution> for String **crates/payment_methods/src/configs/payment_connector_required_fields.rs** Modify existing code
{"pr_number": 8786, "pr_title": "feat(connector): [Barclaycard] Add Google Pay Payment Method", "merged_at": "2025-08-06T07:35:30Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/connector_configs/toml/development.toml", "crates/connector_configs/toml/production.toml", "crates/connector_configs/toml/sandbox.toml", "crates/hyperswitch_connectors/src/connectors/barclaycard.rs", "crates/hyperswitch_connectors/src/connectors/barclaycard/transformers.rs", "crates/payment_methods/src/configs/payment_connector_required_fields.rs"], "tests": ["config/deployments/integration_test.toml", "loadtest/config/development.toml"], "config": ["config/config.example.toml", "config/deployments/production.toml", "config/deployments/sandbox.toml", "config/development.toml", "config/docker_compose.toml"]}, "change_types": {"structs_added": 2, "functions_added": 6, "enums_added": 1, "fields_added": 27, "imports_added": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
<!-- Describe your changes in detail --> Fix Nuvei payments and chargeback webhooks ## How did you test it? <!-- Did you write an integration/unit/API test to verify the code changes? Or did you test this change manually (provide relevant screenshots)? --> Tested it by configuring payments, refunds and chargeback Webhooks at Nuvei <details> <summary>1.Test manual failure case </summary> 1. Create a manual payment with failure card ```sh curl --location 'http://localhost:8080/payments' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: dev_1GzDDtw7u8wOD5LgwtaSVe9S6ycpAy73s9BPr72X3mCpSLmE1oA1bWmQgDUjfmGx' \ --data-raw '{ "amount": 30030, "currency": "USD", "confirm": true, "capture_method": "manual", "billing": { "address": { "line1": "3 Main St.", "city": "Bloomfield", "state": "CT", "zip": "06002", "country": "US", "first_name": "Eileen Jones" } }, "email": "email16@here.com", "payment_method": "card", "payment_method_type": "credit", "payment_method_data": { "card": { "card_number": "4008370896662369", "card_exp_month": "03", "card_exp_year": "50", "card_cvc": "758" } } ,"browser_info": { "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36", "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8", "language": "nl-NL", "color_depth": 24, "screen_height": 723, "screen_width": 1536, "time_zone": 0, "java_enabled": true, "java_script_enabled": true, "ip_address": "13.232.74.226" } }' ``` Response ``` { "payment_id": "pay_MklD1Rd6goefCSNRpl7G", "merchant_id": "postman_merchant_GHAction_cf8f5ac7-8547-418b-a12e-1451b474ac8a", "status": "failed", "amount": 30030, "net_amount": 30030, "shipping_cost": null, "amount_capturable": 30030, "amount_received": null, "connector": "nuvei", "client_secret": "pay_MklD1Rd6goefCSNRpl7G_secret_bQViOfLwoapfPsIUonTt", "created": "2025-09-17T08:21:18.431Z", "currency": "USD", "customer_id": null, "customer": { "id": null, "name": null, "email": "email16@here.com", "phone": null, "phone_country_code": null }, "description": null, "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": null, "off_session": null, "capture_on": null, "capture_method": "manual", "payment_method": "card", "payment_method_data": { "card": { "last4": "2369", "card_type": null, "card_network": null, "card_issuer": null, "card_issuing_country": null, "card_isin": "400837", "card_extended_bin": null, "card_exp_month": "03", "card_exp_year": "50", "card_holder_name": null, "payment_checks": { "avs_result": "", "cvv_2_reply": "", "avs_description": null, "cvv_2_description": null, "merchant_advice_code": "", "merchant_advice_code_description": null }, "authentication_data": { "challengePreferenceReason": "12" } }, "billing": null }, "payment_token": "token_uCdvPzx1vBfDH4ifrStG", "shipping": null, "billing": { "address": { "city": "Bloomfield", "country": "US", "line1": "3 Main St.", "line2": null, "line3": null, "zip": "06002", "state": "CT", "first_name": "Eileen Jones", "last_name": null, "origin_zip": null }, "phone": null, "email": null }, "order_details": null, "email": null, "name": null, "phone": null, "return_url": null, "authentication_type": "no_three_ds", "statement_descriptor_name": null, "statement_descriptor_suffix": null, "next_action": null, "cancellation_reason": null, "error_code": "-1", "error_message": "Decline", "unified_code": "UE_9000", "unified_message": "Something went wrong", "payment_experience": null, "payment_method_type": "credit", "connector_label": null, "business_country": null, "business_label": "default", "business_sub_label": null, "allowed_payment_method_types": null, "ephemeral_key": null, "manual_retry_allowed": null, "connector_transaction_id": "8110000000014575811", "frm_message": null, "metadata": null, "connector_metadata": null, "feature_metadata": { "redirect_response": null, "search_tags": null, "apple_pay_recurring_details": null, "gateway_system": "direct" }, "reference_id": null, "payment_link": null, "profile_id": "pro_Y0YKlaXCpv5VLrjGwNLm", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_Hv2lKARGaUwIrhXxAXH8", "incremental_authorization_allowed": false, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2025-09-17T08:36:18.431Z", "fingerprint": null, "browser_info": { "language": "nl-NL", "time_zone": 0, "ip_address": "13.232.74.226", "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36", "color_depth": 24, "java_enabled": true, "screen_width": 1536, "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8", "screen_height": 723, "java_script_enabled": true }, "payment_channel": null, "payment_method_id": null, "network_transaction_id": null, "payment_method_status": null, "updated": "2025-09-17T08:21:19.815Z", "split_payments": null, "frm_metadata": null, "extended_authorization_applied": null, "capture_before": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": null, "card_discovery": "manual", "force_3ds_challenge": false, "force_3ds_challenge_trigger": false, "issuer_error_code": "-1", "issuer_error_message": "Decline", "is_iframe_redirection_enabled": null, "whole_connector_response": null, "enable_partial_authorization": null, "enable_overcapture": null, "is_overcapture_enabled": null, "network_details": { "network_advice_code": "" } } ``` Webhook from the connector should show 2xx response </details> <details> <summary>2. Create a payment and do a refund</summary> Create a payment ``` curl --location 'http://localhost:8080/payments' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: dev_1GzDDtw7u8wOD5LgwtaSVe9S6ycpAy73s9BPr72X3mCpSLmE1oA1bWmQgDUjfmGx' \ --data-raw '{ "amount": 30030, "currency": "USD", "confirm": true, "capture_method": "automatic", "billing": { "address": { "line1": "3 Main St.", "city": "Bloomfield", "state": "CT", "zip": "06002", "country": "US", "first_name": "Eileen Jones" } }, "email": "email16@here.com", "payment_method": "card", "payment_method_type": "credit", "payment_method_data": { "card": { "card_number": "4111111111111111", "card_exp_month": "03", "card_exp_year": "50", "card_cvc": "758" } } ,"browser_info": { "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36", "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8", "language": "nl-NL", "color_depth": 24, "screen_height": 723, "screen_width": 1536, "time_zone": 0, "java_enabled": true, "java_script_enabled": true, "ip_address": "13.232.74.226" } }' ``` Response ``` { "payment_id": "pay_cK62pqa8F4P32DqPGwf1", "merchant_id": "postman_merchant_GHAction_cf8f5ac7-8547-418b-a12e-1451b474ac8a", "status": "succeeded", "amount": 30030, "net_amount": 30030, "shipping_cost": null, "amount_capturable": 0, "amount_received": 30030, "connector": "nuvei", "client_secret": "pay_cK62pqa8F4P32DqPGwf1_secret_Dvc0djCVscjQY1BcDt9x", "created": "2025-09-17T08:23:51.019Z", "currency": "USD", "customer_id": null, "customer": { "id": null, "name": null, "email": "email16@here.com", "phone": null, "phone_country_code": null }, "description": null, "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": null, "off_session": null, "capture_on": null, "capture_method": "automatic", "payment_method": "card", "payment_method_data": { "card": { "last4": "1111", "card_type": null, "card_network": null, "card_issuer": null, "card_issuing_country": null, "card_isin": "411111", "card_extended_bin": null, "card_exp_month": "03", "card_exp_year": "50", "card_holder_name": null, "payment_checks": { "avs_result": "", "cvv_2_reply": "", "avs_description": null, "cvv_2_description": null, "merchant_advice_code": "", "merchant_advice_code_description": null }, "authentication_data": { "challengePreferenceReason": "12" } }, "billing": null }, "payment_token": "token_Bu1xBMepQFrpomazI8VC", "shipping": null, "billing": { "address": { "city": "Bloomfield", "country": "US", "line1": "3 Main St.", "line2": null, "line3": null, "zip": "06002", "state": "CT", "first_name": "Eileen Jones", "last_name": null, "origin_zip": null }, "phone": null, "email": null }, "order_details": null, "email": null, "name": null, "phone": null, "return_url": null, "authentication_type": "no_three_ds", "statement_descriptor_name": null, "statement_descriptor_suffix": null, "next_action": null, "cancellation_reason": null, "error_code": null, "error_message": null, "unified_code": null, "unified_message": null, "payment_experience": null, "payment_method_type": "credit", "connector_label": null, "business_country": null, "business_label": "default", "business_sub_label": null, "allowed_payment_method_types": null, "ephemeral_key": null, "manual_retry_allowed": null, "connector_transaction_id": "8110000000014576020", "frm_message": null, "metadata": null, "connector_metadata": null, "feature_metadata": { "redirect_response": null, "search_tags": null, "apple_pay_recurring_details": null, "gateway_system": "direct" }, "reference_id": "8894221111", "payment_link": null, "profile_id": "pro_Y0YKlaXCpv5VLrjGwNLm", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_Hv2lKARGaUwIrhXxAXH8", "incremental_authorization_allowed": false, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2025-09-17T08:38:51.019Z", "fingerprint": null, "browser_info": { "language": "nl-NL", "time_zone": 0, "ip_address": "13.232.74.226", "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36", "color_depth": 24, "java_enabled": true, "screen_width": 1536, "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8", "screen_height": 723, "java_script_enabled": true }, "payment_channel": null, "payment_method_id": null, "network_transaction_id": "480213756277396", "payment_method_status": null, "updated": "2025-09-17T08:23:52.744Z", "split_payments": null, "frm_metadata": null, "extended_authorization_applied": null, "capture_before": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": null, "card_discovery": "manual", "force_3ds_challenge": false, "force_3ds_challenge_trigger": false, "issuer_error_code": null, "issuer_error_message": null, "is_iframe_redirection_enabled": null, "whole_connector_response": null, "enable_partial_authorization": null, "enable_overcapture": null, "is_overcapture_enabled": null, "network_details": null } ``` Webhook from connector should have a 200 response Create a Refund ```sh curl --location 'http://localhost:8080/refunds' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: dev_1GzDDtw7u8wOD5LgwtaSVe9S6ycpAy73s9BPr72X3mCpSLmE1oA1bWmQgDUjfmGx' \ --data '{ "payment_id": "pay_cK62pqa8F4P32DqPGwf1", "reason": "Customer returned product", "refund_type": "instant", "metadata": { "udf1": "value1", "new_customer": "true", "login_date": "2019-09-10T10:11:12Z" } }' ``` Response ``` { "refund_id": "ref_OIrC7kZAkOw8f98fIau7", "payment_id": "pay_hesMmqr4ErioGWSfQ6Yu", "amount": 30030, "currency": "USD", "status": "succeeded", "reason": "Customer returned product", "metadata": { "udf1": "value1", "new_customer": "true", "login_date": "2019-09-10T10:11:12Z" }, "error_message": null, "error_code": null, "unified_code": null, "unified_message": null, "created_at": "2025-09-17T09:54:52.906Z", "updated_at": "2025-09-17T09:54:54.027Z", "connector": "nuvei", "profile_id": "pro_Y0YKlaXCpv5VLrjGwNLm", "merchant_connector_id": "mca_Hv2lKARGaUwIrhXxAXH8", "split_refunds": null, "issuer_error_code": null, "issuer_error_message": null } ``` Check for successful response to the web hook </details> ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt --all` - [x] I addressed lints thrown by `cargo clippy` - [ ] I reviewed the submitted code - [ ] I added unit tests for my changes where possible
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. External Connector Integration** - `crates/hyperswitch_connectors/src/connectors/nuvei.rs` - `crates/hyperswitch_connectors/src/connectors/nuvei/transformers.rs` **Code Patterns Applied:** - Define new data structures (2 changes) - Implement new functions (8 changes) - Extend existing types with new fields (92 changes) - Add conditional logic for feature flags or filtering (2 changes) **Detailed Identifier Changes:** Commit 9654d18d: Files to modify: **crates/hyperswitch_connectors/src/connectors/nuvei.rs** Remove: - impl: impl ConnectorIntegration<RSync, RefundsData, RefundsResponseData> for Nuvei Add: - function: private::handle_response - impl: impl ConnectorIntegration<RSync, RefundsData, RefundsResponseData> for Nuvei **crates/hyperswitch_connectors/src/connectors/nuvei/transformers.rs** Remove: - function: private::from - enum: pub::PaymentTransactionType - impl: impl clone() - impl: impl From<&NuveiWebhook> for NuveiWebhookTransactionId Add: - function: private::from - function: pub::map_dispute_notification_to_event - function: private::from - struct: pub::ChargebackData - struct: pub::ChargebackTransactionDetails - enum: pub::NuveiPaymentSyncResponse - enum: pub::DisputeUnifiedStatusCode - enum: pub::ChargebackType - enum: pub::ChargebackStatusCategory - enum: pub::DmnApiTransactionStatus - impl: impl From<NuveiPaymentSyncResponse> for NuveiTransactionSyncResponse - impl: impl From<DisputeUnifiedStatusCode> for common_enums::DisputeStage
{"pr_number": 9378, "pr_title": "fix(connectors): [Nuvei] payments, refunds and chargeback webhooks", "merged_at": "2025-09-19T12:17:17Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["customer", "payment", "merchant"]}, "hierarchy": {"connectors": ["crates/hyperswitch_connectors/src/connectors/nuvei.rs", "crates/hyperswitch_connectors/src/connectors/nuvei/transformers.rs"]}, "change_types": {"structs_added": 2, "functions_added": 8, "enums_added": 5, "fields_added": 92, "imports_added": 1, "conditionals_added": 2}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}
Currently the API Call to the /user/auth endpoint displays only a 200::OK response code without providing a proper response body containing the authentication details for proper debugging.This PR Introduces a Response body of type CreateUserAuthenticationMethodReponse which contains members to be displayed in response to the API call to /user/auth.Modified the create_user_authentication_method as well to include the response body in addition to response code.
To implement this **search_filter** feature, you'll need to modify these architectural layers: **1. API Request/Response Models** - `crates/api_models/src/events/user.rs` - `crates/api_models/src/user.rs` **2. Core Business Logic** - `crates/router/src/core/user.rs` **Code Patterns Applied:** - Define new data structures (1 changes) - Extend existing types with new fields (14 changes) - Add conditional logic for feature flags or filtering (1 changes) **Detailed Identifier Changes:** Commit bebffa97: Files to modify: **crates/api_models/src/events/user.rs** Modify existing code **crates/api_models/src/user.rs** Add: - struct: pub::CreateUserAuthenticationMethodResponse **crates/router/src/core/user.rs** Modify existing code
{"pr_number": 9653, "pr_title": "feat: include response body for create_user_authentication_method", "merged_at": "2025-10-15T16:19:48Z", "intent": {"feature_type": "search_filter", "action": "add_feature", "entities": ["user"]}, "hierarchy": {"api_models": ["crates/api_models/src/events/user.rs", "crates/api_models/src/user.rs"], "core_business": ["crates/router/src/core/user.rs"]}, "change_types": {"structs_added": 1, "fields_added": 14, "conditionals_added": 1}, "has_identifier_data": true, "commits_matched": 1, "match_method": "pr_number"}