Skip to content

fix(connector): [WorldpayWPG] Add Mastercard in WASM for Payouts#12846

Merged
swangi-kumari merged 3 commits into
mainfrom
update-toml-wpg
Jun 18, 2026
Merged

fix(connector): [WorldpayWPG] Add Mastercard in WASM for Payouts#12846
swangi-kumari merged 3 commits into
mainfrom
update-toml-wpg

Conversation

@Vani-1107

Copy link
Copy Markdown
Contributor

Type of Change

  • Bugfix
  • New feature
  • Enhancement
  • Refactoring
  • Dependency updates
  • Documentation
  • CI/CD

Description

Add Mastercard in WASM for Payouts

Additional Changes

  • This PR modifies the API contract
  • This PR modifies the database schema
  • This PR modifies application configuration/environment variables

Motivation and Context

How did you test it?

Screenshot 2026-06-18 at 6 43 08 PM

Checklist

  • 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

@Vani-1107
Vani-1107 requested a review from a team as a code owner June 18, 2026 13:39
@semanticdiff-com

Copy link
Copy Markdown

Review changes with  SemanticDiff

@Vani-1107 Vani-1107 self-assigned this Jun 18, 2026
@Vani-1107 Vani-1107 added the S-test-ready Status: This PR is ready for cypress-tests label Jun 18, 2026
@github-actions github-actions Bot removed the S-test-ready Status: This PR is ready for cypress-tests label Jun 18, 2026
@Vani-1107 Vani-1107 added the S-test-ready Status: This PR is ready for cypress-tests label Jun 18, 2026

@XyneSpaces XyneSpaces left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Review Summary

This PR adds Mastercard support for Worldpay XML payouts across all environments. The changes are straightforward configuration additions.

Findings

Consistency: The pattern follows the existing Visa configuration exactly - credit and debit entries are correctly paired.

Completeness: Changes applied to all three environment files (development, production, sandbox) consistently.

Questions

  1. WASM Implementation: Have you verified that the WASM/connector code in euclid_wasm can handle Mastercard for worldpayxml_payout? The TOML configs feed into the WASM engine for Control Center display - please confirm the payment method is recognized.

  2. Testing: The PR template indicates no unit tests were added. For a connector configuration change like this, consider:

    • Verifying the connector can actually process Mastercard payouts through Worldpay XML
    • Checking if there are any integration tests in config/deployments/integration_test.toml that should be updated

Suggestion

Consider if other card networks (Amex, Discover, JCB) should also be supported for payouts to achieve parity with the main worldpayxml connector's capabilities.


No blocking issues identified. LGTM pending clarification on WASM validation.

payment_method_type = "google_pay"
[[worldpayxml_payout.credit]]
payment_method_type = "Visa"
[[worldpayxml_payout.credit]]

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Question: Has the WASM layer been validated to recognize Mastercard for worldpayxml_payout? The TOML feeds into euclid_wasm for Control Center connector configuration UI.

payment_method_type = "google_pay"
[[worldpayxml_payout.credit]]
payment_method_type = "Visa"
[[worldpayxml_payout.credit]]

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

ℹ️ Note: Change mirrors development.toml - ensure testing was done in sandbox environment before promoting to production config.

@swangi-kumari
swangi-kumari enabled auto-merge June 18, 2026 14:40
@swangi-kumari swangi-kumari added the A-connector-integration Area: Connector integration label Jun 18, 2026
@XyneSpaces

Copy link
Copy Markdown
Contributor

🤖 Automated PR Review Summary

Reviewed by: XyneSpaces Agent
Timestamp: 2026-06-18 14:40 UTC

Files Changed

  • crates/connector_configs/toml/development.toml (+4 lines)
  • crates/connector_configs/toml/production.toml (+4 lines)
  • crates/connector_configs/toml/sandbox.toml (+4 lines)

Key Findings

Severity Count Description
ℹ️ Info 2 Questions about WASM validation and testing coverage

Overall Assessment

The PR adds Mastercard payment method support for Worldpay XML payouts consistently across all environments. The pattern follows existing Visa configurations correctly.

Status: ✅ Ready to merge after addressing minor questions


This is an automated review. Please address inline comments for specific feedback.

@XyneSpaces XyneSpaces left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Review: WorldpayWPG Mastercard WASM Payout Support

Classification: connector-config · wasm-payouts
Risk Level: Low (configuration-only change)

Summary

Adds Mastercard support for Worldpay XML payout connector across all environments (dev, prod, sandbox).

Findings

⚠️ Verify connector transformer supports Mastercard

File: crates/hyperswitch_connectors/src/connectors/worldpaywpg/transformers.rs

This PR only updates TOML configs. Please verify that the WorldpayWPG connector transformer already handles Mastercard payout requests/responses correctly. The connector code may need updates for:

  • Mastercard-specific error response mapping
  • BIN range validation for payout eligibility

🔍 Nitpick: Inconsistent spacing in TOML

Files: All three TOML files

The added lines use 2-space indentation while surrounding code uses mixed formatting. Consider maintaining consistency:

[[worldpayxml_payout.credit]]
  payment_method_type = "Mastercard"

Verification Checklist

  • Connector transformer tested with Mastercard payout flow
  • Sandbox environment verified with test credentials
  • Error responses properly mapped for Mastercard rejections

Overall Assessment

Configuration change is correct. Ensure the underlying connector implementation already supports Mastercard before merge.

@swangi-kumari
swangi-kumari added this pull request to the merge queue Jun 18, 2026
Merged via the queue into main with commit 380e45b Jun 18, 2026
39 of 42 checks passed
@swangi-kumari
swangi-kumari deleted the update-toml-wpg branch June 18, 2026 16:57
@hyperswitch-bot hyperswitch-bot Bot removed the S-test-ready Status: This PR is ready for cypress-tests label Jun 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-connector-integration Area: Connector integration

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants