Skip to content

feat(connector): [Netcetera] Update Base URL and WASM#13145

Open
Anurag-05-prog wants to merge 1 commit into
mainfrom
feat/netcetera-endpoint-migration
Open

feat(connector): [Netcetera] Update Base URL and WASM#13145
Anurag-05-prog wants to merge 1 commit into
mainfrom
feat/netcetera-endpoint-migration

Conversation

@Anurag-05-prog

@Anurag-05-prog Anurag-05-prog commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

Type of Change

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

Description

Updated Base URL to new endpoint. Netcetera team has confirmed that merchant_endpoint_prefix won't be needed anymore, so removed that from the WASM too.

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. Configure Cybersource and Netcetera in MCA
  2. Configure Netcetera as authentication_connector in Business Profile.

Request:

postman request POST '{{baseUrl}}/account/:merchant-id/business_profile/:profile-id' \
  --header 'Content-Type: application/json' \
  --header 'api-key: ••••••' \
  --body '
{
    "authentication_connector_details": {
        "authentication_connectors": ["netcetera"],
        "three_ds_requestor_url": "https://google.com"
    }
}'

Response:

{
    "merchant_id": "merchant_1782997100",
    "profile_id": "pro_IVPKtRRDMuSwxl1tpm6E",
    "profile_name": "US_default",
    "return_url": "https://google.com/success",
    "enable_payment_response_hash": true,
    "payment_response_hash_key": "IP690ZKN3JH5qIzgnvtv8FEIMsDNOVb3EJvQJIWbM6Q1XXeWR201fPGIQa2UUJD2",
    "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": "https://webhook.site/e6d90d32-8b90-47e9-9623-8e7844fc4d89",
        "payment_created_enabled": true,
        "payment_succeeded_enabled": true,
        "payment_failed_enabled": true,
        "payment_statuses_enabled": null,
        "refund_statuses_enabled": null,
        "payout_statuses_enabled": null
    },
    "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": {
        "authentication_connectors": [
            "netcetera"
        ],
        "three_ds_requestor_url": "https://google.com",
        "three_ds_requestor_app_url": 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": false,
    "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,
    "always_request_extended_authorization": null,
    "is_click_to_pay_enabled": false,
    "authentication_product_ids": null,
    "card_testing_guard_config": {
        "card_ip_blocking_status": "disabled",
        "card_ip_blocking_threshold": 3,
        "guest_user_card_blocking_status": "disabled",
        "guest_user_card_blocking_threshold": 10,
        "customer_id_blocking_status": "disabled",
        "customer_id_blocking_threshold": 5,
        "card_testing_guard_expiry": 3600,
        "guest_ip_blocking_status": "disabled",
        "guest_ip_blocking_threshold": 10
    },
    "is_clear_pan_retries_enabled": false,
    "force_3ds_challenge": false,
    "is_debit_routing_enabled": false,
    "merchant_business_country": null,
    "is_pre_network_tokenization_enabled": false,
    "acquirer_configs": null,
    "acquirer_config_bucket": null,
    "is_iframe_redirection_enabled": null,
    "merchant_category_code": null,
    "merchant_country_code": null,
    "dispute_polling_interval": null,
    "is_manual_retry_enabled": null,
    "always_enable_overcapture": null,
    "is_external_vault_enabled": "skip",
    "external_vault_connector_details": null,
    "billing_processor_id": null,
    "surcharge_connector_details": null,
    "is_l2_l3_enabled": false,
    "network_tokenization_credentials": null,
    "payment_method_blocking": null
}
  1. Payments - Create (confirm: false):

Request:

postman request POST '{{baseUrl}}/payments' \
  --header 'Content-Type: application/json' \
  --header 'Accept: application/json' \
  --header 'api-key: ••••••' \
  --body '{
    "amount": 10,
    "currency": "USD",
    "confirm": false,
    "capture_method": "automatic",
    "capture_on": "2022-09-10T10:11:12Z",
    "customer_id": "StripeCustomer",
    "email": "guest@example.com",
    "name": "John Doe",
    "phone": "999999999",
    "phone_country_code": "+65",
    "description": "Its my first payment request",
    "authentication_type": "three_ds",
    "return_url": "https://duck.com",
    "billing": {
        "address": {
            "line1": "1467",
            "line2": "Harrison Street",
            "line3": "Harrison Street",
            "city": "San Fransico",
            "state": "CA",
            "zip": "94122",
            "country": "US",
            "first_name": "PiX",
            "last_name": "abc"
        },
        "phone": {
            "number": "123456789",
            "country_code": "12"
        }
    },
    "shipping": {
        "address": {
            "line1": "1467",
            "line2": "Harrison Street",
            "line3": "Harrison Street",
            "city": "San Fransico",
            "state": "CA",
            "zip": "94122",
            "country": "US",
            "first_name": "PiX",
            "last_name": "Poddar"
        },
        "phone": {
            "number": "123456789",
            "country_code": "12"
        }
    },
    "request_external_three_ds_authentication": true,
    "statement_descriptor_name": "joseph",
    "statement_descriptor_suffix": "JS",
    "metadata": {
        "udf1": "value1",
        "new_customer": "true",
        "login_date": "2019-09-10T10:11:12Z"
    }
}' \
  --auth-apikey-key 'api-key' \
  --auth-apikey-value '***' \
  --auth-apikey-in 'header'

Response:

{
    "payment_id": "pay_rbZGFRdoM0xT920GAfoF",
    "merchant_id": "merchant_1782997100",
    "status": "requires_payment_method",
    "amount": 10,
    "net_amount": 10,
    "shipping_cost": null,
    "amount_capturable": 0,
    "amount_received": null,
    "processor_merchant_id": "merchant_1782997100",
    "initiator": null,
    "sdk_authorization": redacted
    "connector": null,
    "state_metadata": null,
    "client_secret": "pay_rbZGFRdoM0xT920GAfoF_secret_dWyVCRXBDbuToDOYDfj5",
    "created": "2026-07-02T13:04:01.830Z",
    "modified_at": "2026-07-02T13:04:01.868Z",
    "connector_customer_id": null,
    "currency": "USD",
    "customer_id": "StripeCustomer",
    "customer": {
        "id": "StripeCustomer",
        "name": "John Doe",
        "email": "guest@example.com",
        "phone": "999999999",
        "phone_country_code": "+65",
        "customer_document_details": null
    },
    "description": "Its my first payment request",
    "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": null,
    "payment_method_data": null,
    "payment_token": null,
    "shipping": {
        "address": {
            "city": "San Fransico",
            "country": "US",
            "line1": "1467",
            "line2": "Harrison Street",
            "line3": "Harrison Street",
            "zip": "94122",
            "state": "CA",
            "first_name": "PiX",
            "last_name": "Poddar",
            "origin_zip": null
        },
        "phone": {
            "number": "123456789",
            "country_code": "12"
        },
        "email": null
    },
    "billing": {
        "address": {
            "city": "San Fransico",
            "country": "US",
            "line1": "1467",
            "line2": "Harrison Street",
            "line3": "Harrison Street",
            "zip": "94122",
            "state": "CA",
            "first_name": "PiX",
            "last_name": "abc",
            "origin_zip": null
        },
        "phone": {
            "number": "123456789",
            "country_code": "12"
        },
        "email": null
    },
    "order_details": null,
    "email": "guest@example.com",
    "name": "John Doe",
    "phone": "999999999",
    "return_url": "https://duck.com/",
    "authentication_type": "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,
    "error_details": 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,
    "manual_retry_allowed": null,
    "connector_transaction_id": null,
    "frm_message": null,
    "metadata": {
        "udf1": "value1",
        "login_date": "2019-09-10T10:11:12Z",
        "new_customer": "true"
    },
    "connector_metadata": null,
    "connector_response_metadata": null,
    "feature_metadata": null,
    "reference_id": null,
    "payment_link": null,
    "profile_id": "pro_IVPKtRRDMuSwxl1tpm6E",
    "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": "2026-07-02T13:19:01.830Z",
    "fingerprint": null,
    "browser_info": null,
    "payment_channel": null,
    "payment_method_id": null,
    "network_transaction_id": null,
    "network_transaction_link_id": null,
    "payment_method_status": null,
    "updated": "2026-07-02T13:04:01.868Z",
    "split_payments": null,
    "frm_metadata": null,
    "extended_authorization_applied": null,
    "extended_authorization_last_applied_at": null,
    "request_extended_authorization": null,
    "capture_before": null,
    "merchant_order_reference_id": null,
    "order_tax_amount": null,
    "connector_mandate_id": null,
    "card_discovery": null,
    "force_3ds_challenge": false,
    "force_3ds_challenge_trigger": false,
    "issuer_error_code": null,
    "issuer_error_message": null,
    "is_iframe_redirection_enabled": null,
    "whole_connector_response": null,
    "enable_partial_authorization": null,
    "enable_overcapture": null,
    "is_overcapture_enabled": null,
    "network_details": null,
    "is_stored_credential": null,
    "mit_category": null,
    "billing_descriptor": null,
    "tokenization": null,
    "partner_merchant_identifier_details": null,
    "payment_method_tokenization_details": null,
    "installment_options": null,
    "installment_data": null,
    "sender_payment_instrument_id": null
}
  1. Payments - Confirm:

Request:

postman request POST '{{baseUrl}}/payments/:payment-id/confirm' \
  --header 'Content-Type: application/json' \
  --header 'Accept: application/json' \
  --header 'api-key: ••••••' \
  --body '{
    "browser_info": {
        "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36",
        "accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8",
        "language": "nl-NL",
        "color_depth": 24,
        "screen_height": 723,
        "screen_width": 1536,
        "time_zone": 0,
        "java_enabled": true,
        "java_script_enabled": true,
        "ip_address": "115.99.183.2"
    },
    "payment_method": "card",
    "payment_method_data": {
        "card": {
            "card_number": "5306889942833340", 
            "card_exp_month": "12",
            "card_exp_year": "34",
            "card_holder_name": "Sahkal Poddar",
            "card_cvc": "123"
        }
    }
}' \
  --auth-apikey-key 'api-key' \
  --auth-apikey-value '***' \
  --auth-apikey-in 'header'

Response:

{
    "payment_id": "pay_rbZGFRdoM0xT920GAfoF",
    "merchant_id": "merchant_1782997100",
    "status": "requires_customer_action",
    "amount": 10,
    "net_amount": 10,
    "shipping_cost": null,
    "amount_capturable": 0,
    "amount_received": null,
    "processor_merchant_id": "merchant_1782997100",
    "initiator": null,
    "sdk_authorization": redacted,
    "connector": "cybersource",
    "state_metadata": null,
    "client_secret": "pay_rbZGFRdoM0xT920GAfoF_secret_dWyVCRXBDbuToDOYDfj5",
    "created": "2026-07-02T13:04:01.830Z",
    "modified_at": "2026-07-02T13:04:25.830Z",
    "connector_customer_id": null,
    "currency": "USD",
    "customer_id": "StripeCustomer",
    "customer": {
        "id": "StripeCustomer",
        "name": "John Doe",
        "email": "guest@example.com",
        "phone": "999999999",
        "phone_country_code": "+65",
        "customer_document_details": null
    },
    "description": "Its my first payment request",
    "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": "3340",
            "card_type": null,
            "card_network": null,
            "card_issuer": null,
            "card_issuing_country": null,
            "card_isin": "530688",
            "card_extended_bin": null,
            "card_exp_month": "12",
            "card_exp_year": "34",
            "card_holder_name": "Sahkal Poddar",
            "payment_checks": null,
            "authentication_data": null,
            "auth_code": null
        },
        "billing": null
    },
    "payment_token": "token_22vHsoXZwihvl7q3kpir",
    "shipping": {
        "address": {
            "city": "San Fransico",
            "country": "US",
            "line1": "1467",
            "line2": "Harrison Street",
            "line3": "Harrison Street",
            "zip": "94122",
            "state": "CA",
            "first_name": "PiX",
            "last_name": "Poddar",
            "origin_zip": null
        },
        "phone": {
            "number": "123456789",
            "country_code": "12"
        },
        "email": null
    },
    "billing": {
        "address": {
            "city": "San Fransico",
            "country": "US",
            "line1": "1467",
            "line2": "Harrison Street",
            "line3": "Harrison Street",
            "zip": "94122",
            "state": "CA",
            "first_name": "PiX",
            "last_name": "abc",
            "origin_zip": null
        },
        "phone": {
            "number": "123456789",
            "country_code": "12"
        },
        "email": null
    },
    "order_details": null,
    "email": "guest@example.com",
    "name": "John Doe",
    "phone": "999999999",
    "return_url": "https://duck.com/",
    "authentication_type": "three_ds",
    "statement_descriptor_name": "joseph",
    "statement_descriptor_suffix": "JS",
    "next_action": {
        "type": "three_ds_invoke",
        "three_ds_data": {
            "three_ds_authentication_url": "http://localhost:8080/payments/pay_rbZGFRdoM0xT920GAfoF/3ds/authentication",
            "three_ds_authorize_url": "http://localhost:8080/payments/pay_rbZGFRdoM0xT920GAfoF/merchant_1782997100/authorize/cybersource",
            "three_ds_method_details": {
                "three_ds_method_data_submission": true,
                "three_ds_method_data": redacted,
                "three_ds_method_url": redacted,
                "three_ds_method_key": "threeDSMethodData",
                "consume_post_message_for_three_ds_method_completion": false
            },
            "poll_config": {
                "poll_id": "external_authentication_pay_rbZGFRdoM0xT920GAfoF",
                "delay_in_secs": 2,
                "frequency": 5
            },
            "message_version": "2.3.1",
            "directory_server_id": "A000000004",
            "card_network": null,
            "three_ds_connector": "netcetera"
        }
    },
    "cancellation_reason": null,
    "error_code": null,
    "error_message": null,
    "unified_code": null,
    "unified_message": null,
    "error_details": 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,
    "manual_retry_allowed": null,
    "connector_transaction_id": null,
    "frm_message": null,
    "metadata": {
        "udf1": "value1",
        "login_date": "2019-09-10T10:11:12Z",
        "new_customer": "true"
    },
    "connector_metadata": null,
    "connector_response_metadata": null,
    "feature_metadata": null,
    "reference_id": null,
    "payment_link": null,
    "profile_id": "pro_IVPKtRRDMuSwxl1tpm6E",
    "surcharge_details": null,
    "attempt_count": 1,
    "merchant_decision": null,
    "merchant_connector_id": "mca_cuX1dYupoPJJx5LHRdfi",
    "incremental_authorization_allowed": null,
    "authorization_count": null,
    "incremental_authorizations": null,
    "external_authentication_details": {
        "authentication_flow": null,
        "electronic_commerce_indicator": null,
        "status": "pending",
        "ds_transaction_id": "158a91fc-5daa-43c8-b689-0d328587df6f",
        "version": "2.3.1",
        "error_code": null,
        "error_message": null
    },
    "external_3ds_authentication_attempted": true,
    "expires_on": "2026-07-02T13:19:01.830Z",
    "fingerprint": null,
    "browser_info": {
        "os_type": null,
        "referer": null,
        "language": "nl-NL",
        "time_zone": 0,
        "ip_address": "115.99.183.2",
        "os_version": null,
        "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,
        "device_model": null,
        "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,
        "accept_language": "en",
        "java_script_enabled": true
    },
    "payment_channel": null,
    "payment_method_id": null,
    "network_transaction_id": null,
    "network_transaction_link_id": null,
    "payment_method_status": null,
    "updated": "2026-07-02T13:04:25.830Z",
    "split_payments": null,
    "frm_metadata": null,
    "extended_authorization_applied": null,
    "extended_authorization_last_applied_at": null,
    "request_extended_authorization": null,
    "capture_before": null,
    "merchant_order_reference_id": null,
    "order_tax_amount": null,
    "connector_mandate_id": null,
    "card_discovery": "manual",
    "force_3ds_challenge": false,
    "force_3ds_challenge_trigger": false,
    "issuer_error_code": null,
    "issuer_error_message": null,
    "is_iframe_redirection_enabled": null,
    "whole_connector_response": null,
    "enable_partial_authorization": null,
    "enable_overcapture": null,
    "is_overcapture_enabled": null,
    "network_details": null,
    "is_stored_credential": null,
    "mit_category": null,
    "billing_descriptor": null,
    "tokenization": null,
    "partner_merchant_identifier_details": null,
    "payment_method_tokenization_details": null,
    "installment_options": null,
    "installment_data": null,
    "sender_payment_instrument_id": null
}
  1. Authenticate Browser

Request:

postman request POST '{{baseUrl}}/payments/:payment-id/3ds/authentication' \
  --header 'Content-Type: application/json' \
  --header 'Accept: application/json' \
  --header 'api-key: {{publishable-key}}' \
  --body '{
    "client_secret": "{{client-secret}}",
    "device_channel": "BRW",
    "threeds_method_comp_ind": "Y"
}
'

Response:

{
    "trans_status": "C",
    "acs_url": redacted,
    "challenge_request": redacted,
    "challenge_request_key": "creq",
    "acs_reference_number": "3DS_LOA_ACS_201_13579",
    "acs_trans_id": "ea464da6-7284-4b82-b2c1-9725097da172",
    "three_dsserver_trans_id": "158a91fc-5daa-43c8-b689-0d328587df6f",
    "acs_signed_content": null,
    "three_ds_requestor_url": "https://google.com",
    "three_ds_requestor_app_url": null,
    "error_message": null
}
  1. Authorize

Request:

postman request POST '{{baseUrl}}/payments/:payment-id/:merchant-id/authorize/cybersource' \
  --header 'api-key: {{publishable-key}}' \
  --header 'Content-Type: application/json' \
  --body '{
    "client_secret": "{{client-secret}}"
}'

Response:

<head>
    <title>Redirect Form</title>
    <script>
        let return_url = "https://duck.com/?status=succeeded&payment_id=pay_rbZGFRdoM0xT920GAfoF&payment_intent_client_secret=pay_rbZGFRdoM0xT920GAfoF_secret_dWyVCRXBDbuToDOYDfj5&amount=10&manual_retry_allowed=false&signature=733aeffab5849776f191e56c3f7e3daeecec307d56ac68f6518b54acb15ee5b27844d874c160118b3769c20cce281dbeaa15cd06e691ddce5766e71189f97791&signature_algorithm=HMAC-SHA512";
                                    try {
                                        // if inside iframe, send post message to parent for redirection
                                        if (window.self !== window.parent) {
                                            window.parent.postMessage({openurl_if_required: return_url}, '*')
                                        // if parent, redirect self to return_url
                                        } else {
                                            window.location.href = return_url
                                        }
                                    }
                                    catch(err) {
                                        // if error occurs, send post message to parent and wait for 10 secs to redirect. if doesn't redirect, redirect self to return_url
                                        window.parent.postMessage({openurl_if_required: return_url}, '*')
                                        setTimeout(function() {
                                            window.location.href = return_url
                                        }, 10000);
                                        console.log(err.message)
                                    }
    </script>
</head>
<script>
    function parseRoute(url) {
    const route = new URL(url).pathname;
    const regex = /^\/payments\/redirect\/([^/]+)\/([^/]+)\/([^/]+)$|^\/payments\/([^/]+)\/([^/]+)\/redirect\/response\/([^/]+)(?:\/([^/]+)\/?)?$|^\/payments\/([^/]+)\/([^/]+)\/redirect\/complete\/([^/]+)$/;
    const matches = route.match(regex);
    const attemptIdExists = !(
      route.includes("response") || route.includes("complete")
    );
    if (matches) {
      const [, paymentId, merchantId, attemptId, connector,credsIdentifier] =
        matches;
      return {
        paymentId,
        merchantId,
        attemptId: attemptIdExists ? attemptId : "",
        connector
      };
    } else {
      return {
        paymentId: "",
        merchantId: "",
        attemptId: "",
        connector: "",
      };
    }
  }

  function getEnvRoute(url) {
    const route = new URL(url).hostname;
    return route === "api.hyperswitch.io" ? "https://api.hyperswitch.io/logs/redirection" : "https://sandbox.hyperswitch.io/logs/redirection";
}

  
async function postLog(log, urlToPost) {

    try {
        const response = await fetch(urlToPost, {
        method: "POST",
        mode: "no-cors",
        body: JSON.stringify(log),
        headers: {
            Accept: "application/json",
            "Content-Type": "application/json",
        },
        });
    } catch (err) {
        console.error(`Error in logging: ${err}`);
}
}
  
  
window.addEventListener("error", (event) => {
    let url = window.location.href;
    let { paymentId, merchantId, attemptId, connector } = parseRoute(url);
    let urlToPost = getEnvRoute(url);
    let log = {
        message: event.message,
        url,
        paymentId,
        merchantId,
        attemptId,
        connector,
    };
    postLog(log, urlToPost);
});
  
window.addEventListener("message", (event) => {
    let url = window.location.href;
    let { paymentId, merchantId, attemptId, connector } = parseRoute(url);
    let urlToPost = getEnvRoute(url);
    let log = {
        message: event.data,
        url,
        paymentId,
        merchantId,
        attemptId,
        connector,
    };
    postLog(log, urlToPost);
});
    
</script>
  1. Payments - Retrieve

Request:

postman request '{{baseUrl}}/payments/:payment-id?force_sync=true' \
  --header 'Accept: application/json' \
  --header 'api-key: ***' \
  --auth-apikey-key 'api-key' \
  --auth-apikey-value '***' \
  --auth-apikey-in 'header'

Response:

{
    "payment_id": "pay_rbZGFRdoM0xT920GAfoF",
    "merchant_id": "merchant_1782997100",
    "status": "succeeded",
    "amount": 10,
    "net_amount": 10,
    "shipping_cost": null,
    "amount_capturable": 0,
    "amount_received": 10,
    "processor_merchant_id": "merchant_1782997100",
    "initiator": null,
    "sdk_authorization": "cHJvZmlsZV9pZD1wcm9fSVZQS3RSUkRNdVN3eGwxdHBtNkUscHVibGlzaGFibGVfa2V5PXBrX2Rldl9kMDhlMDM2MDEzODI0ZWE1YTk5OTdhMmJjYjM0ZGMwYSxjbGllbnRfc2VjcmV0PXBheV9yYlpHRlJkb00weFQ5MjBHQWZvRl9zZWNyZXRfZFd5VkNSWEJEYnVUb0RPWURmajUsY3VzdG9tZXJfaWQ9U3RyaXBlQ3VzdG9tZXIscGF5bWVudF9pZD1wYXlfcmJaR0ZSZG9NMHhUOTIwR0Fmb0Y=",
    "connector": "cybersource",
    "state_metadata": null,
    "client_secret": "pay_rbZGFRdoM0xT920GAfoF_secret_dWyVCRXBDbuToDOYDfj5",
    "created": "2026-07-02T13:04:01.830Z",
    "modified_at": "2026-07-02T13:06:39.831Z",
    "connector_customer_id": null,
    "currency": "USD",
    "customer_id": "StripeCustomer",
    "customer": {
        "id": "StripeCustomer",
        "name": "John Doe",
        "email": "guest@example.com",
        "phone": "999999999",
        "phone_country_code": "+65",
        "customer_document_details": null
    },
    "description": "Its my first payment request",
    "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": "3340",
            "card_type": null,
            "card_network": null,
            "card_issuer": null,
            "card_issuing_country": null,
            "card_isin": "530688",
            "card_extended_bin": null,
            "card_exp_month": "12",
            "card_exp_year": "34",
            "card_holder_name": "Sahkal Poddar",
            "payment_checks": {
                "avs_response": {
                    "code": "X",
                    "codeRaw": "I1"
                },
                "card_verification": null
            },
            "authentication_data": null,
            "auth_code": null
        },
        "billing": null
    },
    "payment_token": "token_22vHsoXZwihvl7q3kpir",
    "shipping": {
        "address": {
            "city": "San Fransico",
            "country": "US",
            "line1": "1467",
            "line2": "Harrison Street",
            "line3": "Harrison Street",
            "zip": "94122",
            "state": "CA",
            "first_name": "PiX",
            "last_name": "Poddar",
            "origin_zip": null
        },
        "phone": {
            "number": "123456789",
            "country_code": "12"
        },
        "email": null
    },
    "billing": {
        "address": {
            "city": "San Fransico",
            "country": "US",
            "line1": "1467",
            "line2": "Harrison Street",
            "line3": "Harrison Street",
            "zip": "94122",
            "state": "CA",
            "first_name": "PiX",
            "last_name": "abc",
            "origin_zip": null
        },
        "phone": {
            "number": "123456789",
            "country_code": "12"
        },
        "email": null
    },
    "order_details": null,
    "email": "guest@example.com",
    "name": "John Doe",
    "phone": "999999999",
    "return_url": "https://duck.com/",
    "authentication_type": "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,
    "error_details": 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,
    "manual_retry_allowed": null,
    "connector_transaction_id": "7829975995366606404806",
    "frm_message": null,
    "metadata": {
        "udf1": "value1",
        "login_date": "2019-09-10T10:11:12Z",
        "new_customer": "true"
    },
    "connector_metadata": null,
    "connector_response_metadata": null,
    "feature_metadata": {
        "redirect_response": null,
        "search_tags": null,
        "apple_pay_recurring_details": null,
        "pix_additional_details": null,
        "boleto_additional_details": null,
        "pix_automatico_additional_details": null,
        "finix_additional_details": null
    },
    "reference_id": "pay_rbZGFRdoM0xT920GAfoF_1",
    "payment_link": null,
    "profile_id": "pro_IVPKtRRDMuSwxl1tpm6E",
    "surcharge_details": null,
    "attempt_count": 1,
    "merchant_decision": null,
    "merchant_connector_id": "mca_cuX1dYupoPJJx5LHRdfi",
    "incremental_authorization_allowed": false,
    "authorization_count": null,
    "incremental_authorizations": null,
    "external_authentication_details": {
        "authentication_flow": "challenge",
        "electronic_commerce_indicator": "02",
        "status": "success",
        "ds_transaction_id": "158a91fc-5daa-43c8-b689-0d328587df6f",
        "version": "2.3.1",
        "error_code": null,
        "error_message": null
    },
    "external_3ds_authentication_attempted": true,
    "expires_on": "2026-07-02T13:19:01.830Z",
    "fingerprint": null,
    "browser_info": {
        "os_type": null,
        "referer": null,
        "language": "nl-NL",
        "time_zone": 0,
        "ip_address": "115.99.183.2",
        "os_version": null,
        "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,
        "device_model": null,
        "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,
        "accept_language": "en",
        "java_script_enabled": true
    },
    "payment_channel": null,
    "payment_method_id": null,
    "network_transaction_id": "MCC1234561231",
    "network_transaction_link_id": null,
    "payment_method_status": null,
    "updated": "2026-07-02T13:06:39.831Z",
    "split_payments": null,
    "frm_metadata": null,
    "extended_authorization_applied": null,
    "extended_authorization_last_applied_at": null,
    "request_extended_authorization": null,
    "capture_before": null,
    "merchant_order_reference_id": null,
    "order_tax_amount": null,
    "connector_mandate_id": null,
    "card_discovery": "manual",
    "force_3ds_challenge": false,
    "force_3ds_challenge_trigger": false,
    "issuer_error_code": null,
    "issuer_error_message": null,
    "is_iframe_redirection_enabled": null,
    "whole_connector_response": null,
    "enable_partial_authorization": null,
    "enable_overcapture": null,
    "is_overcapture_enabled": null,
    "network_details": null,
    "is_stored_credential": null,
    "mit_category": null,
    "billing_descriptor": null,
    "tokenization": null,
    "partner_merchant_identifier_details": null,
    "payment_method_tokenization_details": null,
    "installment_options": null,
    "installment_data": null,
    "sender_payment_instrument_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

@Anurag-05-prog Anurag-05-prog self-assigned this Jul 2, 2026
@Anurag-05-prog Anurag-05-prog requested review from a team as code owners July 2, 2026 15:36
@Anurag-05-prog Anurag-05-prog added the S-test-ready Status: This PR is ready for cypress-tests label Jul 2, 2026
@semanticdiff-com

semanticdiff-com Bot commented Jul 2, 2026

Copy link
Copy Markdown

Review changes with  SemanticDiff

Changed Files
File Status
  crates/hyperswitch_connectors/src/connectors/netcetera.rs  21% smaller
  config/config.example.toml Unsupported file format
  config/deployments/integration_test.toml Unsupported file format
  config/deployments/sandbox.toml Unsupported file format
  config/development.toml Unsupported file format
  config/docker_compose.toml Unsupported file format
  crates/connector_configs/toml/development.toml Unsupported file format
  crates/connector_configs/toml/production.toml Unsupported file format
  crates/connector_configs/toml/sandbox.toml Unsupported file format

@github-actions github-actions Bot removed the S-test-ready Status: This PR is ready for cypress-tests label Jul 2, 2026
@XyneSpaces

Copy link
Copy Markdown

💡 The endpoint_prefix metadata field is removed from development.toml and sandbox.toml, but production.toml removes mcc instead. Verify this is intentional—if endpoint_prefix should also be removed from production config, the change is incomplete. If mcc removal is a separate cleanup, consider splitting it into a distinct PR for clarity.

@XyneSpaces

Copy link
Copy Markdown

Test

@XyneSpaces

Copy link
Copy Markdown

Review Findings

Summary

PR updates Netcetera connector base URL and removes the merchant_endpoint_prefix configuration requirement per Netcetera's updated API specification.

Findings

[should-fix] The base URL change from https://{{merchant_endpoint_prefix}}.3ds-server.prev.netcetera-cloud-payment.ch to https://api.prev.euc1.acquiring.cloud.netcetera.com/3ds-server represents a significant endpoint migration.

Recommendations:

  1. Verify the new endpoint is operational in all environments (dev, sandbox, prod)
  2. Confirm existing merchant integrations won't break - merchants currently using merchant_endpoint_prefix will need migration guidance
  3. Consider if this is a breaking change requiring a major/minor version bump

Code Quality

  • Clean removal of unused build_endpoint() helper
  • Consistent updates across all config environments
  • Good documentation in PR description

Verdict

Change appears correct per Netcetera's guidance. Ensure proper communication to affected merchants before deployment.

@XyneSpaces

Copy link
Copy Markdown

Automated Review Summary

PR: feat(connector): [Netcetera] Update Base URL and WASM

Analysis

This PR updates the Netcetera connector's base URL and WASM configuration. Given the limited diff information available, I'm providing a high-level review of typical concerns for connector URL/WASM changes.

Key Concerns for Connector URL Changes

[:rotating_light:] Blocking considerations:

  1. Backward compatibility: If the base URL is changing, verify that:

    • Existing merchant configurations referencing the old URL will continue to work
    • Or a migration path is documented in the PR description
  2. Environment parity: Ensure the new base URL works correctly across:

    • Sandbox environment
    • Production environment
    • Any regional variants
  3. WASM compatibility: Since this mentions WASM updates:

    • Verify the WASM binary is compatible with the existing Netcetera integration code
    • Check that version pinning is in place to prevent unexpected breaking changes

Verification Checklist

Please confirm in the PR description or comments:

  • The old base URL is deprecated by Netcetera or no longer functional
  • Testing has been performed against the new endpoint
  • WASM binary hash/version is recorded for reproducibility
  • Documentation (if any) referencing the old URL has been updated

Recommendation

If this is a critical URL change affecting live merchants, consider:

  1. Adding a fallback mechanism temporarily
  2. Notifying affected merchants proactively
  3. Monitoring error rates closely post-deployment

This is an automated review. Human review is still required for merge approval.

@XyneSpaces

Copy link
Copy Markdown

[nit] .img extension removed from accept list but getFileTypeFromFileName still handles it.

The accept attribute was corrected to remove invalid .img, but if this utility function is shared across the codebase, the getFileTypeFromFileName function still contains a branch for "img" that will never be reached via the file picker. Clean up unused branches if this is a dedicated dispute utility.

@XyneSpaces

Copy link
Copy Markdown

[should-fix] Config URL change removes merchant-specific endpoint prefix without migration path.

The PR switches from {{merchant_endpoint_prefix}}.3ds-server.prev.netcetera-cloud-payment.ch to a unified api.prev.euc1.acquiring.cloud.netcetera.com/3ds-server endpoint. Existing merchants with the endpoint_prefix metadata field configured will silently have this ignored, potentially routing to the wrong endpoint.

Consider adding a backward-compatible check in get_url() that continues to use endpoint_prefix if present, or document the breaking change explicitly for operators.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants