Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(connector): [STRIPE] fix stripe mandate #6899

Merged
merged 3 commits into from
Dec 20, 2024
Merged

Conversation

swangi-kumari
Copy link
Contributor

@swangi-kumari swangi-kumari commented Dec 19, 2024

Type of Change

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

Description

  • Revert this PR
  • Pass setup_future_usage = None for ConnectorMandateId and NetworkMandateId.

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?

  1. Create Merchant
  2. Create API KEY
  3. Create Stripe connector
curl --location 'http://localhost:8080/account/postman_merchant_GHAction_1734681965/connectors' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'api-key: test_admin' \
--data '{
    "connector_type": "payment_processor",
    "profile_id": "pro_iprJnfcIANK2ws8xnWhI",
    "connector_name": "stripe",
    "connector_account_details": {
        "auth_type": "HeaderKey",
        "api_key": "__"
    },
    "test_mode": false,
    "disabled": false,
    "payment_methods_enabled": [
        {
            "payment_method": "pay_later",
            "payment_method_types": [
                {
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true,
                    "payment_experience": "redirect_to_url",
                    "payment_method_type": "affirm"
                }
            ]
        },
        {
            "payment_method": "pay_later",
            "payment_method_types": [
                {
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true,
                    "payment_experience": "redirect_to_url",
                    "payment_method_type": "afterpay_clearpay"
                }
            ]
        },
        {
            "payment_method": "pay_later",
            "payment_method_types": [
                {
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true,
                    "payment_experience": "redirect_to_url",
                    "payment_method_type": "klarna"
                }
            ]
        },
        {
            "payment_method": "pay_later",
            "payment_method_types": [
                {
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true,
                    "payment_experience": "invoke_sdk_client",
                    "payment_method_type": "klarna"
                }
            ]
        },
        {
            "payment_method": "bank_redirect",
            "payment_method_types": [
                {
                    "payment_method_type": "ideal",
                    "payment_experience": null,
                    "card_networks": null,
                    "accepted_currencies": null,
                    "accepted_countries": null,
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                },
                {
                    "payment_method_type": "giropay",
                    "payment_experience": null,
                    "card_networks": null,
                    "accepted_currencies": null,
                    "accepted_countries": null,
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                },
                {
                    "payment_method_type": "sofort",
                    "payment_experience": null,
                    "card_networks": null,
                    "accepted_currencies": null,
                    "accepted_countries": null,
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                },
                {
                    "payment_method_type": "eps",
                    "payment_experience": null,
                    "card_networks": null,
                    "accepted_currencies": null,
                    "accepted_countries": null,
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                }
            ]
        },
        {
            "payment_method": "bank_debit",
            "payment_method_types": [
                {
                    "payment_method_type": "ach",
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                },
                {
                    "payment_method_type": "becs",
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                },
                {
                    "payment_method_type": "sepa",
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                }
            ]
        },
        {
            "payment_method": "bank_transfer",
            "payment_method_types": [
                {
                    "payment_method_type": "ach",
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                },
                {
                    "payment_method_type": "bacs",
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                },
                {
                    "payment_method_type": "sepa",
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                }
            ]
        },
        {
            "payment_method": "card",
            "payment_method_types": [
                {
                    "payment_method_type": "credit",
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true,
                    "card_networks": [
                        "AmericanExpress",
                        "Discover",
                        "Interac",
                        "JCB",
                        "Mastercard",
                        "Visa",
                        "DinersClub",
                        "UnionPay",
                        "RuPay"
                    ]
                }
            ]
        },
        {
            "payment_method": "card",
            "payment_method_types": [
                {
                    "payment_method_type": "debit",
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true,
                    "card_networks": [
                        "AmericanExpress",
                        "Discover",
                        "Interac",
                        "JCB",
                        "Mastercard",
                        "Visa",
                        "DinersClub",
                        "UnionPay",
                        "RuPay"
                    ]
                }
            ]
        },
        {
            "payment_method": "wallet",
            "payment_method_types": [
                {
                    "payment_method_type": "apple_pay",
                    "payment_experience": "invoke_sdk_client",
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                }
            ]
        },
        {
            "payment_method": "wallet",
            "payment_method_types": [
                {
                    "payment_method_type": "google_pay",
                    "payment_experience": "invoke_sdk_client",
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                },
                {
                    "payment_method_type": "we_chat_pay",
                    "payment_experience": "invoke_sdk_client",
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                }
            ]
        }
    ],
    "metadata": {
        "google_pay": {
            "allowed_payment_methods": [
                {
                    "type": "CARD",
                    "parameters": {
                        "allowed_auth_methods": [
                            "PAN_ONLY",
                            "CRYPTOGRAM_3DS"
                        ],
                        "allowed_card_networks": [
                            "AMEX",
                            "DISCOVER",
                            "INTERAC",
                            "JCB",
                            "MASTERCARD",
                            "VISA"
                        ]
                    },
                    "tokenization_specification": {
                        "type": "PAYMENT_GATEWAY",
                        "parameters": {
                            "gateway": "example",
                            "gateway_merchant_id": "pk_test_51Msk2GAGHc77EJXX78h549SX2uaOnEkUYqBfjcoD05PIpAnDkYxMn8nQ4d19im85NQuX4Z6WDyHaUw2fFTPBWsIY00Wa7oNerO"
                        }
                    }
                }
            ],
            "merchant_info": {
                "merchant_name": "Narayan Bhat"
            }
        },
        "apple_pay": {
            "session_token_data": {
                "initiative": "web",
                "certificate": "",
                "display_name": "applepay",
                "certificate_keys": "",
                "initiative_context": "sdk-test-app.netlify.app",
                "merchant_identifier": "merchant.com.stripe.sang"
            },
            "payment_request_data": {
                "label": "applepay pvt.ltd",
                "supported_networks": [
                    "visa",
                    "masterCard",
                    "amex",
                    "discover"
                ],
                "merchant_capabilities": [
                    "supports3DS"
                ]
            }
        }
    }
}'
  1. Create Customer
  2. Enable NTID
