prompt
stringlengths
24
63.1k
response
stringlengths
296
101k
metadata
stringlengths
143
152
feat(auth): Add support for partial-auth, by facilitating injection of authentication parameters in headers ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Adding a wrapper over `ApiKeyAuth` and `PublishableKeyAuth` that provides an alternative to allow authentication being done outside the application. This is done by allowing the external entity (most likely a reverse proxy) to send the parameters necessary for the authentication of the request, there by reducing the need to perform db calls and improving the performance of the service. <!-- Describe your changes in detail --> ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [x] 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). --> ## How did you test it? <img width="1728" alt="image" src="https://github.com/juspay/hyperswitch/assets/51093026/ddb3cccf-c6e8-4870-99e9-dc225e6f4194"> Using a dummy service to generate a request and header parameters, and sending this parameter to the hyperswitch application without `api-key` and getting authenticated for the request. ![image](https://github.com/juspay/hyperswitch/assets/51093026/e14abd04-af29-487c-b33a-d6dac5c139e9) ```bash curl --location 'https://sandbox.hyperswitch.io/payments' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'x-merchant-id: bye123' \ --header 'x-key-id: dev_CCCCCCCCCCCCCCCCCCCC' \ --header 'x-auth-type: api_key' \ --header 'x-checksum: 0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef' \ --data-raw '{ "amount": 6540, "currency": "USD", "confirm": true, "capture_method": "automatic", "capture_on": "2022-09-10T10:11:12Z", "amount_to_capture": 6540, "customer_id": "StripeCustomer", "email": "[email protected]", "name": "John Doe", "phone": "999999999", "phone_country_code": "+1", "description": "Its my first payment request", "authentication_type": "no_three_ds", "return_url": "https://google.com", "payment_method": "card", "payment_method_type": "credit", "payment_method_data": { "card": { "card_number": "4242424242424242", "card_exp_month": "10", "card_exp_year": "25", "card_holder_name": "joseph Doe", "card_cvc": "123" } }, "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" }, "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" } }, "statement_descriptor_name": "joseph", "statement_descriptor_suffix": "JS", "metadata": { "udf1": "value1", "new_customer": "true", "login_date": "2019-09-10T10:11:12Z" } }' ``` Here, you can see that the request was successful, but the payment failed. There by showcasing that the request was authenticated successfully. <!-- Did you write an integration/unit/API test to verify the code changes? Or did you test this change manually (provide relevant screenshots)? --> ## 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
<think> PR Context: - Title: feat(decision): add support to register api keys to proxy - Merged: 2024-07-09T07:55:13Z - Files changed: 7 files - Commits: 8 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description This PR adds support for exporting hashed api keys to the incoming proxy allowing for authentication outside the application facilitating detached authentication and ratelimiting ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the data </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(decision): add support to register api keys to proxy (#5168) Files to modify: **crates/router/src/configs/secrets_transformers.rs** Modify existing code **crates/router/src/configs/settings.rs** Add: - struct: pub::DecisionConfig **crates/router/src/core/admin.rs** Modify existing code **crates/router/src/core/api_keys.rs** Modify existing code **crates/router/src/core/metrics.rs** Modify existing code **crates/router/src/services/authentication.rs** Add: - mod: pub::decision **crates/router/src/services/authentication/decision.rs** Add: - function: pub::add_api_key - function: pub::add_publishable_key - function: private::call_decision_service - function: pub::revoke_api_key - function: pub::convert_expiry - function: pub::spawn_tracked_job - struct: pub::RuleRequest - struct: pub::RuleDeleteRequest - enum: pub::AuthType - enum: pub::AuthRuleType - enum: pub::Identifiers
{"issue_number": 4802, "pr_number": 5168, "commits_count": 1, "files_changed": 7, "response_length": 1753, "file_count": 9, "needs_breakdown": false}
[FEATURE]: [Cybersource] Use `connector_request_reference_id` as reference to the connector ### :memo: Feature Description - We transmit our reference id from Hyperswitch to the connector, enabling merchants to subsequently locate the payment within the connector dashboard. - Presently, there is a lack of uniformity in this process, as some implementations employ `payment_id` while others utilize `attempt_id`. - This inconsistency arises from the fact that `payment_id` and `attempt_id` correspond to two distinct entities within our system. ### :hammer: Possible Implementation - To mitigate this confusion, we've introduced a new field called `connector_request_reference_id` in our RouterData. - This id should replace them as a reference id to the connector for payment request. - One might need to have exposure to api docs of the connector for which it is being implemented. - You can check this PR for further reference https://github.com/juspay/hyperswitch/pull/2052 :bookmark: Note : All the changes needed should be contained within `hyperswitch/crates/router/src/connector/` ### :package: Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### :package: Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### :sparkles: Are you willing to submit a PR?
<think> PR Context: - Title: feat(connector): [Cybersource] Use connector_request_reference_id as reference to the connector - Merged: 2023-10-12T06:06:18Z - Files changed: 1 files - Commits: 3 commits Implementation approach: Add reference with value of connector_request_reference_id in Cybersource transformers. Fixes #2296 ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(connector): [Cybersource] Use connector_request_reference_id as reference to the connector (#25 Files to modify: **crates/router/src/connector/cybersource/transformers.rs** Modify existing code
{"issue_number": 2296, "pr_number": 2512, "commits_count": 1, "files_changed": 1, "response_length": 1030, "file_count": 3, "needs_breakdown": false}
refactor(connector): [NMI] Add Zip code as mandatory field for 3DS ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Zip code in billing address is added as mandatory field for 3ds transaction ### 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). --> ## 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)? --> Through Postman. Steps: Create a merchant account: ``` { "merchant_id": "merchant_{{$timestamp}}", "locker_id": "m0010", "merchant_name": "NewAge Retailer", "merchant_details": { "primary_contact_person": "John Test", "primary_email": "[email protected]", "primary_phone": "sunt laborum", "secondary_contact_person": "John Test2", "secondary_email": "[email protected]", "secondary_phone": "cillum do dolor id", "website": "www.example.com", "about_business": "Online Retail with a wide selection of organic products for North America", "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US" } }, "return_url": "https://google.com/success", "webhook_details": { "webhook_version": "1.0.1", "webhook_username": "ekart_retail", "webhook_password": "password_ekart@123", "payment_created_enabled": true, "payment_succeeded_enabled": true, "payment_failed_enabled": true }, // "routing_algorithm": { // "type": "single", // "data": "nmi" // }, "sub_merchants_enabled": false, "metadata": { "city": "NY", "unit": "245" }, "primary_business_details": [ { "country": "US", "business": "default" } ] } ``` Create a payment connector (NMI): ``` { "connector_type": "fiz_operations", "connector_name": "nmi", "connector_account_details": { "auth_type": "BodyKey", "api_key": "{{api_key}}", "key1": "{{key1}}" }, "test_mode": false, "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 } ] }, { "payment_method": "voucher", "payment_method_types": [ { "payment_method_type": "boleto", //"payment_experience": "redirect_to_url", "minimum_amount": 1, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": true } ] }, { "payment_method": "pay_later", "payment_method_types": [ { "payment_method_type": "klarna", "payment_experience": "redirect_to_url", "minimum_amount": 1, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": true }, { "payment_method_type": "affirm", "payment_experience": "redirect_to_url", "minimum_amount": 1, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": true }, { "payment_method_type": "afterpay_clearpay", "payment_experience": "redirect_to_url", "minimum_amount": 1, "maximum_amount": 68607706, "recurring_enabled": true, "installment_payment_enabled": true } ] } ], "metadata": { "city": "NY", "unit": "245" }, "connector_webhook_details": { "merchant_secret": "{{merchant_secret}}" }, "business_country": "US", "business_label": "default" } ``` Create a payment with confirm as false: ``` { "amount": 14003, "currency": "USD", "confirm": false, "amount_to_capture": 14003, "capture_method": "automatic", "capture_on": "2022-09-10T10:11:12Z", "customer_id": "StripeCustomer", "email": "[email protected]", "name": "John Doe", "phone": "999999999", "phone_country_code": "+65", "description": "Its my first payment request", "authentication_type": "three_ds", "return_url": "https://google.com", "setup_future_usage": "on_session", "billing": { "address": { "first_name": "Sakil", "last_name": "Mostak", "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US" } }, "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" }, "shipping": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "John" "last_name": "Doe" } }, "routing": { "type": "single", "data": "nmi" }, "statement_descriptor_name": "joseph", "statement_descriptor_suffix": "JS", "metadata": { "udf1": "value1", "new_customer": "true", "login_date": "2019-09-10T10:11:12Z" }, "payment_method": "card", "payment_method_type": "credit", "payment_method_data": { "card": { "card_number": "4000000000002503", "card_exp_month": "08", "card_exp_year": "25", "card_holder_name": "joseph Doe", "card_cvc": "999" } } } ``` Create a payment method list call with client secret for NMI ``` curl --location 'http://localhost:8080/account/payment_methods?client_secret={{client_secret}}' \ --header 'Accept: application/json' \ --header 'api-key: {{api_key}}' ``` The response should contain the necessary fields required for NMI 3DS transaction <img width="1728" alt="Screenshot 2024-02-15 at 7 41 57 PM" src="https://github.com/juspay/hyperswitch/assets/73734619/1f8fce7d-431c-4f97-bc66-ce061b08214b"> Note: This change impacts the Card 3DS transaction for NMI ## 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 - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: refactor(connector): [NMI] Add Zip code as mandatory field for 3DS - Merged: 2024-02-15T17:05:06Z - Files changed: 1 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Zip code in billing address is added as mandatory field for 3ds transaction Corresponding to #3666 ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies app </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(connector): [NMI] Add Zip code as mandatory field for 3DS (#3665) Files to modify: **crates/router/src/configs/defaults.rs** Modify existing code
{"issue_number": 3666, "pr_number": 3665, "commits_count": 1, "files_changed": 1, "response_length": 957, "file_count": 3, "needs_breakdown": false}
Add audit events for PaymentStatus update Created from #4525 This covers adding events for PaymentStatus operation This event should include the payment data similar to [PaymentCancel](https://github.com/juspay/hyperswitch/pull/4166) It should also include any metadata for the event e.g reason for payment rejection, error codes, rejection source etc ### Submission Process: - Ask the maintainers for assignment of the issue, you can request for assignment by commenting on the issue itself. - Once assigned, submit a pull request (PR). - Maintainers will review and provide feedback, if any. - Maintainers can unassign issues due to inactivity, [read more here](https://github.com/juspay/hyperswitch/wiki/Hacktoberfest-Contribution-Rules). Refer [here](https://github.com/juspay/hyperswitch/blob/main/docs/TERMS_OF_CONTEST.md) for Terms and conditions for the contest.
<think> PR Context: - Title: feat(payments): Add audit events for PaymentStatus update - Merged: 2024-12-16T12:08:46Z - Files changed: 2 files - Commits: 8 commits Implementation approach: ## Type of Change - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description This PR adds an Audit event for the PaymentStatus operation. ### Additional Changes - [x] This PR modifies the files below - `crates/router/src/core/payments/operations/payment_status.rs` - `crates/router/src/events/audit_events.rs` ## Motivation and Context This PR fixes #4677 ## How did you test it - </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(payments): Add audit events for PaymentStatus update (#6520) Files to modify: **crates/router/src/core/payments/operations/payment_status.rs** Modify existing code **crates/router/src/events/audit_events.rs** Modify existing code
{"issue_number": 4677, "pr_number": 6520, "commits_count": 1, "files_changed": 2, "response_length": 1031, "file_count": 4, "needs_breakdown": false}
added field frm_configs to MerchantConnectorAccount ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> We need to accept frm_configs from the dashboard. So needed to do development for accepting new fields for endpoint: `/account/:account_id/connectors` ### Additional Changes - [x] This PR modifies the database schema : `ALTER TABLE "merchant_connector_account" ADD COLUMN frm_configs jsonb;` - [ ] 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 its an obvious bug or documentation fix that will have little conversation). --> It a new feature...we are going to integrate FRM services into hyperswitch, for which we required additional fields for create connector request. This PR will accept frm_configs field for create connector request, and accordingly persist in the db. ## 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)? --> Following are the steps: - Adding an extra field to the request body, to existing curl. - Getting 200 and Expecting this same body in response. ``` "frm_configs" : { "frm_enabled_pms" : ["card"], "frm_enabled_pm_types" : ["credit"], "frm_enabled_gateways" : ["stripe"], "frm_action": "cancel_txn", "frm_preferred_flow_type" : "pre" } ``` ## 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 submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: Revert "added field frm_configs to MerchantConnectorAccount" - Merged: 2023-04-10T13:21:18Z - Files changed: 10 files - Commits: 1 commits Implementation approach: Reverts juspay/hyperswitch#831 The frm_configs handled as a mandatory field in flows. </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** Revert "added field frm_configs to MerchantConnectorAccount" (#848) Files to modify: **crates/api_models/src/admin.rs** Remove: - struct: pub::FrmConfigs **crates/api_models/src/enums.rs** Remove: - enum: pub::FrmAction - enum: pub::FrmPreferredFlowTypes **crates/router/src/core/admin.rs** Modify existing code **crates/router/src/core/payments/flows/authorize_flow.rs** Modify existing code **crates/router/src/db/merchant_connector_account.rs** Modify existing code **crates/router/src/types/transformers.rs** Modify existing code **crates/storage_models/src/merchant_connector_account.rs** Modify existing code **crates/storage_models/src/schema.rs** Modify existing code
{"issue_number": 831, "pr_number": 848, "commits_count": 1, "files_changed": 10, "response_length": 1094, "file_count": 10, "needs_breakdown": false}
[FEATURE]: [Forte] Use `connector_response_reference_id` as reference to merchant ### :memo: Feature Description - Reference id are used to map transactions in the connector’s dashboard. - Hyperswitch manages several reference ids, such as `payment_id`, `attempt_id`, and `connector_transaction_id` for a single transaction. - However, merchants may encounter uncertainty when determining which ID to utilize in the connector dashboard to identify the payment. ### :hammer: Possible Implementation - When we receive a response from the connector for the payment, we deserialize it and populate the `response` field in RouterData. - For the `TransactionResponse` type, we must fill the `connector_response_reference_id` with a corresponding reference id for the merchant to identify the transaction. - One might need to have exposure to api docs of the connector for which it is being implemented to decide what to fill in connector_response_reference_id. - You can check this PR for further reference https://github.com/juspay/hyperswitch/pull/1735 🔖 Note: All the changes needed should be contained within `hyperswitch/crates/router/src/connector/` ### :package: Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### :package: Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### :sparkles: Are you willing to submit a PR?
<think> PR Context: - Title: feat(connector): [Forte] Use connector_response_reference_id as reference to merchant - Merged: 2023-10-05T19:20:09Z - Files changed: 1 files - Commits: 5 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Addreses issue #2330 Updated `connector_response_reference_id` to use `transaction_id` from Forte response. Forte 'POST' Payment Docs -> https://restdocs.forte.net/#c35427927-d955-4087-88d3-f99413ed91c2 ### Additional Changes - </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(connector): [Forte] Use connector_response_reference_id as reference to merchant (#2456) Co-aut Files to modify: **crates/router/src/connector/forte/transformers.rs** Modify existing code
{"issue_number": 2330, "pr_number": 2456, "commits_count": 1, "files_changed": 1, "response_length": 1014, "file_count": 3, "needs_breakdown": false}
[FEATURE]: [Noon] Implement Revoke Mandate ### Feature Description When revoke mandate api is triggered, revoke the existing connector mandate with noon also ### Possible Implementation Implement Revoke Mandate for Noon ### Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? Yes, I am willing to submit a PR!
<think> PR Context: - Title: feat(connector): [noon] add revoke mandate - Merged: 2024-01-30T12:10:04Z - Files changed: 3 files - Commits: 3 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [X] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Implement revoke mandate flow for Noon ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/environment variables <!-- Provide li </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(connector): [noon] add revoke mandate (#3487) Files to modify: **crates/router/src/connector/noon.rs** Add: - function: private::get_headers - function: private::get_content_type - function: private::get_url - function: private::build_request - function: private::get_request_body - function: private::handle_response - function: private::get_error_response - impl: impl api::ConnectorMandateRevoke for Noon - impl: impl ConnectorIntegration< api::MandateRevoke, types::MandateRevokeRequestData, types::MandateRevokeResponseData, > for Noon **crates/router/src/connector/noon/transformers.rs** Remove: - struct: pub::NoonSubscriptionResponse Add: - function: private::try_from - function: private::try_from - struct: pub::NoonSubscriptionObject - struct: pub::NoonCancelSubscriptionObject - struct: pub::NoonRevokeMandateResult - struct: pub::NoonRevokeMandateResponse - enum: pub::NoonRevokeStatus - impl: impl TryFrom<&types::MandateRevokeRouterData> for NoonRevokeMandateRequest - impl: impl TryFrom< types::ResponseRouterData< F, NoonRevokeMandateResponse, types::MandateRevokeRequestData, types::MandateRevokeResponseData, >, > for types::RouterData<F, types::MandateRevokeRequestData, types::MandateRevokeResponseData> **crates/router/src/core/payments/flows.rs** Modify existing code
{"issue_number": 3494, "pr_number": 3487, "commits_count": 1, "files_changed": 3, "response_length": 2254, "file_count": 5, "needs_breakdown": false}
[REFACTOR] Make the function to deserialize hashsets more generic when deserializing application configs ### Description As of opening this issue, there are multiple functions to deserialize hashsets with similar logic. These functions can be made generic, and reduced to one common function for deserializing all types. Links to relevant functions: 1. https://github.com/juspay/hyperswitch/blob/0e4e18441d024b7d669b27d6f8a2feb3eccedb2a/crates/router/src/configs/settings.rs#L215-L242 2. https://github.com/juspay/hyperswitch/blob/0e4e18441d024b7d669b27d6f8a2feb3eccedb2a/crates/router/src/configs/settings.rs#L327-L355 3. https://github.com/juspay/hyperswitch/blob/0e4e18441d024b7d669b27d6f8a2feb3eccedb2a/crates/router/src/configs/settings.rs#L419-L469 4. https://github.com/juspay/hyperswitch/blob/0e4e18441d024b7d669b27d6f8a2feb3eccedb2a/crates/router/src/configs/settings.rs#L759-L772 In addition, the existing functions ignore any deserialization errors in case incorrect or unrecognized enum variants are provided, which causes the application to completely ignore those configuration entries. This would also have to be handled, to raise errors in case incorrect values are provided.
<think> PR Context: - Title: refactor(settings): make the function to deserialize hashsets more generic - Merged: 2024-01-30T09:19:15Z - Files changed: 13 files - Commits: 30 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR updates the application configuration deserialization logic to use a common generic function to deserialize `HashSet<T>` instead of specific ones. In addition, this PR updates the function to be more lenient in that it allows spaces ar </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(settings): make the function to deserialize hashsets more generic (#3104) Files to modify: **crates/common_enums/src/enums.rs** Modify existing code **crates/currency_conversion/src/types.rs** Modify existing code **crates/kgraph_utils/src/transformers.rs** Modify existing code **crates/router/src/configs/settings.rs** Remove: - function: private::connector_deser - function: private::payout_connector_deser - function: private::pm_deser - function: private::pm_type_deser - function: private::string_set_deser - function: private::currency_set_deser - function: private::bank_vec_deser - function: private::deser_to_get_connectors - function: private::test_pm_deserializer - mod: private::payment_method_deserialization_test Add: - function: private::deserialize_hashset_inner - function: private::deserialize_hashset - function: private::deserialize_optional_hashset - function: private::test_payment_method_hashset_deserializer - function: private::test_payment_method_hashset_deserializer_with_spaces - function: private::test_payment_method_hashset_deserializer_error - mod: private::hashset_deserialization_test
{"issue_number": 3466, "pr_number": 3104, "commits_count": 1, "files_changed": 13, "response_length": 2020, "file_count": 6, "needs_breakdown": false}
fix(connector): add expiry year conversion for adyen mit transactions ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR fixes MIT payments failing especially during NTID flow. We previously used to get below error message during MIT Confirm call: ```log "The provided Expiry Date is not valid.: Expiry year should be a 4 digit number greater than 2000: 30" ``` closes https://github.com/juspay/hyperswitch/issues/6850 ### 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). --> ## 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)? --> xecuted below commands: ```sh # cherry picked commits from my cypress branch which is where the existence of this issue came into light git cherry-pick -n ..cypress-delete-pm # ran necessary migrations on the latest branch just migrate # started the server cargo r ``` ran the cypress NTID tests for Adyen: <img width="1425" alt="image" src="https://github.com/user-attachments/assets/6fea7809-854f-428b-be45-c2632a71f5a8" /> full test (based on #6735) -- no regressions found with adyen: ![image](https://github.com/user-attachments/assets/320ee534-f5a7-4efb-9d0e-4a37575495f2) ## 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
<think> PR Context: - Title: ci: add tests that make use of locker - Merged: 2024-12-26T12:15:14Z - Files changed: 13 files - Commits: 30 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [x] CI/CD ## Description <!-- Describe your changes in detail --> This PR introduces necessary refactoring to add support for locker specific tests. This includes `addition of delete payment method` (which is restricted to work only on hosted environments and not local given `tartarus` is unavailable and i </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 6851, "pr_number": 6735, "commits_count": 0, "files_changed": 13, "response_length": 769, "file_count": 0, "needs_breakdown": false}
Include single purpose token and single purpose JWT auth Create single purpose token and single purpose JWT auth that will server as generic for intermediate tokens and can be used for different cases, during TOTP, change passwords, accept invite etc.
<think> PR Context: - Title: feat(user): add single purpose token and auth - Merged: 2024-04-29T12:39:08Z - Files changed: 3 files - Commits: 6 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Add single purpose token and authentication for single purpose token. This token will serves as a intermediate token and used to perform a certain action only. ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(user): add single purpose token and auth (#4470) Files to modify: **crates/router/src/consts.rs** Modify existing code **crates/router/src/services/authentication.rs** Add: - function: private::authenticate_and_fetch - struct: pub::SinglePurposeJWTAuth - impl: impl AuthenticateAndFetch<UserFromSinglePurposeToken, A> for SinglePurposeJWTAuth **crates/router/src/services/authentication/blacklist.rs** Add: - function: private::check_in_blacklist - impl: impl BlackList for SinglePurposeToken
{"issue_number": 4478, "pr_number": 4470, "commits_count": 1, "files_changed": 3, "response_length": 1305, "file_count": 5, "needs_breakdown": false}
One click docker setup A script is needed to ensure one click docker setup, to minimise issues faced by users. > Run the whole setup with simple command > Show output with localhost links for different setups
<think> PR Context: - Title: fix: script for one click docker setup - Merged: 2025-04-13T18:11:03Z - Files changed: 2 files - Commits: 6 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [X] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Added the script for showing output of ```docker compose up -d``` command, along with links to access individual components. ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 7761, "pr_number": 7806, "commits_count": 0, "files_changed": 2, "response_length": 768, "file_count": 0, "needs_breakdown": false}
feat(core): Payments core modification for open banking connectors ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> - Added Post-Processing flows for Open banking connectors - Traits and and type changes - #3758 needs to go in first ### 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). --> ## 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. Add Plaid MCA with `payment_method` as `open_banking` and `payment_method_type` as `open_banking_pis` ``` curl --location --request POST 'http://localhost:8080/account/merchant_1720607250/connectors' \ --header 'api-key: test_admin' \ --header 'Content-Type: application/json' \ --data-raw '{ "connector_type": "payment_processor", "connector_name": "plaid", "connector_account_details": { "auth_type": "BodyKey", "api_key": "some_key", "key1": "some_key" }, "test_mode": false, "disabled": false, "payment_methods_enabled": [ { "payment_method": "open_banking", "payment_method_types": [ { "payment_method_type": "open_banking_pis", "recurring_enabled": false, "installment_payment_enabled": false, "accepted_currencies": { "type": "enable_only", "list": [ "EUR", "GBP" ] } } ] } ], "additional_merchant_data": { "open_banking_recipient_data": { "account_data": { "bacs": { "sort_code": "200000", "account_number": "55779911", "name": "merchant_name" } } } }, "metadata": { "city": "NY", "unit": "246" } }' ``` Response - ``` { "connector_type": "payment_processor", "connector_name": "plaid", "connector_label": "plaid3", "merchant_connector_id": "mca_gVM5IWhLHFsW5q8F3uez", "profile_id": "pro_UgP3FfqWGhfPLuUqYtJF", "connector_account_details": { "auth_type": "BodyKey", "api_key": "Some_key", "key1": "Some_key" }, "payment_methods_enabled": [ { "payment_method": "open_banking", "payment_method_types": [ { "payment_method_type": "open_banking_pis", "payment_experience": null, "card_networks": null, "accepted_currencies": { "type": "enable_only", "list": [ "EUR", "GBP" ] }, "accepted_countries": null, "minimum_amount": null, "maximum_amount": null, "recurring_enabled": false, "installment_payment_enabled": false } ] } ], "connector_webhook_details": null, "metadata": { "city": "NY", "unit": "246" }, "test_mode": false, "disabled": false, "frm_configs": null, "business_country": null, "business_label": null, "business_sub_label": null, "applepay_verified_domains": null, "pm_auth_config": null, "status": "active", "additional_merchant_data": { "open_banking_recipient_data": { "account_data": { "bacs": { "account_number": "55779911", "sort_code": "200000", "name": "merchant_name", "connector_recipient_id": "recipient-id-sandbox-45beb880-9e3d-4ae3-927b-052f5610fd74" } } } } } ``` ## 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 - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: feat(connector): Plaid connector Integration - Merged: 2024-07-19T08:29:01Z - Files changed: 26 files - Commits: 30 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> - Integrated Plaid as a Payment connector - #3758 and #3947 needs to go in first ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies application configurat </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(connector): Plaid connector Integration (#3952) Co-authored-by: hyperswitch-bot[bot] <148525504 Files to modify: **crates/hyperswitch_domain_models/src/router_request_types.rs** Modify existing code **crates/hyperswitch_interfaces/src/configs.rs** Modify existing code **crates/pm_auth/src/connector/plaid/transformers.rs** Modify existing code **crates/pm_auth/src/types.rs** Modify existing code **crates/router/src/connector.rs** Add: - mod: pub::plaid **crates/router/src/connector/plaid.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_request_body - 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_webhook_object_reference_id - function: private::get_webhook_event_type - function: private::get_webhook_resource_object - struct: pub::Plaid - impl: impl Plaid - impl: impl api::Payment for Plaid - impl: impl api::PaymentSession for Plaid - impl: impl api::ConnectorAccessToken for Plaid - impl: impl api::MandateSetup for Plaid - impl: impl api::PaymentAuthorize for Plaid - impl: impl api::PaymentSync for Plaid - impl: impl api::PaymentCapture for Plaid - impl: impl api::PaymentVoid for Plaid - impl: impl api::Refund for Plaid - impl: impl api::RefundExecute for Plaid - impl: impl api::RefundSync for Plaid - impl: impl api::PaymentToken for Plaid - impl: impl api::PaymentsPostProcessing for Plaid - impl: impl ConnectorIntegration< api::PaymentMethodToken, types::PaymentMethodTokenizationData, types::PaymentsResponseData, > for Plaid - impl: impl ConnectorCommonExt<Flow, Request, Response> for Plaid - impl: impl ConnectorCommon for Plaid - impl: impl ConnectorValidation for Plaid - impl: impl ConnectorIntegration<api::Session, types::PaymentsSessionData, types::PaymentsResponseData> for Plaid - impl: impl ConnectorIntegration<api::AccessTokenAuth, types::AccessTokenRequestData, types::AccessToken> for Plaid - impl: impl ConnectorIntegration< api::SetupMandate, types::SetupMandateRequestData, types::PaymentsResponseData, > for Plaid - impl: impl ConnectorIntegration<api::Authorize, types::PaymentsAuthorizeData, types::PaymentsResponseData> for Plaid - impl: impl ConnectorIntegration<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> for Plaid - impl: impl ConnectorIntegration< api::PostProcessing, types::PaymentsPostProcessingData, types::PaymentsResponseData, > for Plaid - impl: impl ConnectorIntegration<api::Capture, types::PaymentsCaptureData, types::PaymentsResponseData> for Plaid - impl: impl ConnectorIntegration<api::Void, types::PaymentsCancelData, types::PaymentsResponseData> for Plaid - impl: impl ConnectorIntegration<api::Execute, types::RefundsData, types::RefundsResponseData> for Plaid - impl: impl ConnectorIntegration<api::RSync, types::RefundsData, types::RefundsResponseData> for Plaid - impl: impl api::IncomingWebhook for Plaid - mod: pub::transformers **crates/router/src/connector/plaid/transformers.rs** Add: - function: private::from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::from - function: private::try_from - function: private::try_from - function: private::try_from - struct: pub::PlaidRouterData - struct: pub::PlaidPaymentsRequest - struct: pub::PlaidAmount - struct: pub::PlaidSchedule - struct: pub::PlaidOptions - struct: pub::PlaidBacs - struct: pub::PlaidLinkTokenRequest - struct: pub::User - struct: pub::PlaidPaymentInitiation - struct: pub::PlaidAuthType - struct: pub::PlaidPaymentsResponse - struct: pub::PlaidLinkTokenResponse - struct: pub::PlaidSyncRequest - struct: pub::PlaidSyncResponse - struct: pub::PlaidErrorResponse - enum: pub::PlaidPaymentStatus - impl: impl From<(FloatMajorUnit, T)> for PlaidRouterData<T> - impl: impl TryFrom<&PlaidRouterData<&types::PaymentsAuthorizeRouterData>> for PlaidPaymentsRequest - impl: impl TryFrom<&types::PaymentsSyncRouterData> for PlaidSyncRequest - impl: impl TryFrom<&types::PaymentsPostProcessingRouterData> for PlaidLinkTokenRequest - impl: impl TryFrom<&types::ConnectorAuthType> for PlaidAuthType - impl: impl From<PlaidPaymentStatus> for enums::AttemptStatus - impl: impl TryFrom<types::ResponseRouterData<F, PlaidPaymentsResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<types::ResponseRouterData<F, PlaidLinkTokenResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<types::ResponseRouterData<F, PlaidSyncResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> **crates/router/src/core/admin.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/core/pm_auth.rs** Modify existing code **crates/router/src/types/api.rs** Modify existing code **crates/router/src/types/domain/payments.rs** Modify existing code **crates/router/src/types/transformers.rs** Modify existing code **crates/router/tests/connectors/main.rs** Add: - mod: private::plaid **crates/router/tests/connectors/plaid.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::PlaidTest - impl: impl ConnectorActions for PlaidTest - impl: impl Connector for PlaidTest **crates/test_utils/src/connector_auth.rs** Modify existing code
{"issue_number": 3947, "pr_number": 3952, "commits_count": 1, "files_changed": 26, "response_length": 9086, "file_count": 19, "needs_breakdown": true}
feat(themes): Support naming themes Currently themes don't have names, and it's better to have a way to attach a name to a theme. So that we can know about theme without having to look at the theme data.
<think> PR Context: - Title: feat(themes): Add `theme_name` and `entity_type` in themes table - Merged: 2024-11-21T21:06:12Z - Files changed: 8 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR adds `theme_name` and `entity_type` in the themes table. This will help us in 1. Having a name for the theme. 2. EntityType identifier to help us identity the lineage type instead of guessing it. ### Additional Changes - [ ] </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(themes): Add `theme_name` and `entity_type` in themes table (#6621) Files to modify: **crates/common_utils/src/types/theme.rs** Modify existing code **crates/diesel_models/src/query/user/theme.rs** Modify existing code **crates/diesel_models/src/schema.rs** Modify existing code **crates/diesel_models/src/schema_v2.rs** Modify existing code **crates/diesel_models/src/user/theme.rs** Modify existing code **crates/router/src/db/user/theme.rs** Modify existing code
{"issue_number": 6620, "pr_number": 6621, "commits_count": 1, "files_changed": 8, "response_length": 1286, "file_count": 8, "needs_breakdown": false}
[FEATURE] add payments get-intent API for v2 # Feature Description Add payments `get-intent` API for v2
<think> PR Context: - Title: feat(router): Add payments get-intent API for v2 - Merged: 2024-10-30T16:28:52Z - Files changed: 18 files - Commits: 8 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Added `get-intent` API for payments ### Additional Changes - [x] 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. </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(router): Add payments get-intent API for v2 (#6396) Co-authored-by: hyperswitch-bot[bot] <14852 Files to modify: **crates/api_models/src/events/payment.rs** Remove: - impl: impl ApiEventMetric for PaymentsCreateIntentResponse Add: - function: private::get_api_event_type - impl: impl ApiEventMetric for PaymentsGetIntentRequest - impl: impl ApiEventMetric for PaymentsIntentResponse **crates/api_models/src/payments.rs** Remove: - struct: pub::PaymentsCreateIntentResponse Add: - struct: pub::PaymentsGetIntentRequest - struct: pub::PaymentsIntentResponse **crates/hyperswitch_domain_models/src/router_flow_types/payments.rs** Remove: - struct: pub::CreateIntent Add: - struct: pub::PaymentCreateIntent - struct: pub::PaymentGetIntent **crates/openapi/src/openapi_v2.rs** Modify existing code **crates/openapi/src/routes/payments.rs** Add: - function: pub::payments_get_intent **crates/router/src/core/payments.rs** Modify existing code **crates/router/src/core/payments/operations.rs** Remove: - mod: pub::payment_confirm_intent Add: - mod: pub::payment_confirm_intent - mod: pub::payment_get_intent **crates/router/src/core/payments/operations/payment_get_intent.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::get_connector - function: private::guard_payment_against_blocklist - struct: pub::PaymentGetIntent - impl: impl Operation<F, PaymentsGetIntentRequest> for &PaymentGetIntent - impl: impl Operation<F, PaymentsGetIntentRequest> for PaymentGetIntent - impl: impl GetTracker<F, payments::PaymentIntentData<F>, PaymentsGetIntentRequest> for PaymentGetIntent - impl: impl UpdateTracker<F, payments::PaymentIntentData<F>, PaymentsGetIntentRequest> for PaymentGetIntent - impl: impl ValidateRequest<F, PaymentsGetIntentRequest, payments::PaymentIntentData<F>> for PaymentGetIntent - impl: impl Domain<F, PaymentsGetIntentRequest, payments::PaymentIntentData<F>> for PaymentGetIntent **crates/router/src/core/payments/transformers.rs** Remove: - impl: impl ToResponse<F, D, Op> for api::PaymentsCreateIntentResponse Add: - impl: impl ToResponse<F, D, Op> for api::PaymentsIntentResponse **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::payments_get_intent **crates/router/src/services/api.rs** Remove: - impl: impl Authenticate for api_models::payments::PaymentsCreateIntentRequest **crates/router/src/types/api/payments.rs** Modify existing code **crates/router_env/src/logger/types.rs** Modify existing code
{"issue_number": 6395, "pr_number": 6396, "commits_count": 1, "files_changed": 18, "response_length": 4012, "file_count": 17, "needs_breakdown": true}
feat(core): add additional revenue recovery call flow ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description For some billing connectors, we get limited data in the webhook that is not sufficient to use. So we need to make an additional api call for this extra data. This pr adds that flow. ### 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 No testing required since its just defining the flow not using it. ## Checklist <!-- Put an `x` in the boxes that apply --> - [ ] 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
<think> PR Context: - Title: feat(connector): Add recovery support for stripebilling - Merged: 2025-04-02T07:49:57Z - Files changed: 30 files - Commits: 30 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Context: In case of some billing connectors we dont get the enough data in the webhook itself to support creation of payment intent and payment attempt in our system. So previously we derived a flow named "AdditionalRevenuerecoveryDetails" in this PR:#7402 which name is now changed t </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(connector): Add recovery support for stripebilling (#7461) Co-authored-by: Nishanth Challa <nis Files to modify: **crates/api_models/src/webhooks.rs** Add: - function: pub::get_connector_transaction_id_as_string - impl: impl ObjectReferenceId **crates/common_enums/src/connector_enums.rs** Modify existing code **crates/connector_configs/src/connector.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors/stripebilling.rs** Add: - function: private::get_headers - function: private::get_content_type - function: private::get_revenue_recovery_attempt_details - function: private::get_revenue_recovery_invoice_details - impl: impl api::revenue_recovery::BillingConnectorPaymentsSyncIntegration for Stripebilling **crates/hyperswitch_connectors/src/connectors/stripebilling/transformers.rs** Add: - function: pub::get_webhook_object_from_body - function: pub::get_invoice_webhook_data_from_body - function: private::try_from - function: private::from - struct: pub::StripebillingRecoveryDetailsData - impl: impl StripebillingWebhookBody - impl: impl StripebillingInvoiceBody - impl: impl TryFrom<StripebillingInvoiceBody> for revenue_recovery::RevenueRecoveryInvoiceData - impl: impl From<StripebillingFundingTypes> for common_enums::PaymentMethodType - mod: pub::auth_headers **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/revenue_recovery.rs** Add: - function: private::from - function: private::from - impl: impl From<&BillingConnectorPaymentsSyncResponse> for RevenueRecoveryInvoiceData - impl: impl From<&BillingConnectorPaymentsSyncResponse> for RevenueRecoveryAttemptData **crates/hyperswitch_domain_models/src/router_data_v2/flow_common_types.rs** Remove: - struct: pub::GetAdditionalRevenueRecoveryFlowCommonData Add: - struct: pub::BillingConnectorPaymentsSyncFlowData **crates/hyperswitch_domain_models/src/router_flow_types/revenue_recovery.rs** Remove: - struct: pub::GetAdditionalRevenueRecoveryDetails Add: - struct: pub::BillingConnectorPaymentsSync **crates/hyperswitch_domain_models/src/router_request_types/revenue_recovery.rs** Remove: - struct: pub::GetAdditionalRevenueRecoveryRequestData Add: - struct: pub::BillingConnectorPaymentsSyncRequest **crates/hyperswitch_domain_models/src/router_response_types/revenue_recovery.rs** Remove: - struct: pub::GetAdditionalRevenueRecoveryResponseData Add: - struct: pub::BillingConnectorPaymentsSyncResponse **crates/hyperswitch_domain_models/src/types.rs** Modify existing code **crates/hyperswitch_interfaces/src/api.rs** Modify existing code **crates/hyperswitch_interfaces/src/api/revenue_recovery.rs** Modify existing code **crates/hyperswitch_interfaces/src/api/revenue_recovery_v2.rs** Remove: - trait: pub::RevenueRecoveryV2 Add: - trait: pub::RevenueRecoveryV2 **crates/hyperswitch_interfaces/src/conversion_impls.rs** Add: - function: private::from_old_router_data - function: private::to_old_router_data - impl: impl RouterDataConversion<T, Req, Resp> for BillingConnectorPaymentsSyncFlowData **crates/hyperswitch_interfaces/src/types.rs** Modify existing code **crates/router/src/configs/secrets_transformers.rs** Modify existing code **crates/router/src/configs/settings.rs** Remove: - struct: pub::GetAdditionalRevenueRecoveryDetailsCall Add: - struct: pub::BillingConnectorPaymentsSyncCall **crates/router/src/core/admin.rs** Modify existing code **crates/router/src/core/errors.rs** Modify existing code **crates/router/src/core/payments/flows.rs** Modify existing code **crates/router/src/core/webhooks/incoming_v2.rs** Modify existing code **crates/router/src/core/webhooks/recovery_incoming.rs** Add: - function: private::get_recovery_invoice_details - function: private::get_recovery_invoice_transaction_details - function: private::get_recovery_payment_attempt - function: private::handle_billing_connector_payment_sync_call - function: private::get_billing_connector_payment_details - function: private::inner - function: private::construct_router_data_for_billing_connector_payment_sync_call - function: private::inner - struct: pub::BillingConnectorPaymentsSyncResponseData - struct: pub::BillingConnectorPaymentsSyncFlowRouterData - impl: impl BillingConnectorPaymentsSyncResponseData - impl: impl BillingConnectorPaymentsSyncFlowRouterData **crates/router/src/services/api.rs** Modify existing code **crates/router/src/types.rs** Modify existing code **crates/router/src/types/api.rs** Modify existing code **crates/router/src/types/transformers.rs** Modify existing code
{"issue_number": 7402, "pr_number": 7461, "commits_count": 1, "files_changed": 30, "response_length": 5731, "file_count": 31, "needs_breakdown": true}
fix(connector): convert PII data into connector request without peeking the info - Currently we are sending the PII information to each connector request by peeking the information and pass it as plain text, instead of doing it in the compile time Serde should handle this process while serialising the data so we can assure PII info not being leaked if someone mistakenly add logs for request data
<think> PR Context: - Title: refactor(connector): remove `peek()` on PII info - Merged: 2023-02-25T13:06:09Z - Files changed: 15 files - Commits: 3 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [X] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> Closes #308 ### Additional Changes - [ ] 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 fi </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(connector): remove `peek()` on PII info (#642) Co-authored-by: Nishant Joshi <nishant.joshi Files to modify: **crates/masking/src/secret.rs** Add: - function: pub::zip - function: pub::map **crates/router/src/connector/aci/transformers.rs** Modify existing code **crates/router/src/connector/authorizedotnet/transformers.rs** Modify existing code **crates/router/src/connector/braintree/transformers.rs** Modify existing code **crates/router/src/connector/cybersource/transformers.rs** Modify existing code **crates/router/src/connector/globalpay.rs** Modify existing code **crates/router/src/connector/globalpay/requests.rs** Modify existing code **crates/router/src/connector/globalpay/transformers.rs** Modify existing code **crates/router/src/connector/shift4/transformers.rs** Modify existing code **crates/router/src/connector/utils.rs** Remove: - function: private::get_card_number - function: private::get_card_expiry_month - function: private::get_card_expiry_year - function: private::get_card_expiry_year_2_digit **crates/router/src/connector/worldpay/requests.rs** Modify existing code **crates/router/src/connector/worldpay/transformers.rs** Remove: - function: private::parse_int **crates/router/src/core/errors/api_error_response.rs** Modify existing code **crates/router/src/core/payments/operations/payment_response.rs** Modify existing code **crates/router/tests/connectors/globalpay.rs** Modify existing code
{"issue_number": 308, "pr_number": 642, "commits_count": 1, "files_changed": 15, "response_length": 2292, "file_count": 17, "needs_breakdown": true}
[REFACTOR] Remove the `pii-encryption-script` cargo feature ### Description As of now, the `sandbox` and `production` cargo features differ only by the `pii-encryption-script` cargo feature: https://github.com/juspay/hyperswitch/blob/fc6acd04cb28f02a4f52ec77d8ae003957183ff2/crates/router/Cargo.toml#L19-L20 If we're to use a single Docker image for all our environments as described in #1346, then this would be an initial step towards that goal.
<think> PR Context: - Title: refactor(router): remove `pii-encryption-script` feature and use of timestamps for decryption - Merged: 2023-06-05T13:37:30Z - Files changed: 24 files - Commits: 3 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR removes the `pii-encryption-script` cargo feature from the `router` crate, and the usage of timestamps to decide and decrypt data stored in the database. ### Additional Changes - [ ] This PR modifies the API contract - [ ] This </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(router): remove `pii-encryption-script` feature and use of timestamps for decryption (#1350 Files to modify: **crates/router/src/bin/router.rs** Modify existing code **crates/router/src/configs/defaults.rs** Modify existing code **crates/router/src/configs/settings.rs** Modify existing code **crates/router/src/core/customers.rs** Modify existing code **crates/router/src/db.rs** Remove: - function: private::get_migration_timestamp - function: private::get_migration_timestamp **crates/router/src/db/address.rs** Modify existing code **crates/router/src/db/customers.rs** Modify existing code **crates/router/src/db/merchant_account.rs** Modify existing code **crates/router/src/db/merchant_connector_account.rs** Modify existing code **crates/router/src/db/merchant_key_store.rs** Modify existing code **crates/router/src/lib.rs** Remove: - mod: pub::scripts **crates/router/src/scripts.rs** Remove: - mod: pub::pii_encryption **crates/router/src/scripts/pii_encryption.rs** Remove: - function: pub::create_merchant_key_store - function: pub::encrypt_merchant_account_fields - function: pub::encrypt_merchant_connector_account_fields - function: pub::encrypt_customer_fields - function: pub::encrypt_address_fields - function: pub::test_2_step_encryption **crates/router/src/services.rs** Modify existing code **crates/router/src/types/domain/address.rs** Modify existing code **crates/router/src/types/domain/behaviour.rs** Modify existing code **crates/router/src/types/domain/customer.rs** Modify existing code **crates/router/src/types/domain/merchant_account.rs** Modify existing code **crates/router/src/types/domain/merchant_connector_account.rs** Modify existing code **crates/router/src/types/domain/merchant_key_store.rs** Modify existing code **crates/router/src/types/domain/types.rs** Modify existing code
{"issue_number": 1349, "pr_number": 1350, "commits_count": 1, "files_changed": 24, "response_length": 2761, "file_count": 23, "needs_breakdown": true}
[FEATURE]: [Iatapay] Use `connector_response_reference_id` as reference to merchant ### :memo: Feature Description - Reference id are used to map transactions in the connector’s dashboard. - Hyperswitch manages several reference ids, such as `payment_id`, `attempt_id`, and `connector_transaction_id` for a single transaction. - However, merchants may encounter uncertainty when determining which ID to utilize in the connector dashboard to identify the payment. ### :hammer: Possible Implementation - When we receive a response from the connector for the payment, we deserialize it and populate the `response` field in RouterData. - For the `TransactionResponse` type, we must fill the `connector_response_reference_id` with a corresponding reference id for the merchant to identify the transaction. - One might need to have exposure to api docs of the connector for which it is being implemented to decide what to fill in connector_response_reference_id. - You can check this PR for further reference https://github.com/juspay/hyperswitch/pull/1735 🔖 Note: All the changes needed should be contained within `hyperswitch/crates/router/src/connector/` ### :package: Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### :package: Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### :sparkles: Are you willing to submit a PR?
<think> PR Context: - Title: feat(connector): [Iatapay] use connector_response_reference_id as reference to connector - Merged: 2023-10-12T07:07:31Z - Files changed: 1 files - Commits: 10 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> - Adressess issue #2333 : Implement `connector_response_reference_id ` as reference to connector for Iatapay - Modified the file `hyperswitch/crates/router/src/connector/iatapay/transformers.rs` - Rebased with changes from [https://github </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(connector): [Iatapay] use connector_response_reference_id as reference to connector (#2524) Co- Files to modify: **crates/router/src/connector/iatapay/transformers.rs** Modify existing code
{"issue_number": 2333, "pr_number": 2524, "commits_count": 1, "files_changed": 1, "response_length": 1020, "file_count": 3, "needs_breakdown": false}
[BUG] Remove default values for created_at and modified_at from the database # Context Currently we are setting `created_at` and `modified_at` in the database during insert through Posgresql `now()` function which gives the current time according to the current time zone. But when we modify the data we pass `common_utils::date_time::now` to update modified at which gives the date time in UTC. # Resolution Remove default values for `created_at` and `modified_at` from database and add it in `DatabaseStructNew` struct. Which forces the developer to pass these values while inserting, which fixes inconsistencies of these two values between database and application
<think> PR Context: - Title: fix: remove defaults from `created_at` and `modified_at` - Merged: 2023-05-02T20:45:30Z - Files changed: 12 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix ## Description <!-- Describe your changes in detail --> This closes #984 ### Additional Changes - [x] This PR modifies the database schema <!-- 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 probl </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 984, "pr_number": 991, "commits_count": 0, "files_changed": 12, "response_length": 787, "file_count": 0, "needs_breakdown": false}
[FEATURE] Add separate function for Plaid in Connector Config Need to add separate function for plaid in connector config for wasm
<think> PR Context: - Title: feat(Connector): Plaid connector configs - Merged: 2024-08-09T09:29:41Z - Files changed: 2 files - Commits: 11 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Refer #5548 ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [x] This PR modifies application configuration/environment variables <!-- Provide links to the files with corresponding changes. Following are the </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(Connector): Plaid connector configs (#5545) Co-authored-by: Sarthak Soni <[email protected] Files to modify: **crates/connector_configs/src/connector.rs** Add: - function: pub::get_pm_authentication_processor_config **crates/euclid_wasm/src/lib.rs** Add: - function: pub::get_pm_authentication_processor_config
{"issue_number": 5548, "pr_number": 5545, "commits_count": 1, "files_changed": 2, "response_length": 1108, "file_count": 4, "needs_breakdown": false}
feat(users): List users in lineage API - Currently user roles are grouped by user email in dashboard. - Payload might look something like this ```json [ { "email": "e1", "roles": [ { "role_id": "r1", "role_name": "name" } ] } ] ```
<think> PR Context: - Title: feat(users): Add API to list users in user lineage - Merged: 2024-08-28T12:18:05Z - Files changed: 18 files - Commits: 6 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> - This PR adds a new API which will be used to list the users in the lineage. - This PR also adds a db function for listing users in a particular org. ### Additional Changes - [x] This PR modifies the API contract - [ ] This PR modifie </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(users): Add API to list users in user lineage (#5722) Files to modify: **crates/api_models/src/user.rs** Add: - struct: pub::ListUsersInEntityResponse - struct: pub::MinimalRoleInfo **crates/common_enums/src/enums.rs** Modify existing code **crates/common_utils/src/consts.rs** Modify existing code **crates/diesel_models/src/query/user_role.rs** Add: - function: pub::generic_user_roles_list_for_user **crates/diesel_models/src/user_role.rs** Add: - function: private::get_entity_id_and_type - function: private::hash - function: private::eq - impl: impl Hash for UserRole - impl: impl PartialEq for UserRole **crates/router/src/consts/user_role.rs** Modify existing code **crates/router/src/core/errors/user.rs** Modify existing code **crates/router/src/core/user.rs** Modify existing code **crates/router/src/core/user_role.rs** Add: - function: private::list_users_in_lineage **crates/router/src/core/user_role/role.rs** Modify existing code **crates/router/src/db/kafka_store.rs** Add: - function: private::list_user_roles_by_user_id_and_version **crates/router/src/db/user_role.rs** Modify existing code **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::list_users_in_lineage **crates/router/src/services/authorization/roles/predefined_roles.rs** Modify existing code **crates/router/src/types/domain/user.rs** Modify existing code **crates/router_env/src/logger/types.rs** Modify existing code
{"issue_number": 5721, "pr_number": 5722, "commits_count": 1, "files_changed": 18, "response_length": 2423, "file_count": 20, "needs_breakdown": true}
[BUG] Setup fail : migration_runner exits with code 1 during standalone setup ### Bug Description While setting up Hyperswitch locally using the scripts/setup.sh script, the setup consistently fails during the migration_runner step. The database (pg) and Redis services start successfully and report as Healthy, but the migration_runner container exits with code 1, causing the setup process to stop. This blocks local development/testing on Windows environments. Below is the ss of error : <img width="930" height="942" alt="Image" src="https://github.com/user-attachments/assets/1578a5d6-323b-4858-8599-fb2cac588804" /> ### Expected Behavior All the containers should have been started and compiled successfully ### Actual Behavior The error mentioned above occurred ### Steps To Reproduce Clone the Repo and run `scripts/setup.sh` ### Context For The Bug This is my first time setting up a project this big locally , so i might have miss something , or this might be an actual bug . Either way , i request some help in this matter ### Environment OS : Windows ### Have you spent some time checking if this bug has been raised before? - [x] I checked and didn't find a similar issue ### Have you read the Contributing Guidelines? - [x] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? Yes, I am willing to submit a PR!
<think> PR Context: - Title: fix(gitattributes): enforce LF for `.patch` files to avoid CRLF parsing errors on Windows - Merged: 2025-09-17T10:03:30Z - Files changed: 1 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR adds the following rule to `.gitattributes` to ensure `.patch` files always use LF line endings, regardless of developer OS: ```gitattributes *.patch text eol=lf ``` This rule overrides Windows’ default `core.autocrlf` behavi </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 9120, "pr_number": 9333, "commits_count": 0, "files_changed": 1, "response_length": 819, "file_count": 0, "needs_breakdown": false}
feat(users): Add profile id in JWT and user_info Currently tokens doesn't have profile id. Backend should start sending it or else dashboard will not work at profile level.
<think> PR Context: - Title: feat(users): Send profile_id in JWT and user_info APIs - Merged: 2024-09-05T13:56:08Z - Files changed: 9 files - Commits: 4 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> 1. This PR changes list users in lineage API so that it don't do any db call to get the role info which leads us to send null in role name in the response. 2. This PR will add profile_id in JWT and user info API. ### Additional Changes </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(users): Send profile_id in JWT and user_info APIs (#5817) Files to modify: **crates/api_models/src/user.rs** Modify existing code **crates/api_models/src/user_role/role.rs** Modify existing code **crates/router/src/core/user.rs** Modify existing code **crates/router/src/core/user_role.rs** Modify existing code **crates/router/src/core/user_role/role.rs** Modify existing code **crates/router/src/types/domain/user.rs** Remove: - function: pub::get_role_from_db - function: pub::get_roles_from_db - function: pub::get_role_from_db_by_merchant_id **crates/router/src/types/domain/user/decision_manager.rs** Modify existing code **crates/router/src/utils/user.rs** Add: - function: pub::generate_jwt_auth_token_with_attributes_without_profile **crates/router/src/utils/user_role.rs** Add: - function: pub::get_single_merchant_id_and_profile_id
{"issue_number": 5816, "pr_number": 5817, "commits_count": 1, "files_changed": 9, "response_length": 1682, "file_count": 11, "needs_breakdown": false}
[CHORE] Bump Cypress to v14 bump cypress version to `v14` from `v13.17.0`. there's a ton of under the hood changes and improvements. check: [docs.cypress.io/app/references/changelog](https://docs.cypress.io/app/references/changelog) cypress v14 has significant impact on the way we do the redirection flow. check pr description for detailed information.
<think> PR Context: - Title: chore: bump cypress to `v14.0.0` - Merged: 2025-02-03T13:52:14Z - Files changed: 10 files - Commits: 30 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [x] Dependency updates - [ ] Documentation - [x] CI/CD ## Description <!-- Describe your changes in detail --> closes #7103 - video recording - video recording gets around the race condition that resulted in parallel tests to fail when a payment failed at the same time - connector specific recording - store only failed payment recording </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 7103, "pr_number": 7102, "commits_count": 0, "files_changed": 10, "response_length": 764, "file_count": 0, "needs_breakdown": false}
[FEATURE] Mandates for alternate payment methods via Stripe ### Feature Description **Scope:** Implementation of - [ ] Applepay recurring payments via Stripe connector - [ ] Googlepay recurring payments via Stripe connector ### Possible Implementation Recurring payments for Applepay and Googlepay needs to be built in a processor agnostic manner. This means that if the first recurring payment is processed via processor A, the second recurring payment could be processed via processor B. ### Have you spent some time to check if this feature request has been raised before? - [X] I checked and didn't find similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? None
<think> PR Context: - Title: feat(connector): Mandates for alternate payment methods via Stripe - Merged: 2023-05-08T14:03:55Z - Files changed: 30 files - Commits: 30 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [X] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Closes #940 ### 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 co </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(connector): Mandates for alternate payment methods via Stripe (#1041) Co-authored-by: Manoj Gho Files to modify: **crates/api_models/src/payments.rs** Add: - struct: pub::ConnectorMandateReferenceId **crates/router/src/configs/settings.rs** Add: - function: private::pm_type_deser - enum: pub::PaymentMethodTypeTokenFilter **crates/router/src/connector/adyen/transformers.rs** Modify existing code **crates/router/src/connector/globalpay/transformers.rs** Modify existing code **crates/router/src/connector/multisafepay/transformers.rs** Modify existing code **crates/router/src/connector/nexinets/transformers.rs** Modify existing code **crates/router/src/connector/nuvei/transformers.rs** Modify existing code **crates/router/src/connector/payeezy/transformers.rs** Modify existing code **crates/router/src/connector/stripe.rs** Modify existing code **crates/router/src/connector/stripe/transformers.rs** Add: - function: private::try_from - function: private::foreign_from - function: private::foreign_from - struct: pub::GooglePayToken - struct: pub::GooglepayPayment - struct: pub::LatestPaymentAttempt - enum: pub::LatestAttempt - impl: impl TryFrom<&payments::GooglePayWalletData> for StripePaymentMethodData - impl: impl ForeignFrom<(Option<StripePaymentMethodOptions>, String)> for types::MandateReference - impl: impl ForeignFrom<Option<LatestAttempt>> for Option<String> **crates/router/src/connector/utils.rs** Add: - function: private::get_connector_mandate_id - trait: pub::MandateReferenceData - impl: impl MandateReferenceData for api_models::payments::ConnectorMandateReferenceId **crates/router/src/core/errors/utils.rs** Modify existing code **crates/router/src/core/mandate.rs** Modify existing code **crates/router/src/core/payments.rs** Add: - function: private::is_payment_method_type_allowed_for_connector - mod: pub::customers - mod: pub::tokenization **crates/router/src/core/payments/customers.rs** Add: - function: pub::create_connector_customer - function: pub::should_call_connector_create_customer - function: pub::update_connector_customer_in_customers **crates/router/src/core/payments/flows/authorize_flow.rs** Remove: - function: private::save_in_locker - function: pub::create_payment_method_metadata - function: private::set_mandate_id - function: pub::update_connector_customer_in_customers - function: pub::should_call_connector_create_customer - function: pub::add_payment_method_token **crates/router/src/core/payments/flows/verfiy_flow.rs** Add: - function: private::add_payment_method_token - function: private::create_connector_customer - function: private::try_from - function: private::try_from - impl: impl TryFrom<types::VerifyRequestData> for types::PaymentMethodTokenizationData **crates/router/src/core/payments/helpers.rs** Modify existing code **crates/router/src/core/payments/operations/payment_create.rs** Modify existing code **crates/router/src/core/payments/operations/payment_update.rs** Modify existing code **crates/router/src/core/payments/tokenization.rs** Add: - function: pub::save_payment_method - function: pub::save_in_locker - function: pub::create_payment_method_metadata - function: pub::add_payment_method_token **crates/router/src/core/payments/transformers.rs** Modify existing code **crates/router/src/types.rs** Add: - struct: pub::MandateReference **crates/router/tests/connectors/main.rs** Add: - mod: private::stripe_ui **crates/router/tests/connectors/nuvei_ui.rs** Modify existing code **crates/router/tests/connectors/selenium.rs** Remove: - function: private::process_payment Add: - function: pub::get_browser **crates/router/tests/connectors/stripe_ui.rs** Add: - function: private::should_make_stripe_3ds_payment - function: private::should_make_stripe_3ds_mandate_payment - function: private::should_fail_recurring_payment_due_to_authentication - function: private::should_make_stripe_3ds_mandate_with_zero_dollar_payment - function: private::should_make_stripe_gpay_payment - function: private::should_make_stripe_gpay_mandate_payment - function: private::should_make_stripe_3ds_payment_test - function: private::should_make_stripe_3ds_mandate_payment_test - function: private::should_fail_recurring_payment_due_to_authentication_test - function: private::should_make_stripe_3ds_mandate_with_zero_dollar_payment_test - function: private::should_make_stripe_gpay_payment_test - function: private::should_make_stripe_gpay_mandate_payment_test - struct: private::StripeSeleniumTest - impl: impl SeleniumTest for StripeSeleniumTest **crates/storage_models/src/mandate.rs** Modify existing code **crates/storage_models/src/schema.rs** Modify existing code
{"issue_number": 940, "pr_number": 1041, "commits_count": 1, "files_changed": 30, "response_length": 5754, "file_count": 31, "needs_breakdown": true}
Add audit events for PaymentCreate update Created from https://github.com/juspay/hyperswitch/issues/4525 This covers adding events for PaymentCreate operation This event should include the payment data similar to https://github.com/juspay/hyperswitch/pull/4166 It should also include any metadata for the event e.g reason for payment rejection, error codes, rejection source etc
<think> PR Context: - Title: feat(payments): Add audit events for PaymentCreate update - Merged: 2024-11-07T13:39:25Z - Files changed: 2 files - Commits: 4 commits Implementation approach: ## Type of Change - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description This PR adds an Audit event for the PaymentCreate operation. ### Additional Changes - [x] This PR modifies the files below - `crates/router/src/core/payments/operations/payment_create.rs` - `crates/router/src/events/audit_events.rs` ## Motivation and Context This PR fixes #4672 ## How did you test it H </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(payments): Add audit events for PaymentCreate update (#6427) Files to modify: **crates/router/src/core/payments/operations/payment_create.rs** Modify existing code **crates/router/src/events/audit_events.rs** Modify existing code
{"issue_number": 4672, "pr_number": 6427, "commits_count": 1, "files_changed": 2, "response_length": 1031, "file_count": 4, "needs_breakdown": false}
[REFACTOR]: [Airwallex] Remove Default Case Handling ### :memo: Feature Description - We utilize match statements to make pivotal decisions, such as generating requests based on the payment method type and managing responses received from the connector. - These conditions generally go hand in hand with enum variants. - Default case is used because a match statement needs to be exhaustive i.e. every variant needs to be covered. - So, if all the explicit cases are handled then default is used to handle the rest. - Each connector have these match statements but many of them don’t provide reference to each variant in their default case, rather a `_` is put to handle all the other cases. - This approach carries a risk because developers may inadvertently overlook the need for explicit handling of the new cases. ### :hammer: Possible Implementation - Instead of relying on a default match case `_`, developers should handle each and every variant explicitly. - By doing so, if there are any changes in the future, they can readily assess the impact of their modifications simply by compiling the code. - You can check this PR for further reference https://github.com/juspay/hyperswitch/pull/1955 :bookmark: Note: All the changes needed should be contained within `hyperswitch/crates/router/src/connector/` ### :package: Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### :package: Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### :sparkles: Are you willing to submit a PR?
<think> PR Context: - Title: refactor(connector): [Airwallex] Remove default case handling - Merged: 2023-10-27T12:12:59Z - Files changed: 1 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> #2262 ### 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 correspond </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(connector): [Airwallex] Remove default case handling (#2703) Files to modify: **crates/router/src/connector/airwallex/transformers.rs** Modify existing code **Commit 2:** refactor(connector): [Airwallex] Remove default case handling (#2703) Files to modify: **crates/router/src/connector/airwallex/transformers.rs** Modify existing code
{"issue_number": 2262, "pr_number": 2703, "commits_count": 2, "files_changed": 1, "response_length": 1148, "file_count": 5, "needs_breakdown": false}
refactor: raise appropriate errors instead of `ValidateError` ## Type of Change Refactoring ## Description <!-- Describe your changes in detail --> To describe briefly, this PR raises appropriate errors instead of `ValidateError` and removes `ValidateError` in favor of `ValidationError`. A better understanding of the changes involved in this PR can be obtained from the commit log. <details> <summary>Commit Log (click to expand):</summary> <ul> <li>fix(connectors): raise <code>ParsingError</code> or <code>ConnectorError</code> during transformations</li> <li>feat(errors): introduce <code>PreconditionFailed</code> variant for <code>ApiErrorResponse</code></li> <li>refactor(stripe errors): minor fixes</li> <li>docs(ApiErrorResponse): document <code>InvalidDataValue</code> and <code>PreconditionFailed</code> variants</li> <li>refactor(payments): raise <code>PreconditionFailed</code> error variant instead of <code>ValidateError</code></li> <li>refactor(ext_traits): raise <code>ValidationError</code> instead of <code>ValidateError</code></li> </ul> </details> ## 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 its an obvious bug or documentation fix that will have little conversation). --> Building on top of #40, this PR incrementally unblocks splitting the `router` crate's API models into a separate crate. ## 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)? --> N/A ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed submitted code <!-- - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable -->
<think> PR Context: - Title: refactor: extract email validation and PII utils to `common_utils` crate - Merged: 2022-12-06T09:49:46Z - Files changed: 12 files - Commits: 9 commits Implementation approach: **NOTE:** Please merge #71 before merging this. --- ## Type of Change <!-- Put an `x` in the boxes that apply --> Refactoring ## Description <!-- Describe your changes in detail --> This PR builds on top of #71 (thus targeting that branch for proper diffs). As stated in the PR title, this change extracts email validations and PII-related utilities to the `common_utils` crate. ## Motivation and Context <!-- Why is this change required? What problem does it solve? If it fixe </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor: extract email validation and PII utils to `common_utils` crate (#72) Files to modify: **crates/common_utils/src/errors.rs** Add: - enum: pub::ValidationError **crates/common_utils/src/lib.rs** Add: - mod: pub::pii - mod: pub::validation **crates/common_utils/src/validation.rs** Add: - function: pub::validate_email - function: private::new_tree - function: private::test_validate_email - struct: private::ValidEmail - impl: impl Strategy for ValidEmail - mod: private::tests **crates/router/src/connector/braintree/transformers.rs** Modify existing code **crates/router/src/core/errors.rs** Remove: - enum: pub::ValidationError **crates/router/src/lib.rs** Remove: - mod: pub::pii Add: - mod: pub::pii **crates/router/src/utils.rs** Modify existing code **crates/router/src/utils/ext_traits.rs** Remove: - function: pub::validate_email - function: private::new_tree - function: private::test_validate_email - struct: private::ValidEmail - impl: impl Strategy for ValidEmail - mod: private::tests
{"issue_number": 71, "pr_number": 72, "commits_count": 1, "files_changed": 12, "response_length": 1911, "file_count": 11, "needs_breakdown": false}
[FEATURE] Implement cache for MerchantKeyStore. ### Feature Description Implement L1 and L2 cache (In memory and Redis) for MerchantKeyStore store for MerchantKeyStore Table ### Possible Implementation There's already a static called `ACCOUNTS_CACHE`. You can use that and call `get_or_populate_in_memory` function to fetch from database if it's not either in redis or in memory cache. Refer https://github.com/juspay/hyperswitch/blob/d21fcc7bfc3bdf672b9cfbc5a234a3f3d03771c8/crates/router/src/db/merchant_account.rs#L99-L108. ### Have you spent some time to check if this feature request has been raised before? - [X] I checked and didn't find similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? None
<think> PR Context: - Title: feat(router): add caching for MerchantKeyStore - Merged: 2023-06-14T10:29:56Z - Files changed: 1 files - Commits: 4 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Implements the use of Moka cache and redis cache for merchant key store, uses same cfg features to apply cache depending on existence and more additions were made to cache.rs and service.rs match patterns while fetching and storing ### Ad </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(router): add caching for MerchantKeyStore (#1409) Files to modify: **crates/router/src/db/merchant_key_store.rs** Modify existing code
{"issue_number": 1381, "pr_number": 1409, "commits_count": 1, "files_changed": 1, "response_length": 922, "file_count": 3, "needs_breakdown": false}
router: Get browser info from payment request ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> Add browser info to PaymentRequest to get it from merchants. ### Additional Changes - [ ] 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 its an obvious bug or documentation fix that will have little conversation). --> Added browser info field to payment request for getting it from merchants. ## 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)? --> ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: feat(themes): Create APIs for managing themes - Merged: 2024-12-04T11:06:34Z - Files changed: 26 files - Commits: 24 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR adds APIs to manage themes. These are the following APIs 1. Create Theme 2. Delete Theme 3. Update Theme 4. Upload Asset 5. Find Theme by Theme ID 6. Find Theme by Lineage ### Additional Changes - [x] This PR modifies the </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(themes): Create APIs for managing themes (#6658) Co-authored-by: hyperswitch-bot[bot] <14852550 Files to modify: **crates/api_models/src/events/user.rs** Modify existing code **crates/api_models/src/user.rs** Add: - mod: pub::theme **crates/api_models/src/user/theme.rs** Add: - struct: pub::GetThemeResponse - struct: pub::UploadFileAssetData - struct: pub::UploadFileRequest - struct: pub::CreateThemeRequest - struct: pub::UpdateThemeRequest - struct: pub::ThemeData - struct: private::Settings - struct: private::Colors - struct: private::Typography - struct: private::Buttons - struct: private::PrimaryButton - struct: private::SecondaryButton - struct: private::Borders - struct: private::Spacing - struct: private::Urls **crates/common_utils/src/types/theme.rs** Add: - function: pub::entity_type - function: pub::tenant_id - function: pub::org_id - function: pub::merchant_id - function: pub::profile_id - impl: impl ThemeLineage **crates/diesel_models/src/query/user/theme.rs** Add: - function: pub::find_by_theme_id **crates/diesel_models/src/user/theme.rs** Add: - function: pub::new - impl: impl ThemeNew **crates/router/src/configs/secrets_transformers.rs** Modify existing code **crates/router/src/configs/settings.rs** Modify existing code **crates/router/src/core/errors/user.rs** Modify existing code **crates/router/src/core/user.rs** Add: - mod: pub::theme **crates/router/src/core/user/theme.rs** Add: - function: pub::get_theme_using_lineage - function: pub::get_theme_using_theme_id - function: pub::upload_file_to_theme_storage - function: pub::create_theme - function: pub::update_theme - function: pub::delete_theme **crates/router/src/db/kafka_store.rs** Add: - function: private::find_theme_by_theme_id **crates/router/src/db/user/theme.rs** Add: - function: private::find_theme_by_theme_id - function: private::find_theme_by_theme_id **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/lock_utils.rs** Modify existing code **crates/router/src/routes/user.rs** Add: - mod: pub::theme **crates/router/src/routes/user/theme.rs** Add: - function: pub::get_theme_using_lineage - function: pub::get_theme_using_theme_id - function: pub::upload_file_to_theme_storage - function: pub::create_theme - function: pub::update_theme - function: pub::delete_theme **crates/router/src/utils/user.rs** Add: - mod: pub::theme **crates/router/src/utils/user/theme.rs** Add: - function: private::get_theme_dir_key - function: pub::get_specific_file_key - function: pub::get_theme_file_key - function: private::path_buf_to_str - function: pub::retrieve_file_from_theme_bucket - function: pub::upload_file_to_theme_bucket - function: pub::validate_lineage - function: private::validate_tenant - function: private::validate_org - function: private::validate_merchant_and_get_key_store - function: private::validate_merchant - function: private::validate_profile **crates/router_env/src/logger/types.rs** Modify existing code
{"issue_number": 27, "pr_number": 6658, "commits_count": 1, "files_changed": 26, "response_length": 4028, "file_count": 22, "needs_breakdown": true}
feat(single_use): add extra fields in `Mandate` table and `MandateData` [Blocked on #61] ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description This PR adds single use mandate support and a 2 new fields to the mandate table (i.e. singe_use_amount, single_use_currency) <!-- Describe your changes in detail --> ### Additional Changes - [x] 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` --> The change includes the following files. - migrations/2022-12-05-090521_single_use_mandate_fields/up.sql - migrations/2022-12-05-090521_single_use_mandate_fields/down.sql ## Motivation and Context Here, the intension is adding a new Validation feature in PaymentsCore, for that reason following are the steps that the change is broken down to. 1. Create new types for the change #45 2. Introduce the Flow and Connector Integration #47 3. Add Stripe POC #50 4. Introduce the new operation and all the related components in the payments core #53 + #61 5. Changing the `MandateData` type 6. Move the mandate related behaviour to domain <!-- 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 its 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)? --> ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: feat(payout): add dynamic fields for payout links - Merged: 2024-09-10T11:31:55Z - Files changed: 24 files - Commits: 22 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description This PR includes below changes - add dynamic fields support for payout widget (#5765) - expose `formLayout` option in payout link config - journey or tabs ### Additional Changes - [x] This PR modifies the API contract - [ ] This PR modifies the database schema - [x] This PR </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(payout): add dynamic fields for payout links (#5764) Co-authored-by: hyperswitch-bot[bot] <1485 Files to modify: **crates/api_models/src/admin.rs** Modify existing code **crates/api_models/src/enums.rs** Modify existing code **crates/api_models/src/payouts.rs** Modify existing code **crates/common_enums/src/enums.rs** Add: - enum: pub::UIWidgetFormLayout **crates/common_utils/src/link_utils.rs** Modify existing code **crates/diesel_models/src/business_profile.rs** Modify existing code **crates/openapi/src/openapi.rs** Modify existing code **crates/openapi/src/openapi_v2.rs** Modify existing code **crates/router/src/configs/defaults.rs** Add: - mod: pub::payout_required_fields **crates/router/src/configs/defaults/payout_required_fields.rs** Add: - function: private::default - function: private::get_connector_payment_method_type_fields - function: private::get_card_fields - function: private::get_bacs_fields - function: private::get_pix_bank_transfer_fields - function: private::get_sepa_fields - function: private::get_paypal_fields - function: private::get_countries_for_connector - function: private::get_billing_details - impl: impl Default for PayoutRequiredFields **crates/router/src/configs/settings.rs** Add: - struct: pub::PayoutRequiredFields **crates/router/src/core/payout_link.rs** Modify existing code **crates/router/src/core/payouts.rs** Modify existing code **crates/router/src/core/payouts/transformers.rs** Add: - function: private::foreign_from - impl: impl ForeignFrom<( &PayoutRequiredFields, Vec<EnabledPaymentMethod>, api::RequiredFieldsOverrideRequest, )> for Vec<api::PayoutEnabledPaymentMethodsInfo> **crates/router/src/types/api/payouts.rs** Modify existing code **crates/router/src/types/transformers.rs** Modify existing code **crates/router/tests/macros.rs** Add: - function: private::test_flat_struct - struct: private::User - struct: private::Address - mod: private::flat_struct_test **crates/router_derive/src/lib.rs** Add: - function: pub::flat_struct_derive
{"issue_number": 66, "pr_number": 5764, "commits_count": 1, "files_changed": 24, "response_length": 2957, "file_count": 20, "needs_breakdown": true}
[REFACTOR] : [Adyen] Error Message For Connector Implementation ### :memo: Feature Description - In terms of errors, we are currently throwing a 'not supported' message, which shouldn't be the case as we are yet to decide on the implementation. ### :hammer: Possible Implementation - In order to manage payment methods that are not implemented by Hyperswitch or yet to be implemented, the connector transformers file should make use of the NotImplemented ConnectorError enum variant. - By doing so, we will throw same error message for all the Connector Implementation - You can check this PR for further reference https://github.com/juspay/hyperswitch/pull/2831 :bookmark: Note: All the changes needed should be contained within `hyperswitch/crates/router/src/connector/` ### :package: Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### :package: Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### :sparkles: Are you willing to submit a PR?
<think> PR Context: - Title: refactor(connector): [Adyen] change error message from not supported to not implemented - Merged: 2024-03-18T07:02:00Z - Files changed: 1 files - Commits: 5 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> ### 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 ch </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(connector): [Adyen] change error message from not supported to not implemented (#2845) Co-a Files to modify: **crates/router/src/connector/adyen/transformers.rs** Modify existing code
{"issue_number": 2838, "pr_number": 2845, "commits_count": 1, "files_changed": 1, "response_length": 1016, "file_count": 3, "needs_breakdown": false}
ci: run tests on PRs with `S-awaiting-merge` label ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> This PR updates the CI workflow to run tests when PRs are labeled `S-awaiting-merge`. This could either be when the PR is opened, reopened, marked ready for review (from a draft PR), assigned a label, or synchronized with the base branch. ## 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 its an obvious bug or documentation fix that will have little conversation). --> We often have people opening WIP PRs which unnecessarily use CI resources with no fruitful results. This change is a hopeful attempt to prevent 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)? --> Haven't tested it, "I hope it works" (TM). :crossed_fingers: ## Checklist <!-- Put an `x` in the boxes that apply --> - [ ] I formatted the code `cargo +nightly fmt` - [ ] I addressed lints thrown by `cargo clippy` - [x] I reviewed submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: ci: allow tests to run on push to `main` branch - Merged: 2022-12-19T08:09:11Z - Files changed: 2 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> This PR fixes a minor mistake in #166 where I forgot to allow tests on the `main` branch. ## 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 </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 166, "pr_number": 167, "commits_count": 0, "files_changed": 2, "response_length": 777, "file_count": 0, "needs_breakdown": false}
refactor(merchant_account): add back `api_key` field for backward compatibility ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> This PR adds back the `api_key` field in the `merchant_account` table temporarily. This change is a temporary one which would be rolled back once all our teams have migrated their applications/services to use the `api_keys` table and endpoints. ### Additional Changes - [x] 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` --> The migrations can be found at [`up.sql`](https://github.com/juspay/hyperswitch/blob/reintroduce-merchant-account-api-key/migrations/2023-03-16-132604_merchant_account_temp_add_api_key/up.sql) and [`down.sql`](https://github.com/juspay/hyperswitch/blob/reintroduce-merchant-account-api-key/migrations/2023-03-16-132604_merchant_account_temp_add_api_key/down.sql). ## 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 its an obvious bug or documentation fix that will have little conversation). --> Backward compatibility. ## 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)? --> Verified that the same API keys are being stored in both the `merchant_account` and `api_keys` tables. ## 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 submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable --- _P.S.: I'd prefer not having to make this change in the first place._
<think> PR Context: - Title: revert: refactor(merchant_account): add back `api_key` field for backward compatibility (#761) - Merged: 2023-05-10T15:34:13Z - Files changed: 9 files - Commits: 3 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR reverts #761 (commit 661dd48ae51493e404bfd50701674da6f0c7e26a). The `api_key` field was added for backwards compatibility and was a temporary change. Now that all our teams have migrated to use the `api_keys` table and endpoints, t </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 761, "pr_number": 1062, "commits_count": 0, "files_changed": 9, "response_length": 824, "file_count": 0, "needs_breakdown": false}
chore: Update apple pay currency filter configs Update apple pay currency filter configs as a temporary fix for failing PR #7921
<think> PR Context: - Title: chore: Update apple pay currency filter configs - Merged: 2025-06-09T07:57:15Z - Files changed: 1 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Apple pay payments for noon were failing due to PR#7921. Adding AED to the currency list for apple pay is a temporary fix for this failure. ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the databa </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 8216, "pr_number": 8217, "commits_count": 0, "files_changed": 1, "response_length": 777, "file_count": 0, "needs_breakdown": false}
fix(connector): [Prophetpay] Use refund_id as reference_id for Refund ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> - Replaced connector_request_reference_id with refund_id for refund. - Removed response_code since we are not receiving it in case of failure - Made tranSeqNumber optional Closes [#3353](https://github.com/juspay/hyperswitch-cloud/issues/3353) ### 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). --> ## 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)? --> - Craete a payment through Prophetpay Card Redirect - If it is successful, go the refund - The refund must be successful <img width="1728" alt="Screenshot 2023-11-23 at 4 16 19 PM" src="https://github.com/juspay/hyperswitch/assets/73734619/e904fff8-04ee-4e43-b398-c2d1c3b39678"> <img width="1728" alt="Screenshot 2023-11-23 at 4 16 25 PM" src="https://github.com/juspay/hyperswitch/assets/73734619/a2cf1607-c034-49ee-b86b-52f719b1ba43"> ## 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 - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: fix(connector): [Prophetpay] Use refund_id as reference_id for Refund - Merged: 2023-11-23T14:08:00Z - Files changed: 1 files - Commits: 2 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Relative PR in main branch [#2966](https://github.com/juspay/hyperswitch/pull/2966) - Replaced connector_request_reference_id with refund_id for refund. - Removed response_code since we are not receiving it in case of failure - Made tranSeq </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(connector): [Prophetpay] Use refund_id as reference_id for Refund (#2962) Files to modify: **crates/router/src/connector/prophetpay/transformers.rs** Modify existing code
{"issue_number": 2966, "pr_number": 2962, "commits_count": 1, "files_changed": 1, "response_length": 980, "file_count": 3, "needs_breakdown": false}
feat: change role apis to support custom roles
<think> PR Context: - Title: feat(authz): Add custom role checks in authorization - Merged: 2024-02-21T13:59:00Z - Files changed: 15 files - Commits: 30 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR will add checks in authorization to check for custom roles. This PR also add custom roles functionality to apis which were dealing with roles. ### Additional Changes - [x] This PR modifies the API contract - [ ] This PR modifie </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(authz): Add custom role checks in authorization (#3719) Co-authored-by: Apoorv Dixit <apoorv.di Files to modify: **crates/api_models/src/user_role.rs** Modify existing code **crates/router/src/analytics.rs** Modify existing code **crates/router/src/core/user.rs** Modify existing code **crates/router/src/core/user_role.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/services/authentication.rs** Modify existing code **crates/router/src/services/authorization.rs** Remove: - mod: pub::predefined_permissions Add: - function: pub::get_permissions - mod: pub::permission_groups - mod: pub::roles **crates/router/src/services/authorization/permission_groups.rs** Add: - function: pub::get_permissions_vec **crates/router/src/services/authorization/permissions.rs** Modify existing code **crates/router/src/services/authorization/roles.rs** Add: - function: pub::get_role_id - function: pub::get_role_name - function: pub::get_permission_groups - function: pub::get_scope - function: pub::is_invitable - function: pub::is_deletable - function: pub::is_internal - function: pub::is_updatable - function: pub::get_permissions_set - function: pub::check_permission_exists - function: pub::get_role_info_from_role_id - function: private::from - struct: pub::RoleInfo - impl: impl RoleInfo - impl: impl From<diesel_models::role::Role> for RoleInfo - mod: pub::predefined_roles **crates/router/src/services/authorization/roles/predefined_roles.rs** Modify existing code **crates/router/src/types/domain/user.rs** Remove: - function: private::try_from - struct: pub::UserAndRoleJoined - impl: impl TryFrom<UserAndRoleJoined> for user_api::UserDetails Add: - function: private::foreign_from - impl: impl ForeignFrom<UserStatus> for user_role_api::UserStatus **crates/router/src/utils/user.rs** Add: - function: pub::get_role_info_from_db **crates/router/src/utils/user_role.rs** Remove: - function: pub::is_internal_role - function: pub::get_role_name_and_permission_response
{"issue_number": 3717, "pr_number": 3719, "commits_count": 1, "files_changed": 15, "response_length": 3041, "file_count": 17, "needs_breakdown": true}
BE Password specification Make password have Minimum number of characters. At least one number, uppercase & lowercase characters and symbol. (This check is there in FE but not in BE).
<think> PR Context: - Title: fix(users): add password validations - Merged: 2024-05-02T14:13:20Z - Files changed: 2 files - Commits: 6 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [X] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Closes #4412 ### 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 c </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(users): add password validations (#4489) Files to modify: **crates/router/src/consts/user.rs** Modify existing code **crates/router/src/types/domain/user.rs** Modify existing code
{"issue_number": 4412, "pr_number": 4489, "commits_count": 1, "files_changed": 2, "response_length": 959, "file_count": 4, "needs_breakdown": false}
[FIX] Add fallback connectors instead of active routing rule connectors if straight through connector is ineligible Add the fallback connectors to the list of eligible connectors instead of adding connectors configured in the active routing rule in case straight through connector is ineligible
<think> PR Context: - Title: revert(routing): Add connectors from current active routing algorithm before adding fallback connectors - Merged: 2025-06-06T07:51:47Z - Files changed: 1 files - Commits: 2 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Add fallback connectors to the list of eligible connectors for routing instead of connectors configured in the active routing rules this PR reverts https://github.com/juspay/hyperswitch/pull/7921 Link for main branch revert PR - https://gith </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** revert(routing): Add connectors from current active routing algorithm before adding fallback connect Files to modify: **crates/router/src/core/payments.rs** Modify existing code
{"issue_number": 8210, "pr_number": 8259, "commits_count": 1, "files_changed": 1, "response_length": 1017, "file_count": 3, "needs_breakdown": false}
feat(single_use): add extra fields in `Mandate` table and `MandateData` [Blocked on #61] ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description This PR adds single use mandate support and a 2 new fields to the mandate table (i.e. singe_use_amount, single_use_currency) <!-- Describe your changes in detail --> ### Additional Changes - [x] 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` --> The change includes the following files. - migrations/2022-12-05-090521_single_use_mandate_fields/up.sql - migrations/2022-12-05-090521_single_use_mandate_fields/down.sql ## Motivation and Context Here, the intension is adding a new Validation feature in PaymentsCore, for that reason following are the steps that the change is broken down to. 1. Create new types for the change #45 2. Introduce the Flow and Connector Integration #47 3. Add Stripe POC #50 4. Introduce the new operation and all the related components in the payments core #53 + #61 5. Changing the `MandateData` type 6. Move the mandate related behaviour to domain <!-- 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 its 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)? --> ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: feat(payout_link): add localisation support for payout link's templates - Merged: 2024-08-12T08:08:33Z - Files changed: 30 files - Commits: 16 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Described in #5559 This uses a forked version of `rust-i18n` which handles string index slicing original - https://github.com/longbridgeapp/rust-i18n forked - https://github.com/kashif-m/rust-i18n/commits/v3.1.1-safe ### Additional Changes - [ ] This PR modifies the API co </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(payout_link): add localisation support for payout link's templates (#5552) Co-authored-by: hype Files to modify: **crates/api_models/src/payouts.rs** Modify existing code **crates/common_utils/src/consts.rs** Modify existing code **crates/hyperswitch_domain_models/src/api.rs** Modify existing code **crates/router/src/compatibility/wrap.rs** Modify existing code **crates/router/src/core/payment_link.rs** Modify existing code **crates/router/src/core/payment_methods.rs** Modify existing code **crates/router/src/core/payout_link.rs** Modify existing code **crates/router/src/core/payouts.rs** Modify existing code **crates/router/src/lib.rs** Add: - mod: pub::locale **crates/router/src/locale.rs** Modify existing code **crates/router/src/routes.rs** Modify existing code **crates/router/src/routes/payout_link.rs** Modify existing code **crates/router/src/routes/payouts.rs** Modify existing code **crates/router/src/services/api.rs** Modify existing code **crates/router/src/services/api/generic_link_response.rs** Add: - mod: pub::context **crates/router/src/services/api/generic_link_response/context.rs** Add: - function: pub::insert_locales_in_context_for_payout_link - function: pub::insert_locales_in_context_for_payout_link_status
{"issue_number": 66, "pr_number": 5552, "commits_count": 1, "files_changed": 30, "response_length": 2119, "file_count": 18, "needs_breakdown": true}
fix(middleware): add support for logging request-id sent in request ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description This adds a log line in the middleware tracking and logging any received request-id in the process. Allow the logs to be linked when multiple services are composed and request id is sent between them <!-- Describe your changes in detail --> ### 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). --> ## 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)? --> ## 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 - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: fix(middleware): add support for logging request-id sent in request (… - Merged: 2024-01-04T10:27:15Z - Files changed: 1 files - Commits: 1 commits Implementation approach: …#3225) ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Extends #3225 <!-- Describe your changes in detail --> ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/environment variables <!-- Provide links to </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(middleware): add support for logging request-id sent in request (… (#3240) Files to modify: **crates/router/src/middleware.rs** Modify existing code
{"issue_number": 3225, "pr_number": 3240, "commits_count": 1, "files_changed": 1, "response_length": 959, "file_count": 3, "needs_breakdown": false}
[FIX]: Take merchant ID from headers in API Key Revoke (v2) For `API Key - Revoke` in v2, the merchant ID is currently being passed in the path. We need to instead read the `X-Merchant-ID` header to get the merchant ID.
<think> PR Context: - Title: fix(router): Take merchant ID from headers in API Key - Revoke (v2) - Merged: 2025-08-05T08:25:19Z - Files changed: 2 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> - Removed merchant ID from path in `API Keys - Revoke` - Changed auth to read merchant ID from headers ### Additional Changes - [x] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies ap </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(router): Take merchant ID from headers in API Key - Revoke (v2) (#8808) Files to modify: **crates/router/src/core/api_keys.rs** Modify existing code **crates/router/src/routes/api_keys.rs** Modify existing code
{"issue_number": 8807, "pr_number": 8808, "commits_count": 1, "files_changed": 2, "response_length": 1021, "file_count": 4, "needs_breakdown": false}
ci(cypress): removal of metadata overwriting during mca update call ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [x] CI/CD ## Description <!-- Describe your changes in detail --> The Connector Update Body is being overwritten, which included the metadata as well. Due to this, if there were any required metadata fields of a connector, then the Connector Update Test would fail. For example, `Braintree` connector has a required metadata field, and while testing the Connector Update, just because it was being overwritten by the `update-connector-body.json` fixture, the test fails as shown in the following screenshot. <img width="2117" alt="image" src="https://github.com/user-attachments/assets/bf8b384a-92be-4f86-bf09-48fd52f01db4" /> ### 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). --> While adding the Card test Flows for the `Braintree` connector, the Connector Update Test Failed. ## 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)? --> Running the `0000-CoreFlows.cy.js` for `Braintree` connector <img width="2116" alt="image" src="https://github.com/user-attachments/assets/7b505791-4da3-4fae-a94c-142dcfc69b53" /> <img width="752" alt="image" src="https://github.com/user-attachments/assets/f9fc5350-4bf9-4b2e-a5da-a62264f5c1b1" /> ## 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
<think> PR Context: - Title: ci(cypress): add Braintree connector configs for cypress test flows - Merged: 2025-04-24T07:23:48Z - Files changed: 3 files - Commits: 30 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [x] CI/CD ## Description <!-- Describe your changes in detail --> Adding Cypress Test Case Flows related Configs for the `Braintree` Payment Processor. ~_Note: The Connector Update Test will fail until https://github.com/juspay/hyperswitch/pull/7622 is not merged to the `main` branch._~ (#7622 is Merged) </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 7622, "pr_number": 7266, "commits_count": 0, "files_changed": 3, "response_length": 798, "file_count": 0, "needs_breakdown": false}
Docs: Adding redirect URL details Documentation didn't have any details about the Redirect URL.
<think> PR Context: - Title: Docs: Adding redirect url details - Merged: 2024-08-22T12:46:04Z - Files changed: 3 files - Commits: 7 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [X] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> ### 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 ch </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** Docs: Adding redirect url details (#5507) Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitc Files to modify: **crates/api_models/src/payments.rs** Modify existing code
{"issue_number": 5506, "pr_number": 5507, "commits_count": 1, "files_changed": 3, "response_length": 946, "file_count": 3, "needs_breakdown": false}
[FEATURE] Add BNPL for Nuvei payment processor Add Buy Now Pay Later support for Nuvei
<think> PR Context: - Title: feat(connector) : add klarna, afterpay support in Nuvei - Merged: 2023-05-09T14:54:13Z - Files changed: 1 files - Commits: 5 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> add payment methods like klarna, afterpay support for Nuvei connector ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/environm </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(connector) : add klarna, afterpay support in Nuvei (#1081) Files to modify: **crates/router/src/connector/nuvei/transformers.rs** Add: - function: private::get_pay_later_info
{"issue_number": 1067, "pr_number": 1081, "commits_count": 1, "files_changed": 1, "response_length": 975, "file_count": 3, "needs_breakdown": false}
ci(workflows): skip CI checks for ignored files ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description This PR allows skipping CI checks for [ignored files](https://github.com/juspay/orca/blob/5593a97c91e347a36b21bf78cf1f91d3ae5a946d/.github/workflows/CI.yml#L20-L30). This adds a workflow file with the same workflow and job names to simply return true for all checks. Even though this feels like a workaround, this is recommended by GitHub on their docs [here](https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/defining-the-mergeability-of-pull-requests/troubleshooting-required-status-checks#handling-skipped-but-required-checks). ### Additional Changes - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/environment variables <!-- Provide links to the files with corresponding changes --> ## 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 its an obvious bug or documentation fix that will have little conversation). --> One of the PRs affected by this behavior is #9, as it's CI checks are stuck on a pending state. ## 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)? --> ## Checklist <!-- Put an `x` in the boxes that apply --> - [ ] I formatted the code `cargo +nightly fmt` - [ ] I addressed lints thrown by `cargo clippy` - [ ] I reviewed submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: ci(CI-skip-ignored-files): specify OS matrix with single entry - Merged: 2022-11-24T08:26:16Z - Files changed: 1 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description This PR fixes a minor derp introduced in #10. Turns out specifying `runs-on: ubuntu-latest` vs. specifying `runs-on: ${{ matrix.os }}` with a single `ubuntu-latest` entry causes GitHub to consider them as different jobs, and thus do not count towards required status checks. ### Additional Changes - [ ] This PR </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 10, "pr_number": 13, "commits_count": 0, "files_changed": 1, "response_length": 792, "file_count": 0, "needs_breakdown": false}
fix(connector): [DummyConnector] add new icons and fix `we_chat_pay` ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Add new icons for 3DS page of dummy connector. Also fix we chat pay wallet. And some UI changes in 3DS page. ### 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 its an obvious bug or documentation fix that will have little conversation). --> To make 3DS page better. ## 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)? --> Postman and Dashboard. ## 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 submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: feat(payouts): extend routing capabilities to payout operation - Merged: 2024-02-26T07:44:15Z - Files changed: 30 files - Commits: 23 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Explained in issue [#1845](https://github.com/juspay/hyperswitch-cloud/issues/1845) ### Additional Changes - [x] This PR modifies the API contract - [x] This PR modifies the database schema - [ ] This PR modifies application configuration/environment variables <!-- Provi </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(payouts): extend routing capabilities to payout operation (#3531) Co-authored-by: Kashif <moham Files to modify: **crates/api_models/src/admin.rs** Remove: - function: private::expecting - function: private::visit_map - function: private::expecting - function: private::visit_some - function: private::visit_none - function: private::visit_unit - function: pub::deserialize - function: pub::deserialize_option - struct: private::RoutingAlgorithmVisitor - struct: private::OptionalRoutingAlgorithmVisitor - enum: pub::PayoutStraightThroughAlgorithm - impl: impl Visitor<'de> for RoutingAlgorithmVisitor - impl: impl Visitor<'de> for OptionalRoutingAlgorithmVisitor - mod: pub::payout_routing_algorithm **crates/api_models/src/enums.rs** Add: - function: private::from - function: private::try_from - impl: impl From<PayoutConnectors> for Connector - impl: impl TryFrom<Connector> for PayoutConnectors **crates/api_models/src/payouts.rs** Modify existing code **crates/api_models/src/routing.rs** Modify existing code **crates/common_enums/src/enums.rs** Add: - enum: pub::TransactionType **crates/diesel_models/src/enums.rs** Modify existing code **crates/diesel_models/src/payout_attempt.rs** Modify existing code **crates/diesel_models/src/query/routing_algorithm.rs** Modify existing code **crates/diesel_models/src/routing_algorithm.rs** Modify existing code **crates/diesel_models/src/schema.rs** Modify existing code **crates/openapi/src/openapi.rs** Modify existing code **crates/router/src/core/admin.rs** Modify existing code **crates/router/src/core/payment_methods/cards.rs** Modify existing code **crates/router/src/core/payments.rs** Modify existing code **crates/router/src/core/payments/routing.rs** Add: - function: pub::make_dsl_input_for_payouts **crates/router/src/core/payouts.rs** Add: - function: private::validate_and_get_business_profile **crates/router/src/core/payouts/helpers.rs** Modify existing code **crates/router/src/core/routing.rs** Add: - enum: pub::TransactionData **crates/router/src/core/routing/helpers.rs** Modify existing code **crates/router/src/core/routing/transformers.rs** Add: - function: private::from - impl: impl From<&routing::TransactionData<'_, F>> for storage_enums::TransactionType **crates/router/src/core/utils.rs** Modify existing code **crates/router/src/db/kafka_store.rs** Add: - function: private::list_routing_algorithm_metadata_by_merchant_id_transaction_type **crates/router/src/db/routing_algorithm.rs** Add: - function: private::list_routing_algorithm_metadata_by_merchant_id_transaction_type - function: private::list_routing_algorithm_metadata_by_merchant_id_transaction_type **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/routing.rs** Modify existing code **crates/router/src/types/api.rs** Remove: - function: private::convert_connector - struct: pub::PayoutConnectorData - struct: pub::PayoutSessionConnectorData - enum: pub::PayoutConnectorChoice - enum: pub::PayoutConnectorCallType - impl: impl PayoutConnectorData Add: - impl: impl ConnectorData **crates/router/src/types/api/admin.rs** Modify existing code **crates/router/src/types/storage.rs** Modify existing code **crates/router/src/types/storage/payout_attempt.rs** Remove: - struct: pub::PayoutRoutingData **crates/router/src/types/transformers.rs** Add: - function: private::foreign_from - impl: impl ForeignFrom<api_models::payouts::PayoutMethodData> for api_enums::PaymentMethodType **crates/router/tests/connectors/adyen.rs** Modify existing code **crates/router/tests/connectors/utils.rs** Modify existing code **crates/router/tests/connectors/wise.rs** Modify existing code
{"issue_number": 1845, "pr_number": 3531, "commits_count": 1, "files_changed": 30, "response_length": 4700, "file_count": 35, "needs_breakdown": true}
[REFACTOR] Worldpay payments integration ### Feature Description WorldPay payments integration currently makes use of modular APIs which gives more control over the integration. This approach is not best compatible with HyperSwitch due to WP's 3DS flows - which requires sending PAN (card numbers) in multiple places. For `on_session` transactions, this would contribute to the added complexity since data is not stored in such transactions (or stored for ~15mins in redis cache). Migrating to WP's standard payments API follows payment resource creation in an uniform way. ### Possible Implementation Migrate from modular APIs [[ref](https://developer.worldpay.com/products/access/card-payments)] to standard payment APIs [[ref](https://developer.worldpay.com/products/access/payments/openapi)]. ### Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? Yes, I am willing to submit a PR!
<think> PR Context: - Title: refactor(connector): [WorldPay] propagate refusal codes as error code and messages - Merged: 2024-10-22T13:03:52Z - Files changed: 3 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Described in #6316 (point # 2) ### 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. Fo </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(connector): [WorldPay] propagate refusal codes as error code and messages (#6392) Files to modify: **crates/router/src/connector/worldpay.rs** Add: - function: private::get_5xx_error_response - function: private::get_5xx_error_response - function: private::get_5xx_error_response - function: private::get_5xx_error_response - function: private::get_5xx_error_response **crates/router/src/connector/worldpay/response.rs** Modify existing code **crates/router/src/connector/worldpay/transformers.rs** Modify existing code
{"issue_number": 6316, "pr_number": 6392, "commits_count": 1, "files_changed": 3, "response_length": 1373, "file_count": 5, "needs_breakdown": false}
refactor(api_keys): remove key ID prefix from plaintext API keys ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> This PR removes the key ID prefix included in the plaintext API keys returned on creating a new API key. The key ID no longer needs to be sent by the user now that #639 makes it easier to identify the API key record in the database table. ## 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 its an obvious bug or documentation fix that will have little conversation). --> This change would also simplify our merchant authentication flow and migration of API keys from the merchant account table to the API keys table. ## 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. Both the `key_id` and the plaintext `api_key` fields now contain the environment prefix for easier identification of the environment with which the keys can be used: ```shell $ curl --location 'http://localhost:8080/api_keys/merchant_123' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: MyVerySecretAdminApiKey' \ --data '{ "name": "API Key 1", "description": null, "expiration": "2023-09-23T01:02:03.000Z" }' { "key_id": "dev_9leW4wj63JYqZ6KFWVT6", "merchant_id": "merchant_123", "name": "API Key 1", "description": null, "api_key": "dev_My64CharLongApiKey", "created": "2023-03-02T10:16:41.606Z", "expiration": "2023-09-23T01:02:03.000Z" } ``` 2. The key prefix returned in the retrieve API key response now returns 12 characters instead of the 8 characters being returned earlier. ```shell $ curl --location 'http://localhost:8080/api_keys/merchant_123/dev_9leW4wj63JYqZ6KFWVT6' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: MyVerySecretAdminApiKey' { "key_id": "dev_9leW4wj63JYqZ6KFWVT6", "merchant_id": "merchant_123", "name": "API Key 1", "description": null, "prefix": "dev_9leW4wj6", "created": "2023-03-02T10:16:41.606Z", "expiration": "2023-09-23T01:02:03.000Z" } ``` ## 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 submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable --- ~Marking as this as draft as this is blocked by #639.~
<think> PR Context: - Title: refactor(authentication): authenticate merchant by API keys from API keys table - Merged: 2023-03-08T09:20:00Z - Files changed: 8 files - Commits: 5 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> This PR updates the API key authentication code to use the API keys from the API keys table instead of the merchant account table. I'll be taking up the deprecation of the `api_key` field from the merchant account table in a separate PR. ## Motivation and Context <!-- Why </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(authentication): authenticate merchant by API keys from API keys table (#712) Files to modify: **crates/router/src/core/api_keys.rs** Remove: - function: pub::verify_hash - struct: pub::PlaintextApiKey Add: - function: private::from - function: private::from - function: private::from - struct: private::PlaintextApiKey - impl: impl From<&str> for PlaintextApiKey - impl: impl From<String> for PlaintextApiKey - impl: impl From<storage::HashedApiKey> for HashedApiKey **crates/router/src/core/errors.rs** Remove: - enum: pub::ApiKeyError **crates/router/src/db/api_keys.rs** Add: - function: private::find_api_key_by_key_id_optional - function: private::find_api_key_by_key_id_optional **crates/router/src/routes/metrics.rs** Modify existing code **crates/router/src/scheduler/metrics.rs** Modify existing code **crates/router/src/services/authentication.rs** Modify existing code **crates/storage_models/src/api_keys.rs** Add: - function: pub::into_inner - impl: impl HashedApiKey **crates/storage_models/src/query/api_keys.rs** Add: - function: pub::find_optional_by_hashed_api_key
{"issue_number": 705, "pr_number": 712, "commits_count": 1, "files_changed": 8, "response_length": 1991, "file_count": 10, "needs_breakdown": false}
[FEATURE] Add support for payout connector integrations for connectors crate ### Feature Description To be able to support connector integrations in router and the new hyperswitch_connectors crate. ### Possible Implementation Move payout API traits to a common place - in hyperswitch_interfaces crate. ### Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? Yes, I am willing to submit a PR!
<think> PR Context: - Title: refactor: move Payout traits to hyperswitch_interfaces for connectors crate - Merged: 2024-11-12T11:24:53Z - Files changed: 7 files - Commits: 10 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Described in #6508 ### 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 </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor: move Payout traits to hyperswitch_interfaces for connectors crate (#6481) Co-authored-by: Files to modify: **crates/hyperswitch_connectors/src/default_implementations.rs** Modify existing code **crates/hyperswitch_interfaces/src/api.rs** Add: - trait: pub::Payouts **crates/hyperswitch_interfaces/src/api/payouts.rs** Add: - trait: pub::Payouts **crates/hyperswitch_interfaces/src/api/payouts_v2.rs** Add: - trait: pub::PayoutsV2 - trait: pub::PayoutsV2 **crates/router/src/core/payments/flows.rs** Remove: - impl: impl api::Payouts for $connector - impl: impl api::Payouts for connector::DummyConnector<T> Add: - impl: impl Payouts for $connector - impl: impl Payouts for connector::DummyConnector<T> **crates/router/src/types/api.rs** Remove: - trait: pub::Payouts - trait: pub::Payouts - trait: pub::PayoutsV2 **crates/router/src/types/api/payouts.rs** Modify existing code
{"issue_number": 6508, "pr_number": 6481, "commits_count": 1, "files_changed": 7, "response_length": 1764, "file_count": 9, "needs_breakdown": false}
refactor: Separate out totp completion from verify Currently,`verify_totp` is the terminating 2fa API and also it was setting the TOTP status as "SET". So , we want to separate the logic of terminating the 2FA to a separate API so that the job of the `verify_totp` API will only be to verify if the totp is valid or not which will also help in reusing it inside dashboard.
<think> PR Context: - Title: feat(users): Create terminate 2fa API - Merged: 2024-05-23T12:15:58Z - Files changed: 10 files - Commits: 8 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [X] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Currently completion of 2fa and setting the status of the 2fa status as "SET" is handled by `verify_totp` API. We want to remove this from `verify_totp`, so this PR creates a new API to terminate the 2fa flow. ### Additional Changes - [X] This PR modifies the API contract - [ </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(users): Create terminate 2fa API (#4731) Files to modify: **crates/api_models/src/user.rs** Add: - struct: pub::SkipTwoFactorAuthQueryParam **crates/router/src/consts/user.rs** Modify existing code **crates/router/src/core/errors/user.rs** Modify existing code **crates/router/src/core/user.rs** Add: - function: pub::terminate_two_factor_auth **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/lock_utils.rs** Modify existing code **crates/router/src/routes/user.rs** Add: - function: pub::terminate_two_factor_auth **crates/router/src/types/domain/user.rs** Add: - function: pub::get_recovery_codes **crates/router/src/utils/user/two_factor_auth.rs** Add: - function: pub::check_recovery_code_in_redis **crates/router_env/src/logger/types.rs** Modify existing code
{"issue_number": 4730, "pr_number": 4731, "commits_count": 1, "files_changed": 10, "response_length": 1626, "file_count": 12, "needs_breakdown": false}
docs: API-ref revamp for better user experience API-ref revamp for better user experience
<think> PR Context: - Title: docs: changes for api ref - Merged: 2025-02-25T19:02:34Z - Files changed: 4 files - Commits: 8 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [X] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> We have changes the Intro page of the API-ref to make it more informative and navigable. Also, The API sidebar is now re-organised basis of different use-cases to improve the dev experience. Added an introduction page to payments API expla </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 7323, "pr_number": 7324, "commits_count": 0, "files_changed": 4, "response_length": 755, "file_count": 0, "needs_breakdown": false}
Fix(CI): Update api-reference path in `pr_labeler` PR #8333 modified the `api-reference` folder structure. Need to update it in `pr_labeler` job
<think> PR Context: - Title: fix(ci): Update api-reference path in pr_labeler job - Merged: 2025-06-16T11:54:06Z - Files changed: 2 files - Commits: 2 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [x] CI/CD ## Description <!-- Describe your changes in detail --> - Updated OpenAPI spec path in `pr_labeler` CI job - Modified `CODEOWNERS` file to remove deleted folder ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 8343, "pr_number": 8344, "commits_count": 0, "files_changed": 2, "response_length": 782, "file_count": 0, "needs_breakdown": false}
feat(router): adding metrics for tracking behavior throughout the `router` crate ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description This PR focuses on adding metrics to the `router` crate. > review-note: consider going through the `metrics.rs` file before reviewing the rest of the PR, while will provide more context while reviewing the rest of the code <!-- Describe your changes in detail --> ### Additional Changes - [ ] 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 its 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)? --> ## 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 submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: release: Update CHANGELOG for release v0.5.1 - Merged: 2023-03-24T06:55:06Z - Files changed: 1 files - Commits: 3 commits Implementation approach: # 0.5.1 (2023-03-21) ## Documentation Changes * **try_local_system:** * add Ubuntu on WSL2 setup instructions (#767) (1d2166cf) * add API key creation step (#765) (4b268068) ## New Features * **pm_list:** handle client secret check (#759) (82344fc4) * add in-memory cache support for config table (#751) (abedaae4) * compile time optimization (#775) (5b5557b7) * **router:** * add support for stateful straight through routing (#752) (568bf01a) * adding metrics for </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 768, "pr_number": 796, "commits_count": 0, "files_changed": 1, "response_length": 774, "file_count": 3, "needs_breakdown": false}
[DOCS] Update Rustman documentation The current documentation misses some key points that WILL result in people not being able to run the collections and ask for help. We would want to update it so that it look cleaner with `Notes` that are highlighted thereby making it more readable and clearer.
<think> PR Context: - Title: docs(postman): update rustman and collection generation docs - Merged: 2024-02-13T07:33:55Z - Files changed: 2 files - Commits: 3 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [x] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR updates the `Rustman` documentation easing the collection development process along with the things to look for before running the collection. Closes #3616 ### Additional Changes - [ ] This PR modifies the API contract - [ </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 3616, "pr_number": 3615, "commits_count": 0, "files_changed": 2, "response_length": 790, "file_count": 0, "needs_breakdown": false}
Todo redis interface ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Enhancement ## Description This PR is a part of greater refactoring which aims on removing `// TODO: ...` & `// FIXME: ..` from the entire codebase. The objective of this PR is to fix `xgroup_create` by adding a guard or some specific `RedisEntryId` while also adding unit tests for the same. It also adds crate documentation for the `redis_interface` crate <!-- Describe your changes in detail --> ### Additional Changes - [ ] 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 The codebase wide initiative in fixing existing problems, `TODO:`s and `FIXME:`s while also adding documentations. <!-- 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 its an obvious bug or documentation fix that will have little conversation). --> ## How did you test it? unit-tests included <!-- Did you write an integration/unit/API test to verify the code changes? Or did you test this change manually (provide relevant screenshots)? --> ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed submitted code - [x] I added unit tests for my changes where possible
<think> PR Context: - Title: fix: todos and fixmes resolution for api_models - Merged: 2022-12-14T12:19:48Z - Files changed: 17 files - Commits: 6 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Enhancement ## Description This PR targets on removing `// TODO: ..` & `// FIXME: ..` specifically from the `api_models` This PR is part of the chain of micro PR's focused on removing todo 1. #136 2. #139 <!-- Describe your changes in detail --> ### Additional Changes - [x] This PR modifies the database schema - [ ] This PR modifies application configuration/environment variables <!-- Provide links to </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix: todos and fixmes resolution for api_models (#144) Files to modify: **crates/api_models/src/admin.rs** Modify existing code **crates/api_models/src/payment_methods.rs** Add: - enum: pub::PaymentExperience **crates/api_models/src/payments.rs** Modify existing code **crates/api_models/src/refunds.rs** Add: - enum: pub::RefundType **crates/masking/src/abs.rs** Modify existing code **crates/router/src/core/payment_methods/cards.rs** Modify existing code **crates/router/src/core/payment_methods/transformers.rs** Modify existing code **crates/router/src/core/payments/operations/payment_response.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Modify existing code **crates/router/src/core/refunds.rs** Modify existing code **crates/router/src/db/payment_attempt.rs** Modify existing code **crates/router/src/types/transformers.rs** Add: - function: private::from - impl: impl From<F<api_models::refunds::RefundType>> for F<storage_enums::RefundType> **crates/storage_models/src/payment_attempt.rs** Modify existing code **crates/storage_models/src/schema.rs** Modify existing code
{"issue_number": 136, "pr_number": 144, "commits_count": 1, "files_changed": 17, "response_length": 1955, "file_count": 16, "needs_breakdown": true}
chore(codeowners): add codeowners data for PR reviews ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description Adding a CODEOWNERS file for facilitating PR reviews for teams ### Additional Changes - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/environment variables <!-- Provide links to the files with corresponding changes --> ## 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 its an obvious bug or documentation fix that will have little conversation). --> This leads to better ownership boundaries & increased efficiency for reviewers ## 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)? --> Doesn't need to be tested ## Checklist <!-- Put an `x` in the boxes that apply --> - [x] I formatted the code `cargo +nightly fmt` - [x] I addressed lints thrown by `cargo clippy` - [x] I reviewed submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: feat(payments): [Payment links] Add config for changing button text for payment links - Merged: 2024-12-19T13:28:25Z - Files changed: 11 files - Commits: 2 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [X] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Added config for changing text of confirm button for payment links ### 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 fil </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(payments): [Payment links] Add config for changing button text for payment links (#6860) Co-aut Files to modify: **crates/api_models/src/admin.rs** Modify existing code **crates/api_models/src/payments.rs** Modify existing code **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/router/src/core/payment_link.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Modify existing code **crates/router/src/types/transformers.rs** Modify existing code
{"issue_number": 1, "pr_number": 6860, "commits_count": 1, "files_changed": 11, "response_length": 1485, "file_count": 10, "needs_breakdown": false}
update refunds filters and list Include filter for amount and merchant connector id in refunds list.
<think> PR Context: - Title: feat(refunds): update refunds filters - Merged: 2024-05-13T13:31:58Z - Files changed: 14 files - Commits: 12 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description The PR: - Adds support for new `filter_v2` api to get list of available filters for refunds quickly: connector with their corresponding label with merchant_connector_ids, currency and refund status. This api is quicker than previous one and gives static and dynamic filter. In this li </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(refunds): update refunds filters (#4409) Co-authored-by: hyperswitch-bot[bot] <148525504+hypers Files to modify: **crates/api_models/src/admin.rs** Modify existing code **crates/api_models/src/events/refund.rs** Add: - function: private::get_api_event_type - impl: impl ApiEventMetric for RefundListFilters **crates/api_models/src/payments.rs** Modify existing code **crates/api_models/src/refunds.rs** Add: - struct: pub::RefundListFilters **crates/common_enums/src/enums.rs** Modify existing code **crates/openapi/src/openapi.rs** Modify existing code **crates/router/src/core/refunds.rs** Add: - function: pub::get_filters_for_refunds **crates/router/src/db/refund.rs** Modify existing code **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/lock_utils.rs** Modify existing code **crates/router/src/routes/refunds.rs** Add: - function: pub::get_refunds_filters **crates/router/src/types/storage/refund.rs** Modify existing code **crates/router_env/src/logger/types.rs** Modify existing code
{"issue_number": 4408, "pr_number": 4409, "commits_count": 1, "files_changed": 14, "response_length": 1863, "file_count": 15, "needs_breakdown": false}
refactor: move config defaults from TOML files to `Default` trait ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> This PR moves default values for `router` and `drainer` binaries' configuration from the `defaults.toml` files to the implementation of the `Default` trait. Since we add a `#[serde(default)]` to the `Settings` struct, it will use the `Default` trait implementation to provide the default values. ## 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 its an obvious bug or documentation fix that will have little conversation). --> This should help catch errors in the default configuration values during compilation, and help reduce binary size. ## 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)? --> Ran the `router` and `drainer` binaries, verified that they both work with the current defaults provided. ## 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 submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: chore(errors): cleanup unused `ApplicationError` variants - Merged: 2023-01-12T11:06:31Z - Files changed: 2 files - Commits: 3 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> This PR removes some variants of the `ApplicationError` enum that are no longer used. Found that there were quite a lot of unused variants when working on #352. ## Motivation and Context <!-- Why is this change required? What problem does it solve? If it fixes an open is </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** chore(errors): cleanup unused `ApplicationError` variants (#356) Files to modify: **crates/router/src/core/errors.rs** Modify existing code **crates/router/src/types/api.rs** Modify existing code
{"issue_number": 352, "pr_number": 356, "commits_count": 1, "files_changed": 2, "response_length": 992, "file_count": 4, "needs_breakdown": false}
feat(pm_list): add pm list support for bank_debits ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] New feature ## Description <!-- Describe your changes in detail --> This PR was not merged to main in #927 because of github not automatically changing the base branch when parent branch is merged to main. ### Additional Changes - [x] This PR modifies the API contract Adds support for bank debits in the payment list, can be checked in #927 <!-- 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 its 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)? --> ```json { "payment_method": "bank_debit", "payment_method_types": [ { "payment_method_type": "ach", "payment_experience": null, "card_networks": null, "bank_names": null, "bank_debits": { "eligible_connectors": [ "stripe" ] } } ] } ``` ## 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 submitted code
<think> PR Context: - Title: hotfix(router): add webhooks and sessions hotfixes - Merged: 2023-05-11T16:10:50Z - Files changed: 16 files - Commits: 3 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> #1120 #1126 #1128 ### 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 file </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** hotfix(router): add webhooks and sessions hotfixes (#1134) Files to modify: **crates/api_models/src/payment_methods.rs** Add: - struct: pub::BankDebitTypes **crates/router/src/connector/checkout.rs** Modify existing code **crates/router/src/connector/checkout/transformers.rs** Remove: - struct: pub::CheckoutWebhookBody Add: - struct: pub::CheckoutWebhookBody **crates/router/src/core/payment_methods/cards.rs** Modify existing code **crates/router/src/core/payments.rs** Modify existing code **crates/router/src/core/payments/helpers.rs** Add: - function: pub::filter_mca_based_on_business_details **crates/router/src/core/payments/operations.rs** Modify existing code **crates/router/src/core/payments/operations/payment_complete_authorize.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/operations/payment_method_validate.rs** Modify existing code **crates/router/src/core/payments/operations/payment_session.rs** Modify existing code **crates/router/src/core/payments/operations/payment_start.rs** Modify existing code **crates/router/src/core/payments/operations/payment_status.rs** Modify existing code **crates/router/src/core/payments/operations/payment_update.rs** Modify existing code **crates/router/src/types/api.rs** Modify existing code
{"issue_number": 1120, "pr_number": 1134, "commits_count": 1, "files_changed": 16, "response_length": 2287, "file_count": 18, "needs_breakdown": true}
enhance(stripe): send statement descriptor to stripe ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Enhancement ## Description <!-- Describe your changes in detail --> - Pass statement descriptor field to stripe. - Replace Juspay with hyperswitch in docs ## 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 its 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 with both `statement_descriptor` and `statement_descriptor_suffix` and check the same in stripe dashboard. ![Screenshot 2023-03-03 at 12 15 28 PM](https://user-images.githubusercontent.com/48803246/222650470-61acda78-81ad-474d-a6f6-aa596d6352d2.png) ## 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 submitted code
<think> PR Context: - Title: refactor: rename statement descriptor to statement descriptor name - Merged: 2023-03-04T06:10:19Z - Files changed: 7 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Refactoring ## Description <!-- Describe your changes in detail --> Renaming the field in `PaymentsRequest` and `PaymentsResponse` back to statement_descriptor_name. ## 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 imp </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor: rename statement descriptor to statement descriptor name (#711) Files to modify: **crates/api_models/src/payments.rs** Modify existing code **crates/router/src/compatibility/stripe/payment_intents/types.rs** Modify existing code **crates/router/src/compatibility/stripe/setup_intents/types.rs** Modify existing code **crates/router/src/core/payments/operations/payment_create.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
{"issue_number": 707, "pr_number": 711, "commits_count": 1, "files_changed": 7, "response_length": 1420, "file_count": 9, "needs_breakdown": false}
`nmi` tests shows different error messages for the same request Postman Tests for nmi behaves like the following while running `Flow Testcases/Variation Cases/Scenario9-Create a mandate payment` ## Creating a mandate payment for `nmi` ```curl curl --location '{{baseUrl}}/payments' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: {{apiKey}}' \ --data-raw '{ "amount": 47074, "currency": "USD", "confirm": true, "capture_method": "automatic", "capture_on": "2022-09-10T10:11:12Z", "amount_to_capture": 47074, "customer_id": "StripeCustomer", "email": "[email protected]", "name": "John Doe", "phone": "999999999", "phone_country_code": "+65", "description": "Its my first payment request", "authentication_type": "no_three_ds", "return_url": "https://duck.com", "payment_method": "card", "payment_method_data": { "card": { "card_number": "4111111111111111", "card_exp_month": "10", "card_exp_year": "69", "card_holder_name": "joseph Doe", "card_cvc": "123" } }, "setup_future_usage": "off_session", "mandate_data": { "customer_acceptance": { "acceptance_type": "offline", "accepted_at": "1963-05-03T04:07:52.723Z", "online": { "ip_address": "127.0.0.1", "user_agent": "amet irure esse" } }, "mandate_type": { "single_use": { "amount": 7000, "currency": "USD" } } }, "customer_acceptance": { "acceptance_type": "online", "accepted_at": "2022-09-10T10:11:12Z", "online": { "ip_address": "123.32.25.123", "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36" } }, "billing": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "John" } }, "shipping": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "John" } }, "statement_descriptor_name": "joseph", "statement_descriptor_suffix": "JS", "metadata": { "udf1": "value1", "new_customer": "true", "login_date": "2019-09-10T10:11:12Z" } }' ``` ### Integ Response ```json { "error": { "type": "invalid_request", "message": "Payment method type not supported", "code": "IR_19", "reason": "credit mandate payment is not supported by nmi" } } ``` ### SBX Response ```json { "error": { "type": "invalid_request", "message": "Payment method type not supported", "code": "IR_19", "reason": "debit mandate payment is not supported by nmi" } } ``` It shows different error messages for two environments.
<think> PR Context: - Title: ci(postman): update assertion error message for nmi collection - Merged: 2025-04-17T07:51:28Z - Files changed: 2 files - Commits: 10 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [x] CI/CD ## Description <!-- Describe your changes in detail --> Postman Tests for `nmi` were failing on SBX (but not on Integ) because `Flow Testcases/Variation Cases/Scenario9-Create a mandate payment` responded an error message as `debit mandate payment is not supported by nmi` on SBX and `credit mandate </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 7764, "pr_number": 7765, "commits_count": 0, "files_changed": 2, "response_length": 793, "file_count": 0, "needs_breakdown": false}
Feat: Ability to accept 3 values in ConnectorAuthType Currently we support max 2 values from keys.conf / db ```rust pub enum ConnectorAuthType { HeaderKey { api_key: String }, BodyKey { api_key: String, key1: String }, } ``` I'm trying to integrate Cybersource, it requires [`http signatures`](https://developer.cybersource.com/docs/cybs/en-us/payments/developer/all/rest/payments/GenerateHeader/httpSignatureAuthentication.html#id193AL0O0BY4_id199IL0O0AY4). I will need 3 values * Merchant Id * Api Key * Api Secret With these I'm able to generate the http signature headers, like ``` digest: "SHA-256=cwjLNSMNo0IFp7hbUtTNu+7KxaF9O67ydqKWMnQ7J5g=" signature: 'keyid="5476633e-eff2-4e65-9834-58081207dd61", algorithm="HmacSHA256", headers="host (request-target) digest v-c-merchant-id", signature="djnWLdaLRh8xtWLCXxGIlavyRG4jBvB7gIzUWTKzPoQ="' ``` So I'm proposing ```rust pub enum ConnectorAuthType { HeaderKey { api_key: String }, BodyKey { api_key: String, key1: String }, SignatureKey { api_key: String, key1: String, api_secret: String }, } ``` @SanchithHegde @Narayanbhat166 @jarnura I can add the PR for it. referring #58
<think> PR Context: - Title: feat(router): add support for Signature Key ConnectorAuthType - Merged: 2022-12-08T09:11:28Z - Files changed: 1 files - Commits: 2 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description This will allow us to accept 3 keys for a connector. Generally Public key, Private key and the merchant id. <!-- Describe your changes in detail --> ### Additional Changes - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/environment variables <!-- Provide li </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(router): add support for Signature Key ConnectorAuthType (#85) Co-authored-by: Arun Raj M <jarn Files to modify: **crates/router/src/types.rs** Modify existing code
{"issue_number": 69, "pr_number": 85, "commits_count": 1, "files_changed": 1, "response_length": 967, "file_count": 3, "needs_breakdown": false}
[BUG] Various errors in `rust_locker_open_api_spec.yml` ### Bug Description The two identical files [`api-reference/rust_locker_open_api_spec.yml`](https://github.com/juspay/hyperswitch/blob/d06d19fc96e1a74d20e2fe3613f86d541947e0ae/api-reference/rust_locker_open_api_spec.yml) and [`api-reference-v2/rust_locker_open_api_spec.yml`](https://github.com/juspay/hyperswitch/blob/d06d19fc96e1a74d20e2fe3613f86d541947e0ae/api-reference-v2/rust_locker_open_api_spec.yml) contain some mistakes and errors. ### Expected Behavior The documentation should be clear. ### Actual Behavior The documentation contains some errors. ### Steps To Reproduce Not relevant. ### Context For The Bug Some examples: https://github.com/juspay/hyperswitch/blob/d06d19fc96e1a74d20e2fe3613f86d541947e0ae/api-reference/rust_locker_open_api_spec.yml#L5 https://github.com/juspay/hyperswitch/blob/d06d19fc96e1a74d20e2fe3613f86d541947e0ae/api-reference/rust_locker_open_api_spec.yml#L12 https://github.com/juspay/hyperswitch/blob/d06d19fc96e1a74d20e2fe3613f86d541947e0ae/api-reference/rust_locker_open_api_spec.yml#L14 https://github.com/juspay/hyperswitch/blob/d06d19fc96e1a74d20e2fe3613f86d541947e0ae/api-reference/rust_locker_open_api_spec.yml#L42 ### Environment Not relevant. ### Have you spent some time checking if this bug has been raised before? - [X] I checked and didn't find a similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? Yes, I am willing to submit a PR!
<think> PR Context: - Title: docs(openapi): improve `rust_locker_open_api_spec` - Merged: 2024-10-24T13:31:41Z - Files changed: 2 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [x] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Improved wording in the edit files. ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/environment variables <!-- Provide lin </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 6321, "pr_number": 6322, "commits_count": 0, "files_changed": 2, "response_length": 780, "file_count": 0, "needs_breakdown": false}
[REFACTOR] Worldpay payments integration ### Feature Description WorldPay payments integration currently makes use of modular APIs which gives more control over the integration. This approach is not best compatible with HyperSwitch due to WP's 3DS flows - which requires sending PAN (card numbers) in multiple places. For `on_session` transactions, this would contribute to the added complexity since data is not stored in such transactions (or stored for ~15mins in redis cache). Migrating to WP's standard payments API follows payment resource creation in an uniform way. ### Possible Implementation Migrate from modular APIs [[ref](https://developer.worldpay.com/products/access/card-payments)] to standard payment APIs [[ref](https://developer.worldpay.com/products/access/payments/openapi)]. ### Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? Yes, I am willing to submit a PR!
<think> PR Context: - Title: refactor(connector): [WorldPay] migrate from modular to standard payment APIs - Merged: 2024-10-21T10:24:32Z - Files changed: 12 files - Commits: 30 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Described in #6316 ### 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 a </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(connector): [WorldPay] migrate from modular to standard payment APIs (#6317) Co-authored-by Files to modify: **crates/router/src/connector/utils.rs** Add: - function: private::get_capture_method **crates/router/src/connector/worldpay.rs** Modify existing code **crates/router/src/connector/worldpay/requests.rs** Remove: - struct: pub::WorldpayPaymentsRequest - struct: pub::Instruction - struct: pub::RequestAutoSettlement - struct: pub::CardToken - struct: pub::WalletPayment - struct: pub::ExpiryDate - enum: pub::PaymentInstrument - enum: pub::PaymentType Add: - struct: pub::WorldpayPaymentsRequest - struct: pub::Merchant - struct: pub::Instruction - struct: pub::CardPayment - struct: pub::CardToken - struct: pub::WalletPayment - struct: pub::ExpiryDate - struct: pub::AutoSettlement - enum: pub::PaymentInstrument - enum: pub::PaymentType **crates/router/src/connector/worldpay/response.rs** Remove: - function: private::try_from - function: private::foreign_try_from - enum: pub::RefundOutcome - impl: impl ForeignTryFrom<Option<PaymentLinks>> for types::ResponseId Add: - struct: pub::AuthorizedResponse - struct: pub::FraudHighRiskResponse - struct: pub::RefusedResponse - struct: pub::ThreeDsResponse - struct: pub::DDCResponse - struct: pub::DDCToken - struct: pub::DDCActionLink - struct: pub::SelfLinkInner - struct: pub::ActionLinks - struct: pub::ActionLink - struct: pub::Fraud - enum: pub::WorldpayPaymentResponseFields - enum: pub::IssuerResponse - enum: pub::FraudOutcome **crates/router/src/connector/worldpay/transformers.rs** Add: - function: private::try_from - struct: pub::WorldpayConnectorMetadataObject - impl: impl TryFrom<&Option<pii::SecretSerdeValue>> for WorldpayConnectorMetadataObject **crates/router/src/consts.rs** Modify existing code **crates/router/src/lib.rs** Modify existing code
{"issue_number": 6316, "pr_number": 6317, "commits_count": 1, "files_changed": 12, "response_length": 2831, "file_count": 9, "needs_breakdown": false}
fix: merchant order ref id filter and refund_id filter - Add merchant_order reference id filter for payments list - Fix refunds list filter, search by refund id. (It is construction a totally new filter ignoring the merchant id when searching)
<think> PR Context: - Title: feat(payments): add merchant order ref id filter - Merged: 2024-11-25T14:06:30Z - Files changed: 5 files - Commits: 2 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description The PR - Add merchant order reference id filter for payments list - Fix bug for search by refund id (or payment_id), using `or` instead of `or_filter`. Earlier we were searching in whole list, ignoring the filter previously applied in the query. However this was the only case for w </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(payments): add merchant order ref id filter (#6630) Files to modify: **crates/api_models/src/payments.rs** Modify existing code **crates/hyperswitch_domain_models/src/payments/payment_intent.rs** Modify existing code **crates/router/src/types/storage/dispute.rs** Modify existing code **crates/router/src/types/storage/refund.rs** Modify existing code **crates/storage_impl/src/payments/payment_intent.rs** Modify existing code
{"issue_number": 6629, "pr_number": 6630, "commits_count": 1, "files_changed": 5, "response_length": 1229, "file_count": 7, "needs_breakdown": false}
feat(users): handle email URLs for users in different tenancies We will be sending emails to users in different tenancies, on clicking the email they should land on that particular tenant URL. For that we need tenant level user configs. And 'll be using it to generate emails.
<think> PR Context: - Title: feat(users): handle email url for users in different tenancies - Merged: 2024-12-19T08:50:07Z - Files changed: 12 files - Commits: 9 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description - Add support for user in tenants configs. - Handle email URLs for different tenancies ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/environment variables <!-- P </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(users): handle email url for users in different tenancies (#6809) Files to modify: **crates/external_services/src/email.rs** Modify existing code **crates/router/src/configs/settings.rs** Add: - struct: pub::TenantUserConfig **crates/router/src/core/recon.rs** Modify existing code **crates/router/src/core/user.rs** Modify existing code **crates/router/src/core/user/dashboard_metadata.rs** Modify existing code **crates/router/src/services/email/types.rs** Add: - function: pub::get_base_url **crates/router/src/workflows/api_key_expiry.rs** Modify existing code
{"issue_number": 6808, "pr_number": 6809, "commits_count": 1, "files_changed": 12, "response_length": 1395, "file_count": 9, "needs_breakdown": false}
refactor: Home and Sign out API changes for 2FA Phase - II As we are having the reset TOTP and regenerate recovery codes flows in the Phase - II, we need to let FE know whether the user has completed the 2FA or not and also number of recovery codes left for the user, so that FE can show a warning if there are less. And also redis needs to be cleaned up if user signs out.
<think> PR Context: - Title: refactor(users): Changes for Home and Signout APIs for TOTP Redis flows - Merged: 2024-06-03T14:25:35Z - Files changed: 3 files - Commits: 5 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> After this PR, Home API will send the details about the user's 2FA, specifically weather user has completed 2FA setup and number of recovery codes left for him. ### Additional Changes - [x] This PR modifies the API contract - [ ] This P </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(users): Changes for Home and Signout APIs for TOTP Redis flows (#4851) Co-authored-by: hype Files to modify: **crates/api_models/src/user.rs** Modify existing code **crates/router/src/core/user.rs** Modify existing code **crates/router/src/utils/user/two_factor_auth.rs** Add: - function: pub::delete_totp_from_redis - function: pub::delete_recovery_code_from_redis
{"issue_number": 4848, "pr_number": 4851, "commits_count": 1, "files_changed": 3, "response_length": 1196, "file_count": 5, "needs_breakdown": false}
fix(connector): [noon] address next_action_url being null for cards in 3ds payment ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> ORIGINAL PR: https://github.com/juspay/hyperswitch/pull/7862 Fix Noon redirection. ### 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). --> ## Clippy <img width="1153" alt="Screenshot 2025-04-21 at 9 35 14 PM" src="https://github.com/user-attachments/assets/379bf7b3-a53c-4063-a195-33388981a40a" /> ## How did you test it? 1. create payments for cards ``` curl --location 'http://localhost:8080/payments' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: _' \ --data-raw '{ "amount": 390, "currency": "AED", "confirm": true, "capture_method": "automatic", "customer_id": "sammantest2722", "capture_on": "2022-09-10T10:11:12Z", "authentication_type": "three_ds", "return_url": "https://google.com", "email": "[email protected]", "name": "Joseph Doe", "phone": "999999999", "phone_country_code": "+65", "description": "Its my first payment", "statement_descriptor_name": "Juspay", "statement_descriptor_suffix": "Router", "payment_method": "card", "payment_method_type": "credit", "payment_method_data": { "card": { "card_number": "4000000000002701", "card_exp_month": "01", "card_exp_year": "2035", "card_holder_name": "joseph Doe", "card_cvc": "100" } }, "billing": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "AE", "first_name": "joseph", "last_name": "Doe" }, "phone": { "number": "8056594427", "country_code": "+91" } }, "browser_info": { "user_agent": "Mozilla\/5.0 (iPhone 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" }, "connector_metadata": { "noon": { "order_category": "pay" } }, "order_details": [ { "product_name": "Apple iphone 15", "quantity": 1, "amount": 390, "account_name": "transaction_processing" } ] }' ``` Response ``` { "payment_id": "pay_WEMpRS2dSPqvSDwcK7GI", "merchant_id": "postman_merchant_GHAction_d454dc3a-a050-4353-81f2-4137042d2fa5", "status": "requires_customer_action", "amount": 390, "net_amount": 390, "shipping_cost": null, "amount_capturable": 390, "amount_received": null, "connector": "noon", "client_secret": "pay_WEMpRS2dSPqvSDwcK7GI_secret_tfiuX7BUmEEiD5cXnYSj", "created": "2025-04-21T15:52:49.398Z", "currency": "AED", "customer_id": "sammantest2722", "customer": { "id": "sammantest2722", "name": "Joseph Doe", "email": "[email protected]", "phone": "999999999", "phone_country_code": "+65" }, "description": "Its my first payment", "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": "2701", "card_type": "CREDIT", "card_network": "Visa", "card_issuer": "INTL HDQTRS-CENTER OWNED", "card_issuing_country": "UNITEDSTATES", "card_isin": "400000", "card_extended_bin": null, "card_exp_month": "01", "card_exp_year": "2035", "card_holder_name": "joseph Doe", "payment_checks": null, "authentication_data": null }, "billing": null }, "payment_token": null, "shipping": null, "billing": { "address": { "city": "San Fransico", "country": "AE", "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "zip": "94122", "state": "California", "first_name": "joseph", "last_name": "Doe" }, "phone": { "number": "8056594427", "country_code": "+91" }, "email": null }, "order_details": [ { "brand": null, "amount": 390, "category": null, "quantity": 1, "tax_rate": null, "product_id": null, "product_name": "Apple iphone 15", "product_type": null, "sub_category": null, "product_img_link": null, "product_tax_code": null, "total_tax_amount": null, "requires_shipping": null } ], "email": "[email protected]", "name": "Joseph Doe", "phone": "999999999", "return_url": "https://google.com/", "authentication_type": "three_ds", "statement_descriptor_name": "Juspay", "statement_descriptor_suffix": "Router", "next_action": { "type": "redirect_to_url", "redirect_to_url": "http://localhost:8080/payments/redirect/pay_WEMpRS2dSPqvSDwcK7GI/postman_merchant_GHAction_d454dc3a-a050-4353-81f2-4137042d2fa5/pay_WEMpRS2dSPqvSDwcK7GI_1" }, "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": "sammantest2722", "created_at": 1745250769, "expires": 1745254369, "secret": "epk_258b6242371e49de87b11ec760786ebd" }, "manual_retry_allowed": null, "connector_transaction_id": "201016052379", "frm_message": null, "metadata": null, "connector_metadata": { "apple_pay": null, "airwallex": null, "noon": { "order_category": "pay" }, "braintree": null }, "feature_metadata": null, "reference_id": "pay_WEMpRS2dSPqvSDwcK7GI_1", "payment_link": null, "profile_id": "pro_vFAhahe8vxYUCVFfWJkD", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_vxFAhPLux0GKTVLZA3TZ", "incremental_authorization_allowed": null, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2025-04-21T16:07:49.398Z", "fingerprint": null, "browser_info": { "language": "nl-NL", "time_zone": 0, "ip_address": "128.0.0.1", "user_agent": "Mozilla/5.0 (iPhone 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_method_id": null, "payment_method_status": null, "updated": "2025-04-21T15:52:51.296Z", "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 } ``` 2. do retrieve ``` curl --location 'http://localhost:8080/payments/pay_WEMpRS2dSPqvSDwcK7GI?force_sync=true' \ --header 'Accept: application/json' \ --header 'api-key: _' ``` Response ``` { "payment_id": "pay_WEMpRS2dSPqvSDwcK7GI", "merchant_id": "postman_merchant_GHAction_d454dc3a-a050-4353-81f2-4137042d2fa5", "status": "succeeded", "amount": 390, "net_amount": 390, "shipping_cost": null, "amount_capturable": 0, "amount_received": 390, "connector": "noon", "client_secret": "pay_WEMpRS2dSPqvSDwcK7GI_secret_tfiuX7BUmEEiD5cXnYSj", "created": "2025-04-21T15:52:49.398Z", "currency": "AED", "customer_id": "sammantest2722", "customer": { "id": "sammantest2722", "name": "Joseph Doe", "email": "[email protected]", "phone": "999999999", "phone_country_code": "+65" }, "description": "Its my first payment", "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": "2701", "card_type": "CREDIT", "card_network": "Visa", "card_issuer": "INTL HDQTRS-CENTER OWNED", "card_issuing_country": "UNITEDSTATES", "card_isin": "400000", "card_extended_bin": null, "card_exp_month": "01", "card_exp_year": "2035", "card_holder_name": "joseph Doe", "payment_checks": null, "authentication_data": null }, "billing": null }, "payment_token": null, "shipping": null, "billing": { "address": { "city": "San Fransico", "country": "AE", "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "zip": "94122", "state": "California", "first_name": "joseph", "last_name": "Doe" }, "phone": { "number": "8056594427", "country_code": "+91" }, "email": null }, "order_details": [ { "brand": null, "amount": 390, "category": null, "quantity": 1, "tax_rate": null, "product_id": null, "product_name": "Apple iphone 15", "product_type": null, "sub_category": null, "product_img_link": null, "product_tax_code": null, "total_tax_amount": null, "requires_shipping": null } ], "email": "[email protected]", "name": "Joseph Doe", "phone": "999999999", "return_url": "https://google.com/", "authentication_type": "three_ds", "statement_descriptor_name": "Juspay", "statement_descriptor_suffix": "Router", "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": false, "connector_transaction_id": "201016052379", "frm_message": null, "metadata": null, "connector_metadata": { "apple_pay": null, "airwallex": null, "noon": { "order_category": "pay" }, "braintree": null }, "feature_metadata": null, "reference_id": "pay_WEMpRS2dSPqvSDwcK7GI_1", "payment_link": null, "profile_id": "pro_vFAhahe8vxYUCVFfWJkD", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_vxFAhPLux0GKTVLZA3TZ", "incremental_authorization_allowed": null, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2025-04-21T16:07:49.398Z", "fingerprint": null, "browser_info": { "language": "nl-NL", "time_zone": 0, "ip_address": "128.0.0.1", "user_agent": "Mozilla/5.0 (iPhone 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_method_id": null, "payment_method_status": null, "updated": "2025-04-21T15:52:59.993Z", "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 } ``` ## 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
<think> PR Context: - Title: revert: fix(connector): [noon] address next_action_url being null for cards in 3ds payment - Merged: 2025-04-22T08:23:14Z - Files changed: 1 files - Commits: 1 commits Implementation approach: Reverts juspay/hyperswitch#7861 </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** revert: fix(connector): [noon] address next_action_url being null for cards in 3ds payment (#7863) Files to modify: **crates/hyperswitch_connectors/src/connectors/noon/transformers.rs** Modify existing code
{"issue_number": 7861, "pr_number": 7863, "commits_count": 1, "files_changed": 1, "response_length": 564, "file_count": 3, "needs_breakdown": false}
refactor(users): Populate optional fields in the user APIs Currently - list users in lineage - get user role details - list invitations APIs send `null` for role_name, entity_name etc... These fields should be populated with proper data.
<think> PR Context: - Title: refactor(user_roles): Populate role names and entity names in user role APIs - Merged: 2024-09-13T13:21:52Z - Files changed: 12 files - Commits: 3 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> - Populate entity name in list invitations API. - Add role name in the response of get user role details API. - Populate role name in list users in lineage API. ### Additional Changes - [x] This PR modifies the API contract - [ ] This </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(user_roles): Populate role names and entity names in user role APIs (#5861) Files to modify: **crates/api_models/src/user.rs** Modify existing code **crates/api_models/src/user_role/role.rs** Modify existing code **crates/diesel_models/src/query/role.rs** Add: - function: pub::find_by_role_id_in_org_scope **crates/router/src/analytics.rs** Modify existing code **crates/router/src/core/user.rs** Modify existing code **crates/router/src/core/user_role.rs** Modify existing code **crates/router/src/core/user_role/role.rs** Modify existing code **crates/router/src/db/kafka_store.rs** Add: - function: private::find_role_by_role_id_in_org_scope **crates/router/src/db/role.rs** Add: - function: private::find_role_by_role_id_in_org_scope - function: private::find_role_by_role_id_in_org_scope **crates/router/src/services/authorization/roles.rs** Add: - function: pub::from_role_id_in_merchant_scope **crates/router/src/utils/user.rs** Modify existing code **crates/router/src/utils/user_role.rs** Modify existing code
{"issue_number": 5860, "pr_number": 5861, "commits_count": 1, "files_changed": 12, "response_length": 1895, "file_count": 14, "needs_breakdown": false}
Add PayU for card payments
<think> PR Context: - Title: feat(connector): add payment create, sync, capture, refund, void, rsync support for PayU - Merged: 2023-01-14T07:37:04Z - Files changed: 14 files - Commits: 16 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [X] New feature ## Description <!-- Describe your changes in detail --> - Adding support for [payU](https://developers.payu.com/en/overview.html) payment gateway - Updated connector creation script **Payment Method:** card, GooglePay, ApplePay **Supported payment flows** - [Authorize](https://developers.payu.com/en/restapi.html#creating_new_order_api) - [Capture](https://developers.payu.com/en/restapi.html#status_u </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(connector): add payment create, sync, capture, refund, void, rsync support for PayU (#351) Co-a Files to modify: **crates/api_models/src/enums.rs** Modify existing code **crates/router/src/configs/settings.rs** Modify existing code **crates/router/src/connector.rs** Add: - mod: pub::payu **crates/router/src/connector/payu.rs** Add: - function: private::build_headers - function: private::id - 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::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::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_flow_type - struct: pub::Payu - impl: impl ConnectorCommonExt<Flow, Request, Response> for Payu - impl: impl ConnectorCommon for Payu - impl: impl api::Payment for Payu - impl: impl api::PreVerify for Payu - impl: impl services::ConnectorIntegration< api::Verify, types::VerifyRequestData, types::PaymentsResponseData, > for Payu - impl: impl api::PaymentVoid for Payu - impl: impl services::ConnectorIntegration< api::Void, types::PaymentsCancelData, types::PaymentsResponseData, > for Payu - impl: impl api::PaymentSync for Payu - impl: impl services::ConnectorIntegration<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> for Payu - impl: impl api::PaymentCapture for Payu - impl: impl services::ConnectorIntegration< api::Capture, types::PaymentsCaptureData, types::PaymentsResponseData, > for Payu - impl: impl api::PaymentSession for Payu - impl: impl services::ConnectorIntegration< api::Session, types::PaymentsSessionData, types::PaymentsResponseData, > for Payu - impl: impl api::PaymentAuthorize for Payu - impl: impl services::ConnectorIntegration< api::Authorize, types::PaymentsAuthorizeData, types::PaymentsResponseData, > for Payu - impl: impl api::Refund for Payu - impl: impl api::RefundExecute for Payu - impl: impl api::RefundSync for Payu - impl: impl services::ConnectorIntegration<api::Execute, types::RefundsData, types::RefundsResponseData> for Payu - impl: impl services::ConnectorIntegration<api::RSync, types::RefundsData, types::RefundsResponseData> for Payu - impl: impl api::IncomingWebhook for Payu - impl: impl services::ConnectorRedirectResponse for Payu - mod: private::transformers **crates/router/src/connector/payu/transformers.rs** Add: - function: private::try_from - function: private::try_from - function: private::from - function: private::try_from - function: private::try_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::PayuPaymentsRequest - struct: pub::PayuPaymentMethod - struct: pub::PayuWallet - struct: pub::PayuAuthType - struct: pub::PayuPaymentsResponse - struct: pub::PayuPaymentsCaptureRequest - struct: pub::PayuPaymentsCaptureResponse - struct: pub::PayuPaymentsCancelResponse - struct: pub::PayuPaymentStatusData - struct: pub::PayuProductData - struct: pub::PayuOrderResponseData - struct: pub::PayuOrderResponseBuyerData - struct: pub::PayuOrderResponseProperty - struct: pub::PayuPaymentsSyncResponse - struct: pub::PayuRefundRequestData - struct: pub::PayuRefundRequest - struct: pub::PayuRefundResponseData - struct: pub::RefundResponse - struct: pub::RefundSyncResponse - struct: pub::PayuErrorData - struct: pub::PayuErrorResponse - enum: pub::PayuPaymentMethodData - enum: pub::PayuCard - enum: pub::PayuWalletCode - enum: pub::PayuPaymentStatus - enum: pub::OrderStatus - enum: pub::PayuOrderResponsePayMethod - enum: pub::RefundStatus - impl: impl TryFrom<&types::PaymentsAuthorizeRouterData> for PayuPaymentsRequest - impl: impl TryFrom<&types::ConnectorAuthType> for PayuAuthType - impl: impl From<PayuPaymentStatus> for enums::AttemptStatus - impl: impl TryFrom<types::ResponseRouterData<F, PayuPaymentsResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<&types::PaymentsCaptureRouterData> for PayuPaymentsCaptureRequest - impl: impl TryFrom< types::ResponseRouterData<F, PayuPaymentsCaptureResponse, T, types::PaymentsResponseData>, > for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom< types::ResponseRouterData<F, PayuPaymentsCancelResponse, T, types::PaymentsResponseData>, > for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl From<OrderStatus> for enums::AttemptStatus - impl: impl TryFrom<types::ResponseRouterData<F, PayuPaymentsSyncResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<&types::RefundsRouterData<F>> for PayuRefundRequest - impl: impl From<RefundStatus> for enums::RefundStatus - impl: impl TryFrom<types::RefundsResponseRouterData<api::Execute, RefundResponse>> for types::RefundsRouterData<api::Execute> - impl: impl TryFrom<types::RefundsResponseRouterData<api::RSync, RefundSyncResponse>> for types::RefundsRouterData<api::RSync> **crates/router/src/services/api.rs** Modify existing code **crates/router/src/services/api/client.rs** Modify existing code **crates/router/src/types/api.rs** Modify existing code **crates/router/tests/connectors/connector_auth.rs** Modify existing code **crates/router/tests/connectors/main.rs** Add: - mod: private::payu **crates/router/tests/connectors/payu.rs** Add: - function: private::get_data - function: private::get_auth_token - function: private::get_name - function: private::should_authorize_card_payment - function: private::should_authorize_gpay_payment - function: private::should_capture_already_authorized_payment - function: private::should_sync_payment - function: private::should_void_already_authorized_payment - function: private::should_refund_succeeded_payment - function: private::should_sync_succeeded_refund_payment - function: private::should_fail_already_refunded_payment - struct: private::Payu - impl: impl ConnectorActions for Payu - impl: impl utils::Connector for Payu **crates/router/tests/connectors/utils.rs** Add: - function: private::default - struct: pub::BrowserInfoType - impl: impl Default for BrowserInfoType
{"issue_number": 237, "pr_number": 351, "commits_count": 1, "files_changed": 14, "response_length": 9303, "file_count": 16, "needs_breakdown": true}
fix(router): populate card network in the network transaction id based MIT flow ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> In the PG agnostic MIT flow (card details with network transaction id) the card network is being passed a null in the response. As the card network fetched form the card info lookup is not being used. Additionally this pr also contains the changes to include the `network_transaction_id_supported_connectors` in `production.toml`. And pass internet as the commerce_indicator for discover cards in cybersource. ### 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). --> ## 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 merchant account and merchant connector account -> enable `is_connector_agnostic_mit_enabled` flag ``` curl --location 'http://localhost:8080/account/merchant_1732783890/business_profile/pro_lNl3x8up5RJTzGLgq0cC' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: test_admin' \ --data '{ "is_connector_agnostic_mit_enabled": true }' ``` ``` { "merchant_id": "merchant_1732783890", "profile_id": "pro_lNl3x8up5RJTzGLgq0cC", "profile_name": "US_default", "return_url": "https://google.com/success", "enable_payment_response_hash": true, "payment_response_hash_key": "EHpgSu6g2VWesxu9L3tPGXVI7XuL1lqZ4CAwjYH3PUHr6VTiO1gyVuPsLSQoCGCO", "redirect_to_merchant_with_http_post": false, "webhook_details": { "webhook_version": "1.0.1", "webhook_username": "ekart_retail", "webhook_password": "password_ekart@123", "webhook_url": null, "payment_created_enabled": true, "payment_succeeded_enabled": true, "payment_failed_enabled": true }, "metadata": null, "routing_algorithm": null, "intent_fulfillment_time": 900, "frm_routing_algorithm": null, "payout_routing_algorithm": null, "applepay_verified_domains": null, "session_expiry": 900, "payment_link_config": null, "authentication_connector_details": null, "use_billing_as_payment_method_billing": true, "extended_card_info_config": null, "collect_shipping_details_from_wallet_connector": false, "collect_billing_details_from_wallet_connector": false, "always_collect_shipping_details_from_wallet_connector": false, "always_collect_billing_details_from_wallet_connector": false, "is_connector_agnostic_mit_enabled": true, "payout_link_config": null, "outgoing_webhook_custom_http_headers": null, "tax_connector_id": null, "is_tax_connector_enabled": false, "is_network_tokenization_enabled": false, "is_auto_retries_enabled": false, "max_auto_retries_enabled": null } ``` -> Create a payment with `"setup_future_usage": "off_session",` ``` { "amount": 100, "currency": "USD", "confirm": true, "capture_method": "automatic", "capture_on": "2022-09-10T10:11:12Z", "customer_id": "cu_{{$timestamp}}", "email": "[email protected]", "name": "John Doe", "phone": "999999999", "phone_country_code": "+65", "description": "Its my first payment request", "authentication_type": "no_three_ds", "return_url": "https://google.com", "payment_method": "card", "payment_method_type": "credit", "payment_method_data": { "card": { "card_number": "4242424242424242", "card_exp_month": "03", "card_exp_year": "2030", "card_holder_name": "name name", "card_cvc": "737" } }, "setup_future_usage": "off_session", "customer_acceptance": { "acceptance_type": "offline", "accepted_at": "1963-05-03T04:07:52.723Z", "online": { "ip_address": "in sit", "user_agent": "amet irure esse" } }, "billing": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "PiX", "last_name": "ss" } }, "shipping": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "John", "last_name": "Doe" }, "phone": { "number": "8056594427", "country_code": "+91" } }, "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" }, "statement_descriptor_name": "joseph", "statement_descriptor_suffix": "JS", "metadata": {}, "order_details": [ { "product_name": "Apple iphone 15", "quantity": 1, "amount": 0, "account_name": "transaction_processing" } ] } ``` ``` { "payment_id": "pay_fnfBuSFwvwVMzmk0OZM3", "merchant_id": "merchant_1732784068", "status": "succeeded", "amount": 100, "net_amount": 100, "shipping_cost": null, "amount_capturable": 0, "amount_received": 100, "connector": "cybersource", "client_secret": "pay_fnfBuSFwvwVMzmk0OZM3_secret_VoTLxuhAVA1mYPyTQyN4", "created": "2024-11-28T08:55:25.492Z", "currency": "USD", "customer_id": "cu_1732784125", "customer": { "id": "cu_1732784125", "name": "John Doe", "email": "[email protected]", "phone": "999999999", "phone_country_code": "+65" }, "description": "Its my first payment request", "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": "off_session", "off_session": null, "capture_on": null, "capture_method": "automatic", "payment_method": "card", "payment_method_data": { "card": { "last4": "4242", "card_type": "CREDIT", "card_network": "Visa", "card_issuer": "STRIPE PAYMENTS UK LIMITED", "card_issuing_country": "UNITEDKINGDOM", "card_isin": "424242", "card_extended_bin": null, "card_exp_month": "03", "card_exp_year": "2030", "card_holder_name": null, "payment_checks": { "avs_response": { "code": "Y", "codeRaw": "Y" }, "card_verification": null }, "authentication_data": null }, "billing": null }, "payment_token": "token_hrw68v72wmWkd6uDjNCl", "shipping": { "address": { "city": "San Fransico", "country": "US", "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "zip": "94122", "state": "California", "first_name": "John", "last_name": "Doe" }, "phone": { "number": "8056594427", "country_code": "+91" }, "email": null }, "billing": { "address": { "city": "San Fransico", "country": "US", "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "zip": "94122", "state": "California", "first_name": "PiX", "last_name": "ss" }, "phone": null, "email": null }, "order_details": [ { "brand": null, "amount": 0, "category": null, "quantity": 1, "product_id": null, "product_name": "Apple iphone 15", "product_type": null, "sub_category": null, "product_img_link": null, "product_tax_code": null, "requires_shipping": null } ], "email": "[email protected]", "name": "John Doe", "phone": "999999999", "return_url": "https://google.com/", "authentication_type": "no_three_ds", "statement_descriptor_name": "joseph", "statement_descriptor_suffix": "JS", "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": "cu_1732784125", "created_at": 1732784125, "expires": 1732787725, "secret": "epk_06284b9a905f4c3aa196b00ad8112174" }, "manual_retry_allowed": false, "connector_transaction_id": "7327841265636354504951", "frm_message": null, "metadata": {}, "connector_metadata": null, "feature_metadata": null, "reference_id": "pay_fnfBuSFwvwVMzmk0OZM3_1", "payment_link": null, "profile_id": "pro_ENrgK0m9AXuOtOMzxFju", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_N3lWoDG7yvB9rbvJFyrb", "incremental_authorization_allowed": false, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2024-11-28T09:10:25.492Z", "fingerprint": null, "browser_info": { "language": "nl-NL", "time_zone": 0, "ip_address": "125.0.0.1", "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_method_id": "pm_qUyvJqDRB16ItLjiBATM", "payment_method_status": "active", "updated": "2024-11-28T08:55:27.234Z", "charges": null, "frm_metadata": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": "27F62F9C4E44ACD0E063AF598E0A7075" } ``` ![image](https://github.com/user-attachments/assets/6c5ed3d5-0430-4db6-a252-cf7af0213c3f) -> Create a payment for the same customer ``` curl --location 'http://localhost:8080/payments' \ --header 'Accept: application/json' \ --header 'api-key: dev_JZ5SfN6HmdFyVadqiq6iO6cZD9JDnWNT0bVhEEbOFLbw9NXkYNNr3MaXXTpVjFEY' \ --header 'Content-Type: application/json' \ --data '{ "amount": 10000, "currency": "USD", "capture_method": "automatic", "authentication_type": "three_ds", "confirm": false, "setup_future_usage": "off_session", "customer_id": "cu_1732784125" }' ``` ``` { "payment_id": "pay_Nxx6173Q7F2ES49eeMYr", "merchant_id": "merchant_1732784068", "status": "requires_payment_method", "amount": 10000, "net_amount": 10000, "shipping_cost": null, "amount_capturable": 0, "amount_received": null, "connector": null, "client_secret": "pay_Nxx6173Q7F2ES49eeMYr_secret_2qPhrFGrz8F4ODupztNl", "created": "2024-11-28T08:58:33.763Z", "currency": "USD", "customer_id": "cu_1732784125", "customer": { "id": "cu_1732784125", "name": "John Doe", "email": "[email protected]", "phone": "999999999", "phone_country_code": "+65" }, "description": null, "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": "off_session", "off_session": null, "capture_on": null, "capture_method": "automatic", "payment_method": null, "payment_method_data": null, "payment_token": null, "shipping": null, "billing": null, "order_details": null, "email": "[email protected]", "name": "John Doe", "phone": "999999999", "return_url": null, "authentication_type": "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": null, "connector_label": null, "business_country": null, "business_label": "default", "business_sub_label": null, "allowed_payment_method_types": null, "ephemeral_key": { "customer_id": "cu_1732784125", "created_at": 1732784313, "expires": 1732787913, "secret": "epk_9ed01dde281f46a0966f1c0d779f6099" }, "manual_retry_allowed": null, "connector_transaction_id": null, "frm_message": null, "metadata": null, "connector_metadata": null, "feature_metadata": null, "reference_id": null, "payment_link": null, "profile_id": "pro_ENrgK0m9AXuOtOMzxFju", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": null, "incremental_authorization_allowed": null, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2024-11-28T09:13:33.763Z", "fingerprint": null, "browser_info": null, "payment_method_id": null, "payment_method_status": null, "updated": "2024-11-28T08:58:33.784Z", "charges": null, "frm_metadata": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": null } ``` -> List customer pml with the client_secret ``` curl --location 'http://localhost:8080/customers/payment_methods?client_secret=pay_Nxx6173Q7F2ES49eeMYr_secret_2qPhrFGrz8F4ODupztNl' \ --header 'Accept: application/json' \ --header 'api-key: pk_dev_2cbdf84777ed4b15827d8bc8e6b19622' ``` ``` { "customer_payment_methods": [ { "payment_token": "token_GN84Zv1iv1sbEpE9Fupv", "payment_method_id": "pm_qUyvJqDRB16ItLjiBATM", "customer_id": "cu_1732784125", "payment_method": "card", "payment_method_type": "credit", "payment_method_issuer": "STRIPE PAYMENTS UK LIMITED", "payment_method_issuer_code": null, "recurring_enabled": true, "installment_payment_enabled": false, "payment_experience": [ "redirect_to_url" ], "card": { "scheme": "Visa", "issuer_country": "UNITEDKINGDOM", "last4_digits": "4242", "expiry_month": "03", "expiry_year": "2030", "card_token": null, "card_holder_name": "name name", "card_fingerprint": null, "nick_name": null, "card_network": "Visa", "card_isin": "424242", "card_issuer": "STRIPE PAYMENTS UK LIMITED", "card_type": "CREDIT", "saved_to_locker": true }, "metadata": null, "created": "2024-11-28T08:55:27.197Z", "bank": null, "surcharge_details": null, "requires_cvv": false, "last_used_at": "2024-11-28T08:55:27.197Z", "default_payment_method_set": true, "billing": { "address": { "city": "San Fransico", "country": "US", "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "zip": "94122", "state": "California", "first_name": "name", "last_name": "name" }, "phone": null, "email": null } } ], "is_guest_customer": false } ``` -> Confirm the payment ``` curl --location 'http://localhost:8080/payments/pay_Nxx6173Q7F2ES49eeMYr/confirm' \ --header 'api-key: pk_dev_2cbdf84777ed4b15827d8bc8e6b19622' \ --header 'Content-Type: application/json' \ --data-raw '{ "payment_token": "token_GN84Zv1iv1sbEpE9Fupv", "payment_method_type": "credit", "payment_method": "card", "client_secret": "pay_Nxx6173Q7F2ES49eeMYr_secret_2qPhrFGrz8F4ODupztNl", "billing": { "address": { "city": "test", "country": "US", "line1": "here", "line2": "there", "line3": "anywhere", "zip": "560095", "state": "Washington", "first_name": "One", "last_name": "Two" }, "phone": { "number": "1234567890", "country_code": "+1" }, "email": "[email protected]" } }' ``` ``` { "payment_id": "pay_Nxx6173Q7F2ES49eeMYr", "merchant_id": "merchant_1732784068", "status": "succeeded", "amount": 10000, "net_amount": 10000, "shipping_cost": null, "amount_capturable": 0, "amount_received": 10000, "connector": "cybersource", "client_secret": "pay_Nxx6173Q7F2ES49eeMYr_secret_2qPhrFGrz8F4ODupztNl", "created": "2024-11-28T08:58:33.763Z", "currency": "USD", "customer_id": "cu_1732784125", "customer": { "id": "cu_1732784125", "name": "John Doe", "email": "[email protected]", "phone": "999999999", "phone_country_code": "+65" }, "description": null, "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": "off_session", "off_session": null, "capture_on": null, "capture_method": "automatic", "payment_method": "card", "payment_method_data": { "card": { "last4": "4242", "card_type": "CREDIT", "card_network": "Visa", "card_issuer": "STRIPE PAYMENTS UK LIMITED", "card_issuing_country": "UNITEDKINGDOM", "card_isin": "424242", "card_extended_bin": null, "card_exp_month": "03", "card_exp_year": "2030", "card_holder_name": null, "payment_checks": null, "authentication_data": null }, "billing": null }, "payment_token": "token_GN84Zv1iv1sbEpE9Fupv", "shipping": null, "billing": { "address": { "city": "test", "country": "US", "line1": "here", "line2": "there", "line3": "anywhere", "zip": "560095", "state": "Washington", "first_name": "One", "last_name": "Two" }, "phone": { "number": "1234567890", "country_code": "+1" }, "email": "[email protected]" }, "order_details": null, "email": "[email protected]", "name": "John Doe", "phone": "999999999", "return_url": null, "authentication_type": "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": false, "connector_transaction_id": "7327843962556379004951", "frm_message": null, "metadata": null, "connector_metadata": null, "feature_metadata": null, "reference_id": "pay_Nxx6173Q7F2ES49eeMYr_1", "payment_link": null, "profile_id": "pro_ENrgK0m9AXuOtOMzxFju", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_N3lWoDG7yvB9rbvJFyrb", "incremental_authorization_allowed": false, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2024-11-28T09:13:33.763Z", "fingerprint": null, "browser_info": { "language": null, "time_zone": null, "ip_address": "::1", "user_agent": null, "color_depth": null, "java_enabled": null, "screen_width": null, "accept_header": null, "screen_height": null, "java_script_enabled": null }, "payment_method_id": "pm_qUyvJqDRB16ItLjiBATM", "payment_method_status": "active", "updated": "2024-11-28T08:59:56.654Z", "charges": null, "frm_metadata": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": null } ``` -> Create a cit with stripe and perform the recurring with cybersource ``` { "amount": 100, "currency": "USD", "confirm": true, "capture_method": "automatic", "capture_on": "2022-09-10T10:11:12Z", "customer_id": "cu_{{$timestamp}}", "email": "[email protected]", "name": "John Doe", "phone": "999999999", "phone_country_code": "+65", "description": "Its my first payment request", "authentication_type": "no_three_ds", "return_url": "https://google.com", "payment_method": "card", "payment_method_type": "credit", "payment_method_data": { "card": { "card_number": "4242424242424242", "card_exp_month": "03", "card_exp_year": "2030", "card_holder_name": "name name", "card_cvc": "737" } }, "setup_future_usage": "off_session", "customer_acceptance": { "acceptance_type": "offline", "accepted_at": "1963-05-03T04:07:52.723Z", "online": { "ip_address": "in sit", "user_agent": "amet irure esse" } }, "billing": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "PiX", "last_name": "ss" } }, "shipping": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "John", "last_name": "Doe" }, "phone": { "number": "8056594427", "country_code": "+91" } }, "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" }, "statement_descriptor_name": "joseph", "statement_descriptor_suffix": "JS", "metadata": {}, "order_details": [ { "product_name": "Apple iphone 15", "quantity": 1, "amount": 0, "account_name": "transaction_processing" } ] } ``` ``` { "payment_id": "pay_mKYKX3ChuavzS7atiqrC", "merchant_id": "merchant_1732786757", "status": "succeeded", "amount": 100, "net_amount": 100, "shipping_cost": null, "amount_capturable": 0, "amount_received": 100, "connector": "stripe", "client_secret": "pay_mKYKX3ChuavzS7atiqrC_secret_aI23DBV8qxTNg2WPESAt", "created": "2024-11-28T09:41:01.957Z", "currency": "USD", "customer_id": "cu_1732786862", "customer": { "id": "cu_1732786862", "name": "John Doe", "email": "[email protected]", "phone": "999999999", "phone_country_code": "+65" }, "description": "Its my first payment request", "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": "off_session", "off_session": null, "capture_on": null, "capture_method": "automatic", "payment_method": "card", "payment_method_data": { "card": { "last4": "4242", "card_type": "CREDIT", "card_network": "Visa", "card_issuer": "STRIPE PAYMENTS UK LIMITED", "card_issuing_country": "UNITEDKINGDOM", "card_isin": "424242", "card_extended_bin": null, "card_exp_month": "03", "card_exp_year": "2030", "card_holder_name": null, "payment_checks": { "cvc_check": "pass", "address_line1_check": "pass", "address_postal_code_check": "pass" }, "authentication_data": null }, "billing": null }, "payment_token": null, "shipping": { "address": { "city": "San Fransico", "country": "US", "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "zip": "94122", "state": "California", "first_name": "John", "last_name": "Doe" }, "phone": { "number": "8056594427", "country_code": "+91" }, "email": null }, "billing": { "address": { "city": "San Fransico", "country": "US", "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "zip": "94122", "state": "California", "first_name": "PiX", "last_name": "ss" }, "phone": null, "email": null }, "order_details": [ { "brand": null, "amount": 0, "category": null, "quantity": 1, "product_id": null, "product_name": "Apple iphone 15", "product_type": null, "sub_category": null, "product_img_link": null, "product_tax_code": null, "requires_shipping": null } ], "email": "[email protected]", "name": "John Doe", "phone": "999999999", "return_url": "https://google.com/", "authentication_type": "no_three_ds", "statement_descriptor_name": "joseph", "statement_descriptor_suffix": "JS", "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": "cu_1732786862", "created_at": 1732786861, "expires": 1732790461, "secret": "epk_2ee23c3779a54e56b9c15816e56d47af" }, "manual_retry_allowed": false, "connector_transaction_id": "pi_3QQ4DaEOqOywnAIx00EgTOEA", "frm_message": null, "metadata": {}, "connector_metadata": null, "feature_metadata": null, "reference_id": "pi_3QQ4DaEOqOywnAIx00EgTOEA", "payment_link": null, "profile_id": "pro_LHl9xKTts4FUwsDgPIAA", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_PohIcY4T0yRYB4FRQpsG", "incremental_authorization_allowed": null, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2024-11-28T09:56:01.957Z", "fingerprint": null, "browser_info": { "language": "nl-NL", "time_zone": 0, "ip_address": "125.0.0.1", "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_method_id": "pm_GuFw64hE9GdwBaAdu60R", "payment_method_status": "active", "updated": "2024-11-28T09:41:04.190Z", "charges": null, "frm_metadata": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": "pm_1QQ4DaEOqOywnAIxeM9Q73Pt" } ``` -> Create payment for same customer ``` curl --location 'http://localhost:8080/payments' \ --header 'Accept: application/json' \ --header 'api-key: dev_vEvPY8nOxGDtjC1IfIgOVDVouV4bfDK1MPyTB2vqPCDjf3QTSaW4lP0UkjDORWi1' \ --header 'Content-Type: application/json' \ --data '{ "amount": 10000, "currency": "USD", "capture_method": "automatic", "authentication_type": "three_ds", "confirm": false, "setup_future_usage": "off_session", "customer_id": "cu_1732786862" }' ``` ``` { "payment_id": "pay_PiKxSAcgYv1SCRuTgbNW", "merchant_id": "merchant_1732786757", "status": "requires_payment_method", "amount": 10000, "net_amount": 10000, "shipping_cost": null, "amount_capturable": 0, "amount_received": null, "connector": null, "client_secret": "pay_PiKxSAcgYv1SCRuTgbNW_secret_6PMdd9eOqqYm0XyBvRCs", "created": "2024-11-28T09:41:24.895Z", "currency": "USD", "customer_id": "cu_1732786862", "customer": { "id": "cu_1732786862", "name": "John Doe", "email": "[email protected]", "phone": "999999999", "phone_country_code": "+65" }, "description": null, "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": "off_session", "off_session": null, "capture_on": null, "capture_method": "automatic", "payment_method": null, "payment_method_data": null, "payment_token": null, "shipping": null, "billing": null, "order_details": null, "email": "[email protected]", "name": "John Doe", "phone": "999999999", "return_url": null, "authentication_type": "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": null, "connector_label": null, "business_country": null, "business_label": "default", "business_sub_label": null, "allowed_payment_method_types": null, "ephemeral_key": { "customer_id": "cu_1732786862", "created_at": 1732786884, "expires": 1732790484, "secret": "epk_89b1364c0b6048d9aba374bfee2c68e6" }, "manual_retry_allowed": null, "connector_transaction_id": null, "frm_message": null, "metadata": null, "connector_metadata": null, "feature_metadata": null, "reference_id": null, "payment_link": null, "profile_id": "pro_LHl9xKTts4FUwsDgPIAA", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": null, "incremental_authorization_allowed": null, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2024-11-28T09:56:24.895Z", "fingerprint": null, "browser_info": null, "payment_method_id": null, "payment_method_status": null, "updated": "2024-11-28T09:41:24.934Z", "charges": null, "frm_metadata": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": null } ``` -> Customer pml ``` curl --location 'http://localhost:8080/customers/payment_methods?client_secret=pay_PiKxSAcgYv1SCRuTgbNW_secret_6PMdd9eOqqYm0XyBvRCs' \ --header 'Accept: application/json' \ --header 'api-key: pk_dev_c7c7295d08b54d589459ec0e8de731aa' ``` ``` { "customer_payment_methods": [ { "payment_token": "token_WTkWv5zRyilJVfcZFZB4", "payment_method_id": "pm_GuFw64hE9GdwBaAdu60R", "customer_id": "cu_1732786862", "payment_method": "card", "payment_method_type": "credit", "payment_method_issuer": "STRIPE PAYMENTS UK LIMITED", "payment_method_issuer_code": null, "recurring_enabled": true, "installment_payment_enabled": false, "payment_experience": [ "redirect_to_url" ], "card": { "scheme": "Visa", "issuer_country": "UNITEDKINGDOM", "last4_digits": "4242", "expiry_month": "03", "expiry_year": "2030", "card_token": null, "card_holder_name": "name name", "card_fingerprint": null, "nick_name": null, "card_network": "Visa", "card_isin": "424242", "card_issuer": "STRIPE PAYMENTS UK LIMITED", "card_type": "CREDIT", "saved_to_locker": true }, "metadata": null, "created": "2024-11-28T09:41:04.160Z", "bank": null, "surcharge_details": null, "requires_cvv": false, "last_used_at": "2024-11-28T09:41:04.160Z", "default_payment_method_set": true, "billing": { "address": { "city": "San Fransico", "country": "US", "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "zip": "94122", "state": "California", "first_name": "name", "last_name": "name" }, "phone": null, "email": null } } ], "is_guest_customer": false } ``` -> Confirm with cybersource ``` curl --location 'http://localhost:8080/payments/pay_PiKxSAcgYv1SCRuTgbNW/confirm' \ --header 'api-key: pk_dev_c7c7295d08b54d589459ec0e8de731aa' \ --header 'Content-Type: application/json' \ --data-raw '{ "payment_token": "token_WTkWv5zRyilJVfcZFZB4", "payment_method_type": "credit", "payment_method": "card", "client_secret": "pay_PiKxSAcgYv1SCRuTgbNW_secret_6PMdd9eOqqYm0XyBvRCs", "routing": { "type": "single", "data": { "connector": "cybersource", "merchant_connector_id": "mca_XcYZAcIAg28iKuSfTVOm" } }, "billing": { "address": { "city": "test", "country": "US", "line1": "here", "line2": "there", "line3": "anywhere", "zip": "560095", "state": "Washington", "first_name": "One", "last_name": "Two" }, "phone": { "number": "1234567890", "country_code": "+1" }, "email": "[email protected]" } }' ``` ``` { "payment_id": "pay_PiKxSAcgYv1SCRuTgbNW", "merchant_id": "merchant_1732786757", "status": "succeeded", "amount": 10000, "net_amount": 10000, "shipping_cost": null, "amount_capturable": 0, "amount_received": 10000, "connector": "cybersource", "client_secret": "pay_PiKxSAcgYv1SCRuTgbNW_secret_6PMdd9eOqqYm0XyBvRCs", "created": "2024-11-28T09:41:24.895Z", "currency": "USD", "customer_id": "cu_1732786862", "customer": { "id": "cu_1732786862", "name": "John Doe", "email": "[email protected]", "phone": "999999999", "phone_country_code": "+65" }, "description": null, "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": "off_session", "off_session": null, "capture_on": null, "capture_method": "automatic", "payment_method": "card", "payment_method_data": { "card": { "last4": "4242", "card_type": "CREDIT", "card_network": "Visa", "card_issuer": "STRIPE PAYMENTS UK LIMITED", "card_issuing_country": "UNITEDKINGDOM", "card_isin": "424242", "card_extended_bin": null, "card_exp_month": "03", "card_exp_year": "2030", "card_holder_name": null, "payment_checks": null, "authentication_data": null }, "billing": null }, "payment_token": "token_WTkWv5zRyilJVfcZFZB4", "shipping": null, "billing": { "address": { "city": "test", "country": "US", "line1": "here", "line2": "there", "line3": "anywhere", "zip": "560095", "state": "Washington", "first_name": "One", "last_name": "Two" }, "phone": { "number": "1234567890", "country_code": "+1" }, "email": "[email protected]" }, "order_details": null, "email": "[email protected]", "name": "John Doe", "phone": "999999999", "return_url": null, "authentication_type": "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": false, "connector_transaction_id": "7327869509776879404951", "frm_message": null, "metadata": null, "connector_metadata": null, "feature_metadata": null, "reference_id": "pay_PiKxSAcgYv1SCRuTgbNW_1", "payment_link": null, "profile_id": "pro_LHl9xKTts4FUwsDgPIAA", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_XcYZAcIAg28iKuSfTVOm", "incremental_authorization_allowed": false, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2024-11-28T09:56:24.895Z", "fingerprint": null, "browser_info": { "language": null, "time_zone": null, "ip_address": "::1", "user_agent": null, "color_depth": null, "java_enabled": null, "screen_width": null, "accept_header": null, "screen_height": null, "java_script_enabled": null }, "payment_method_id": "pm_GuFw64hE9GdwBaAdu60R", "payment_method_status": "active", "updated": "2024-11-28T09:42:31.429Z", "charges": null, "frm_metadata": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_id": null } ``` -> Psync ``` curl --location 'http://localhost:8080/payments/pay_PiKxSAcgYv1SCRuTgbNW?force_sync=true' \ --header 'Accept: application/json' \ --header 'api-key: dev_vEvPY8nOxGDtjC1IfIgOVDVouV4bfDK1MPyTB2vqPCDjf3QTSaW4lP0UkjDORWi1' ``` ``` { "payment_id": "pay_PiKxSAcgYv1SCRuTgbNW", "merchant_id": "merchant_1732786757", "status": "succeeded", "amount": 10000, "net_amount": 10000, "shipping_cost": null, "amount_capturable": 0, "amount_received": 10000, "connector": "cybersource", "client_secret": "pay_PiKxSAcgYv1SCRuTgbNW_secret_6PMdd9eOqqYm0XyBvRCs", "created": "2024-11-28T09:41:24.895Z", "currency": "USD", "customer_id": "cu_1732786862", "customer": { "id": "cu_1732786862", "name": "John Doe", "email": "[email protected]", "phone": "999999999", "phone_country_code": "+65" }, "description": null, "refunds": null, "disputes": null, "mandate_id": null, "mandate_data": null, "setup_future_usage": "off_session", "off_session": null, "capture_on": null, "capture_method": "automatic", "payment_method": "card", "payment_method_data": { "card": { "last4": "4242", "card_type": "CREDIT", "card_network": "Visa", "card_issuer": "STRIPE PAYMENTS UK LIMITED", "card_issuing_country": "UNITEDKINGDOM", "card_isin": "424242", "card_extended_bin": null, "card_exp_month": "03", "card_exp_year": "2030", "card_holder_name": null, "payment_checks": null, "authentication_data": null }, "billing": null }, "payment_token": "token_WTkWv5zRyilJVfcZFZB4", "shipping": null, "billing": { "address": { "city": "test", "country": "US", "line1": "here", "line2": "there", "line3": "anywhere", "zip": "560095", "state": "Washington", "first_name": "One", "last_name": "Two" }, "phone": { "number": "1234567890", "country_code": "+1" }, "email": "[email protected]" }, "order_details": null, "email": "[email protected]", "name": "John Doe", "phone": "999999999", "return_url": null, "authentication_type": "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": false, "connector_transaction_id": "7327869509776879404951", "frm_message": null, "metadata": null, "connector_metadata": null, "feature_metadata": null, "reference_id": "pay_PiKxSAcgYv1SCRuTgbNW_1", "payment_link": null, "profile_id": "pro_LHl9xKTts4FUwsDgPIAA", "surcharge_details": null, "attempt_count": 1, "merchant_decision": null, "merchant_connector_id": "mca_XcYZAcIAg28iKuSfTVOm", "incremental_authorization_allowed": false, "authorization_count": null, "incremental_authorizations": null, "external_authentication_details": null, "external_3ds_authentication_attempted": false, "expires_on": "2024-11-28T09:56:24.895Z", "fingerprint": null, "browser_info": { "language": null, "time_zone": null, "ip_address": "::1", "user_agent": null, "color_depth": null, "java_enabled": null, "screen_width": null, "accept_header": null, "screen_height": null, "java_script_enabled": null }, "payment_method_id": "pm_GuFw64hE9GdwBaAdu60R", "payment_method_status": "active", "updated": "2024-11-28T09:42:31.429Z", "charges": null, "frm_metadata": null, "merchant_order_reference_id": null, "order_tax_amount": null, "connector_mandate_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
<think> PR Context: - Title: fix(connector): [Cybersource] change commerce indicator for discover cards in apple pay - Merged: 2024-12-03T10:39:13Z - Files changed: 1 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> commerce indicator for discover card in applepay is changed since the payments are failing in production for cybersource Note: This is hotifx against [#6690](https://github.com/juspay/hyperswitch/pull/6690) ### Additional Changes - [ </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(connector): [Cybersource] change commerce indicator for discover cards in apple pay (#6728) Files to modify: **crates/router/src/connector/cybersource/transformers.rs** Modify existing code
{"issue_number": 6690, "pr_number": 6728, "commits_count": 1, "files_changed": 1, "response_length": 1017, "file_count": 3, "needs_breakdown": false}
Propage request id to chat service Send request id to chat service in headers.
<think> PR Context: - Title: fix(chat): append request id to headers for chat request - Merged: 2025-07-25T07:27:38Z - Files changed: 4 files - Commits: 7 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Propagation request-id to chat service for consistency. Propagate chat session id as well in request Add count metric for chat api ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies application c </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(chat): append request id to headers for chat request (#8680) Files to modify: **crates/common_utils/src/consts.rs** Modify existing code **crates/router/src/core/chat.rs** Modify existing code **crates/router/src/routes/chat.rs** Modify existing code **crates/router/src/routes/metrics.rs** Modify existing code
{"issue_number": 8679, "pr_number": 8680, "commits_count": 1, "files_changed": 4, "response_length": 1117, "file_count": 6, "needs_breakdown": false}
[BUG] Update Iatapay config URL to use sandbox URl instead of production URL ### Bug Description It bugs out when you try to do a payment with Iatapay and it throws Unauthorized error in Sandbox environment ### Expected Behavior It should do the payment. ### Actual Behavior Throws an error ### Steps To Reproduce 1. Do a Payment through Iatapay ### Context For The Bug Error. Unauthorized error. ### Environment Are you using hyperswitch hosted version? Yes Sandbox ### Have you spent some time checking if this bug has been raised before? - [X] I checked and didn't find a similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? Yes, I am willing to submit a PR!
<think> PR Context: - Title: chore(env): update Iatapay env to use Sandbox URL instead of Prod - Merged: 2024-02-13T13:19:45Z - Files changed: 1 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [x] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR updates Iatapay to use Sandbox URL instead of Production URL in Sandbox environment. Closes #3643 ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifi </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 3643, "pr_number": 3644, "commits_count": 0, "files_changed": 1, "response_length": 795, "file_count": 0, "needs_breakdown": false}
[REFACTOR]: [Multisafepay] Remove Default Case Handling ### :memo: Feature Description - We utilize match statements to make pivotal decisions, such as generating requests based on the payment method type and managing responses received from the connector. - These conditions generally go hand in hand with enum variants. - Default case is used because a match statement needs to be exhaustive i.e. every variant needs to be covered. - So, if all the explicit cases are handled then default is used to handle the rest. - Each connector have these match statements but many of them don’t provide reference to each variant in their default case, rather a `_` is put to handle all the other cases. - This approach carries a risk because developers may inadvertently overlook the need for explicit handling of the new cases. ### :hammer: Possible Implementation - Instead of relying on a default match case `_`, developers should handle each and every variant explicitly. - By doing so, if there are any changes in the future, they can readily assess the impact of their modifications simply by compiling the code. - You can check this PR for further reference https://github.com/juspay/hyperswitch/pull/1955 :bookmark: Note: All the changes needed should be contained within `hyperswitch/crates/router/src/connector/` ### :package: Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### :package: Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### :sparkles: Are you willing to submit a PR?
<think> PR Context: - Title: refactor(connector): [multisafepay] Remove Default Case Handling - Merged: 2023-10-16T14:01:15Z - Files changed: 1 files - Commits: 2 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Removed all the default case handling in multisafepay and handle all the missing cases. Closes: #2274 ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/environment vari </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(connector): [multisafepay] Remove Default Case Handling (#2586) Files to modify: **crates/router/src/connector/multisafepay/transformers.rs** Modify existing code
{"issue_number": 2274, "pr_number": 2586, "commits_count": 1, "files_changed": 1, "response_length": 972, "file_count": 3, "needs_breakdown": false}
Implement `CardsInfoInterface` for `MockDb` Spin out from #172. Please refer to that issue for more information.
<think> PR Context: - Title: feat(router): implement `CardsInfoInterface` for `MockDB` - Merged: 2023-05-25T07:25:37Z - Files changed: 2 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Very simply implement `CardsInfoInterface` for `MockDB`, allowing looking up of card info, the only trait method ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(router): implement `CardsInfoInterface` for `MockDB` (#1262) Files to modify: **crates/router/src/db.rs** Modify existing code **crates/router/src/db/cards_info.rs** Modify existing code
{"issue_number": 1189, "pr_number": 1262, "commits_count": 1, "files_changed": 2, "response_length": 988, "file_count": 4, "needs_breakdown": false}
[REFACTOR] provide an identifier for the api key in the expiry reminder email ### Issue Description: Currently, our system sends out reminder emails to merchants when their API key is about to expire. However, since merchants can create multiple API keys, the email lacks clarity on which specific API key is expiring. ### Proposed Solution: Refactor the api key expiry reminder workflow to include the name and prefix of the expiring API key in email. This will help merchants easily identify which API key requires attention without confusion. ### Details: Update the email template to include the following information: API Key Name along with Prefix in below format - `API_KEY_NAME [PREFIX]` ### Reference: Check `ApiKeyExpiryTrackingData` type in https://github.com/juspay/hyperswitch/blob/2c95dcd19778726f476b219271dc42da182088af/crates/diesel_models/src/api_keys.rs
<think> PR Context: - Title: feat(connector): [Stripe] Metadata to connector metadata mapping - Merged: 2024-01-30T11:50:54Z - Files changed: 3 files - Commits: 16 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Resolves [#3801](https://github.com/juspay/hyperswitch-cloud/issues/3801) ## Test Case Testing can be done by creating a card/gpay/applepay payment and by passing the following metadata in PAYMENTS-CREATE: "metadata": { "count_tickets": 1 </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(connector): [Stripe] Metadata to connector metadata mapping (#3295) Co-authored-by: hyperswitch Files to modify: **crates/router/src/connector/stripe/transformers.rs** Add: - function: private::get_transaction_metadata **crates/router/src/core/payments/transformers.rs** Modify existing code **crates/router/src/types.rs** Modify existing code
{"issue_number": 3801, "pr_number": 3295, "commits_count": 1, "files_changed": 3, "response_length": 1161, "file_count": 5, "needs_breakdown": false}
[FEATURE]: [Cybersource] Use `connector_response_reference_id` as reference to merchant ### :memo: Feature Description - Reference id are used to map transactions in the connector’s dashboard. - Hyperswitch manages several reference ids, such as `payment_id`, `attempt_id`, and `connector_transaction_id` for a single transaction. - However, merchants may encounter uncertainty when determining which ID to utilize in the connector dashboard to identify the payment. ### :hammer: Possible Implementation - When we receive a response from the connector for the payment, we deserialize it and populate the `response` field in RouterData. - For the `TransactionResponse` type, we must fill the `connector_response_reference_id` with a corresponding reference id for the merchant to identify the transaction. - One might need to have exposure to api docs of the connector for which it is being implemented to decide what to fill in connector_response_reference_id. - You can check this PR for further reference https://github.com/juspay/hyperswitch/pull/1735 🔖 Note: All the changes needed should be contained within `hyperswitch/crates/router/src/connector/` ### :package: Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### :package: Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### :sparkles: Are you willing to submit a PR?
<think> PR Context: - Title: feat(connector): [Cybersource] Use connector_response_reference_id as reference to merchant - Merged: 2023-10-07T06:52:01Z - Files changed: 1 files - Commits: 13 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Use connector_response_reference_id as reference to merchant for Cybersource Fixes #2327 ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/environment variables <!-- </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(connector): [Cybersource] Use connector_response_reference_id as reference to merchant (#2470) Files to modify: **crates/router/src/connector/cybersource/transformers.rs** Modify existing code
{"issue_number": 2327, "pr_number": 2470, "commits_count": 1, "files_changed": 1, "response_length": 1028, "file_count": 3, "needs_breakdown": false}
fix: Fix bugs caused by token only flows - Password without special characters is not throwing parsing failed error. - Signup is not populating the `last_password_modified_at`. - Verify email is blacklisting all email tokens. - If the SPT token time is less than JWT time, some SPTs issued after that blacklist are not working.
<think> PR Context: - Title: fix(users): Fix bugs caused by the new token only flows - Merged: 2024-05-09T14:30:19Z - Files changed: 3 files - Commits: 5 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR fixes the following bugs: - Password without special characters is not throwing parsing failed error. - Signup is not populating the `last_password_modified_at`. - Verify email is blacklisting all email tokens. - If the SPT token t </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(users): Fix bugs caused by the new token only flows (#4607) Files to modify: **crates/router/src/consts.rs** Modify existing code **crates/router/src/core/user.rs** Modify existing code **crates/router/src/types/domain/user.rs** Modify existing code
{"issue_number": 4606, "pr_number": 4607, "commits_count": 1, "files_changed": 3, "response_length": 1051, "file_count": 5, "needs_breakdown": false}
refactor(permissions): Deprecate permissions from permission info API response The permissions in the permission info API are not being used and should be removed.
<think> PR Context: - Title: refactor(permissions): Remove permissions field from permission info API response - Merged: 2024-10-22T10:15:42Z - Files changed: 4 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> The permissions in the permission info API are not being used and this PR will remove them. This will help the future PRs which will introduce new kind of Permissions. ### Additional Changes - [x] This PR modifies the API contract - </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(permissions): Remove permissions field from permission info API response (#6376) Files to modify: **crates/api_models/src/user_role.rs** Remove: - struct: pub::PermissionInfo - enum: pub::Permission **crates/router/src/services/authorization/info.rs** Remove: - function: pub::get_permission_info_from_permissions **crates/router/src/services/authorization/permissions.rs** Remove: - function: pub::get_permission_description - impl: impl Permission **crates/router/src/utils/user_role.rs** Remove: - function: private::from - impl: impl From<Permission> for user_role_api::Permission
{"issue_number": 6375, "pr_number": 6376, "commits_count": 1, "files_changed": 4, "response_length": 1448, "file_count": 6, "needs_breakdown": false}
[ENHANCE] Send connector in refund response ### Feature Description Add field connector in `api_models::refunds::RefundResponse`. ### Possible Implementation We store connector field in `storage_models::Refund`. Map it to the field in `RefundResponse` ### Have you spent some time to check if this feature request has been raised before? - [X] I checked and didn't find similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? Yes I am willing to submit a PR!
<think> PR Context: - Title: feat(refunds): add connector field in refund response - Merged: 2023-05-09T15:36:46Z - Files changed: 2 files - Commits: 2 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Added connector field in refund response. We have connector field in storage model of Refund but don't return it in Refund response. Add it in refund response gives context as to which connector was called for refund(same connector through whi </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(refunds): add connector field in refund response (#1059) Co-authored-by: Sarthak Soni <76486416 Files to modify: **crates/api_models/src/refunds.rs** Modify existing code **crates/router/src/core/refunds.rs** Modify existing code
{"issue_number": 1058, "pr_number": 1059, "commits_count": 1, "files_changed": 2, "response_length": 1027, "file_count": 4, "needs_breakdown": false}
[FEATURE] [CONNECTOR] Nordea Integrate a new connector Nordea. Developer Docs: https://developer.nordeaopenbanking.com/documentation Login Dashboard: https://developer.nordeaopenbanking.com/login
<think> PR Context: - Title: feat(connector): [nordea] template code - Merged: 2025-05-21T07:49:27Z - Files changed: 24 files - Commits: 4 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Connector template code for new connector `Nordea`. Developer Docs: https://developer.nordeaopenbanking.com/documentation Login Dashboard: https://developer.nordeaopenbanking.com/login ### Additional Changes - [x] This PR modifies </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(connector): [nordea] template code (#8056) Co-authored-by: hyperswitch-bot[bot] <148525504+hype Files to modify: **crates/common_enums/src/connector_enums.rs** Modify existing code **crates/connector_configs/src/connector.rs** Modify existing code **crates/hyperswitch_connectors/src/connectors.rs** Add: - mod: pub::nordea **crates/hyperswitch_connectors/src/connectors/nordea.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::Nordea - impl: impl Nordea - impl: impl api::Payment for Nordea - impl: impl api::PaymentSession for Nordea - impl: impl api::ConnectorAccessToken for Nordea - impl: impl api::MandateSetup for Nordea - impl: impl api::PaymentAuthorize for Nordea - impl: impl api::PaymentSync for Nordea - impl: impl api::PaymentCapture for Nordea - impl: impl api::PaymentVoid for Nordea - impl: impl api::Refund for Nordea - impl: impl api::RefundExecute for Nordea - impl: impl api::RefundSync for Nordea - impl: impl api::PaymentToken for Nordea - impl: impl ConnectorIntegration<PaymentMethodToken, PaymentMethodTokenizationData, PaymentsResponseData> for Nordea - impl: impl ConnectorCommonExt<Flow, Request, Response> for Nordea - impl: impl ConnectorCommon for Nordea - impl: impl ConnectorValidation for Nordea - impl: impl ConnectorIntegration<Session, PaymentsSessionData, PaymentsResponseData> for Nordea - impl: impl ConnectorIntegration<AccessTokenAuth, AccessTokenRequestData, AccessToken> for Nordea - impl: impl ConnectorIntegration<SetupMandate, SetupMandateRequestData, PaymentsResponseData> for Nordea - impl: impl ConnectorIntegration<Authorize, PaymentsAuthorizeData, PaymentsResponseData> for Nordea - impl: impl ConnectorIntegration<PSync, PaymentsSyncData, PaymentsResponseData> for Nordea - impl: impl ConnectorIntegration<Capture, PaymentsCaptureData, PaymentsResponseData> for Nordea - impl: impl ConnectorIntegration<Void, PaymentsCancelData, PaymentsResponseData> for Nordea - impl: impl ConnectorIntegration<Execute, RefundsData, RefundsResponseData> for Nordea - impl: impl ConnectorIntegration<RSync, RefundsData, RefundsResponseData> for Nordea - impl: impl webhooks::IncomingWebhook for Nordea - impl: impl ConnectorSpecifications for Nordea - mod: pub::transformers **crates/hyperswitch_connectors/src/connectors/nordea/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::NordeaRouterData - struct: pub::NordeaPaymentsRequest - struct: pub::NordeaCard - struct: pub::NordeaAuthType - struct: pub::NordeaPaymentsResponse - struct: pub::NordeaRefundRequest - struct: pub::RefundResponse - struct: pub::NordeaErrorResponse - enum: pub::NordeaPaymentStatus - enum: pub::RefundStatus - impl: impl From<(StringMinorUnit, T)> for NordeaRouterData<T> - impl: impl TryFrom<&NordeaRouterData<&PaymentsAuthorizeRouterData>> for NordeaPaymentsRequest - impl: impl TryFrom<&ConnectorAuthType> for NordeaAuthType - impl: impl From<NordeaPaymentStatus> for common_enums::AttemptStatus - impl: impl TryFrom<ResponseRouterData<F, NordeaPaymentsResponse, T, PaymentsResponseData>> for RouterData<F, T, PaymentsResponseData> - impl: impl TryFrom<&NordeaRouterData<&RefundsRouterData<F>>> for NordeaRefundRequest - 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/configs.rs** Modify existing code **crates/router/src/connector.rs** Modify existing code **crates/router/src/core/admin.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/main.rs** Add: - mod: private::nordea **crates/router/tests/connectors/nordea.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::NordeaTest - impl: impl ConnectorActions for NordeaTest - impl: impl utils::Connector for NordeaTest **crates/test_utils/src/connector_auth.rs** Modify existing code
{"issue_number": 8055, "pr_number": 8056, "commits_count": 1, "files_changed": 24, "response_length": 8717, "file_count": 17, "needs_breakdown": true}
refactor(NMI,PAYONE) , Move files from router to hyperswitch connectors Move the connectors from routers to hyperswitch_connectors
<think> PR Context: - Title: refactor(connector): [NMI,PAYONE,RISKIFIED] moved to hyperswitch_connectors - Merged: 2025-04-24T10:35:43Z - Files changed: 20 files - Commits: 27 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Moving connectors (NMI,Riskified,and payone) from `router` crate to `hyperswitch_connector` crate ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies applicat </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(connector): [NMI,PAYONE,RISKIFIED] moved to hyperswitch_connectors (#7666) Files to modify: **crates/hyperswitch_connectors/src/connectors.rs** Add: - mod: pub::nmi - mod: pub::payone - mod: pub::riskified **crates/hyperswitch_connectors/src/connectors/riskified/transformers/auth.rs** Add: - function: private::try_from - struct: pub::RiskifiedAuthType - impl: impl TryFrom<&ConnectorAuthType> for RiskifiedAuthType **crates/hyperswitch_connectors/src/default_implementations.rs** Modify existing code **crates/hyperswitch_connectors/src/default_implementations_v2.rs** Modify existing code **crates/hyperswitch_connectors/src/types.rs** Modify existing code **crates/hyperswitch_connectors/src/utils.rs** Add: - function: private::is_payment_successful - function: private::get_order_details - function: private::get_currency - trait: pub::FrmTransactionRouterDataRequest - trait: pub::FraudCheckCheckoutRequest - trait: pub::FraudCheckTransactionRequest - impl: impl FrmTransactionRouterDataRequest for FrmTransactionRouterData - impl: impl FraudCheckCheckoutRequest for FraudCheckCheckoutData - impl: impl FraudCheckTransactionRequest for FraudCheckTransactionData **crates/router/src/connector.rs** Remove: - mod: pub::nmi - mod: pub::payone - mod: pub::riskified **crates/router/src/connector/riskified/transformers/auth.rs** Remove: - function: private::try_from - struct: pub::RiskifiedAuthType - impl: impl TryFrom<&types::ConnectorAuthType> for RiskifiedAuthType **crates/router/src/core/payments/flows.rs** Modify existing code **crates/router/src/macros.rs** Modify existing code
{"issue_number": 7715, "pr_number": 7666, "commits_count": 1, "files_changed": 20, "response_length": 2525, "file_count": 12, "needs_breakdown": false}
Implement `MandateInterface` for `MockDb` Spin out from https://github.com/juspay/hyperswitch/issues/172. Please refer to that issue for more information.
<think> PR Context: - Title: feat(db): implement `MandateInterface` for `MockDb` - Merged: 2023-06-17T08:25:58Z - Files changed: 2 files - Commits: 25 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [x] New feature - [x] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> - fixes #1256 ### 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 co </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(db): implement `MandateInterface` for `MockDb` (#1387) Files to modify: **crates/router/src/db.rs** Modify existing code **crates/router/src/db/mandate.rs** Modify existing code
{"issue_number": 1256, "pr_number": 1387, "commits_count": 1, "files_changed": 2, "response_length": 974, "file_count": 4, "needs_breakdown": false}
[FEATURE] Update worldpay connector's integration # Storing long connector transaction IDs (\>128 characters) ## Aim This issue describes the approach for efficiently storing long connector transaction IDs in HyperSwitch application. ## Context HyperSwitch is integrated with multiple connectors, these underlying connectors generate their own resource IDs which are stored in HyperSwitch DB for future references and / or debugging. For payments, this is stored in payment\_attempt table \- `connector_transaction_id` For refunds, this is stored in refunds table \- `connector_refund_id` For captures, this is stored in captures table \- `connector_capture_id` Both these columns are of size 128 characters in length, giving ample amount of space for storing these resource identifiers. Some connectors \- like Worldpay, use a different approach for their resource identifiers. Worldpay uses an encrypted token as its resource identifier whose length usually exceeds 450 characters. HyperSwitch cannot keep increasing the length of these two columns for storing IDs with such large lengths due to performance impacts on both read and write, specifically during webhooks flows as `connector_transaction_id` is an indexed column. ## Solution Includes a bug fix and basically migrates the API endpoints to consume the v7 endpoints. Bug fix -`entity` is a param in their API spec for specifying the merchant's account. The solution requires making changes in two places \- 1. Convert `connector_transaction_id` to a typed enum with two variants in the application 1. `ConnectorTxnId` 2. `HashedConnectorData` 2. Introduce a new column per table for storing such large resource identifiers. ### Pre-requisites - Add a new column `connector_transaction_data` ### Storing large IDs - If input string length \> 128 characters, store this data in `connector_transaction_data` - Create a one-way hash of this data and store it in `connector_transaction_id` with a prefix `hs_hash_` ### Consuming large IDs - If input string length \> 128 characters, create a hash and query using the hashed value - Deserialize `connector_transaction_id` into a typed variant \- either `ConnectorTxnId` or `HashedConnectorData` based on the prefix (`hs_hash_`) - If it’s `HashedConnectorData`, use `connector_transaction_data` as resource ID ## Example Let’s say we want to extend storage of such IDs to payment attempts table 1. Add a new column in the said table \- `connector_transaction_data` 2. While receiving these IDs (assuming length \>128), store in `connector_transaction_data` 3. Create a one-way hash and store in `connector_transaction_id` 4. While querying using these IDs (webhooks flow), create a hash and query using the hashed value 5. Use `connector_transaction_data` instead of `connector_transaction_id` in application and application responses ## Notes - Never expose the hashed `connector_transaction_id’s` outside the system, i.e. in API responses or webhook responses - Deserialize into `HashedConnectorData` only when the `connector_transaction_id` is prefixed with `hs_hash_` ### Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? Yes, I am willing to submit a PR!
<think> PR Context: - Title: feat(worldpay): migrate to v7 - Merged: 2024-10-17T10:57:00Z - Files changed: 30 files - Commits: 25 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Described in #6116 ### 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 </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(worldpay): migrate to v7 (#6109) Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bo Files to modify: **crates/common_enums/src/enums.rs** Modify existing code **crates/common_utils/src/consts.rs** Modify existing code **crates/common_utils/src/types.rs** Add: - function: pub::get_id - function: pub::form_id_and_data - function: pub::get_txn_id - function: private::from - function: private::build - function: private::from_sql - function: private::to_sql - function: private::get_optional_connector_transaction_id - function: private::get_connector_transaction_id - function: private::get_optional_connector_refund_id - enum: pub::ConnectorTransactionId - trait: pub::ConnectorTransactionIdTrait - impl: impl ConnectorTransactionId - impl: impl From<String> for ConnectorTransactionId - impl: impl Queryable<sql_types::Text, DB> for ConnectorTransactionId - impl: impl FromSql<sql_types::Text, DB> for ConnectorTransactionId - impl: impl ToSql<sql_types::Text, DB> for ConnectorTransactionId **crates/currency_conversion/src/types.rs** Modify existing code **crates/diesel_models/src/capture.rs** Modify existing code **crates/diesel_models/src/payment_attempt.rs** Add: - function: private::get_optional_connector_transaction_id - function: private::get_optional_connector_transaction_id - impl: impl ConnectorTransactionIdTrait for PaymentAttempt - impl: impl ConnectorTransactionIdTrait for PaymentAttempt **crates/diesel_models/src/query/capture.rs** Add: - function: private::get_optional_connector_transaction_id - impl: impl ConnectorTransactionIdTrait for Capture **crates/diesel_models/src/refund.rs** Add: - function: private::get_optional_connector_refund_id - function: private::get_connector_transaction_id - impl: impl ConnectorTransactionIdTrait for Refund **crates/diesel_models/src/schema.rs** Modify existing code **crates/diesel_models/src/schema_v2.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/hyperswitch_domain_models/src/router_request_types.rs** Modify existing code **crates/kgraph_utils/src/transformers.rs** Modify existing code **crates/router/src/connector/worldpay.rs** Remove: - function: private::get_url - struct: pub::Worldpay Add: - function: pub::new - function: private::get_url - struct: pub::Worldpay - impl: impl Worldpay **crates/router/src/connector/worldpay/requests.rs** Modify existing code **crates/router/src/connector/worldpay/response.rs** Remove: - function: pub::new - function: pub::new - function: pub::new - function: pub::new - struct: pub::PaymentInstrumentCard - struct: pub::PaymentInstrumentCardExpiryDate - struct: pub::PaymentInstrumentCardIssuer - struct: pub::PaymentInstrumentCardNumber - enum: pub::Outcome - impl: impl Exemption - impl: impl PaymentsResPaymentInstrument - impl: impl PaymentInstrumentCardExpiryDate - impl: impl PaymentInstrumentCardIssuer Add: - enum: pub::PaymentOutcome - enum: pub::RefundOutcome **crates/router/src/connector/worldpay/transformers.rs** Modify existing code **crates/router/src/core/fraud_check/flows/transaction_flow.rs** Modify existing code **crates/router/src/core/payments/operations/payment_response.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Modify existing code **crates/router/src/core/payments/types.rs** Modify existing code **crates/router/src/core/refunds.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/db/address.rs** Modify existing code **crates/router/src/db/capture.rs** Modify existing code **crates/router/src/db/customers.rs** Modify existing code **crates/router/src/db/mandate.rs** Modify existing code **crates/router/src/db/payment_method.rs** Modify existing code **crates/router/src/db/refund.rs** Modify existing code **crates/router/src/db/reverse_lookup.rs** Modify existing code **crates/router/src/services/kafka/refund.rs** Modify existing code **crates/router/src/services/kafka/refund_event.rs** Modify existing code **crates/router/src/types/api.rs** Modify existing code **crates/router/src/types/storage/payment_attempt.rs** Modify existing code **crates/router/src/types/transformers.rs** Modify existing code **crates/router/src/utils/user/sample_data.rs** Modify existing code **crates/router/tests/connectors/worldpay.rs** Modify existing code **crates/storage_impl/src/lookup.rs** Modify existing code **crates/storage_impl/src/payments/payment_attempt.rs** Modify existing code **crates/storage_impl/src/payments/payment_intent.rs** Modify existing code **crates/storage_impl/src/payouts/payout_attempt.rs** Modify existing code **crates/storage_impl/src/payouts/payouts.rs** Modify existing code **crates/storage_impl/src/redis/kv_store.rs** Modify existing code
{"issue_number": 6116, "pr_number": 6109, "commits_count": 1, "files_changed": 30, "response_length": 6031, "file_count": 47, "needs_breakdown": true}
[REFACTOR] Worldpay payments integration ### Feature Description WorldPay payments integration currently makes use of modular APIs which gives more control over the integration. This approach is not best compatible with HyperSwitch due to WP's 3DS flows - which requires sending PAN (card numbers) in multiple places. For `on_session` transactions, this would contribute to the added complexity since data is not stored in such transactions (or stored for ~15mins in redis cache). Migrating to WP's standard payments API follows payment resource creation in an uniform way. ### Possible Implementation Migrate from modular APIs [[ref](https://developer.worldpay.com/products/access/card-payments)] to standard payment APIs [[ref](https://developer.worldpay.com/products/access/payments/openapi)]. ### Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? Yes, I am willing to submit a PR!
<think> PR Context: - Title: fix(connector): [Worldpay] use 4 digit expiry year - Merged: 2024-11-19T15:34:37Z - Files changed: 3 files - Commits: 2 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Described in #6316 point # 7 ### 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. Fo </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(connector): [Worldpay] use 4 digit expiry year (#6543) Files to modify: **crates/hyperswitch_connectors/src/connectors/worldpay/transformers.rs** Modify existing code **crates/hyperswitch_connectors/src/utils.rs** Add: - function: private::get_expiry_year_as_4_digit_i32
{"issue_number": 6316, "pr_number": 6543, "commits_count": 1, "files_changed": 3, "response_length": 1068, "file_count": 4, "needs_breakdown": false}
[BUG] DB constraints for events table ### Bug Description `idempotent_event_id` column is a combination of `payment_id` and the `event_type`. Length of this field in DB can be a maximum of 64 characters. However, since `payment_id` can also be 64 characters, the resulting `idempotent_event_id` can easily exceed 64 characters leading to inconsistent behavior in the flows. Currently, this is breaking outgoing webhooks flow. ### Expected Behavior Outgoing webhooks flow should succeed. ### Actual Behavior Outgoing webhooks flow breaks due to DB constraints. ``` { "message": "[INCOMING_WEBHOOKS_CORE - EVENT] Incoming webhook flow failed", "extra": { "error": "{\"error\":{\"type\":\"router_error\",\"code\":\"WE_03\",\"message\":\"There was some issue processing the webhook\"}}\\n├╴at crates/router/src/core/webhooks/outgoing.rs:196:18\\n├╴Failed to insert event in events table\\n├╴Incoming webhook flow for payments failed\\n│\\n╰─▶ DatabaseError: An unknown error occurred\\n ├╴at /router/crates/diesel_models/src/query/generics.rs:89:36\\n ├╴Error while inserting EventNew { event_id: \"evt_01979b2125017d93bb4d846d42979839\", event_type: PaymentAuthorized, event_class: Payments, is_webhook_notified: false, primary_object_id: \"AFR_202506237e491a4f-1bd8-4d97-a9a6-a2f86832bc79\", primary_object_type: PaymentDetails, created_at: 2025-06-23 4:52:10.113410262, merchant_id: Some(MerchantId(\"merchant_1741787326\")), business_profile_id: Some(ProfileId(\"pro_r3uCseg4NT35RBFpmUPA\")), primary_object_created_at: Some(2025-06-23 4:51:14.154239), idempotent_event_id: Some(\"AFR_202506237e491a4f-1bd8-4d97-a9a6-a2f86832bc79_payment_authorized\"), initial_attempt_id: Some(\"evt_01979b2125017d93bb4d846d42979839\"), request: Some(Encryption { inner: *** Encrypted data of length 7223 bytes *** }), response: None, delivery_attempt: Some(InitialAttempt), metadata: Some(Payment { payment_id: PaymentId(\"AFR_202506237e491a4f-1bd8-4d97-a9a6-a2f86832bc79\") }), is_overall_delivery_successful: Some(false) }\\n │\\n ╰─▶ value too long for type character varying(64)\\n ╰╴at /router/crates/diesel_models/src/query/generics.rs:89:22\\n ╰╴at crates/router/src/db/events.rs:129:30" } } ``` ### Steps To Reproduce -- ### Context For The Bug -- ### Environment -- ### Have you spent some time checking if this bug has been raised before? - [x] I checked and didn't find a similar issue ### Have you read the Contributing Guidelines? - [x] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? None
<think> PR Context: - Title: fix(webhooks): add idempotent_event_id generation using URL-safe Base64 (no padding) and SHA256 digest - Merged: 2025-09-22T08:30:21Z - Files changed: 7 files - Commits: 7 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This change updates the idempotent_event_id generation to first hash the base string with SHA256 and then encode it using URL-safe Base64 without padding. By doing this, the generated IDs are guaranteed to be short and deterministic, ensuring </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(webhooks): add idempotent_event_id generation using URL-safe Base64 (no padding) and SHA256 dige Files to modify: **crates/common_utils/src/consts.rs** Modify existing code **crates/router/src/core/errors.rs** Modify existing code **crates/router/src/core/webhooks/outgoing.rs** Modify existing code **crates/router/src/core/webhooks/outgoing_v2.rs** Modify existing code **crates/router/src/core/webhooks/utils.rs** Modify existing code **crates/router/src/core/webhooks/webhook_events.rs** Modify existing code **crates/router/src/workflows/outgoing_webhook_retry.rs** Modify existing code
{"issue_number": 8460, "pr_number": 9405, "commits_count": 1, "files_changed": 7, "response_length": 1452, "file_count": 9, "needs_breakdown": false}
fix(payments_list): handle same payment/attempt IDs for different merchants The query planner was applying the merchant_id filter before the join operation, which caused incorrect results when different merchants had the same payment_id or attempt_id. This prematurely filtered out valid rows from the payment_attempt table that had matching payment_id or attempt_id but a different merchant_id.
<think> PR Context: - Title: fix(payments_list): handle same payment/attempt ids for different merchants - Merged: 2024-12-24T13:29:37Z - Files changed: 1 files - Commits: 4 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Changed the query to apply the merchant_id filter after the join. This ensures valid rows aren’t excluded too early and fixes an issue where **payments with the same IDs but different merchants** were being handled incorrectly. ### Additional Changes - [ ] This PR modifies the A </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(payments_list): handle same payment/attempt ids for different merchants (#6917) Files to modify: **crates/storage_impl/src/payments/payment_intent.rs** Modify existing code
{"issue_number": 6916, "pr_number": 6917, "commits_count": 1, "files_changed": 1, "response_length": 988, "file_count": 4, "needs_breakdown": false}
[REFACTOR] handle payment method duplication in payouts Currently, when same payment method is saved in payouts, duplication logic is not handled. Locker returns `duplication_check` based on which duplication of payment methods has to be handled in Hyperswitch. This issue similar to https://github.com/juspay/hyperswitch/issues/3147
<think> PR Context: - Title: fix(locker): handle card duplication in payouts flow - Merged: 2024-04-05T07:03:32Z - Files changed: 3 files - Commits: 5 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Explained in #3950 ### 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 </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(locker): handle card duplication in payouts flow (#4013) Co-authored-by: hyperswitch-bot[bot] <1 Files to modify: **crates/router/src/core/payment_methods/transformers.rs** Add: - function: pub::update_requestor_card_reference - impl: impl StoreLockerReq<'_> **crates/router/src/core/payouts.rs** Modify existing code **crates/router/src/core/payouts/helpers.rs** Modify existing code
{"issue_number": 3950, "pr_number": 4013, "commits_count": 1, "files_changed": 3, "response_length": 1191, "file_count": 5, "needs_breakdown": false}
feat: Add config to force 2FA for users Currently 2FA is skippable in all the environments. We need to force 2FA in prod later at some point, so there should be config to which forces 2FA is enabled.
<think> PR Context: - Title: feat(users): Add `force_two_factor_auth` environment variable - Merged: 2024-11-05T14:59:29Z - Files changed: 10 files - Commits: 5 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR will add force 2fa environment variable. When enabled it will force users to complete 2FA to access the control center. ### Additional Changes - [x] This PR modifies the API contract - [ ] This PR modifies the database schema - </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(users): Add `force_two_factor_auth` environment variable (#6466) Files to modify: **crates/api_models/src/user.rs** Modify existing code **crates/router/src/configs/settings.rs** Modify existing code **crates/router/src/core/user.rs** Modify existing code
{"issue_number": 4774, "pr_number": 6466, "commits_count": 1, "files_changed": 10, "response_length": 1065, "file_count": 5, "needs_breakdown": false}
docs(openapi): document path parameters for API keys endpoints ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> This PR documents the path parameters added to the API keys endpoints in #600. ## 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 its an obvious bug or documentation fix that will have little conversation). --> Documenting the path parameters correctly makes it easier for users to try out our APIs via the SwaggerUI preview. ## 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)? --> Generated the OpenAPI specification locally, tested the rendered Swagger UI preview. ## 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 submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: Release v0.5.0 - Merged: 2023-03-21T10:02:11Z - Files changed: 30 files - Commits: 30 commits Implementation approach: # 0.5.0 (2023-03-21) ## Build System / Dependencies * **deps:** update deps (#734) (16bc886c) ## Chores * **merchant_account:** remove `api_key` field (#713) (230fcdd4) * **config:** move connector base URLs under the `[connectors]` table (#723) (df8c8b5a) * address Rust 1.68 clippy lints (#728) (1ffabb40) ## Continuous Integration * **release:** specify `fetch-depth` for code checkout and use official Docker GitHub actions (#722) (c451368f) ## Documentation Changes </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** Release v0.5.0 (#789) Co-authored-by: Narayan Bhat <[email protected] Files to modify: **connector-template/mod.rs** Add: - function: private::get_headers - function: private::get_content_type - function: private::get_url - function: private::get_request_body - function: private::get_error_response - impl: impl api::Payment for project - impl: impl api::PaymentSession for project - impl: impl api::ConnectorAccessToken for project - impl: impl api::PreVerify for project - impl: impl api::PaymentAuthorize for project - impl: impl api::PaymentSync for project - impl: impl api::PaymentCapture for project - impl: impl api::PaymentVoid for project - impl: impl api::Refund for project - impl: impl api::RefundExecute for project - impl: impl api::RefundSync for project **connector-template/test.rs** Add: - function: private::get_default_payment_info **connector-template/transformers.rs** Modify existing code **crates/api_models/src/admin.rs** Remove: - struct: pub::CreateMerchantAccount Add: - struct: pub::MerchantAccountCreate - struct: pub::MerchantAccountUpdate - struct: pub::PaymentMethodsEnabled - struct: pub::AcceptedCurrencies **crates/api_models/src/customers.rs** Modify existing code **crates/api_models/src/enums.rs** Remove: - enum: pub::PaymentMethodSubType Add: - enum: pub::PaymentExperience - enum: pub::PaymentMethodType - enum: pub::BankNames - enum: pub::CardNetwork **crates/api_models/src/errors/actix.rs** Modify existing code **crates/api_models/src/errors/types.rs** Modify existing code **crates/api_models/src/payment_methods.rs** Remove: - struct: pub::CreatePaymentMethod Add: - function: pub::new - struct: pub::PaymentMethodCreate - struct: pub::CardNetworkTypes - struct: pub::ResponsePaymentMethodTypes - struct: pub::ResponsePaymentMethodsEnabled - struct: pub::ResponsePaymentMethodIntermediate - struct: pub::RequestPaymentMethodTypes - struct: pub::PaymentMethodListRequest - impl: impl ResponsePaymentMethodIntermediate **crates/api_models/src/payments.rs** Remove: - enum: pub::KlarnaIssuer - enum: pub::AffirmIssuer - enum: pub::AfterpayClearpayIssuer Add: - function: private::from - struct: pub::BankData - struct: pub::BankCodeInformation - struct: pub::ConnectorCode - struct: pub::BankCodeResponse - struct: pub::SofortBilling - struct: pub::BankRedirectBilling - struct: pub::PaypalRedirection - struct: pub::GooglePayPaymentMethodInfo - struct: pub::PayPalWalletData - struct: pub::GpayTokenizationData - struct: pub::ApplePayWalletData - struct: pub::ApplepayPaymentMethod - enum: pub::PaymentMethodData - enum: pub::AdditionalPaymentData - enum: pub::BankRedirectData - enum: pub::WalletData - impl: impl From<&PaymentMethodData> for AdditionalPaymentData **crates/api_models/src/refunds.rs** Modify existing code **crates/api_models/src/webhooks.rs** Add: - struct: pub::IncomingWebhookRequestDetails - trait: pub::OutgoingWebhookType - impl: impl OutgoingWebhookType for OutgoingWebhook **crates/common_utils/src/crypto.rs** Add: - function: private::generate_digest - function: private::verify_signature - function: private::generate_digest - function: private::test_md5_digest - function: private::test_md5_verify_signature - struct: pub::Sha256 - struct: pub::Md5 - impl: impl GenerateDigest for Md5 - impl: impl VerifySignature for Md5 - impl: impl GenerateDigest for Sha256 **crates/common_utils/src/custom_serde.rs** Modify existing code **crates/common_utils/src/ext_traits.rs** Add: - function: private::parse_struct **crates/common_utils/src/lib.rs** Add: - function: pub::date_as_yyyymmddhhmmss - function: pub::date_as_yyyymmddthhmmssmmmz **crates/common_utils/src/pii.rs** Modify existing code **crates/drainer/src/errors.rs** Modify existing code **crates/drainer/src/metrics.rs** Modify existing code **crates/masking/src/secret.rs** Add: - function: pub::zip - function: pub::map **crates/masking/tests/basic.rs** Modify existing code **crates/redis_interface/src/errors.rs** Modify existing code **crates/redis_interface/src/lib.rs** Add: - function: private::deref - function: pub::new - function: private::subscribe - function: private::publish - function: private::on_message - struct: pub::RedisClient - trait: pub::PubSubInterface - impl: impl std::ops::Deref for RedisClient - impl: impl RedisClient - impl: impl PubSubInterface for RedisConnectionPool **crates/router/src/cache.rs** Add: - function: private::as_any - function: private::deref - function: pub::new - function: pub::get_val - function: private::construct_and_get_cache - struct: pub::Cache - trait: pub::Cacheable - impl: impl Cacheable for T - impl: impl std::ops::Deref for Cache - impl: impl Cache - mod: private::cache_tests **crates/router/src/compatibility/stripe.rs** Add: - mod: pub::webhooks **crates/router/src/compatibility/stripe/app.rs** Add: - function: pub::server - struct: pub::Webhooks - impl: impl Webhooks **crates/router/src/compatibility/stripe/customers/types.rs** Remove: - struct: pub::CustomerAddress **crates/router/src/compatibility/stripe/errors.rs** Modify existing code **crates/router/src/compatibility/stripe/payment_intents/types.rs** Add: - function: private::into_stripe_next_action - struct: pub::RedirectUrl - struct: pub::StripeNextAction **crates/router/src/compatibility/stripe/refunds/types.rs** Modify existing code **crates/router/src/compatibility/stripe/setup_intents/types.rs** Modify existing code **crates/router/src/compatibility/stripe/webhooks.rs** Add: - function: private::from - function: private::from - function: private::get_id - struct: pub::StripeOutgoingWebhook - enum: pub::StripeWebhookObject - impl: impl api::OutgoingWebhookType for StripeOutgoingWebhook - impl: impl From<api::OutgoingWebhook> for StripeOutgoingWebhook - impl: impl From<api::OutgoingWebhookContent> for StripeWebhookObject - impl: impl StripeWebhookObject **crates/router/src/configs/defaults.rs** Modify existing code **crates/router/src/configs/settings.rs** Add: - function: private::string_set_deser - function: private::currency_set_deser - function: private::bank_vec_deser - struct: pub::BankRedirectConfig - struct: pub::ConnectorBankNames - struct: pub::BanksVector - struct: pub::ConnectorFilters - struct: pub::PaymentMethodFilters - struct: pub::CurrencyCountryFilter - struct: pub::ApiKeys - struct: pub::Kms - enum: pub::PaymentMethodFilterKey - enum: pub::LockerSetup **crates/router/src/configs/validations.rs** Remove: - function: pub::validate - impl: impl super::settings::Jwekey Add: - function: pub::validate - function: pub::validate - impl: impl super::settings::ApiKeys - impl: impl super::settings::Kms **crates/router/src/connector.rs** Add: - mod: pub::airwallex - mod: pub::bambora - mod: pub::bluesnap - mod: pub::dlocal - mod: pub::multisafepay - mod: pub::nuvei - mod: pub::trustpay - mod: pub::mollie **crates/router/src/connector/aci.rs** Remove: - impl: impl services::ConnectorRedirectResponse for Aci **crates/router/src/connector/aci/transformers.rs** Modify existing code **crates/router/src/connector/adyen.rs** Modify existing code **crates/router/src/connector/adyen/transformers.rs** Add: - function: private::try_from - function: private::get_bank_redirect_specific_payment_data - function: private::from - struct: pub::AdyenPaymentRequest - struct: pub::BankRedirectionWithIssuer - struct: pub::AdyenTestBankNames - enum: pub::WebhookEventCode - impl: impl From<WebhookEventCode> for IncomingWebhookEvent **crates/router/src/connector/airwallex.rs** Add: - function: private::build_headers - function: private::id - function: private::common_get_content_type - function: private::base_url - function: private::build_error_response - function: private::get_url - function: private::get_headers - 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::execute_pretasks - 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::handle_response - function: private::build_request - 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_source_verification_algorithm - function: private::get_webhook_source_verification_signature - function: private::get_webhook_source_verification_message - function: private::get_webhook_source_verification_merchant_secret - function: private::get_webhook_object_reference_id - function: private::get_webhook_event_type - function: private::get_webhook_resource_object - struct: pub::Airwallex - impl: impl ConnectorCommonExt<Flow, Request, Response> for Airwallex - impl: impl ConnectorCommon for Airwallex - impl: impl api::Payment for Airwallex - impl: impl api::PreVerify for Airwallex - impl: impl ConnectorIntegration<api::Verify, types::VerifyRequestData, types::PaymentsResponseData> for Airwallex - impl: impl api::ConnectorAccessToken for Airwallex - impl: impl ConnectorIntegration<api::AccessTokenAuth, types::AccessTokenRequestData, types::AccessToken> for Airwallex - impl: impl ConnectorIntegration< api::AuthorizeSessionToken, types::AuthorizeSessionTokenData, types::PaymentsResponseData, > for Airwallex - impl: impl api::PaymentAuthorize for Airwallex - impl: impl ConnectorIntegration<api::Authorize, types::PaymentsAuthorizeData, types::PaymentsResponseData> for Airwallex - impl: impl api::PaymentSync for Airwallex - impl: impl ConnectorIntegration<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> for Airwallex - impl: impl api::PaymentCapture for Airwallex - impl: impl ConnectorIntegration<api::Capture, types::PaymentsCaptureData, types::PaymentsResponseData> for Airwallex - impl: impl api::PaymentSession for Airwallex - impl: impl ConnectorIntegration<api::Session, types::PaymentsSessionData, types::PaymentsResponseData> for Airwallex - impl: impl api::PaymentVoid for Airwallex - impl: impl ConnectorIntegration<api::Void, types::PaymentsCancelData, types::PaymentsResponseData> for Airwallex - impl: impl api::Refund for Airwallex - impl: impl api::RefundExecute for Airwallex - impl: impl api::RefundSync for Airwallex - impl: impl ConnectorIntegration<api::Execute, types::RefundsData, types::RefundsResponseData> for Airwallex - impl: impl ConnectorIntegration<api::RSync, types::RefundsData, types::RefundsResponseData> for Airwallex - impl: impl api::IncomingWebhook for Airwallex - mod: private::transformers **crates/router/src/connector/airwallex/transformers.rs** Add: - function: private::try_from - function: private::try_from - function: private::try_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::AirwallexIntentRequest - struct: pub::AirwallexPaymentsRequest - struct: pub::AirwallexCard - struct: pub::AirwallexCardDetails - struct: pub::AirwallexCardPaymentOptions - struct: pub::AirwallexAuthUpdateResponse - struct: pub::AirwallexPaymentsCaptureRequest - struct: pub::AirwallexPaymentsCancelRequest - struct: pub::AirwallexRedirectFormData - struct: pub::AirwallexPaymentsNextAction - struct: pub::AirwallexPaymentsResponse - struct: pub::AirwallexRefundRequest - struct: pub::RefundResponse - struct: pub::AirwallexWebhookData - struct: pub::AirwallexWebhookDataResource - struct: pub::AirwallexWebhookObjectResource - struct: pub::AirwallexErrorResponse - enum: pub::AirwallexPaymentMethod - enum: pub::AirwallexPaymentType - enum: pub::AirwallexPaymentOptions - enum: pub::AirwallexPaymentStatus - enum: pub::RefundStatus - impl: impl TryFrom<&types::PaymentsAuthorizeSessionTokenRouterData> for AirwallexIntentRequest - impl: impl TryFrom<&types::PaymentsAuthorizeRouterData> for AirwallexPaymentsRequest - impl: impl TryFrom<types::ResponseRouterData<F, AirwallexAuthUpdateResponse, T, types::AccessToken>> for types::RouterData<F, T, types::AccessToken> - impl: impl TryFrom<&types::PaymentsCaptureRouterData> for AirwallexPaymentsCaptureRequest - impl: impl TryFrom<&types::PaymentsCancelRouterData> for AirwallexPaymentsCancelRequest - impl: impl From<AirwallexPaymentStatus> for enums::AttemptStatus - impl: impl TryFrom<types::ResponseRouterData<F, AirwallexPaymentsResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<&types::RefundsRouterData<F>> for AirwallexRefundRequest - impl: impl From<RefundStatus> for enums::RefundStatus - impl: impl TryFrom<types::RefundsResponseRouterData<api::Execute, RefundResponse>> for types::RefundsRouterData<api::Execute> - impl: impl TryFrom<types::RefundsResponseRouterData<api::RSync, RefundResponse>> for types::RefundsRouterData<api::RSync> **crates/router/src/connector/applepay.rs** Remove: - impl: impl services::ConnectorRedirectResponse for Applepay **crates/router/src/connector/applepay/transformers.rs** Modify existing code **crates/router/src/connector/authorizedotnet.rs** Remove: - impl: impl services::ConnectorRedirectResponse for Authorizedotnet **crates/router/src/connector/authorizedotnet/transformers.rs** Modify existing code **crates/router/src/connector/bambora.rs** Add: - function: private::build_headers - function: private::id - 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::get_error_response - function: private::handle_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::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: pub::get_payment_flow - struct: pub::Bambora - impl: impl ConnectorCommonExt<Flow, Request, Response> for Bambora - impl: impl ConnectorCommon for Bambora - impl: impl api::Payment for Bambora - impl: impl api::PreVerify for Bambora - impl: impl ConnectorIntegration<api::Verify, types::VerifyRequestData, types::PaymentsResponseData> for Bambora - impl: impl api::PaymentVoid for Bambora - impl: impl ConnectorIntegration<api::Void, types::PaymentsCancelData, types::PaymentsResponseData> for Bambora - impl: impl api::ConnectorAccessToken for Bambora - impl: impl ConnectorIntegration<api::AccessTokenAuth, types::AccessTokenRequestData, types::AccessToken> for Bambora - impl: impl api::PaymentSync for Bambora - impl: impl ConnectorIntegration<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> for Bambora - impl: impl api::PaymentCapture for Bambora - impl: impl ConnectorIntegration<api::Capture, types::PaymentsCaptureData, types::PaymentsResponseData> for Bambora - impl: impl api::PaymentSession for Bambora - impl: impl ConnectorIntegration<api::Session, types::PaymentsSessionData, types::PaymentsResponseData> for Bambora - impl: impl api::PaymentAuthorize for Bambora - impl: impl ConnectorIntegration<api::Authorize, types::PaymentsAuthorizeData, types::PaymentsResponseData> for Bambora - impl: impl api::Refund for Bambora - impl: impl api::RefundExecute for Bambora - impl: impl api::RefundSync for Bambora - impl: impl ConnectorIntegration<api::Execute, types::RefundsData, types::RefundsResponseData> for Bambora - impl: impl ConnectorIntegration<api::RSync, types::RefundsData, types::RefundsResponseData> for Bambora - impl: impl api::IncomingWebhook for Bambora - mod: private::transformers **crates/router/src/connector/bambora/transformers.rs** Add: - function: private::try_from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::str_or_i32 - function: private::try_from - function: private::try_from - function: private::from - function: private::try_from - function: private::try_from - struct: pub::BamboraCard - struct: pub::ThreeDSecure - struct: pub::Browser - struct: pub::BamboraPaymentsRequest - struct: pub::BamboraAuthType - struct: pub::BamboraPaymentsResponse - struct: pub::CardData - struct: pub::AvsObject - struct: pub::AddressData - struct: pub::CustomData - struct: pub::AdjustedBy - struct: pub::Links - struct: pub::BamboraPaymentsCaptureRequest - struct: pub::BamboraRefundRequest - struct: pub::RefundResponse - struct: pub::BamboraErrorResponse - struct: pub::CardError - struct: pub::AVSDetails - struct: pub::ErrorDetail - struct: pub::CardValidation - enum: pub::PaymentFlow - enum: private::StrOrI32 - enum: pub::PaymentMethod - enum: pub::RefundStatus - impl: impl TryFrom<&types::PaymentsAuthorizeRouterData> for BamboraPaymentsRequest - impl: impl TryFrom<&types::PaymentsCancelRouterData> for BamboraPaymentsRequest - impl: impl TryFrom<&types::ConnectorAuthType> for BamboraAuthType - impl: impl TryFrom<( types::ResponseRouterData<F, BamboraPaymentsResponse, T, types::PaymentsResponseData>, PaymentFlow, )> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<&types::PaymentsCaptureRouterData> for BamboraPaymentsCaptureRequest - impl: impl TryFrom<&types::RefundsRouterData<F>> for BamboraRefundRequest - impl: impl From<RefundStatus> for enums::RefundStatus - impl: impl TryFrom<types::RefundsResponseRouterData<api::Execute, RefundResponse>> for types::RefundsRouterData<api::Execute> - impl: impl TryFrom<types::RefundsResponseRouterData<api::RSync, RefundResponse>> for types::RefundsRouterData<api::RSync> **crates/router/src/connector/bluesnap.rs** Add: - function: private::build_headers - function: private::id - 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::get_error_response - function: private::handle_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::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_source_verification_algorithm - function: private::get_webhook_source_verification_signature - function: private::get_webhook_source_verification_message - function: private::get_webhook_source_verification_merchant_secret - function: private::verify_webhook_source - function: private::get_webhook_object_reference_id - function: private::get_webhook_event_type - function: private::get_webhook_resource_object - struct: pub::Bluesnap - impl: impl ConnectorCommonExt<Flow, Request, Response> for Bluesnap - impl: impl ConnectorCommon for Bluesnap - impl: impl api::Payment for Bluesnap - impl: impl api::PreVerify for Bluesnap - impl: impl ConnectorIntegration<api::Verify, types::VerifyRequestData, types::PaymentsResponseData> for Bluesnap - impl: impl api::PaymentVoid for Bluesnap - impl: impl ConnectorIntegration<api::Void, types::PaymentsCancelData, types::PaymentsResponseData> for Bluesnap - impl: impl api::ConnectorAccessToken for Bluesnap - impl: impl ConnectorIntegration<api::AccessTokenAuth, types::AccessTokenRequestData, types::AccessToken> for Bluesnap - impl: impl api::PaymentSync for Bluesnap - impl: impl ConnectorIntegration<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> for Bluesnap - impl: impl api::PaymentCapture for Bluesnap - impl: impl ConnectorIntegration<api::Capture, types::PaymentsCaptureData, types::PaymentsResponseData> for Bluesnap - impl: impl api::PaymentSession for Bluesnap - impl: impl ConnectorIntegration<api::Session, types::PaymentsSessionData, types::PaymentsResponseData> for Bluesnap - impl: impl api::PaymentAuthorize for Bluesnap - impl: impl ConnectorIntegration<api::Authorize, types::PaymentsAuthorizeData, types::PaymentsResponseData> for Bluesnap - impl: impl api::Refund for Bluesnap - impl: impl api::RefundExecute for Bluesnap - impl: impl api::RefundSync for Bluesnap - impl: impl ConnectorIntegration<api::Execute, types::RefundsData, types::RefundsResponseData> for Bluesnap - impl: impl ConnectorIntegration<api::RSync, types::RefundsData, types::RefundsResponseData> for Bluesnap - impl: impl api::IncomingWebhook for Bluesnap - mod: private::transformers **crates/router/src/connector/bluesnap/transformers.rs** Add: - function: private::try_from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::foreign_try_from - function: private::from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::try_from - struct: pub::BluesnapPaymentsRequest - struct: pub::Card - struct: pub::BluesnapVoidRequest - struct: pub::BluesnapCaptureRequest - struct: pub::BluesnapAuthType - struct: pub::BluesnapPaymentsResponse - struct: pub::Refund - struct: pub::ProcessingInfoResponse - struct: pub::BluesnapRefundRequest - struct: pub::RefundResponse - struct: pub::BluesnapWebhookBody - struct: pub::BluesnapWebhookObjectEventType - struct: pub::BluesnapWebhookObjectResource - struct: pub::ErrorDetails - struct: pub::BluesnapErrorResponse - struct: pub::BluesnapAuthErrorResponse - enum: pub::PaymentMethodDetails - enum: pub::BluesnapTxnType - enum: pub::BluesnapProcessingStatus - enum: pub::BluesnapErrors - impl: impl TryFrom<&types::PaymentsAuthorizeRouterData> for BluesnapPaymentsRequest - impl: impl TryFrom<&types::PaymentsCancelRouterData> for BluesnapVoidRequest - impl: impl TryFrom<&types::PaymentsCaptureRouterData> for BluesnapCaptureRequest - impl: impl TryFrom<&types::ConnectorAuthType> for BluesnapAuthType - impl: impl ForeignTryFrom<(BluesnapTxnType, BluesnapProcessingStatus)> for enums::AttemptStatus - impl: impl From<BluesnapProcessingStatus> for enums::RefundStatus - impl: impl TryFrom<types::ResponseRouterData<F, BluesnapPaymentsResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<&types::RefundsRouterData<F>> for BluesnapRefundRequest - impl: impl TryFrom<types::RefundsResponseRouterData<api::RSync, BluesnapPaymentsResponse>> for types::RefundsRouterData<api::RSync> - impl: impl TryFrom<types::RefundsResponseRouterData<api::Execute, RefundResponse>> for types::RefundsRouterData<api::Execute> **crates/router/src/connector/braintree.rs** Remove: - function: private::get_flow_type - impl: impl services::ConnectorRedirectResponse for Braintree **crates/router/src/connector/braintree/transformers.rs** Modify existing code **crates/router/src/connector/checkout.rs** Modify existing code **crates/router/src/connector/checkout/transformers.rs** Modify existing code **crates/router/src/connector/cybersource.rs** Remove: - impl: impl services::ConnectorRedirectResponse for Cybersource **crates/router/src/connector/cybersource/transformers.rs** Modify existing code **crates/router/src/connector/dlocal.rs** Add: - function: private::build_headers - function: private::id - function: private::common_get_content_type - function: private::base_url - 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::get_error_response - function: private::handle_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::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::Dlocal - impl: impl api::Payment for Dlocal - impl: impl api::PaymentSession for Dlocal - impl: impl api::ConnectorAccessToken for Dlocal - impl: impl api::PreVerify for Dlocal - impl: impl api::PaymentAuthorize for Dlocal - impl: impl api::PaymentSync for Dlocal - impl: impl api::PaymentCapture for Dlocal - impl: impl api::PaymentVoid for Dlocal - impl: impl api::Refund for Dlocal - impl: impl api::RefundExecute for Dlocal - impl: impl api::RefundSync for Dlocal - impl: impl ConnectorCommonExt<Flow, Request, Response> for Dlocal - impl: impl ConnectorCommon for Dlocal - impl: impl ConnectorIntegration<api::Session, types::PaymentsSessionData, types::PaymentsResponseData> for Dlocal - impl: impl ConnectorIntegration<api::AccessTokenAuth, types::AccessTokenRequestData, types::AccessToken> for Dlocal - impl: impl ConnectorIntegration<api::Verify, types::VerifyRequestData, types::PaymentsResponseData> for Dlocal - impl: impl ConnectorIntegration<api::Authorize, types::PaymentsAuthorizeData, types::PaymentsResponseData> for Dlocal - impl: impl ConnectorIntegration<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> for Dlocal - impl: impl ConnectorIntegration<api::Capture, types::PaymentsCaptureData, types::PaymentsResponseData> for Dlocal - impl: impl ConnectorIntegration<api::Void, types::PaymentsCancelData, types::PaymentsResponseData> for Dlocal - impl: impl ConnectorIntegration<api::Execute, types::RefundsData, types::RefundsResponseData> for Dlocal - impl: impl ConnectorIntegration<api::RSync, types::RefundsData, types::RefundsResponseData> for Dlocal - impl: impl api::IncomingWebhook for Dlocal - mod: private::transformers **crates/router/src/connector/dlocal/transformers.rs** Add: - function: private::try_from - function: private::get_payer_name - function: private::try_from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::get_doc_from_currency - struct: pub::Payer - struct: pub::Card - struct: pub::ThreeDSecureReqData - struct: pub::DlocalPaymentsRequest - struct: pub::DlocalPaymentsSyncRequest - struct: pub::DlocalPaymentsCancelRequest - struct: pub::DlocalPaymentsCaptureRequest - struct: pub::DlocalAuthType - struct: pub::ThreeDSecureResData - struct: pub::DlocalPaymentsResponse - struct: pub::DlocalPaymentsSyncResponse - struct: pub::DlocalPaymentsCaptureResponse - struct: pub::DlocalPaymentsCancelResponse - struct: pub::RefundRequest - struct: pub::RefundResponse - struct: pub::DlocalRefundsSyncRequest - struct: pub::DlocalErrorResponse - enum: pub::PaymentMethodId - enum: pub::PaymentMethodFlow - enum: pub::DlocalPaymentStatus - enum: pub::RefundStatus - impl: impl TryFrom<&types::PaymentsAuthorizeRouterData> for DlocalPaymentsRequest - impl: impl TryFrom<&types::PaymentsSyncRouterData> for DlocalPaymentsSyncRequest - impl: impl TryFrom<&types::PaymentsCancelRouterData> for DlocalPaymentsCancelRequest - impl: impl TryFrom<&types::PaymentsCaptureRouterData> for DlocalPaymentsCaptureRequest - impl: impl TryFrom<&types::ConnectorAuthType> for DlocalAuthType - impl: impl From<DlocalPaymentStatus> for enums::AttemptStatus - impl: impl TryFrom<types::ResponseRouterData<F, DlocalPaymentsResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom< types::ResponseRouterData<F, DlocalPaymentsSyncResponse, T, types::PaymentsResponseData>, > for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom< types::ResponseRouterData<F, DlocalPaymentsCaptureResponse, T, types::PaymentsResponseData>, > for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom< types::ResponseRouterData<F, DlocalPaymentsCancelResponse, T, types::PaymentsResponseData>, > for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<&types::RefundsRouterData<F>> for RefundRequest - impl: impl From<RefundStatus> for enums::RefundStatus - impl: impl TryFrom<types::RefundsResponseRouterData<api::Execute, RefundResponse>> for types::RefundsRouterData<api::Execute> - impl: impl TryFrom<&types::RefundSyncRouterData> for DlocalRefundsSyncRequest - impl: impl TryFrom<types::RefundsResponseRouterData<api::RSync, RefundResponse>> for types::RefundsRouterData<api::RSync> **crates/router/src/connector/fiserv.rs** Remove: - impl: impl services::ConnectorIntegration< api::AccessTokenAuth, types::AccessTokenRequestData, types::AccessToken, > for Fiserv - impl: impl services::ConnectorIntegration< api::Verify, types::VerifyRequestData, types::PaymentsResponseData, > for Fiserv - impl: impl services::ConnectorIntegration< api::Void, types::PaymentsCancelData, types::PaymentsResponseData, > for impl services::ConnectorIntegration<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> Add: - function: private::build_headers - 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::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::get_request_body - function: private::build_request - function: private::handle_response - function: private::get_error_response - impl: impl ConnectorCommonExt<Flow, Request, Response> for Fiserv - impl: impl ConnectorIntegration<api::AccessTokenAuth, types::AccessTokenRequestData, types::AccessToken> for Fiserv - impl: impl ConnectorIntegration<api::Verify, types::VerifyRequestData, types::PaymentsResponseData> for Fiserv - impl: impl ConnectorIntegration<api::Void, types::PaymentsCancelData, types::PaymentsResponseData> for Fiserv - impl: impl ConnectorIntegration<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> **crates/router/src/connector/fiserv/transformers.rs** Remove: - struct: pub::Source - struct: pub::FiservRefundRequest - enum: pub::RefundStatus Add: - enum: pub::Source - enum: pub::TransactionInteractionOrigin - enum: pub::TransactionInteractionEciIndicator - enum: pub::TransactionInteractionPosConditionCode **crates/router/src/connector/globalpay.rs** Remove: - function: private::get_flow_type - impl: impl services::ConnectorRedirectResponse for Globalpay **crates/router/src/connector/globalpay/requests.rs** Modify existing code **crates/router/src/connector/globalpay/transformers.rs** Add: - struct: pub::GlobalPayMeta **crates/router/src/connector/klarna.rs** Remove: - impl: impl services::ConnectorRedirectResponse for Klarna **crates/router/src/connector/klarna/transformers.rs** Modify existing code **crates/router/src/connector/mollie.rs** Add: - function: private::build_headers - function: private::id - function: private::base_url - function: private::get_auth_header - function: private::build_error_response - 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::build_request - 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_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_flow_type - struct: pub::Mollie - impl: impl api::Payment for Mollie - impl: impl api::PaymentSession for Mollie - impl: impl api::ConnectorAccessToken for Mollie - impl: impl api::PreVerify for Mollie - impl: impl api::PaymentAuthorize for Mollie - impl: impl api::PaymentsCompleteAuthorize for Mollie - impl: impl api::PaymentSync for Mollie - impl: impl api::PaymentCapture for Mollie - impl: impl api::PaymentVoid for Mollie - impl: impl api::Refund for Mollie - impl: impl api::RefundExecute for Mollie - impl: impl api::RefundSync for Mollie - impl: impl ConnectorCommonExt<Flow, Request, Response> for Mollie - impl: impl ConnectorCommon for Mollie - impl: impl ConnectorIntegration<api::Session, types::PaymentsSessionData, types::PaymentsResponseData> for Mollie - impl: impl ConnectorIntegration<api::AccessTokenAuth, types::AccessTokenRequestData, types::AccessToken> for Mollie - impl: impl ConnectorIntegration<api::Verify, types::VerifyRequestData, types::PaymentsResponseData> for Mollie - impl: impl ConnectorIntegration<api::Authorize, types::PaymentsAuthorizeData, types::PaymentsResponseData> for Mollie - impl: impl ConnectorIntegration< api::CompleteAuthorize, types::CompleteAuthorizeData, types::PaymentsResponseData, > for Mollie - impl: impl ConnectorIntegration<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> for Mollie - impl: impl ConnectorIntegration<api::Capture, types::PaymentsCaptureData, types::PaymentsResponseData> for Mollie - impl: impl ConnectorIntegration<api::Void, types::PaymentsCancelData, types::PaymentsResponseData> for Mollie - impl: impl ConnectorIntegration<api::Execute, types::RefundsData, types::RefundsResponseData> for Mollie - impl: impl ConnectorIntegration<api::RSync, types::RefundsData, types::RefundsResponseData> for Mollie - impl: impl api::IncomingWebhook for Mollie - impl: impl services::ConnectorRedirectResponse for Mollie - mod: private::transformers **crates/router/src/connector/mollie/transformers.rs** Add: - function: private::try_from - function: private::get_payment_method_for_bank_redirect - function: private::get_payment_method_for_wallet - function: private::get_shipping_details - function: private::get_billing_details - function: private::get_address_details - function: private::from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::from - function: private::try_from - struct: pub::MolliePaymentsRequest - struct: pub::Amount - struct: pub::ApplePayMethodData - struct: pub::IdealMethodData - struct: pub::PaypalMethodData - struct: pub::Address - struct: pub::MolliePaymentsResponse - struct: pub::Link - struct: pub::Links - struct: pub::CardDetails - struct: pub::BankDetails - struct: pub::MollieAuthType - struct: pub::MollieRefundRequest - struct: pub::RefundResponse - struct: pub::ErrorResponse - enum: pub::PaymentMethodData - enum: pub::SequenceType - enum: pub::MolliePaymentStatus - enum: pub::MollieRefundStatus - impl: impl TryFrom<&types::PaymentsAuthorizeRouterData> for MolliePaymentsRequest - impl: impl From<MolliePaymentStatus> for enums::AttemptStatus - impl: impl TryFrom<&types::ConnectorAuthType> for MollieAuthType - impl: impl TryFrom<types::ResponseRouterData<F, MolliePaymentsResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<&types::RefundsRouterData<F>> for MollieRefundRequest - impl: impl From<MollieRefundStatus> for enums::RefundStatus - impl: impl TryFrom<types::RefundsResponseRouterData<T, RefundResponse>> for types::RefundsRouterData<T> **crates/router/src/connector/multisafepay.rs** Add: - function: private::build_headers - function: private::id - 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::build_request - function: private::get_error_response - function: private::handle_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::Multisafepay - impl: impl ConnectorCommonExt<Flow, Request, Response> for Multisafepay - impl: impl ConnectorCommon for Multisafepay - impl: impl api::Payment for Multisafepay - impl: impl api::PreVerify for Multisafepay - impl: impl ConnectorIntegration<api::Verify, types::VerifyRequestData, types::PaymentsResponseData> for Multisafepay - impl: impl api::PaymentVoid for Multisafepay - impl: impl ConnectorIntegration<api::Void, types::PaymentsCancelData, types::PaymentsResponseData> for Multisafepay - impl: impl api::ConnectorAccessToken for Multisafepay - impl: impl ConnectorIntegration<api::AccessTokenAuth, types::AccessTokenRequestData, types::AccessToken> for Multisafepay - impl: impl api::PaymentSync for Multisafepay - impl: impl ConnectorIntegration<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> for Multisafepay - impl: impl api::PaymentCapture for Multisafepay - impl: impl ConnectorIntegration<api::Capture, types::PaymentsCaptureData, types::PaymentsResponseData> for Multisafepay - impl: impl api::PaymentSession for Multisafepay - impl: impl ConnectorIntegration<api::Session, types::PaymentsSessionData, types::PaymentsResponseData> for Multisafepay - impl: impl api::PaymentAuthorize for Multisafepay - impl: impl ConnectorIntegration<api::Authorize, types::PaymentsAuthorizeData, types::PaymentsResponseData> for Multisafepay - impl: impl api::Refund for Multisafepay - impl: impl api::RefundExecute for Multisafepay - impl: impl api::RefundSync for Multisafepay - impl: impl ConnectorIntegration<api::Execute, types::RefundsData, types::RefundsResponseData> for Multisafepay - impl: impl ConnectorIntegration<api::RSync, types::RefundsData, types::RefundsResponseData> for Multisafepay - impl: impl api::IncomingWebhook for Multisafepay - mod: private::transformers **crates/router/src/connector/multisafepay/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::Coupons - struct: pub::Mistercash - struct: pub::Gateways - struct: pub::Settings - struct: pub::PaymentOptions - struct: pub::Browser - struct: pub::Customer - struct: pub::GatewayInfo - struct: pub::DeliveryObject - struct: pub::DefaultObject - struct: pub::TaxObject - struct: pub::CheckoutOptions - struct: pub::Item - struct: pub::ShoppingCart - struct: pub::MultisafepayPaymentsRequest - struct: pub::MultisafepayAuthType - struct: pub::Data - struct: pub::MultisafepayPaymentDetails - struct: pub::MultisafepayPaymentsResponse - struct: pub::MultisafepayRefundRequest - struct: pub::RefundData - struct: pub::RefundResponse - struct: pub::MultisafepayErrorResponse - enum: pub::Type - enum: pub::Gateway - enum: pub::MultisafepayPaymentStatus - enum: pub::RefundStatus - impl: impl From<utils::CardIssuer> for Gateway - impl: impl TryFrom<&types::PaymentsAuthorizeRouterData> for MultisafepayPaymentsRequest - impl: impl TryFrom<&types::ConnectorAuthType> for MultisafepayAuthType - impl: impl From<MultisafepayPaymentStatus> for enums::AttemptStatus - impl: impl TryFrom< types::ResponseRouterData<F, MultisafepayPaymentsResponse, T, types::PaymentsResponseData>, > for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<&types::RefundsRouterData<F>> for MultisafepayRefundRequest - impl: impl From<RefundStatus> for enums::RefundStatus - impl: impl TryFrom<types::RefundsResponseRouterData<api::Execute, RefundResponse>> for types::RefundsRouterData<api::Execute> - impl: impl TryFrom<types::RefundsResponseRouterData<api::RSync, RefundResponse>> for types::RefundsRouterData<api::RSync> **crates/router/src/connector/nuvei.rs** Add: - function: private::build_headers - function: private::id - function: private::common_get_content_type - function: private::base_url - function: private::get_auth_header - 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::get_request_body - function: private::build_request - function: private::get_error_response - function: private::handle_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::execute_pretasks - 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::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_webhook_object_reference_id - function: private::get_webhook_event_type - function: private::get_webhook_resource_object - function: private::get_flow_type - struct: pub::Nuvei - impl: impl ConnectorCommonExt<Flow, Request, Response> for Nuvei - impl: impl ConnectorCommon for Nuvei - impl: impl api::Payment for Nuvei - impl: impl api::PreVerify for Nuvei - impl: impl api::PaymentVoid for Nuvei - impl: impl api::PaymentSync for Nuvei - impl: impl api::PaymentCapture for Nuvei - impl: impl api::PaymentSession for Nuvei - impl: impl api::PaymentAuthorize for Nuvei - impl: impl api::Refund for Nuvei - impl: impl api::RefundExecute for Nuvei - impl: impl api::RefundSync for Nuvei - impl: impl api::PaymentsCompleteAuthorize for Nuvei - impl: impl api::ConnectorAccessToken for Nuvei - impl: impl ConnectorIntegration<api::Verify, types::VerifyRequestData, types::PaymentsResponseData> for Nuvei - impl: impl ConnectorIntegration< api::CompleteAuthorize, types::CompleteAuthorizeData, types::PaymentsResponseData, > for Nuvei - impl: impl ConnectorIntegration<api::Void, types::PaymentsCancelData, types::PaymentsResponseData> for Nuvei - impl: impl ConnectorIntegration<api::AccessTokenAuth, types::AccessTokenRequestData, types::AccessToken> for Nuvei - impl: impl ConnectorIntegration<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> for Nuvei - impl: impl ConnectorIntegration<api::Capture, types::PaymentsCaptureData, types::PaymentsResponseData> for Nuvei - impl: impl ConnectorIntegration<api::Session, types::PaymentsSessionData, types::PaymentsResponseData> for Nuvei - impl: impl ConnectorIntegration<api::Authorize, types::PaymentsAuthorizeData, types::PaymentsResponseData> for Nuvei - impl: impl ConnectorIntegration< api::AuthorizeSessionToken, types::AuthorizeSessionTokenData, types::PaymentsResponseData, > for Nuvei - impl: impl ConnectorIntegration<InitPayment, types::PaymentsAuthorizeData, types::PaymentsResponseData> for Nuvei - impl: impl ConnectorIntegration<api::Execute, types::RefundsData, types::RefundsResponseData> for Nuvei - impl: impl ConnectorIntegration<api::RSync, types::RefundsData, types::RefundsResponseData> for Nuvei - impl: impl api::IncomingWebhook for Nuvei - impl: impl services::ConnectorRedirectResponse for Nuvei - mod: private::transformers **crates/router/src/connector/nuvei/transformers.rs** Add: - function: private::from - function: private::encode_payload - function: private::try_from - function: private::try_from - function: private::try_from - function: private::get_card_info - function: private::try_from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::try_from - function: private::from - function: private::get_payment_status - function: private::try_from - function: private::try_from - function: private::from - function: private::try_from - function: private::try_from - function: private::get_refund_response - struct: pub::NuveiMeta - struct: pub::NuveiSessionRequest - struct: pub::NuveiSessionResponse - struct: pub::NuveiPaymentsRequest - struct: pub::NuveiInitPaymentRequest - struct: pub::NuveiPaymentFlowRequest - struct: pub::NuveiPaymentSyncRequest - struct: pub::PaymentOption - struct: pub::AlternativePaymentMethod - struct: pub::BillingAddress - struct: pub::Card - struct: pub::ExternalToken - struct: pub::ThreeD - struct: pub::BrowserDetails - struct: pub::V2AdditionalParams - struct: pub::DeviceDetails - struct: pub::NuveiRedirectionResponse - struct: pub::NuveiACSResponse - struct: pub::MessageExtension - struct: pub::MessageExtensionData - struct: pub::NuveiAuthType - struct: pub::NuveiPaymentsResponse - struct: pub::FraudDetails - enum: pub::TransactionType - enum: pub::AlternativePaymentMethodType - enum: pub::ExternalTokenProvider - enum: pub::MethodCompletion - enum: pub::PlatformType - enum: pub::LiabilityShift - enum: pub::NuveiPaymentStatus - enum: pub::NuveiTransactionStatus - enum: pub::NuveiTransactionType - impl: impl From<enums::CaptureMethod> for TransactionType - impl: impl TryFrom<&types::PaymentsAuthorizeSessionTokenRouterData> for NuveiSessionRequest - impl: impl TryFrom<types::ResponseRouterData<F, NuveiSessionResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<( &types::RouterData<F, types::PaymentsAuthorizeData, types::PaymentsResponseData>, String, )> for NuveiPaymentsRequest - impl: impl TryFrom<( &types::RouterData<F, types::CompleteAuthorizeData, types::PaymentsResponseData>, String, )> for NuveiPaymentsRequest - impl: impl TryFrom<&types::PaymentsCaptureRouterData> for NuveiPaymentFlowRequest - impl: impl TryFrom<&types::RefundExecuteRouterData> for NuveiPaymentFlowRequest - impl: impl TryFrom<&types::PaymentsSyncRouterData> for NuveiPaymentSyncRequest - impl: impl TryFrom<&types::PaymentsCancelRouterData> for NuveiPaymentFlowRequest - impl: impl TryFrom<&types::ConnectorAuthType> for NuveiAuthType - impl: impl From<NuveiTransactionStatus> for enums::AttemptStatus - impl: impl TryFrom<types::ResponseRouterData<F, NuveiPaymentsResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<types::ResponseRouterData<F, NuveiACSResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl From<NuveiTransactionStatus> for enums::RefundStatus - impl: impl TryFrom<types::RefundsResponseRouterData<api::Execute, NuveiPaymentsResponse>> for types::RefundsRouterData<api::Execute> - impl: impl TryFrom<types::RefundsResponseRouterData<api::RSync, NuveiPaymentsResponse>> for types::RefundsRouterData<api::RSync> **crates/router/src/connector/payu.rs** Remove: - function: private::get_flow_type - impl: impl services::ConnectorRedirectResponse for Payu **crates/router/src/connector/payu/transformers.rs** Modify existing code **crates/router/src/connector/rapyd.rs** Modify existing code **crates/router/src/connector/rapyd/transformers.rs** Modify existing code **crates/router/src/connector/shift4.rs** Remove: - function: private::get_flow_type - impl: impl services::ConnectorRedirectResponse for Shift4 **crates/router/src/connector/shift4/transformers.rs** Modify existing code **crates/router/src/connector/stripe.rs** Modify existing code **crates/router/src/connector/stripe/transformers.rs** Remove: - impl: impl TryFrom<(api::PaymentMethod, enums::AuthenticationType)> for StripePaymentMethodData Add: - function: private::get_bank_name - function: private::try_from - function: private::infer_stripe_bank_redirect_issuer - function: private::try_from - function: private::try_from - function: private::get_bank_specific_data - function: private::create_stripe_payment_method - function: private::deref - function: private::deref - struct: pub::StripeBankRedirectData - struct: pub::PaymentSyncResponse - struct: pub::LastPaymentError - struct: pub::PaymentIntentSyncResponse - struct: pub::StripeBillingAddress - enum: pub::StripeBankName - enum: pub::BankSpecificData - enum: pub::StripeBankNames - impl: impl TryFrom<&api_models::enums::BankNames> for StripeBankNames - impl: impl TryFrom<(&api_models::payments::PayLaterData, StripePaymentMethodType)> for StripeBillingAddress - impl: impl TryFrom<&payments::BankRedirectData> for StripeBillingAddress - impl: impl std::ops::Deref for PaymentSyncResponse - impl: impl std::ops::Deref for PaymentIntentSyncResponse - impl: impl TryFrom<( api::PaymentMethodData, enums::AuthenticationType, StripePaymentMethodType, )> for StripePaymentMethodData **crates/router/src/connector/trustpay.rs** Add: - function: private::build_headers - function: private::id - function: private::common_get_content_type - function: private::base_url - function: private::get_auth_header - function: private::build_error_response - function: private::get_url - function: private::get_content_type - function: private::get_headers - 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::get_error_response - function: private::handle_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_flow_type - struct: pub::Trustpay - impl: impl ConnectorCommonExt<Flow, Request, Response> for Trustpay - impl: impl ConnectorCommon for Trustpay - impl: impl api::Payment for Trustpay - impl: impl api::PreVerify for Trustpay - impl: impl ConnectorIntegration<api::Verify, types::VerifyRequestData, types::PaymentsResponseData> for Trustpay - impl: impl api::PaymentVoid for Trustpay - impl: impl ConnectorIntegration<api::Void, types::PaymentsCancelData, types::PaymentsResponseData> for Trustpay - impl: impl api::ConnectorAccessToken for Trustpay - impl: impl ConnectorIntegration<api::AccessTokenAuth, types::AccessTokenRequestData, types::AccessToken> for Trustpay - impl: impl api::PaymentSync for Trustpay - impl: impl ConnectorIntegration<api::PSync, types::PaymentsSyncData, types::PaymentsResponseData> for Trustpay - impl: impl api::PaymentCapture for Trustpay - impl: impl ConnectorIntegration<api::Capture, types::PaymentsCaptureData, types::PaymentsResponseData> for Trustpay - impl: impl api::PaymentSession for Trustpay - impl: impl ConnectorIntegration<api::Session, types::PaymentsSessionData, types::PaymentsResponseData> for Trustpay - impl: impl api::PaymentAuthorize for Trustpay - impl: impl ConnectorIntegration<api::Authorize, types::PaymentsAuthorizeData, types::PaymentsResponseData> for Trustpay - impl: impl api::Refund for Trustpay - impl: impl api::RefundExecute for Trustpay - impl: impl api::RefundSync for Trustpay - impl: impl ConnectorIntegration<api::Execute, types::RefundsData, types::RefundsResponseData> for Trustpay - impl: impl ConnectorIntegration<api::RSync, types::RefundsData, types::RefundsResponseData> for Trustpay - impl: impl api::IncomingWebhook for Trustpay - impl: impl services::ConnectorRedirectResponse for Trustpay - mod: private::transformers **crates/router/src/connector/trustpay/transformers.rs** Add: - function: private::try_from - function: private::get_trustpay_payment_method - function: private::get_mandatory_fields - function: private::get_card_request_data - function: private::get_bank_redirection_request_data - function: private::try_from - function: private::is_payment_failed - function: private::is_payment_successful - function: private::get_pending_status_based_on_redirect_url - function: private::get_transaction_status - function: private::from - function: private::from - function: private::try_from - function: private::handle_cards_response - function: private::handle_bank_redirects_response - function: private::handle_bank_redirects_error_response - function: private::handle_bank_redirects_sync_response - function: pub::get_trustpay_response - function: private::try_from - function: private::try_from - function: private::try_from - function: private::handle_cards_refund_response - function: private::handle_bank_redirects_refund_response - function: private::handle_bank_redirects_refund_sync_response - function: private::handle_bank_redirects_refund_sync_error_response - function: private::try_from - function: private::get_refund_status - function: private::get_refund_status_from_result_info - struct: pub::TrustpayAuthType - struct: pub::MerchantIdentification - struct: pub::References - struct: pub::Amount - struct: pub::Reason - struct: pub::StatusReasonInformation - struct: pub::BankPaymentInformation - struct: pub::BankPaymentInformationResponse - struct: pub::CallbackURLs - struct: pub::PaymentRequestCards - struct: pub::PaymentRequestBankRedirect - struct: pub::TrustpayMandatoryParams - struct: pub::PaymentsResponseCards - struct: pub::PaymentsResponseBankRedirect - struct: pub::ErrorResponseBankRedirect - struct: pub::ReferencesResponse - struct: pub::SyncResponseBankRedirect - struct: pub::TrustpayAuthUpdateRequest - struct: pub::ResultInfo - struct: pub::TrustpayAuthUpdateResponse - struct: pub::TrustpayAccessTokenErrorResponse - struct: pub::TrustpayRefundRequestCards - struct: pub::TrustpayRefundRequestBankRedirect - struct: pub::CardsRefundResponse - struct: pub::BankRedirectRefundResponse - struct: pub::TrustpayRedirectResponse - struct: pub::Errors - struct: pub::TrustpayErrorResponse - enum: pub::TrustpayPaymentMethod - enum: pub::TrustpayPaymentsRequest - enum: pub::TrustpayBankRedirectPaymentStatus - enum: pub::TrustpayPaymentsResponse - enum: pub::TrustpayRefundRequest - enum: pub::RefundResponse - impl: impl TryFrom<&types::ConnectorAuthType> for TrustpayAuthType - impl: impl TryFrom<&types::PaymentsAuthorizeRouterData> for TrustpayPaymentsRequest - impl: impl From<TrustpayBankRedirectPaymentStatus> for enums::AttemptStatus - impl: impl From<TrustpayBankRedirectPaymentStatus> for enums::RefundStatus - impl: impl TryFrom<types::ResponseRouterData<F, TrustpayPaymentsResponse, T, types::PaymentsResponseData>> for types::RouterData<F, T, types::PaymentsResponseData> - impl: impl TryFrom<&types::RefreshTokenRouterData> for TrustpayAuthUpdateRequest - impl: impl TryFrom<types::ResponseRouterData<F, TrustpayAuthUpdateResponse, T, types::AccessToken>> for types::RouterData<F, T, types::AccessToken> - impl: impl TryFrom<&types::RefundsRouterData<F>> for TrustpayRefundRequest - impl: impl TryFrom<types::RefundsResponseRouterData<F, RefundResponse>> for types::RefundsRouterData<F> **crates/router/src/connector/utils.rs** Remove: - function: private::get_connector_refund_id - function: private::get_card - function: private::get_card_number - trait: pub::RefundsRequestData - impl: impl RefundsRequestData for types::RefundsData Add: - function: private::get_billing - function: private::get_description - function: private::get_billing_address - function: private::get_connector_meta - function: private::get_session_token - function: private::to_connector_meta - function: private::is_three_ds - function: private::get_shipping_address - function: private::is_auto_capture - function: private::get_email - function: private::get_browser_info - function: private::get_card - function: private::is_auto_capture - function: private::get_connector_transaction_id - function: private::get_amount - function: private::get_currency - function: private::get_connector_refund_id - function: private::get_card_expiry_month_year_2_digit_with_delimiter - function: private::get_combined_address_line - function: pub::to_boolean - function: pub::get_connector_meta - function: pub::to_connector_meta - function: pub::to_connector_meta_from_secret - function: private::switch - function: pub::to_string - function: pub::base64_decode - function: pub::to_currency_base_unit_from_optional_amount - function: pub::to_currency_base_unit - function: pub::str_to_f32 - enum: pub::CardIssuer - trait: pub::PaymentsAuthorizeRequestData - trait: pub::PaymentsSyncRequestData - trait: pub::PaymentsCancelRequestData - trait: pub::RefundsRequestData - impl: impl PaymentsAuthorizeRequestData for types::PaymentsAuthorizeData - impl: impl PaymentsSyncRequestData for types::PaymentsSyncData - impl: impl RefundsRequestData for types::RefundsData - impl: impl common_utils::errors::ErrorSwitch<errors::ConnectorError> for errors::ParsingError **crates/router/src/connector/worldline.rs** Remove: - impl: impl services::ConnectorRedirectResponse for Worldline Add: - function: private::is_endpoint_verification - function: private::get_webhook_source_verification_algorithm - function: private::get_webhook_source_verification_signature - function: private::get_webhook_source_verification_message - function: private::get_webhook_source_verification_merchant_secret - function: private::get_webhook_api_response **crates/router/src/connector/worldline/transformers.rs** Remove: - function: private::get_card_product_id Add: - function: private::try_from - struct: pub::WebhookBody - enum: pub::Gateway - enum: pub::WebhookEvent - impl: impl TryFrom<utils::CardIssuer> for Gateway **crates/router/src/connector/worldpay.rs** Remove: - function: private::get_flow_type - impl: impl services::ConnectorRedirectResponse for Worldpay **crates/router/src/connector/worldpay/requests.rs** Modify existing code **crates/router/src/connector/worldpay/response.rs** Modify existing code **crates/router/src/connector/worldpay/transformers.rs** Remove: - function: private::parse_int **crates/router/src/consts.rs** Modify existing code **crates/router/src/core/admin.rs** Modify existing code **crates/router/src/core/api_keys.rs** Remove: - function: pub::verify_hash - struct: pub::PlaintextApiKey Add: - function: pub::get_hash_key - struct: pub::PlaintextApiKey **crates/router/src/core/customers.rs** Modify existing code **crates/router/src/core/errors.rs** Modify existing code **crates/router/src/core/errors/api_error_response.rs** Modify existing code **crates/router/src/core/errors/utils.rs** Modify existing code **crates/router/src/core/mandate.rs** Modify existing code **crates/router/src/core/payment_methods/cards.rs** Add: - function: pub::get_card_from_locker - function: pub::delete_card_from_locker - function: pub::add_card_hs - function: pub::get_card_from_hs_locker - function: pub::get_card_from_legacy_locker - function: pub::delete_card_from_hs_locker - function: pub::delete_card - function: pub::mock_add_card_hs - function: pub::mock_delete_card_hs - function: private::filter_pm_based_on_config - function: private::card_network_filter - function: private::global_country_currency_filter - function: private::filter_pm_card_network_based - function: private::filter_pm_country_based - function: private::filter_pm_currencies_based **crates/router/src/core/payment_methods/transformers.rs** Remove: - struct: pub::GetCard Add: - function: pub::basilisk_hs_key_id - function: pub::get_dotted_jwe - function: pub::get_dotted_jws - function: pub::get_decrypted_response_payload - function: pub::mk_basilisk_req - function: pub::mk_add_card_response_hs - function: pub::mk_add_card_request - function: pub::mk_get_card_request_hs - function: pub::mk_get_card_response - function: pub::mk_delete_card_request_hs - function: pub::mk_delete_card_response - struct: pub::StoreCardReq - struct: pub::Card - struct: pub::StoreCardResp - struct: pub::StoreCardRespPayload - struct: pub::CardReqBody - struct: pub::RetrieveCardResp - struct: pub::RetrieveCardRespPayload - struct: pub::DeleteCardResp - struct: pub::GetCard **crates/router/src/core/payment_methods/vault.rs** Remove: - impl: impl Vaultable for api::PaymentMethod Add: - function: pub::get_key_id - function: private::get_locker_jwe_keys - function: pub::add_delete_tokenized_data_task - function: pub::start_tokenize_data_workflow - function: pub::get_delete_tokenize_schedule_time - function: pub::retry_delete_tokenize - impl: impl Vaultable for api::PaymentMethodData **crates/router/src/core/payments.rs** Add: - struct: pub::PaymentsRedirectResponseData **crates/router/src/core/payments/access_token.rs** Modify existing code **crates/router/src/core/payments/flows.rs** Add: - mod: pub::complete_authorize_flow **crates/router/src/core/payments/flows/authorize_flow.rs** Add: - function: private::decide_authentication_type **crates/router/src/core/payments/flows/complete_authorize_flow.rs** Add: - function: private::construct_router_data - function: private::decide_flows - function: private::add_access_token - function: pub::decide_flow - impl: impl ConstructFlowSpecificData< api::CompleteAuthorize, types::CompleteAuthorizeData, types::PaymentsResponseData, > for PaymentData<api::CompleteAuthorize> - impl: impl Feature<api::CompleteAuthorize, types::CompleteAuthorizeData> for types::RouterData< api::CompleteAuthorize, types::CompleteAuthorizeData, types::PaymentsResponseData, > - impl: impl types::PaymentsCompleteAuthorizeRouterData **crates/router/src/core/payments/flows/session_flow.rs** Modify existing code **crates/router/src/core/payments/flows/verfiy_flow.rs** Modify existing code **crates/router/src/core/payments/helpers.rs** Add: - function: pub::create_complete_authorize_url **crates/router/src/core/payments/operations.rs** Add: - mod: pub::payment_complete_authorize **crates/router/src/core/payments/operations/payment_complete_authorize.rs** Add: - function: private::get_trackers - function: private::get_or_create_customer_details - function: private::make_pm_data - function: private::add_task_to_process_tracker - function: private::get_connector - function: private::update_trackers - function: private::validate_request - struct: pub::CompleteAuthorize - impl: impl GetTracker<F, PaymentData<F>, api::PaymentsRequest> for CompleteAuthorize - impl: impl Domain<F, api::PaymentsRequest> for CompleteAuthorize - impl: impl UpdateTracker<F, PaymentData<F>, api::PaymentsRequest> for CompleteAuthorize - impl: impl ValidateRequest<F, api::PaymentsRequest> for CompleteAuthorize **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/operations/payment_method_validate.rs** Modify existing code **crates/router/src/core/payments/operations/payment_response.rs** Add: - function: private::update_tracker - impl: impl PostUpdateTracker<F, PaymentData<F>, types::CompleteAuthorizeData> for PaymentResponse **crates/router/src/core/payments/operations/payment_session.rs** Remove: - struct: pub::PaymentMethodEnabled **crates/router/src/core/payments/operations/payment_start.rs** Modify existing code **crates/router/src/core/payments/operations/payment_status.rs** Modify existing code **crates/router/src/core/payments/operations/payment_update.rs** Modify existing code **crates/router/src/core/payments/transformers.rs** Add: - function: private::foreign_from - function: private::try_from - impl: impl ForeignFrom<(storage::PaymentIntent, storage::PaymentAttempt)> for api::PaymentsResponse - impl: impl TryFrom<PaymentData<F>> for types::CompleteAuthorizeData **crates/router/src/core/refunds.rs** Modify existing code **crates/router/src/core/refunds/validator.rs** Modify existing code **crates/router/src/core/utils.rs** Modify existing code **crates/router/src/core/webhooks.rs** Add: - function: private::payments_incoming_webhook_flow **crates/router/src/db/api_keys.rs** Add: - function: private::find_api_key_by_key_id_optional - function: private::find_api_key_by_key_id_optional **crates/router/src/db/cache.rs** Modify existing code **crates/router/src/db/merchant_account.rs** Remove: - function: private::find_merchant_account_by_api_key - function: private::find_merchant_account_by_api_key **crates/router/src/db/merchant_connector_account.rs** Modify existing code **crates/router/src/db/payment_attempt.rs** Modify existing code **crates/router/src/db/refund.rs** Add: - function: private::find_refund_by_merchant_id_connector_refund_id_connector **crates/router/src/db/reverse_lookup.rs** Modify existing code **crates/router/src/db_wrapper.rs** Add: - function: private::get_db_call - function: private::get_db_call - function: private::new - function: private::default - function: private::query_entity - function: pub::make_parallel_db_call - struct: pub::DbCall - struct: pub::EntityResult - enum: pub::PaymentAttemptDbCall - enum: pub::PaymentIntentDbCall - enum: pub::ConnectorResponseDbCall - enum: pub::AddressDbCall - enum: pub::EntityRequest - enum: pub::Entity - trait: pub::QueryEntity - impl: impl PaymentAttemptDbCall - impl: impl PaymentIntentDbCall - impl: impl EntityResult - impl: impl Default for EntityResult - impl: impl QueryEntity for EntityRequest **crates/router/src/lib.rs** Add: - mod: pub::cache **crates/router/src/macros.rs** Modify existing code **crates/router/src/openapi.rs** Add: - function: private::modify - struct: private::SecurityAddon - impl: impl utoipa::Modify for SecurityAddon **crates/router/src/routes/admin.rs** Modify existing code **crates/router/src/routes/api_keys.rs** Modify existing code **crates/router/src/routes/app.rs** Modify existing code **crates/router/src/routes/customers.rs** Modify existing code **crates/router/src/routes/mandates.rs** Modify existing code **crates/router/src/routes/metrics.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/refunds.rs** Modify existing code **crates/router/src/routes/webhooks.rs** Modify existing code **crates/router/src/scheduler/metrics.rs** Modify existing code **crates/router/src/scheduler/types/process_data.rs** Add: - function: private::default - struct: pub::PaymentMethodsPTMapping - impl: impl Default for PaymentMethodsPTMapping **crates/router/src/scheduler/utils.rs** Add: - function: pub::get_pm_schedule_time **crates/router/src/scheduler/workflows.rs** Add: - mod: pub::tokenized_data **crates/router/src/scheduler/workflows/tokenized_data.rs** Add: - function: private::execute_workflow - function: private::execute_workflow - function: private::error_handler - impl: impl ProcessTrackerWorkflow for DeleteTokenizeDataWorkflow **crates/router/src/services.rs** Add: - mod: pub::kms **crates/router/src/services/api.rs** Remove: - impl: impl Authenticate for api_models::payment_methods::ListPaymentMethodRequest Add: - function: private::execute_pretasks - function: private::execute_posttasks - enum: pub::PaymentAction - trait: pub::ConnectorIntegration - impl: impl Authenticate for api_models::payment_methods::PaymentMethodListRequest **crates/router/src/services/api/client.rs** Remove: - enum: private::ProxyType **crates/router/src/services/authentication.rs** Remove: - impl: impl ClientSecretFetch for ListPaymentMethodRequest Add: - impl: impl ClientSecretFetch for PaymentMethodListRequest **crates/router/src/services/encryption.rs** Remove: - function: pub::get_kms_decrypted_key - function: pub::get_kms_decrypted_key - function: pub::get_key_id - struct: pub::KeyHandler - impl: impl KeyHandler **crates/router/src/services/kms.rs** Add: - function: pub::get_kms_client - function: pub::new - function: pub::decrypt - struct: pub::KmsClient - impl: impl KmsClient **crates/router/src/types.rs** Add: - function: private::from - function: private::from - struct: pub::AuthorizeSessionTokenData - struct: pub::CompleteAuthorizeData - impl: impl From<&&mut PaymentsAuthorizeRouterData> for AuthorizeSessionTokenData - impl: impl From<(&&mut RouterData<F1, T1, PaymentsResponseData>, T2)> for RouterData<F2, T2, PaymentsResponseData> **crates/router/src/types/api.rs** Modify existing code **crates/router/src/types/api/admin.rs** Modify existing code **crates/router/src/types/api/mandates.rs** Modify existing code **crates/router/src/types/api/payment_methods.rs** Modify existing code **crates/router/src/types/api/payments.rs** Remove: - function: private::from - impl: impl From<Foreign<storage::PaymentIntent>> for Foreign<PaymentsResponse> Add: - struct: pub::AuthorizeSessionToken - struct: pub::CompleteAuthorize - struct: pub::InitPayment - trait: pub::PaymentsCompleteAuthorize **crates/router/src/types/api/refunds.rs** Modify existing code **crates/router/src/types/api/webhooks.rs** Modify existing code **crates/router/src/types/storage/payment_method.rs** Modify existing code **crates/router/src/types/transformers.rs** Remove: - function: private::from - function: private::foreign_from - function: private::foreign_try_from - function: private::from - struct: pub::Foreign - impl: impl From<T> for Foreign<T> - impl: impl ForeignFrom<F> for T - impl: impl ForeignTryFrom<F> for T - impl: impl From<F<api_enums::RoutingAlgorithm>> for F<storage_enums::RoutingAlgorithm> **crates/router/src/utils.rs** Modify existing code **crates/router/tests/connectors/aci.rs** Modify existing code **crates/router/tests/connectors/adyen.rs** Modify existing code **crates/router/tests/connectors/airwallex.rs** Add: - function: private::get_data - function: private::get_auth_token - function: private::get_name - function: private::get_access_token - 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_card_number - function: private::should_fail_payment_for_empty_card_number - 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::AirwallexTest - impl: impl ConnectorActions for AirwallexTest - impl: impl Connector for AirwallexTest **crates/router/tests/connectors/authorizedotnet.rs** Modify existing code **crates/router/tests/connectors/bambora.rs** Add: - function: private::get_data - function: private::get_auth_token - function: private::get_name - function: private::get_default_payment_authorize_data - 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_sync_refund - function: private::should_fail_payment_for_incorrect_card_number - function: private::should_fail_payment_for_empty_card_number - 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_succeed_for_refund_amount_higher_than_payment_amount - struct: private::BamboraTest - impl: impl ConnectorActions for BamboraTest - impl: impl utils::Connector for BamboraTest **crates/router/tests/connectors/bluesnap.rs** Add: - function: private::get_data - function: private::get_auth_token - function: private::get_name - 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_card_number - function: private::should_fail_payment_for_empty_card_number - 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::BluesnapTest - impl: impl ConnectorActions for BluesnapTest - impl: impl utils::Connector for BluesnapTest **crates/router/tests/connectors/checkout.rs** Modify existing code **crates/router/tests/connectors/connector_auth.rs** Modify existing code **crates/router/tests/connectors/cybersource.rs** Modify existing code **crates/router/tests/connectors/dlocal.rs** Add: - function: private::get_data - function: private::get_auth_token - function: private::get_name - 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_card_number - function: private::should_fail_payment_for_empty_card_number - 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 - function: pub::get_payment_info - struct: private::DlocalTest - impl: impl ConnectorActions for DlocalTest - impl: impl utils::Connector for DlocalTest **crates/router/tests/connectors/fiserv.rs** Remove: - struct: private::Fiserv - impl: impl ConnectorActions for Fiserv Add: - function: private::payment_method_details - function: private::get_default_payment_info - 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_invalid_exp_month - function: private::should_fail_void_payment_for_auto_capture - function: private::should_fail_for_refund_amount_higher_than_payment_amount - struct: private::FiservTest - impl: impl ConnectorActions for FiservTest - impl: impl utils::Connector for FiservTest **crates/router/tests/connectors/globalpay.rs** Modify existing code **crates/router/tests/connectors/main.rs** Add: - mod: private::airwallex - mod: private::bambora - mod: private::bluesnap - mod: private::dlocal - mod: private::mollie - mod: private::multisafepay - mod: private::nuvei - mod: private::trustpay **crates/router/tests/connectors/mollie.rs** Add: - function: private::get_data - function: private::get_auth_token - function: private::get_name - struct: private::MollieTest - impl: impl ConnectorActions for MollieTest - impl: impl utils::Connector for MollieTest **crates/router/tests/connectors/multisafepay.rs** Add: - function: private::get_data - function: private::get_auth_token - function: private::get_name - 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_card_number - function: private::should_fail_payment_for_empty_card_number - 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::MultisafepayTest - impl: impl ConnectorActions for MultisafepayTest - impl: impl utils::Connector for MultisafepayTest **crates/router/tests/connectors/nuvei.rs** Add: - function: private::get_data - function: private::get_auth_token - function: private::get_name - function: private::get_payment_data - 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_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_fail_payment_for_incorrect_card_number - function: private::should_fail_payment_for_empty_card_number - function: private::should_fail_payment_for_incorrect_cvc - function: private::should_fail_payment_for_invalid_exp_month - function: private::should_succeed_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_accept_refund_amount_higher_than_payment_amount - struct: private::NuveiTest - impl: impl ConnectorActions for NuveiTest - impl: impl utils::Connector for NuveiTest **crates/router/tests/connectors/payu.rs** Modify existing code **crates/router/tests/connectors/rapyd.rs** Modify existing code **crates/router/tests/connectors/shift4.rs** Modify existing code **crates/router/tests/connectors/stripe.rs** Modify existing code **crates/router/tests/connectors/trustpay.rs** Add: - function: private::get_data - function: private::get_auth_token - function: private::get_name - function: private::get_default_browser_info - function: private::get_default_payment_authorize_data - function: private::get_default_payment_info - function: private::should_make_payment - function: private::should_sync_auto_captured_payment - function: private::should_refund_auto_captured_payment - function: private::should_sync_refund - function: private::should_fail_payment_for_incorrect_card_number - function: private::should_fail_payment_for_empty_card_number - function: private::should_fail_payment_for_incorrect_expiry_year - struct: private::TrustpayTest - impl: impl ConnectorActions for TrustpayTest - impl: impl utils::Connector for TrustpayTest **crates/router/tests/connectors/utils.rs** Modify existing code **crates/router/tests/connectors/worldline.rs** Modify existing code **crates/router/tests/connectors/worldpay.rs** Modify existing code **crates/router/tests/payments.rs** Modify existing code **crates/router/tests/payments2.rs** Modify existing code **crates/router/tests/utils.rs** Modify existing code **crates/router_derive/src/lib.rs** Add: - function: pub::diesel_enum_derive_string **crates/router_derive/src/macros.rs** Modify existing code **crates/router_derive/src/macros/diesel.rs** Add: - function: pub::diesel_enum_text_derive_inner - enum: private::StorageType **crates/router_derive/src/macros/operation.rs** Modify existing code **crates/router_env/src/lib.rs** Add: - mod: pub::metrics **crates/router_env/src/logger/setup.rs** Modify existing code **crates/router_env/src/logger/types.rs** Modify existing code **crates/router_env/src/metrics.rs** Modify existing code **crates/storage_models/src/api_keys.rs** Add: - function: pub::into_inner - impl: impl HashedApiKey **crates/storage_models/src/customers.rs** Modify existing code **crates/storage_models/src/enums.rs** Remove: - enum: pub::PaymentFlow - enum: pub::PaymentMethodSubType - enum: pub::PaymentMethodType Add: - enum: pub::PaymentMethod - enum: pub::PaymentMethodType - enum: pub::PaymentExperience **crates/storage_models/src/merchant_account.rs** Modify existing code **crates/storage_models/src/merchant_connector_account.rs** Modify existing code **crates/storage_models/src/payment_attempt.rs** Modify existing code **crates/storage_models/src/payment_intent.rs** Modify existing code **crates/storage_models/src/payment_method.rs** Add: - struct: pub::TokenizeCoreWorkflow **crates/storage_models/src/query/api_keys.rs** Add: - function: pub::find_optional_by_hashed_api_key **crates/storage_models/src/query/merchant_account.rs** Remove: - function: pub::find_by_api_key **crates/storage_models/src/query/merchant_connector_account.rs** Modify existing code **crates/storage_models/src/query/refund.rs** Add: - function: pub::find_by_merchant_id_connector_refund_id_connector **crates/storage_models/src/refund.rs** Modify existing code **crates/storage_models/src/schema.rs** Modify existing code
{"issue_number": 702, "pr_number": 789, "commits_count": 1, "files_changed": 30, "response_length": 101056, "file_count": 220, "needs_breakdown": true}
[BUG] Failing unit tests for Routing ### Bug Description Certain unit tests in the `euclid` and `kgraph_utils` crates are failing. **euclid** ``` test dssa::analyzer::tests::test_exhaustive_negation_detection ... FAILED test frontend::dir::test::test_consistent_dir_key_naming ... FAILED ``` **kgraph_utils** ``` test mca::tests::test_sandbox_applepay_bug_usecase ... FAILED ``` ### Expected Behavior All unit tests should pass. ### Actual Behavior Some tests fail owing to being outdated or due to a code discrepancy. ### Steps To Reproduce 1. Clone the main branch 2. Run the unit tests for the `euclid` and `kgraph_utils` crates ### Context For The Bug _No response_ ### Environment Local ### Have you spent some time checking if this bug has been raised before? - [X] I checked and didn't find a similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? Yes, I am willing to submit a PR!
<think> PR Context: - Title: fix(routing/tests): fix unit tests for routing - Merged: 2024-04-24T09:39:37Z - Files changed: 3 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR fixes failing unit tests for routing, either by updating outdated tests, or resolving code discrepancies. See #4437 for more info on failing tests. ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR mod </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(routing/tests): fix unit tests for routing (#4438) Files to modify: **crates/euclid/src/dssa/analyzer.rs** Modify existing code **crates/euclid/src/frontend/dir.rs** Modify existing code **crates/kgraph_utils/src/mca.rs** Modify existing code
{"issue_number": 4437, "pr_number": 4438, "commits_count": 1, "files_changed": 3, "response_length": 1035, "file_count": 5, "needs_breakdown": false}
github: add bug report and feature request issue forms ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> This PR adds bug report and feature request issue forms. ### Additional Changes - [ ] 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 its an obvious bug or documentation fix that will have little conversation). --> Adding issue forms helps keep most bug reports/feature requests uniform, and ensure that all the required information is included by the issue authors. ## 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)? --> N/A. ## Checklist <!-- Put an `x` in the boxes that apply --> - [ ] I formatted the code `cargo +nightly fmt` - [ ] I addressed lints thrown by `cargo clippy` - [ ] I reviewed submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: feat(router): include git commit hash and timestamp in `--version` output - Merged: 2022-11-28T04:49:57Z - Files changed: 8 files - Commits: 5 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates ## Description <!-- Describe your changes in detail --> This PR adds the following two fields of information to the output of `router --version`: - Short git commit hash - Git commit timestamp In addition, the version number in the output is obtained in the below fashion: - If git tags are present in the repository which </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(router): include git commit hash and timestamp in `--version` output (#29) Files to modify: **crates/router/src/build.rs** Add: - function: private::main **crates/router/src/configs/settings.rs** Modify existing code **crates/router_env/src/build.rs** Modify existing code **crates/router_env/src/env.rs** Modify existing code **crates/router_env/src/lib.rs** Add: - mod: pub::vergen **crates/router_env/src/vergen.rs** Add: - function: pub::generate_cargo_instructions
{"issue_number": 20, "pr_number": 29, "commits_count": 1, "files_changed": 8, "response_length": 1311, "file_count": 8, "needs_breakdown": false}
[REFACTOR] : [Stripe] Error Message For Connector Implementation ### :memo: Feature Description - In terms of errors, we are currently throwing a 'not supported' message, which shouldn't be the case as we are yet to decide on the implementation. ### :hammer: Possible Implementation - In order to manage payment methods that are not implemented by Hyperswitch or yet to be implemented, the connector transformers file should make use of the NotImplemented ConnectorError enum variant. - By doing so, we will throw same error message for all the Connector Implementation - You can check this PR for further reference https://github.com/juspay/hyperswitch/pull/2831 :bookmark: Note: All the changes needed should be contained within `hyperswitch/crates/router/src/connector/` ### :package: Have you spent some time checking if this feature request has been raised before? - [X] I checked and didn't find a similar issue ### :package: Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### :sparkles: Are you willing to submit a PR?
<think> PR Context: - Title: refactor(stripe): change NotSupported to NotImplemented error for Stripe - Merged: 2024-03-18T07:00:21Z - Files changed: 1 files - Commits: 1 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Should close #2863 by changing `NotSupported` to `NotImplemented` error for Stripe ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/environment variables <!-- Provid </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** refactor(stripe): change NotSupported to NotImplemented error for Stripe (#3690) Files to modify: **crates/router/src/connector/stripe/transformers.rs** Modify existing code
{"issue_number": 2863, "pr_number": 3690, "commits_count": 1, "files_changed": 1, "response_length": 982, "file_count": 3, "needs_breakdown": false}
refactor(router): add dynamic_routing feature flag in release features ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR will add dynamic_routing in release feature set ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [x] 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). --> ## 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)? --> Feature flag addition can't be tested. ## 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
<think> PR Context: - Title: chore(deps): bump the cargo group across 1 directories with 3 updates - Merged: 2024-01-22T07:23:09Z - Files changed: 11 files - Commits: 1 commits Implementation approach: Bumps the cargo group with 3 updates in the /. directory: [tokio](https://github.com/tokio-rs/tokio), [h2](https://github.com/hyperium/h2) and [rustix](https://github.com/bytecodealliance/rustix). Updates `tokio` from 1.32.0 to 1.35.1 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/tokio-rs/tokio/releases">tokio's releases</a>.</em></p> <blockquote> <h2>Tokio v1.35.1</h2> <h1>1.35.1 (December 19, 2023)</h1> <p>This is a forward part of a change that wa </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 6144, "pr_number": 3409, "commits_count": 0, "files_changed": 11, "response_length": 800, "file_count": 0, "needs_breakdown": false}
refactor(connectors): [Bitpay] PII data masking ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [x] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Mask pii information passed and received in the connector request and response for Bitpay ## Test Case Check if sensitive fields within connector request and response is masked in the click house for Bitpay Sanity test 1. Payment create - card ``` curl --location 'http://localhost:8080/payments' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'api-key: {{api_key}}' \ --data-raw '{ "amount": 2000, "currency": "GBP", "confirm": true, "capture_method": "automatic", "capture_on": "2022-09-10T10:11:12Z", "customer_id": "StripeCustomer", "email": "[email protected]", "name": "John Doe", "phone": "999999999", "phone_country_code": "+65", "description": "Its my first payment request", "authentication_type": "no_three_ds", "return_url": "https://google.com", "billing": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "John", "last_name": "Doe" } }, "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" }, "shipping": { "address": { "line1": "1467", "line2": "Harrison Street", "line3": "Harrison Street", "city": "San Fransico", "state": "California", "zip": "94122", "country": "US", "first_name": "John", "last_name": "Doe" } }, "statement_descriptor_name": "joseph", "statement_descriptor_suffix": "JS", "metadata": { "udf1": "value1", "new_customer": "true", "login_date": "2019-09-10T10:11:12Z" }, "payment_method": "card", "payment_method_data": { "card": { "card_number": "5123456789012346", "card_exp_month": "10", "card_exp_year": "30", "card_holder_name": "Joseph Doe", "card_cvc": "123" } } }' ``` response ``` BitpayPaymentsResponse { data: BitpayPaymentResponseData { url: Some(Url { scheme: "https", cannot_be_a_base: false, username: "", password: None, host: Some(Domain("test.bitpay.com")), port: None, path: "/invoice", query: Some("id=8wNbxWa97mrqBCavAQBmi8"), fragment: None }), status: New, price: 2000, currency: "GBP", amount_paid: 0, invoice_time: Some(1708434493106), rate_refresh_time: Some(1708434493106), expiration_time: Some(1708435393106), current_time: Some(1708434493513), id: "8wNbxWa97mrqBCavAQBmi8", order_id: Some("pay_uE8IRzN7s2e3s4AYLq9N_1"), low_fee_detected: Some(false), display_amount_paid: Some("0"), exception_status: Bool(false), redirect_url: None, refund_address_request_pending: Some(false), merchant_name: Some(*** alloc::string::String ***), token: Some(*** alloc::string::String ***) }, facade: Some("pos/invoice") } ``` In logs check for `topic = "hyperswitch-outgoing-connector-events" ` ## 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 - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: feat(pm_list): add required fields for sofort - Merged: 2024-01-30T09:23:16Z - Files changed: 11 files - Commits: 27 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Resolves [#3704](https://github.com/juspay/hyperswitch-cloud/issues/3704) ### Test Cases 1. Create a sofort payment with mollie with empty payment method object. The payment should succeed. ``` { "amount": 1000, "currency": "EUR", </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(pm_list): add required fields for sofort (#3192) Co-authored-by: hyperswitch-bot[bot] <14852550 Files to modify: **crates/api_models/src/payments.rs** Modify existing code **crates/router/src/configs/defaults.rs** Modify existing code **crates/router/src/connector/aci/transformers.rs** Modify existing code **crates/router/src/connector/adyen/transformers.rs** Modify existing code **crates/router/src/connector/paypal/transformers.rs** Modify existing code **crates/router/src/connector/stripe/transformers.rs** Add: - function: private::get_stripe_sepa_dd_mandate_billing_details
{"issue_number": 3704, "pr_number": 3192, "commits_count": 1, "files_changed": 11, "response_length": 1391, "file_count": 8, "needs_breakdown": false}
fix(router): add validation for all the connector auth type ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description Issue is caused when in any Connector 's `auth_type` we configure the invalid `auth_type` for that particular connector and gets stored in the Db. Thus , whenever we call the Connector Integration we get a 500. ### 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` --> ## How did you test it? <img width="1728" alt="Screenshot 2023-07-25 at 5 33 44 PM" src="https://github.com/juspay/hyperswitch/assets/55580080/0f00aa25-071d-47d3-a826-da28d22cf400"> For the wrong `connector_auth_type` <img width="1728" alt="Screenshot 2023-07-25 at 5 57 06 PM" src="https://github.com/juspay/hyperswitch/assets/55580080/43af662c-1319-4f2d-aa78-21bd857ea5aa"> For the correct `connector_auth_type` ## 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 submitted code - [ ] I added unit tests for my changes where possible - [ ] I added a [CHANGELOG](/CHANGELOG.md) entry if applicable
<think> PR Context: - Title: revert: fix(core): add validation for all the connector auth_type - Merged: 2023-08-04T14:13:51Z - Files changed: 30 files - Commits: 11 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [x] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description This PR reverts the commit of `1cda7ad` (PR #1748 ) and also adds a new implementation for the validation of auth_type ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [ ] This PR modifies application configuration/e </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** revert: fix(core): add validation for all the connector auth_type (#1833) Files to modify: **crates/router/src/connector/aci.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/adyen.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/airwallex.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/authorizedotnet.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/authorizedotnet/transformers.rs** Modify existing code **crates/router/src/connector/bambora.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/bitpay.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/bluesnap.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/boku.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/braintree.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/cashtocode.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/checkout.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/coinbase.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/cryptopay.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/cybersource.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/dlocal.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/dummyconnector.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/fiserv.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/forte.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/globalpay.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/globepay.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/iatapay.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/klarna.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/mollie.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/multisafepay.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/nexinets.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/nmi.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/noon.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/nuvei.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/opayo.rs** Remove: - function: private::validate_auth_type **crates/router/src/connector/opennode.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/payeezy.rs** Remove: - function: private::validate_auth_type **crates/router/src/connector/payme.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/paypal.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/payu.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/powertranz.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/rapyd.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/shift4.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/square.rs** Remove: - function: private::validate_auth_type **crates/router/src/connector/stax.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/stripe.rs** Remove: - function: private::validate_auth_type **crates/router/src/connector/trustpay.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/tsys.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/wise.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/worldline.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/worldline/transformers.rs** Modify existing code **crates/router/src/connector/worldpay.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/connector/zen.rs** Remove: - function: private::validate_auth_type - mod: private::transformers Add: - mod: pub::transformers **crates/router/src/core/admin.rs** Add: - function: pub::validate_auth_type **crates/router/src/routes/admin.rs** Modify existing code **crates/router/src/types/api.rs** Modify existing code
{"issue_number": 1748, "pr_number": 1833, "commits_count": 1, "files_changed": 30, "response_length": 8669, "file_count": 53, "needs_breakdown": true}
[BUG] : [Adyen] Handle redirection response incase of no connector_transaction_id ### Bug Description In Adyen, for certain payment methods that involve redirection, the /payments API call doesn't return a psp_reference (Adyen's transaction ID). In such cases, we need to save the redirectResult field from the redirection response parameter into `encoded_data` field of our payment attempt to facilitate a Psync with proper payment context. However, we have observed that our Psync call lacks context of the Adyen payment because the redirectResult is not stored in the encoded_data ### Expected Behavior Psync for all redirection payments must hit Adyen and retrieve the status of appropriate payment. ### Actual Behavior Psync call has no context of the connector_transaction_id ### Steps To Reproduce Provide an unambiguous set of steps to reproduce this bug. Include code or configuration to reproduce, if relevant. 1.Create a payment with adyen wechatpay 2.Do a Psync call (the payment status remains to be `requires_customer_action` ### Have you spent some time checking if this bug has been raised before? - [X] I checked and didn't find a similar issue ### Have you read the Contributing Guidelines? - [X] I have read the [Contributing Guidelines](https://github.com/juspay/hyperswitch/blob/main/docs/CONTRIBUTING.md) ### Are you willing to submit a PR? None
<think> PR Context: - Title: fix(connector): [adyen] production endpoints and mappings - Merged: 2024-02-29T18:41:57Z - Files changed: 17 files - Commits: 7 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [X] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> - Add production live endpoint for Adyen - Fix webhooks status mapping - Fix redirection data not getting populated in encoded data - Add Live Bank Names for Ideal - Add Currency, Country config for `klarna, ideal, sofort, paypal` ### A </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** fix(connector): [adyen] production endpoints and mappings (#3900) Co-authored-by: hyperswitch-bot[bo Files to modify: **crates/api_models/src/enums.rs** Modify existing code **crates/router/src/connector/adyen.rs** Add: - function: private::build_env_specific_endpoint **crates/router/src/connector/adyen/transformers.rs** Remove: - function: private::from - impl: impl From<CancelStatus> for storage_enums::AttemptStatus Add: - function: private::try_from - function: private::try_from - struct: pub::AdyenConnectorMetadataObject - struct: pub::AdyenBankNames - impl: impl TryFrom<&Option<pii::SecretSerdeValue>> for AdyenConnectorMetadataObject - impl: impl TryFrom<&api_enums::BankNames> for AdyenBankNames<'a> - impl: impl TryFrom<(&api_models::payments::BankRedirectData, Option<bool>)> for AdyenPaymentMethod<'a> **crates/router/src/connector/nuvei/transformers.rs** Modify existing code **crates/router/src/core/admin.rs** Modify existing code **crates/router/src/core/payments/operations/payment_status.rs** Modify existing code
{"issue_number": 3614, "pr_number": 3900, "commits_count": 1, "files_changed": 17, "response_length": 1888, "file_count": 8, "needs_breakdown": false}
Setup for Data services locally targeting clickhouse/ kafka and the relevant features on dashboard
<think> PR Context: - Title: docs(analytics): Add documentation for setting up data services and enabling data features in control center - Merged: 2024-05-28T07:16:23Z - Files changed: 7 files - Commits: 5 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [ ] Enhancement - [ ] Refactoring - [ ] Dependency updates - [x] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> Fixes #4740 - Update `docker-compose.yml` profiles to unfiy them - Add steps in `try_local_system.md` to setup data services - Add additional documentation in `analytics` crate to enable features in `control-center` - update architectur </think> To implement this, you'll need to modify: (No detailed commit information available)
{"issue_number": 4740, "pr_number": 4741, "commits_count": 0, "files_changed": 7, "response_length": 838, "file_count": 0, "needs_breakdown": false}
fix: Ability to change TOTP issuer name depending on the env As of now, the issuer name in TOTP is always "Hyperswitch" independent of env. As TOTP will be present in multiple environments, we need to have different issuer names for all the environments, so that user can easily identify the TOTP.
<think> PR Context: - Title: feat(users): Create config for TOTP Issuer - Merged: 2024-06-03T14:07:38Z - Files changed: 11 files - Commits: 8 commits Implementation approach: ## Type of Change <!-- Put an `x` in the boxes that apply --> - [ ] Bugfix - [ ] New feature - [x] Enhancement - [ ] Refactoring - [ ] Dependency updates - [ ] Documentation - [ ] CI/CD ## Description <!-- Describe your changes in detail --> This PR adds configs for TOTP Issuer (to easily change issuer name of TOTP) ### Additional Changes - [ ] This PR modifies the API contract - [ ] This PR modifies the database schema - [x] This PR modifies application configuration/envi </think> To implement this, you'll need to modify: **Detailed Implementation:** **Commit 1:** feat(users): Create config for TOTP Issuer (#4776) Files to modify: **crates/router/src/configs/settings.rs** Modify existing code **crates/router/src/consts/user.rs** Modify existing code **crates/router/src/core/user.rs** Modify existing code **crates/router/src/utils/user/two_factor_auth.rs** Modify existing code
{"issue_number": 4775, "pr_number": 4776, "commits_count": 1, "files_changed": 11, "response_length": 1106, "file_count": 6, "needs_breakdown": false}