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): [BANKOFAMERICA] Remove cards 3ds flow #5294

Merged
merged 1 commit into from
Jul 11, 2024

Conversation

deepanshu-iiitu
Copy link
Contributor

@deepanshu-iiitu deepanshu-iiitu commented Jul 11, 2024

Type of Change

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

Description

Cards 3DS Flow is not supported on production by Bankofamerica and hence it is removed.

Additional Changes

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

Motivation and Context

#5288

How did you test it?

3DS Flow is not supported on production by Bankofamerica hence it is removed. 3DS payments will now go through normal Non-3DS flow.
Request:

curl --location 'http://localhost:8080/payments' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'api-key: dev_mF5ApaF7qylFyewcvRbsOVw9bhOUy2ufhC8MutbWQvLwNWWqX7CZGDPf5SnZ6KRE' \
--data-raw '{
    "amount": 999,
    "currency": "USD",
    "confirm": true,
    "customer_id": "hkfewkhefwdwfkhj",
    "email": "guest@deepankjnshgkhju.com",
    "return_url": "https://google.com",
    "authentication_type": "three_ds",
    "payment_method": "card",
    "payment_method_type": "credit",
    "payment_method_data": {
        "card": {
            "card_number": "4111111111111111",
            "card_exp_month": "05",
            "card_exp_year": "25",
            "card_cvc": "123"
        }
    },
    "billing": {
        "address": {
            "line1": "eqnkl",
            "city": "San Francisco",
            "state": "CA",
            "zip": "94122",
            "country": "IN",
            "first_name": "John",
            "last_name": "Bond"
        }
    }
}'

Response:

{
    "payment_id": "pay_cwUGBO1EUp1YSnICJnGt",
    "merchant_id": "merchant_1718024306",
    "status": "succeeded",
    "amount": 999,
    "net_amount": 999,
    "amount_capturable": 0,
    "amount_received": 999,
    "connector": "bankofamerica",
    "client_secret": "pay_cwUGBO1EUp1YSnICJnGt_secret_58yq6aN6TMIx3rawYRru",
    "created": "2024-07-11T11:01:04.937Z",
    "currency": "USD",
    "customer_id": "hkfewkhefwdwfkhj",
    "customer": {
        "id": "hkfewkhefwdwfkhj",
        "name": null,
        "email": "guest@deepankjnshgkhju.com",
        "phone": null,
        "phone_country_code": null
    },
    "description": null,
    "refunds": null,
    "disputes": null,
    "mandate_id": null,
    "mandate_data": null,
    "setup_future_usage": null,
    "off_session": null,
    "capture_on": null,
    "capture_method": null,
    "payment_method": "card",
    "payment_method_data": {
        "card": {
            "last4": "1111",
            "card_type": null,
            "card_network": null,
            "card_issuer": null,
            "card_issuing_country": null,
            "card_isin": "411111",
            "card_extended_bin": null,
            "card_exp_month": "05",
            "card_exp_year": "25",
            "card_holder_name": null,
            "payment_checks": {
                "avs_response": {
                    "code": "Y",
                    "codeRaw": "Y"
                },
                "card_verification": {
                    "resultCode": "M",
                    "resultCodeRaw": "M"
                },
                "approval_code": "831000",
                "consumer_authentication_response": {
                    "code": "2",
                    "codeRaw": "2"
                },
                "cavv": null,
                "eci": null,
                "eci_raw": null
            },
            "authentication_data": {
                "retrieval_reference_number": "419311106891",
                "acs_transaction_id": null,
                "system_trace_audit_number": "106891"
            }
        },
        "billing": null
    },
    "payment_token": "token_M45bEnvOf2GPLMysWnOr",
    "shipping": null,
    "billing": {
        "address": {
            "city": "San Francisco",
            "country": "IN",
            "line1": "eqnkl",
            "line2": null,
            "line3": null,
            "zip": "94122",
            "state": "CA",
            "first_name": "John",
            "last_name": "Bond"
        },
        "phone": null,
        "email": null
    },
    "order_details": null,
    "email": "guest@deepankjnshgkhju.com",
    "name": null,
    "phone": null,
    "return_url": "https://google.com/",
    "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": {
        "customer_id": "hkfewkhefwdwfkhj",
        "created_at": 1720695664,
        "expires": 1720699264,
        "secret": "epk_76f83d509ad3425db0f6f724459079ee"
    },
    "manual_retry_allowed": false,
    "connector_transaction_id": "7206956666866029204951",
    "frm_message": null,
    "metadata": null,
    "connector_metadata": null,
    "feature_metadata": null,
    "reference_id": "pay_cwUGBO1EUp1YSnICJnGt_1",
    "payment_link": null,
    "profile_id": "pro_sjoiFN7MPB9SdG5Zr0iT",
    "surcharge_details": null,
    "attempt_count": 1,
    "merchant_decision": null,
    "merchant_connector_id": "mca_QxbSnL7xEEr3Wc2sODHD",
    "incremental_authorization_allowed": null,
    "authorization_count": null,
    "incremental_authorizations": null,
    "external_authentication_details": null,
    "external_3ds_authentication_attempted": false,
    "expires_on": "2024-07-11T11:16:04.937Z",
    "fingerprint": null,
    "browser_info": null,
    "payment_method_id": null,
    "payment_method_status": null,
    "updated": "2024-07-11T11:01:07.583Z",
    "charges": null,
    "frm_metadata": null,
    "merchant_order_reference_id": null
}

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

@deepanshu-iiitu deepanshu-iiitu added A-connector-integration Area: Connector integration C-bug Category: Bug labels Jul 11, 2024
@deepanshu-iiitu deepanshu-iiitu self-assigned this Jul 11, 2024
@deepanshu-iiitu deepanshu-iiitu requested review from a team as code owners July 11, 2024 10:23
@deepanshu-iiitu deepanshu-iiitu linked an issue Jul 11, 2024 that may be closed by this pull request
2 tasks
@likhinbopanna likhinbopanna added this pull request to the merge queue Jul 11, 2024
Merged via the queue into main with commit 7c408af Jul 11, 2024
19 of 21 checks passed
@likhinbopanna likhinbopanna deleted the boa-remove-3ds branch July 11, 2024 12:55
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.

[FEATURE] [BANKOFAMERICA] Remove 3DS Flow
4 participants