curl --location 'http://localhost:8080/account/postman_merchant_GHAction_1734681965/business_profile/pro_iprJnfcIANK2ws8xnWhI' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'api-key: test_admin' \
--data '{
    "is_connector_agnostic_mit_enabled": true
}'
  1. Payment Create
curl --location 'http://localhost:8080/payments' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Accept-Language: ja' \
--header 'api-key: dev_qILOUpgjqH3hbdxrwstzlnFJD0L14SSdNzGOrKDbtOZFEqRpvJzg7TiggleMHOnz' \
--data-raw '{
    "customer_acceptance": null,
    "setup_future_usage": "off_session",
    "currency": "USD",
    "amount": 6500,
    "authentication_type": "no_three_ds",
    "customer_id": "cus_1WMNEGiqjuLCQXJL64BK",
    "capture_method": "automatic",
    "description": "Joseph First Crypto",
    "email": "[email protected]",
    "profile_id": "pro_iprJnfcIANK2ws8xnWhI",
    "connector_metadata": {
        "noon": {
            "order_category": "applepay"
        }
    },
    "metadata": {
        "udf1": "value1",
        "new_customer": "true",
        "login_date": "2019-09-10T10:11:12Z"
    }
}'

7.list PM for a customer

curl --location 'http://localhost:8080/customers/payment_methods?client_secret=pay_Pot19w2IWklIY8Zdci9e_secret_msckr4O1BLNGkOY7EAjQ' \
--header 'Accept: application/json' \
--header 'api-key: pk_dev_0139f3ccb0494e959a4df8ceb8b07fbc'

Response

{
    "customer_payment_methods": [
        {
            "payment_token": "token_gaP8kf82RteJe7iNyyzs",
            "payment_method_id": "pm_wE02Lr7fNXwUGaXQ1BiC",
            "customer_id": "cus_1WMNEGiqjuLCQXJL64BK",
            "payment_method": "card",
            "payment_method_type": "debit",
            "payment_method_issuer": null,
            "payment_method_issuer_code": null,
            "recurring_enabled": true,
            "installment_payment_enabled": false,
            "payment_experience": [
                "redirect_to_url"
            ],
            "card": {
                "scheme": null,
                "issuer_country": null,
                "last4_digits": "4242",
                "expiry_month": "10",
                "expiry_year": "50",
                "card_token": null,
                "card_holder_name": "morino",
                "card_fingerprint": null,
                "nick_name": null,
                "card_network": null,
                "card_isin": "424242",
                "card_issuer": null,
                "card_type": null,
                "saved_to_locker": true
            },
            "metadata": null,
            "created": "2024-12-20T08:06:07.307Z",
            "bank": null,
            "surcharge_details": null,
            "requires_cvv": false,
            "last_used_at": "2024-12-20T08:06:11.041Z",
            "default_payment_method_set": true,
            "billing": {
                "address": {
                    "city": "New York",
                    "country": "US",
                    "line1": "123 Main Street Apt 4B",
                    "line2": "123 Main Street Apt 4B",
                    "line3": "123 Main Street Apt 4B",
                    "zip": "10001",
                    "state": "New York",
                    "first_name": "morino",
                    "last_name": null
                },
                "phone": null,
                "email": null
            }
        }
    ],
    "is_guest_customer": false
}
  1. paymnet confirm (MIT-PMID)
curl --location 'http://localhost:8080/payments/pay_Pot19w2IWklIY8Zdci9e/confirm' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'api-key: dev_qILOUpgjqH3hbdxrwstzlnFJD0L14SSdNzGOrKDbtOZFEqRpvJzg7TiggleMHOnz' \
--data '{
    "profile_id": "pro_iprJnfcIANK2ws8xnWhI",
    "amount": 7000,
    "currency": "USD",
    "confirm": true,
    "capture_method": "automatic",
    "customer_id": "cus_1WMNEGiqjuLCQXJL64BK",
    "return_url": "https://hyperswitch.io",
    "recurring_details": {
        "type": "payment_method_id",
        "data": "pm_wE02Lr7fNXwUGaXQ1BiC"
    },
    "off_session": true,
    "billing": {
        "address": {
            "first_name": "John",
            "last_name": "Doe",
            "line1": "1467",
            "line2": "Harrison Street",
            "line3": "Harrison Street",
            "city": "San Fransico",
            "state": "California",
            "zip": "94122",
            "country": "US"
        },
        "phone": {
            "number": "9123456789",
            "country_code": "+91"
        }
    },
    "browser_info": {
        "ip_address": "129.0.0.1",
        "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
        "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8",
        "language": "en-US",
        "color_depth": 32,
        "screen_height": 1117,
        "screen_width": 1728,
        "time_zone": -330,
        "java_enabled": true,
        "java_script_enabled": true
    }
}'

Response

{
    "payment_id": "pay_Pot19w2IWklIY8Zdci9e",
    "merchant_id": "postman_merchant_GHAction_1734681965",
    "status": "succeeded",
    "amount": 6500,
    "net_amount": 6500,
    "shipping_cost": null,
    "amount_capturable": 0,
    "amount_received": 6500,
    "connector": "stripe",
    "client_secret": "pay_Pot19w2IWklIY8Zdci9e_secret_msckr4O1BLNGkOY7EAjQ",
    "created": "2024-12-20T08:12:00.298Z",
    "currency": "USD",
    "customer_id": "cus_1WMNEGiqjuLCQXJL64BK",
    "customer": {
        "id": "cus_1WMNEGiqjuLCQXJL64BK",
        "name": "John Doe",
        "email": "[email protected]",
        "phone": "999999999",
        "phone_country_code": "+65"
    },
    "description": "Joseph First Crypto",
    "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": null,
            "card_network": null,
            "card_issuer": null,
            "card_issuing_country": null,
            "card_isin": "424242",
            "card_extended_bin": null,
            "card_exp_month": "10",
            "card_exp_year": "50",
            "card_holder_name": "morino",
            "payment_checks": {
                "cvc_check": null,
                "address_line1_check": "pass",
                "address_postal_code_check": "pass"
            },
            "authentication_data": null
        },
        "billing": null
    },
    "payment_token": null,
    "shipping": null,
    "billing": {
        "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": "9123456789",
            "country_code": "+91"
        },
        "email": null
    },
    "order_details": null,
    "email": "[email protected]",
    "name": "John Doe",
    "phone": "999999999",
    "return_url": "https://hyperswitch.io/",
    "authentication_type": "no_three_ds",
    "statement_descriptor_name": null,
    "statement_descriptor_suffix": null,
    "next_action": null,
    "cancellation_reason": null,
    "error_code": null,
    "error_message": null,
    "unified_code": null,
    "unified_message": null,
    "payment_experience": null,
    "payment_method_type": "debit",
    "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": "pi_3QY1JdEOqOywnAIx1WuFU78T",
    "frm_message": null,
    "metadata": {
        "udf1": "value1",
        "login_date": "2019-09-10T10:11:12Z",
        "new_customer": "true"
    },
    "connector_metadata": {
        "apple_pay": null,
        "airwallex": null,
        "noon": {
            "order_category": "applepay"
        }
    },
    "feature_metadata": null,
    "reference_id": "pi_3QY1JdEOqOywnAIx1WuFU78T",
    "payment_link": null,
    "profile_id": "pro_iprJnfcIANK2ws8xnWhI",
    "surcharge_details": null,
    "attempt_count": 1,
    "merchant_decision": null,
    "merchant_connector_id": "mca_K3vxJ0wdLtkya4PMCoCy",
    "incremental_authorization_allowed": null,
    "authorization_count": null,
    "incremental_authorizations": null,
    "external_authentication_details": null,
    "external_3ds_authentication_attempted": false,
    "expires_on": "2024-12-20T08:27:00.298Z",
    "fingerprint": null,
    "browser_info": {
        "language": "en-US",
        "time_zone": -330,
        "ip_address": "129.0.0.1",
        "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
        "color_depth": 32,
        "java_enabled": true,
        "screen_width": 1728,
        "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8",
        "screen_height": 1117,
        "java_script_enabled": true
    },
    "payment_method_id": "pm_wE02Lr7fNXwUGaXQ1BiC",
    "payment_method_status": "active",
    "updated": "2024-12-20T08:12:10.416Z",
    "split_payments": null,
    "frm_metadata": null,
    "merchant_order_reference_id": null,
    "order_tax_amount": null,
    "connector_mandate_id": null
}
  1. Payment create
curl --location 'http://localhost:8080/payments' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Accept-Language: ja' \
--header 'api-key: dev_tPRMqr7DaBlAPnluXjLw4Y7aA3A6ylsrS7ZuTAxPQNwwyr5ocp0NwzYKmPGGPJho' \
--data-raw '{
    "customer_acceptance": null,
    "setup_future_usage": "off_session",
    "currency": "USD",
    "amount": 6500,
    "authentication_type": "no_three_ds",
    "customer_id": "cus_1WMNEGiqjuLCQXJL64BK",
    "capture_method": "automatic",
    "description": "Joseph First Crypto",
    "email": "[email protected]",
    "profile_id": "pro_iprJnfcIANK2ws8xnWhI",
    "connector_metadata": {
        "noon": {
            "order_category": "applepay"
        }
    },
    "metadata": {
        "udf1": "value1",
        "new_customer": "true",
        "login_date": "2019-09-10T10:11:12Z"
    }
}'
  1. List payment method for a customer
curl --location 'http://localhost:8080/customers/payment_methods?client_secret=pay_URniJoADP0OxGr3uMFB5_secret_N1h6iyWVlCkxbbWS73oQ' \
--header 'Accept: application/json' \
--header 'api-key: pk_dev_b1f42086801d4d08bfd3f504ad818c86'

11.Payment confirm (MIT-token)

curl --location 'http://localhost:8080/payments/pay_Pot19w2IWklIY8Zdci9e/confirm' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'api-key: pk_dev_b1f42086801d4d08bfd3f504ad818c86' \
--data '{
    "client_secret": "_",
    "profile_id": "pro_iprJnfcIANK2ws8xnWhI",
    "payment_method": "card",
    "payment_token": "token_gaP8kf82RteJe7iNyyzs",
    "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"
        }
    },
    "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"
        }
    },
    "browser_info": {
        "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
        "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8",
        "language": "en-US",
        "color_depth": 32,
        "screen_height": 1117,
        "screen_width": 1728,
        "time_zone": -330,
        "java_enabled": true,
        "java_script_enabled": true,
        "ip_address": "127.0.0.1"
    }
}'

response

{
    "payment_id": "pay_RjY0jXFE8Xar83PI8Chi",
    "merchant_id": "postman_merchant_GHAction_1734606213",
    "status": "succeeded",
    "amount": 6500,
    "net_amount": 6500,
    "shipping_cost": null,
    "amount_capturable": 0,
    "amount_received": 6500,
    "connector": "stripe",
    "client_secret": "pay_RjY0jXFE8Xar83PI8Chi_secret_mEVWBGUNPRq86unP86by",
    "created": "2024-12-19T13:42:38.281Z",
    "currency": "USD",
    "customer_id": "cus_qvJuiZpsZp0tyO91SzVu",
    "customer": {
        "id": "cus_qvJuiZpsZp0tyO91SzVu",
        "name": "John Doe",
        "email": "[email protected]",
        "phone": "999999999",
        "phone_country_code": "+65"
    },
    "description": "Joseph First Crypto",
    "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": null,
            "card_network": null,
            "card_issuer": null,
            "card_issuing_country": null,
            "card_isin": "424242",
            "card_extended_bin": null,
            "card_exp_month": "10",
            "card_exp_year": "50",
            "card_holder_name": "morino",
            "payment_checks": null,
            "authentication_data": null
        },
        "billing": null
    },
    "payment_token": "token_4kowz49reGMiVCsl7RtO",
    "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": null,
        "email": null
    },
    "billing": {
        "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": null,
        "email": null
    },
    "order_details": null,
    "email": "[email protected]",
    "name": "John Doe",
    "phone": "999999999",
    "return_url": null,
    "authentication_type": "no_three_ds",
    "statement_descriptor_name": null,
    "statement_descriptor_suffix": null,
    "next_action": null,
    "cancellation_reason": null,
    "error_code": null,
    "error_message": null,
    "unified_code": null,
    "unified_message": null,
    "payment_experience": null,
    "payment_method_type": "debit",
    "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": "pi_3QXk01EOqOywnAIx15jAcdAC",
    "frm_message": null,
    "metadata": {
        "udf1": "value1",
        "login_date": "2019-09-10T10:11:12Z",
        "new_customer": "true"
    },
    "connector_metadata": {
        "apple_pay": null,
        "airwallex": null,
        "noon": {
            "order_category": "applepay"
        }
    },
    "feature_metadata": null,
    "reference_id": "pi_3QXk01EOqOywnAIx15jAcdAC",
    "payment_link": null,
    "profile_id": "pro_keF9gI6O2yVuvWUaqQNW",
    "surcharge_details": null,
    "attempt_count": 1,
    "merchant_decision": null,
    "merchant_connector_id": "mca_p2LE8wJaSteDl2w5GUx7",
    "incremental_authorization_allowed": null,
    "authorization_count": null,
    "incremental_authorizations": null,
    "external_authentication_details": null,
    "external_3ds_authentication_attempted": false,
    "expires_on": "2024-12-19T13:57:38.281Z",
    "fingerprint": null,
    "browser_info": {
        "language": "en-US",
        "time_zone": -330,
        "ip_address": "127.0.0.1",
        "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
        "color_depth": 32,
        "java_enabled": true,
        "screen_width": 1728,
        "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8",
        "screen_height": 1117,
        "java_script_enabled": true
    },
    "payment_method_id": "pm_lkBZNj9fkhdg8DunXWUn",
    "payment_method_status": "active",
    "updated": "2024-12-19T13:42:46.314Z",
    "split_payments": null,
    "frm_metadata": null,
    "merchant_order_reference_id": null,
    "order_tax_amount": null,
    "connector_mandate_id": null
}

Adyen cypress test

  1. Connector Agnostic NTID
image
  1. Save card flow
image

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

@swangi-kumari swangi-kumari self-assigned this Dec 19, 2024
@swangi-kumari swangi-kumari requested a review from a team as a code owner December 19, 2024 14:17
Copy link

semanticdiff-com bot commented Dec 19, 2024

Review changes with  SemanticDiff

Changed Files
File Status
  crates/router/src/core/payments/transformers.rs  83% smaller
  crates/router/src/connector/stripe/transformers.rs  58% smaller

@swangi-kumari swangi-kumari added the A-connector-integration Area: Connector integration label Dec 19, 2024
@swangi-kumari swangi-kumari requested a review from a team as a code owner December 20, 2024 07:44
@swangi-kumari swangi-kumari added the C-bug Category: Bug label Dec 20, 2024
@likhinbopanna likhinbopanna added this pull request to the merge queue Dec 20, 2024
Merged via the queue into main with commit 9f2ce05 Dec 20, 2024
32 of 35 checks passed
@likhinbopanna likhinbopanna deleted the stripe-mandate-fix branch December 20, 2024 10:59
pixincreate added a commit that referenced this pull request Dec 20, 2024
…ete-pm

* 'main' of github.com:juspay/hyperswitch:
  fix(connector): Update mandate PMT configs for Mandate Supported Connectors (#6903)
  fix(connector): [STRIPE] fix stripe mandate (#6899)
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 C-bug Category: Bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants