{"title":"Redirect 3DS Drop-in integration","category":"default","creationDate":1776961627,"content":"<p>Our <a href=\"\/pt\/online-payments\/build-your-integration\/sessions-flow?platform=Android&amp;integration=Drop-in\">Android Drop-in<\/a> renders the available cards in your payment form, and securely collects any sensitive card information, so it doesn't touch your server. Drop-in also redirects the shopper to perform 3D Secure 2 authentication.<\/p>\n<p>When adding card payments with redirect 3D Secure authentication to your integration, you additionally need to:<\/p>\n<ol>\n<li><a href=\"#key\">Configure Drop-in<\/a> to collect the card holder name.<\/li>\n<li><a href=\"#make-a-payment\">Provide the required 3D Secure parameters<\/a> when making a payment request.<\/li>\n<li><a href=\"#handle-the-redirect\">Handle the redirect<\/a> after the shopper returns to your website.<\/li>\n<\/ol>\n<div class=\"notices green\">\n<p>This page describes the integration steps for <a href=\"\/pt\/online-payments\/release-notes\">Android Drop-in v4.0.0 or later<\/a>.<\/p>\n<\/div>\n<h2>Requirements<\/h2>\n<p>This page explains how to add cards with redirect 3D Secure authentication to your existing Android Drop-in integration. The Android Drop-in integration works the same way for all payment methods. If you haven't done this integration yet, refer to our <a href=\"\/pt\/online-payments\/build-your-integration\/sessions-flow?platform=Android&amp;integration=Drop-in\">Drop-in integration guide<\/a>.<\/p>\n<p>Before you begin your integration:<\/p>\n<ol>\n<li>Make sure that you have <a href=\"\/pt\/online-payments\/build-your-integration\/sessions-flow?platform=Android&amp;integration=Drop-in\">set up your back end implementation<\/a>, and <a href=\"\/pt\/online-payments\/build-your-integration\/sessions-flow\/?platform=Android&amp;integration=Drop-in#set-up\">added Drop-in to your payment form<\/a>.<\/li>\n<li><a href=\"\/pt\/payment-methods\/add-payment-methods\">Add the cards that you want to accept in your test Customer Area<\/a>.<\/li>\n<li>If you are using 3D Secure for PSD2 compliance, read our <a href=\"\/pt\/online-payments\/psd2-sca-compliance-and-implementation-guide\">comprehensive PSD2 SCA guide<\/a>.<\/li>\n<\/ol>\n<h2>Collect additional parameters in your payment form<\/h2>\n<p>For higher authentication rates, we strongly recommend that you collect the shopper's billing address and email address in advance in your payment form. Deliver these parameters to your backend when <a href=\"#make-a-payment\">making a payment<\/a> as they are required by the card schemes.<\/p>\n<h2>Show the available cards in your payment form<\/h2>\n<div class=\"additional-info-block output-inline\">\n<div class=\"additional-info-block__body\"><p>For information about the supported countries\/regions and currencies for each card, refer to <a href=\"https:\/\/www.adyen.com\/payment-methods\" target=\"_blank\" rel=\"nofollow noopener noreferrer\" class=\"external-link no-image\">Payment methods<\/a>.<\/p><\/div><\/div>\n\n<p>To show cards in your payment form:<\/p>\n<ol>\n<li>\n<p>Specify in your  <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/paymentMethods\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">\/paymentMethods<\/a> request a combination of  <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/paymentMethods\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">countryCode<\/a> and  <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/paymentMethods#request-amount\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">amount.currency<\/a>. Drop-in uses this information to show the available cards to your shopper.<\/p>\n<\/li>\n<li>\n<p><a id=\"key\"><\/a>When <a href=\"\/pt\/online-payments\/build-your-integration\/sessions-flow\/?platform=Android&amp;integration=Drop-in#launch-and-show\">creating an instance of Drop-in<\/a>, create a configuration object, and pass your <a href=\"\/pt\/development-resources\/client-side-authentication\/#get-your-client-key\">client key<\/a>. To make sure you collect the cardholder name, set <code>holderNameRequired<\/code> to <strong>true<\/strong>.<\/p>\n<\/li>\n<\/ol>\n<pre><code class=\"language-kotlin\">val cardConfiguration = CardConfiguration.Builder(context, \"YOUR_CLIENT_KEY\")\n  \/\/ Makes the cardholder name required\n  .setHolderNameRequired(true)\n  \/\/ When you are ready to accept live payments, change the value to one of our live environments.\n  .setEnvironment(Environment.TEST)\n  .build()\n\nval dropInConfiguration = DropInConfiguration.Builder(context, YourDropInService::class.java, \"YOUR_CLIENT_KEY\")\n   \/\/ When you are ready to accept live payments, change the value to one of our live environments.\n   .setEnvironment(Environment.TEST)\n   .addCardConfiguration(cardConfiguration)\n   .build()<\/code><\/pre>\n<h2 id=\"make-a-payment\">Make a payment<\/h2>\n<p>When the shopper proceeds to pay, Drop-in returns the <code>paymentComponentData.paymentMethod<\/code>.<\/p>\n<ol>\n<li>Pass the <code>paymentComponentData.paymentMethod<\/code> object to your server.<\/li>\n<li>\n<p>When you <a href=\"\/pt\/online-payments\/build-your-integration\/advanced-flow?platform=Android&amp;integration=Drop-in&amp;version=latest#make-a-payment\">make a payment request<\/a>, include the following additional 3D Secure 2 parameters.<\/p>\n<div class=\"notices green\">\n<p>See additional 3D Secure 2 parameters that we recommend to include in your request to increase authentication performance in our <a href=\"\/pt\/online-payments\/3d-secure\/api-reference\">API reference<\/a>.<\/p>\n<\/div>\n<\/li>\n<\/ol>\n<table>\n<thead>\n<tr>\n<th style=\"text-align: left;\">Parameter name<\/th>\n<th style=\"text-align: center;\">Required<\/th>\n<th style=\"text-align: left;\">Description<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td style=\"text-align: left;\"> <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments#request-paymentMethod\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">paymentMethod<\/a><\/td>\n<td style=\"text-align: center;\"><span class=\"hint--bottom\" data-hint=\"Required\" markdown=\"1\"><img style=\"width: 25px;\" alt=\"Required\" src=\"\/user\/pages\/reuse\/image-library\/01.icons\/required\/required.svg?decoding=auto&amp;fetchpriority=auto\" \/><\/span><\/td>\n<td style=\"text-align: left;\">The type and required details for a card payment method. The <code>paymentComponentData.paymentMethod<\/code> object from your client app.<\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"> <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments#request-paymentMethod-CardDetails-holderName\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">paymentMethod.holderName<\/a><\/td>\n<td style=\"text-align: center;\"><span class=\"hint--bottom\" data-hint=\"Conditionally required\" markdown=\"1\"><img style=\"width: 25px;\" alt=\"Conditionally required\" src=\"\/user\/pages\/reuse\/image-library\/01.icons\/conditionally-required\/conditionally-required.svg?decoding=auto&amp;fetchpriority=auto\" \/><\/span><\/td>\n<td style=\"text-align: left;\"><strong>Use case<\/strong>: required for Visa and JCB transactions. <br> The cardholder's name.<\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"> <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments#request-channel\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">channel<\/a><\/td>\n<td style=\"text-align: center;\"><span class=\"hint--bottom\" data-hint=\"Required\" markdown=\"1\"><img style=\"width: 25px;\" alt=\"Required\" src=\"\/user\/pages\/reuse\/image-library\/01.icons\/required\/required.svg?decoding=auto&amp;fetchpriority=auto\" \/><\/span><\/td>\n<td style=\"text-align: left;\">The platform where the transaction takes place. Set to <strong>Android<\/strong>.<\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"> <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments#request-returnUrl\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">returnUrl<\/a><\/td>\n<td style=\"text-align: center;\"><span class=\"hint--bottom\" data-hint=\"Required\" markdown=\"1\"><img style=\"width: 25px;\" alt=\"Required\" src=\"\/user\/pages\/reuse\/image-library\/01.icons\/required\/required.svg?decoding=auto&amp;fetchpriority=auto\" \/><\/span><\/td>\n<td style=\"text-align: left;\">The URL where the shopper will be redirected back to after completing 3D Secure authentication. Get this URL from Drop-in in the <code>RedirectComponent.getReturnUrl(context)<\/code>. <br> <strong>Format<\/strong>: <ul><li markdown=\"1\">Maximum characters: 1024.<\/li><li markdown=\"1\">Must not include <code>\/\/<\/code> (double slash) after the top-level domain.<\/li><\/ul><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"> <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments#request-browserInfo\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">browserInfo<\/a><\/td>\n<td style=\"text-align: center;\"><span class=\"hint--bottom\" data-hint=\"Required\" markdown=\"1\"><img style=\"width: 25px;\" alt=\"Required\" src=\"\/user\/pages\/reuse\/image-library\/01.icons\/required\/required.svg?decoding=auto&amp;fetchpriority=auto\" \/><\/span><\/td>\n<td style=\"text-align: left;\">The shopper's browser information. The following sub-fields are required: <ul><li markdown=\"1\"> <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments#request-browserInfo-acceptHeader\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">acceptHeader<\/a>: The accept header value of the shopper's browser. You can use a dummy value.<\/li><li>  <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments#request-browserInfo-userAgent\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">userAgent<\/a>: Get it using <a href=\"https:\/\/developer.android.com\/reference\/android\/webkit\/WebSettings#getDefaultUserAgent(android.content.Context)\" target=\"_blank\" rel=\"nofollow noopener noreferrer\" class=\"external-link no-image\">\n  <code>WebSettings.getDefaultUserAgent(Context);<\/code>\n<\/a>.<\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"> <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments#request-shopperIP\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">shopperIP<\/a><\/td>\n<td style=\"text-align: center;\"><span class=\"hint--bottom\" data-hint=\"Conditionally required\" markdown=\"1\"><img style=\"width: 25px;\" alt=\"Conditionally required\" src=\"\/user\/pages\/reuse\/image-library\/01.icons\/conditionally-required\/conditionally-required.svg?decoding=auto&amp;fetchpriority=auto\" \/><\/span><\/td>\n<td style=\"text-align: left;\"><strong>Use case<\/strong>: required for Visa and JCB transactions. <br> The shopper's IP address.<\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"> <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments#request-shopperEmail\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">shopperEmail<\/a><\/td>\n<td style=\"text-align: center;\"><span class=\"hint--bottom\" data-hint=\"Conditionally required\" markdown=\"1\"><img style=\"width: 25px;\" alt=\"Conditionally required\" src=\"\/user\/pages\/reuse\/image-library\/01.icons\/conditionally-required\/conditionally-required.svg?decoding=auto&amp;fetchpriority=auto\" \/><\/span><\/td>\n<td style=\"text-align: left;\"><strong>Use case<\/strong>: required for Visa and JCB transactions. <br> The cardholder's email address. If you do not include the shopper email, you must include the shopper's phone number in your request.<\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"> <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments#request-telephoneNumber\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">telephoneNumber<\/a><\/td>\n<td style=\"text-align: center;\"><span class=\"hint--bottom\" data-hint=\"Conditionally required\" markdown=\"1\"><img style=\"width: 25px;\" alt=\"Conditionally required\" src=\"\/user\/pages\/reuse\/image-library\/01.icons\/conditionally-required\/conditionally-required.svg?decoding=auto&amp;fetchpriority=auto\" \/><\/span><\/td>\n<td style=\"text-align: left;\"><strong>Use case<\/strong>: required for Visa and JCB transactions if you did not include the <code>shopperEmail<\/code> field. <br>The shopper's phone number. To be more specific, you can use the <code>mobilePhone<\/code>, <code>homePhone<\/code>, and <code>workPhone<\/code> fields in the <code>threeDS2RequestData<\/code> object.  <br> <strong>Format<\/strong>: The phone number must include a plus sign (+) and a country code (1-3 digits), followed by the number (4-15 digits). <br>  <strong>Example<\/strong>: <strong>+4912345678901<\/strong> <div class=\"sc-notice note\"><div> If the value you provide does not follow the guidelines, we drop the value and do not submit it for authentication. <\/div><\/div><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><img alt=\"This is the required icon.\" src=\"\/user\/pages\/reuse\/image-library\/01.icons\/requirements-legend\/required.svg?decoding=auto&amp;fetchpriority=auto\" \/> Required for all transactions. <br><img alt=\"This is the conditionally required icon.\" src=\"\/user\/pages\/reuse\/image-library\/01.icons\/requirements-legend\/conditionally-required.svg?decoding=auto&amp;fetchpriority=auto\" \/> Required for particular setups, or issuers and card schemes. <br><img alt=\"This is the recommended icon.\" src=\"\/user\/pages\/reuse\/image-library\/01.icons\/requirements-legend\/recommended.svg?decoding=auto&amp;fetchpriority=auto\" \/> Recommended for all transactions, but not required.<\/p>\n<div data-component-wrapper=\"code-sample\">\n    <code-sample :title=\"''\" :id=\"'payments-request-3ds-redirect-mobile'\" :code-data=\"[{&quot;language&quot;:&quot;bash&quot;,&quot;tabTitle&quot;:&quot;curl&quot;,&quot;content&quot;:&quot;curl https:\\\/\\\/checkout-test.adyen.com\\\/v72\\\/payments \\\\\\n-H 'x-api-key: ADYEN_API_KEY' \\\\\\n-H 'content-type: application\\\/json' \\\\\\n-d '{\\n   \\&quot;amount\\&quot;:{\\n      \\&quot;currency\\&quot;:\\&quot;EUR\\&quot;,\\n      \\&quot;value\\&quot;:1000\\n   },\\n   \\&quot;reference\\&quot;:\\&quot;YOUR_ORDER_NUMBER\\&quot;,\\n   \\&quot;shopperReference\\&quot;:\\&quot;YOUR_UNIQUE_SHOPPER_ID\\&quot;,\\n   \\&quot;{hint:state.data.paymentMethod from didSubmit}paymentMethod{\\\/hint}\\&quot;:{\\n      \\&quot;type\\&quot;:\\&quot;scheme\\&quot;,\\n      \\&quot;encryptedCardNumber\\&quot;:\\&quot;adyenjs_0_1_18$k7s65M5V0KdPxTErhBIPoMPI8HlC..\\&quot;,\\n      \\&quot;encryptedExpiryMonth\\&quot;:\\&quot;adyenjs_0_1_18$p2OZxW2XmwAA8C1Avxm3G9UB6e4..\\&quot;,\\n      \\&quot;encryptedExpiryYear\\&quot;:\\&quot;adyenjs_0_1_18$CkCOLYZsdqpxGjrALWHj3QoGHqe+..\\&quot;,\\n      \\&quot;encryptedSecurityCode\\&quot;:\\&quot;adyenjs_0_1_24$XUyMJyHebrra\\\/TpSda9fha978+..\\&quot;,\\n      \\&quot;holderName\\&quot;:\\&quot;S. Hopper\\&quot;\\n   },\\n   \\&quot;{hint:state.data.billingAddress from onSubmit}billingAddress{\\\/hint}\\&quot;: {\\n      \\&quot;street\\&quot;: \\&quot;Infinite Loop\\&quot;,\\n      \\&quot;houseNumberOrName\\&quot;: \\&quot;1\\&quot;,\\n      \\&quot;postalCode\\&quot;: \\&quot;1011DJ\\&quot;,\\n      \\&quot;city\\&quot;: \\&quot;Amsterdam\\&quot;,\\n      \\&quot;country\\&quot;: \\&quot;NL\\&quot;\\n   },\\n   \\&quot;browserInfo\\&quot;: {\\n      \\&quot;userAgent\\&quot;:\\&quot;Mozilla\/5.0 (Linux; Android 6.0.1; Nexus 6P Build\/MMB29P) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/47.0.2526.83 Mobile Safari\/537.36\\&quot;,\\n      \\&quot;acceptHeader\\&quot;:\\&quot;text\\\\\\\/html,application\\\\\\\/xhtml+xml,application\\\\\\\/xml;q=0.9,image\\\\\\\/webp,image\\\\\\\/apng,*\\\\\\\/*;q=0.8\\&quot;\\n   },\\n   \\&quot;shopperEmail\\&quot;:\\&quot;s.hopper@example.com\\&quot;,\\n   \\&quot;channel\\&quot;:\\&quot;Android\\&quot;,\\n   \\&quot;returnUrl\\&quot;:\\&quot;adyencheckout:\/\/your.package.name\\&quot;,\\n   \\&quot;merchantAccount\\&quot;:\\&quot;YOUR_MERCHANT_ACCOUNT\\&quot;\\n}'&quot;},{&quot;language&quot;:&quot;java&quot;,&quot;tabTitle&quot;:&quot;Java&quot;,&quot;content&quot;:&quot;\\\/\\\/ Adyen Java API Library v27.0.0\\nimport com.adyen.Client;\\nimport com.adyen.enums.Environment;\\nimport com.adyen.model.checkout.*;\\nimport java.time.OffsetDateTime;\\nimport java.util.*;\\nimport com.adyen.model.RequestOptions;\\nimport com.adyen.service.checkout.*;\\n\\n\\\/\\\/ For the live environment, additionally include your liveEndpointUrlPrefix.\\nClient client = new Client(\\&quot;ADYEN_API_KEY\\&quot;, Environment.TEST);\\n\\n\\\/\\\/ Create the request object(s)\\nAmount amount = new Amount()\\n  .currency(\\&quot;EUR\\&quot;)\\n  .value(1000L);\\n\\nCardDetails cardDetails = new CardDetails()\\n  .encryptedCardNumber(\\&quot;adyenjs_0_1_18$k7s65M5V0KdPxTErhBIPoMPI8HlC..\\&quot;)\\n  .holderName(\\&quot;S. Hopper\\&quot;)\\n  .encryptedSecurityCode(\\&quot;adyenjs_0_1_24$XUyMJyHebrra\\\/TpSda9fha978+..\\&quot;)\\n  .encryptedExpiryYear(\\&quot;adyenjs_0_1_18$CkCOLYZsdqpxGjrALWHj3QoGHqe+..\\&quot;)\\n  .encryptedExpiryMonth(\\&quot;adyenjs_0_1_18$p2OZxW2XmwAA8C1Avxm3G9UB6e4..\\&quot;)\\n  .type(CardDetails.TypeEnum.SCHEME);\\n\\nBillingAddress billingAddress = new BillingAddress()\\n  .country(\\&quot;NL\\&quot;)\\n  .city(\\&quot;Amsterdam\\&quot;)\\n  .street(\\&quot;Infinite Loop\\&quot;)\\n  .houseNumberOrName(\\&quot;1\\&quot;)\\n  .postalCode(\\&quot;1011DJ\\&quot;);\\n\\nBrowserInfo browserInfo = new BrowserInfo()\\n  .acceptHeader(\\&quot;text\\\/html,application\\\/xhtml+xml,application\\\/xml;q=0.9,image\\\/webp,image\\\/apng,*\\\/*;q=0.8\\&quot;)\\n  .userAgent(\\&quot;Mozilla\/5.0 (Linux; Android 6.0.1; Nexus 6P Build\/MMB29P) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/47.0.2526.83 Mobile Safari\/537.36\\&quot;);\\n\\nPaymentRequest paymentRequest = new PaymentRequest()\\n  .reference(\\&quot;YOUR_ORDER_NUMBER\\&quot;)\\n  .amount(amount)\\n  .merchantAccount(\\&quot;YOUR_MERCHANT_ACCOUNT\\&quot;)\\n  .channel(PaymentRequest.ChannelEnum.)\\n  .paymentMethod(new CheckoutPaymentMethod(cardDetails))\\n  .shopperEmail(\\&quot;s.hopper@example.com\\&quot;)\\n  .billingAddress(billingAddress)\\n  .returnUrl(\\&quot;adyencheckout:\/\/your.package.name\\&quot;)\\n  .browserInfo(browserInfo)\\n  .shopperReference(\\&quot;YOUR_UNIQUE_SHOPPER_ID\\&quot;);\\n\\n\\\/\\\/ Send the request\\nPaymentsApi service = new PaymentsApi(client);\\nPaymentResponse response = service.payments(paymentRequest, new RequestOptions().idempotencyKey(\\&quot;UUID\\&quot;));&quot;},{&quot;language&quot;:&quot;php&quot;,&quot;tabTitle&quot;:&quot;PHP&quot;,&quot;content&quot;:&quot;\\\/\\\/ Adyen PHP API Library v19.0.0\\nuse Adyen\\\\Client;\\nuse Adyen\\\\Environment;\\nuse Adyen\\\\Model\\\\Checkout\\\\Amount;\\nuse Adyen\\\\Model\\\\Checkout\\\\CheckoutPaymentMethod;\\nuse Adyen\\\\Model\\\\Checkout\\\\BillingAddress;\\nuse Adyen\\\\Model\\\\Checkout\\\\BrowserInfo;\\nuse Adyen\\\\Model\\\\Checkout\\\\PaymentRequest;\\nuse Adyen\\\\Service\\\\Checkout\\\\PaymentsApi;\\n\\n$client = new Client();\\n$client-&gt;setXApiKey(\\&quot;ADYEN_API_KEY\\&quot;);\\n\\\/\\\/ For the live environment, additionally include your liveEndpointUrlPrefix.\\n$client-&gt;setEnvironment(Environment::TEST);\\n\\n\\n\\\/\\\/ Create the request object(s)\\n$amount = new Amount();\\n$amount\\n  -&gt;setCurrency(\\&quot;EUR\\&quot;)\\n  -&gt;setValue(1000);\\n\\n$checkoutPaymentMethod = new CheckoutPaymentMethod();\\n$checkoutPaymentMethod\\n  -&gt;setEncryptedCardNumber(\\&quot;adyenjs_0_1_18\\\\$k7s65M5V0KdPxTErhBIPoMPI8HlC..\\&quot;)\\n  -&gt;setHolderName(\\&quot;S. Hopper\\&quot;)\\n  -&gt;setEncryptedSecurityCode(\\&quot;adyenjs_0_1_24\\\\$XUyMJyHebrra\\\/TpSda9fha978+..\\&quot;)\\n  -&gt;setEncryptedExpiryYear(\\&quot;adyenjs_0_1_18\\\\$CkCOLYZsdqpxGjrALWHj3QoGHqe+..\\&quot;)\\n  -&gt;setEncryptedExpiryMonth(\\&quot;adyenjs_0_1_18\\\\$p2OZxW2XmwAA8C1Avxm3G9UB6e4..\\&quot;)\\n  -&gt;setType(\\&quot;scheme\\&quot;);\\n\\n$billingAddress = new BillingAddress();\\n$billingAddress\\n  -&gt;setCountry(\\&quot;NL\\&quot;)\\n  -&gt;setCity(\\&quot;Amsterdam\\&quot;)\\n  -&gt;setStreet(\\&quot;Infinite Loop\\&quot;)\\n  -&gt;setHouseNumberOrName(\\&quot;1\\&quot;)\\n  -&gt;setPostalCode(\\&quot;1011DJ\\&quot;);\\n\\n$browserInfo = new BrowserInfo();\\n$browserInfo\\n  -&gt;setAcceptHeader(\\&quot;text\\\/html,application\\\/xhtml+xml,application\\\/xml;q=0.9,image\\\/webp,image\\\/apng,*\\\/*;q=0.8\\&quot;)\\n  -&gt;setUserAgent(\\&quot;Mozilla\/5.0 (Linux; Android 6.0.1; Nexus 6P Build\/MMB29P) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/47.0.2526.83 Mobile Safari\/537.36\\&quot;);\\n\\n$paymentRequest = new PaymentRequest();\\n$paymentRequest\\n  -&gt;setReference(\\&quot;YOUR_ORDER_NUMBER\\&quot;)\\n  -&gt;setAmount($amount)\\n  -&gt;setMerchantAccount(\\&quot;YOUR_MERCHANT_ACCOUNT\\&quot;)\\n  -&gt;setChannel(\\&quot;Android\\&quot;)\\n  -&gt;setPaymentMethod($checkoutPaymentMethod)\\n  -&gt;setShopperEmail(\\&quot;s.hopper@example.com\\&quot;)\\n  -&gt;setBillingAddress($billingAddress)\\n  -&gt;setReturnUrl(\\&quot;adyencheckout:\/\/your.package.name\\&quot;)\\n  -&gt;setBrowserInfo($browserInfo)\\n  -&gt;setShopperReference(\\&quot;YOUR_UNIQUE_SHOPPER_ID\\&quot;);\\n\\n$requestOptions['idempotencyKey'] = 'UUID';\\n\\n\\\/\\\/ Send the request\\n$service = new PaymentsApi($client);\\n$response = $service-&gt;payments($paymentRequest, $requestOptions);&quot;},{&quot;language&quot;:&quot;cs&quot;,&quot;tabTitle&quot;:&quot;C#&quot;,&quot;content&quot;:&quot;\\\/\\\/ Adyen .net API Library v17.0.0\\nusing Adyen;\\nusing Environment = Adyen.Model.Environment;\\nusing Adyen.Model;\\nusing Adyen.Model.Checkout;\\nusing Adyen.Service.Checkout;\\n\\n\\\/\\\/ For the live environment, additionally include your liveEndpointUrlPrefix.\\nvar config = new Config()\\n{\\n    XApiKey = \\&quot;ADYEN_API_KEY\\&quot;,\\n    Environment = Environment.Test\\n};\\nvar client = new Client(config);\\n\\n\\\/\\\/ Create the request object(s)\\nAmount amount = new Amount\\n{\\n  Currency = \\&quot;EUR\\&quot;,\\n  Value = 1000\\n};\\n\\nCardDetails cardDetails = new CardDetails\\n{\\n  EncryptedCardNumber = \\&quot;adyenjs_0_1_18$k7s65M5V0KdPxTErhBIPoMPI8HlC..\\&quot;,\\n  HolderName = \\&quot;S. Hopper\\&quot;,\\n  EncryptedSecurityCode = \\&quot;adyenjs_0_1_24$XUyMJyHebrra\\\/TpSda9fha978+..\\&quot;,\\n  EncryptedExpiryYear = \\&quot;adyenjs_0_1_18$CkCOLYZsdqpxGjrALWHj3QoGHqe+..\\&quot;,\\n  EncryptedExpiryMonth = \\&quot;adyenjs_0_1_18$p2OZxW2XmwAA8C1Avxm3G9UB6e4..\\&quot;,\\n  Type = CardDetails.TypeEnum.Scheme\\n};\\n\\nBillingAddress billingAddress = new BillingAddress\\n{\\n  Country = \\&quot;NL\\&quot;,\\n  City = \\&quot;Amsterdam\\&quot;,\\n  Street = \\&quot;Infinite Loop\\&quot;,\\n  HouseNumberOrName = \\&quot;1\\&quot;,\\n  PostalCode = \\&quot;1011DJ\\&quot;\\n};\\n\\nBrowserInfo browserInfo = new BrowserInfo\\n{\\n  AcceptHeader = \\&quot;text\\\/html,application\\\/xhtml+xml,application\\\/xml;q=0.9,image\\\/webp,image\\\/apng,*\\\/*;q=0.8\\&quot;,\\n  UserAgent = \\&quot;Mozilla\/5.0 (Linux; Android 6.0.1; Nexus 6P Build\/MMB29P) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/47.0.2526.83 Mobile Safari\/537.36\\&quot;\\n};\\n\\nPaymentRequest paymentRequest = new PaymentRequest\\n{\\n  Reference = \\&quot;YOUR_ORDER_NUMBER\\&quot;,\\n  Amount = amount,\\n  MerchantAccount = \\&quot;YOUR_MERCHANT_ACCOUNT\\&quot;,\\n  Channel = PaymentRequest.ChannelEnum.Android,\\n  PaymentMethod = new CheckoutPaymentMethod(cardDetails),\\n  ShopperEmail = \\&quot;s.hopper@example.com\\&quot;,\\n  BillingAddress = billingAddress,\\n  ReturnUrl = \\&quot;adyencheckout:\/\/your.package.name\\&quot;,\\n  BrowserInfo = browserInfo,\\n  ShopperReference = \\&quot;YOUR_UNIQUE_SHOPPER_ID\\&quot;\\n};\\n\\n\\\/\\\/ Send the request\\nvar service = new PaymentsService(client);\\nvar response = service.Payments(paymentRequest, requestOptions: new RequestOptions { IdempotencyKey = \\&quot;UUID\\&quot;});&quot;},{&quot;language&quot;:&quot;js&quot;,&quot;tabTitle&quot;:&quot;NodeJS (JavaScript)&quot;,&quot;content&quot;:&quot;\\\/\\\/ Adyen Node API Library v18.0.0\\n\\\/\\\/ Require the parts of the module you want to use\\nconst { Client, CheckoutAPI } = require('@adyen\\\/api-library');\\n\\\/\\\/ Initialize the client object\\n\\\/\\\/ For the live environment, additionally include your liveEndpointUrlPrefix.\\nconst client = new Client({apiKey: \\&quot;ADYEN_API_KEY\\&quot;, environment: \\&quot;TEST\\&quot;});\\n\\n\\\/\\\/ Create the request object(s)\\nconst paymentRequest = {\\n  amount: {\\n    currency: \\&quot;EUR\\&quot;,\\n    value: 1000\\n  },\\n  reference: \\&quot;YOUR_ORDER_NUMBER\\&quot;,\\n  shopperReference: \\&quot;YOUR_UNIQUE_SHOPPER_ID\\&quot;,\\n  paymentMethod: {\\n    type: \\&quot;scheme\\&quot;,\\n    encryptedCardNumber: \\&quot;adyenjs_0_1_18$k7s65M5V0KdPxTErhBIPoMPI8HlC..\\&quot;,\\n    encryptedExpiryMonth: \\&quot;adyenjs_0_1_18$p2OZxW2XmwAA8C1Avxm3G9UB6e4..\\&quot;,\\n    encryptedExpiryYear: \\&quot;adyenjs_0_1_18$CkCOLYZsdqpxGjrALWHj3QoGHqe+..\\&quot;,\\n    encryptedSecurityCode: \\&quot;adyenjs_0_1_24$XUyMJyHebrra\\\/TpSda9fha978+..\\&quot;,\\n    holderName: \\&quot;S. Hopper\\&quot;\\n  },\\n  billingAddress: {\\n    street: \\&quot;Infinite Loop\\&quot;,\\n    houseNumberOrName: \\&quot;1\\&quot;,\\n    postalCode: \\&quot;1011DJ\\&quot;,\\n    city: \\&quot;Amsterdam\\&quot;,\\n    country: \\&quot;NL\\&quot;\\n  },\\n  browserInfo: {\\n    userAgent: \\&quot;Mozilla\/5.0 (Linux; Android 6.0.1; Nexus 6P Build\/MMB29P) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/47.0.2526.83 Mobile Safari\/537.36\\&quot;,\\n    acceptHeader: \\&quot;text\\\/html,application\\\/xhtml+xml,application\\\/xml;q=0.9,image\\\/webp,image\\\/apng,*\\\/*;q=0.8\\&quot;\\n  },\\n  shopperEmail: \\&quot;s.hopper@example.com\\&quot;,\\n  channel: \\&quot;Android\\&quot;,\\n  returnUrl: \\&quot;adyencheckout:\/\/your.package.name\\&quot;,\\n  merchantAccount: \\&quot;YOUR_MERCHANT_ACCOUNT\\&quot;\\n}\\n\\n\\\/\\\/ Send the request\\nconst checkoutAPI = new CheckoutAPI(client);\\nconst response = checkoutAPI.PaymentsApi.payments(paymentRequest, { idempotencyKey: \\&quot;UUID\\&quot; });&quot;},{&quot;language&quot;:&quot;go&quot;,&quot;tabTitle&quot;:&quot;Go&quot;,&quot;content&quot;:&quot;\\\/\\\/ Adyen Go API Library v10.4.0\\nimport (\\n  \\&quot;context\\&quot;\\n  \\&quot;github.com\\\/adyen\\\/adyen-go-api-library\\\/v9\\\/src\\\/common\\&quot;\\n  \\&quot;github.com\\\/adyen\\\/adyen-go-api-library\\\/v9\\\/src\\\/adyen\\&quot;\\n  \\&quot;github.com\\\/adyen\\\/adyen-go-api-library\\\/v9\\\/src\\\/checkout\\&quot;\\n)\\n\\\/\\\/ For the live environment, additionally include your liveEndpointUrlPrefix.\\nclient := adyen.NewClient(&amp;common.Config{\\n  ApiKey:      \\&quot;ADYEN_API_KEY\\&quot;,\\n  Environment: common.TestEnv,\\n})\\n\\n\\\/\\\/ Create the request object(s)\\namount := checkout.Amount{\\n  Currency: \\&quot;EUR\\&quot;,\\n  Value: 1000,\\n}\\n\\ncardDetails := checkout.CardDetails{\\n  EncryptedCardNumber: common.PtrString(\\&quot;adyenjs_0_1_18$k7s65M5V0KdPxTErhBIPoMPI8HlC..\\&quot;),\\n  HolderName: common.PtrString(\\&quot;S. Hopper\\&quot;),\\n  EncryptedSecurityCode: common.PtrString(\\&quot;adyenjs_0_1_24$XUyMJyHebrra\\\/TpSda9fha978+..\\&quot;),\\n  EncryptedExpiryYear: common.PtrString(\\&quot;adyenjs_0_1_18$CkCOLYZsdqpxGjrALWHj3QoGHqe+..\\&quot;),\\n  EncryptedExpiryMonth: common.PtrString(\\&quot;adyenjs_0_1_18$p2OZxW2XmwAA8C1Avxm3G9UB6e4..\\&quot;),\\n  Type: common.PtrString(\\&quot;scheme\\&quot;),\\n}\\n\\nbillingAddress := checkout.BillingAddress{\\n  Country: \\&quot;NL\\&quot;,\\n  City: \\&quot;Amsterdam\\&quot;,\\n  Street: \\&quot;Infinite Loop\\&quot;,\\n  HouseNumberOrName: \\&quot;1\\&quot;,\\n  PostalCode: \\&quot;1011DJ\\&quot;,\\n}\\n\\nbrowserInfo := checkout.BrowserInfo{\\n  AcceptHeader: \\&quot;text\\\/html,application\\\/xhtml+xml,application\\\/xml;q=0.9,image\\\/webp,image\\\/apng,*\\\/*;q=0.8\\&quot;,\\n  UserAgent: \\&quot;Mozilla\/5.0 (Linux; Android 6.0.1; Nexus 6P Build\/MMB29P) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/47.0.2526.83 Mobile Safari\/537.36\\&quot;,\\n}\\n\\npaymentRequest := checkout.PaymentRequest{\\n  Reference: \\&quot;YOUR_ORDER_NUMBER\\&quot;,\\n  Amount: amount,\\n  MerchantAccount: \\&quot;YOUR_MERCHANT_ACCOUNT\\&quot;,\\n  Channel: common.PtrString(\\&quot;Android\\&quot;),\\n  PaymentMethod: checkout.CardDetailsAsCheckoutPaymentMethod(&amp;cardDetails),\\n  ShopperEmail: common.PtrString(\\&quot;s.hopper@example.com\\&quot;),\\n  BillingAddress: &amp;billingAddress,\\n  ReturnUrl: \\&quot;adyencheckout:\/\/your.package.name\\&quot;,\\n  BrowserInfo: &amp;browserInfo,\\n  ShopperReference: common.PtrString(\\&quot;YOUR_UNIQUE_SHOPPER_ID\\&quot;),\\n}\\n\\n\\\/\\\/ Send the request\\nservice := client.Checkout()\\nreq := service.PaymentsApi.PaymentsInput().IdempotencyKey(\\&quot;UUID\\&quot;).PaymentRequest(paymentRequest)\\nres, httpRes, err := service.PaymentsApi.Payments(context.Background(), req)&quot;},{&quot;language&quot;:&quot;py&quot;,&quot;tabTitle&quot;:&quot;Python&quot;,&quot;content&quot;:&quot;# Adyen Python API Library v12.5.1\\nimport Adyen\\n\\nadyen = Adyen.Adyen()\\nadyen.client.xapikey = \\&quot;ADYEN_API_KEY\\&quot;\\n# For the live environment, additionally include your liveEndpointUrlPrefix.\\nadyen.client.platform = \\&quot;test\\&quot; # The environment to use library in.\\n\\n# Create the request object(s)\\njson_request = {\\n  \\&quot;amount\\&quot;: {\\n    \\&quot;currency\\&quot;: \\&quot;EUR\\&quot;,\\n    \\&quot;value\\&quot;: 1000\\n  },\\n  \\&quot;reference\\&quot;: \\&quot;YOUR_ORDER_NUMBER\\&quot;,\\n  \\&quot;shopperReference\\&quot;: \\&quot;YOUR_UNIQUE_SHOPPER_ID\\&quot;,\\n  \\&quot;paymentMethod\\&quot;: {\\n    \\&quot;type\\&quot;: \\&quot;scheme\\&quot;,\\n    \\&quot;encryptedCardNumber\\&quot;: \\&quot;adyenjs_0_1_18$k7s65M5V0KdPxTErhBIPoMPI8HlC..\\&quot;,\\n    \\&quot;encryptedExpiryMonth\\&quot;: \\&quot;adyenjs_0_1_18$p2OZxW2XmwAA8C1Avxm3G9UB6e4..\\&quot;,\\n    \\&quot;encryptedExpiryYear\\&quot;: \\&quot;adyenjs_0_1_18$CkCOLYZsdqpxGjrALWHj3QoGHqe+..\\&quot;,\\n    \\&quot;encryptedSecurityCode\\&quot;: \\&quot;adyenjs_0_1_24$XUyMJyHebrra\\\/TpSda9fha978+..\\&quot;,\\n    \\&quot;holderName\\&quot;: \\&quot;S. Hopper\\&quot;\\n  },\\n  \\&quot;billingAddress\\&quot;: {\\n    \\&quot;street\\&quot;: \\&quot;Infinite Loop\\&quot;,\\n    \\&quot;houseNumberOrName\\&quot;: \\&quot;1\\&quot;,\\n    \\&quot;postalCode\\&quot;: \\&quot;1011DJ\\&quot;,\\n    \\&quot;city\\&quot;: \\&quot;Amsterdam\\&quot;,\\n    \\&quot;country\\&quot;: \\&quot;NL\\&quot;\\n  },\\n  \\&quot;browserInfo\\&quot;: {\\n    \\&quot;userAgent\\&quot;: \\&quot;Mozilla\/5.0 (Linux; Android 6.0.1; Nexus 6P Build\/MMB29P) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/47.0.2526.83 Mobile Safari\/537.36\\&quot;,\\n    \\&quot;acceptHeader\\&quot;: \\&quot;text\\\/html,application\\\/xhtml+xml,application\\\/xml;q=0.9,image\\\/webp,image\\\/apng,*\\\/*;q=0.8\\&quot;\\n  },\\n  \\&quot;shopperEmail\\&quot;: \\&quot;s.hopper@example.com\\&quot;,\\n  \\&quot;channel\\&quot;: \\&quot;Android\\&quot;,\\n  \\&quot;returnUrl\\&quot;: \\&quot;adyencheckout:\/\/your.package.name\\&quot;,\\n  \\&quot;merchantAccount\\&quot;: \\&quot;YOUR_MERCHANT_ACCOUNT\\&quot;\\n}\\n\\n# Send the request\\nresult = adyen.checkout.payments_api.payments(request=json_request, idempotency_key=\\&quot;UUID\\&quot;)&quot;},{&quot;language&quot;:&quot;rb&quot;,&quot;tabTitle&quot;:&quot;Ruby&quot;,&quot;content&quot;:&quot;# Adyen Ruby API Library v9.5.1\\nrequire \\&quot;adyen-ruby-api-library\\&quot;\\n\\nadyen = Adyen::Client.new\\nadyen.api_key = 'ADYEN_API_KEY'\\n# For the live environment, additionally include your liveEndpointUrlPrefix.\\nadyen.env = :test # Set to \\&quot;live\\&quot; for live environment\\n\\n# Create the request object(s)\\nrequest_body = {\\n  :amount =&gt; {\\n    :currency =&gt; 'EUR',\\n    :value =&gt; 1000\\n  },\\n  :reference =&gt; 'YOUR_ORDER_NUMBER',\\n  :shopperReference =&gt; 'YOUR_UNIQUE_SHOPPER_ID',\\n  :paymentMethod =&gt; {\\n    :type =&gt; 'scheme',\\n    :encryptedCardNumber =&gt; 'adyenjs_0_1_18$k7s65M5V0KdPxTErhBIPoMPI8HlC..',\\n    :encryptedExpiryMonth =&gt; 'adyenjs_0_1_18$p2OZxW2XmwAA8C1Avxm3G9UB6e4..',\\n    :encryptedExpiryYear =&gt; 'adyenjs_0_1_18$CkCOLYZsdqpxGjrALWHj3QoGHqe+..',\\n    :encryptedSecurityCode =&gt; 'adyenjs_0_1_24$XUyMJyHebrra\\\/TpSda9fha978+..',\\n    :holderName =&gt; 'S. Hopper'\\n  },\\n  :billingAddress =&gt; {\\n    :street =&gt; 'Infinite Loop',\\n    :houseNumberOrName =&gt; '1',\\n    :postalCode =&gt; '1011DJ',\\n    :city =&gt; 'Amsterdam',\\n    :country =&gt; 'NL'\\n  },\\n  :browserInfo =&gt; {\\n    :userAgent =&gt; 'Mozilla\/5.0 (Linux; Android 6.0.1; Nexus 6P Build\/MMB29P) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/47.0.2526.83 Mobile Safari\/537.36',\\n    :acceptHeader =&gt; 'text\\\/html,application\\\/xhtml+xml,application\\\/xml;q=0.9,image\\\/webp,image\\\/apng,*\\\/*;q=0.8'\\n  },\\n  :shopperEmail =&gt; 's.hopper@example.com',\\n  :channel =&gt; 'Android',\\n  :returnUrl =&gt; 'adyencheckout:\/\/your.package.name',\\n  :merchantAccount =&gt; 'YOUR_MERCHANT_ACCOUNT'\\n}\\n\\n# Send the request\\nresult = adyen.checkout.payments_api.payments(request_body, headers: { 'Idempotency-Key' =&gt; 'UUID' })&quot;},{&quot;language&quot;:&quot;ts&quot;,&quot;tabTitle&quot;:&quot;NodeJS (TypeScript)&quot;,&quot;content&quot;:&quot;\\\/\\\/ Adyen Node API Library v18.0.0\\n\\\/\\\/ Require the parts of the module you want to use\\nimport { Client, CheckoutAPI, Types } from \\&quot;@adyen\\\/api-library\\&quot;;\\n\\\/\\\/ Initialize the client object\\n\\\/\\\/ For the live environment, additionally include your liveEndpointUrlPrefix.\\nconst client = new Client({apiKey: \\&quot;ADYEN_API_KEY\\&quot;, environment: \\&quot;TEST\\&quot;});\\n\\n\\\/\\\/ Create the request object(s)\\nconst amount: Types.checkout.Amount = {\\n  currency: \\&quot;EUR\\&quot;,\\n  value: 1000\\n};\\n\\nconst cardDetails: Types.checkout.CardDetails = {\\n  encryptedCardNumber: \\&quot;adyenjs_0_1_18$k7s65M5V0KdPxTErhBIPoMPI8HlC..\\&quot;,\\n  holderName: \\&quot;S. Hopper\\&quot;,\\n  encryptedSecurityCode: \\&quot;adyenjs_0_1_24$XUyMJyHebrra\\\/TpSda9fha978+..\\&quot;,\\n  encryptedExpiryYear: \\&quot;adyenjs_0_1_18$CkCOLYZsdqpxGjrALWHj3QoGHqe+..\\&quot;,\\n  encryptedExpiryMonth: \\&quot;adyenjs_0_1_18$p2OZxW2XmwAA8C1Avxm3G9UB6e4..\\&quot;,\\n  type: Types.checkout.CardDetails.TypeEnum.Scheme\\n};\\n\\nconst billingAddress: Types.checkout.BillingAddress = {\\n  country: \\&quot;NL\\&quot;,\\n  city: \\&quot;Amsterdam\\&quot;,\\n  street: \\&quot;Infinite Loop\\&quot;,\\n  houseNumberOrName: \\&quot;1\\&quot;,\\n  postalCode: \\&quot;1011DJ\\&quot;\\n};\\n\\nconst browserInfo: Types.checkout.BrowserInfo = {\\n  acceptHeader: \\&quot;text\\\/html,application\\\/xhtml+xml,application\\\/xml;q=0.9,image\\\/webp,image\\\/apng,*\\\/*;q=0.8\\&quot;,\\n  userAgent: \\&quot;Mozilla\/5.0 (Linux; Android 6.0.1; Nexus 6P Build\/MMB29P) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/47.0.2526.83 Mobile Safari\/537.36\\&quot;\\n};\\n\\nconst paymentRequest: Types.checkout.PaymentRequest = {\\n  reference: \\&quot;YOUR_ORDER_NUMBER\\&quot;,\\n  amount: amount,\\n  merchantAccount: \\&quot;YOUR_MERCHANT_ACCOUNT\\&quot;,\\n  channel: Types.checkout.PaymentRequest.ChannelEnum.Android,\\n  paymentMethod: cardDetails,\\n  shopperEmail: \\&quot;s.hopper@example.com\\&quot;,\\n  billingAddress: billingAddress,\\n  returnUrl: \\&quot;adyencheckout:\/\/your.package.name\\&quot;,\\n  browserInfo: browserInfo,\\n  shopperReference: \\&quot;YOUR_UNIQUE_SHOPPER_ID\\&quot;\\n};\\n\\n\\\/\\\/ Send the request\\nconst checkoutAPI = new CheckoutAPI(client);\\nconst response = checkoutAPI.PaymentsApi.payments(paymentRequest, { idempotencyKey: \\&quot;UUID\\&quot; });&quot;}]\" :enable-copy-link-to-code-block=\"true\" :code-sample-card-size=\"'fullsize'\"><\/code-sample>\n<\/div>\n<ol start=\"3\">\n<li>\n<p>In the response, check if there is an <code>action<\/code> object.<\/p>\n\n<div id=\"tabj7RFT\">\n    <div data-component-wrapper=\"tabs\">\n        <tabs\n                        :items=\"[{&quot;title&quot;:&quot;Checkout API v67 and later&quot;,&quot;content&quot;:&quot;\\n&lt;p&gt;Your next steps depend on whether the response contains an &lt;code&gt;action&lt;\\\/code&gt; object, and on the &lt;code&gt;action.type&lt;\\\/code&gt;.&lt;\\\/p&gt;\\n&lt;table&gt;\\n&lt;thead&gt;\\n&lt;tr&gt;\\n&lt;th&gt;&lt;\\\/th&gt;\\n&lt;th&gt;Description&lt;\\\/th&gt;\\n&lt;th&gt;Next steps&lt;\\\/th&gt;\\n&lt;\\\/tr&gt;\\n&lt;\\\/thead&gt;\\n&lt;tbody&gt;\\n&lt;tr&gt;\\n&lt;td&gt;No &lt;code&gt;action&lt;\\\/code&gt; object&lt;\\\/td&gt;\\n&lt;td&gt;The transaction was either exempted or out-of-scope for 3D Secure 2 authentication.&lt;\\\/td&gt;\\n&lt;td&gt;1. Return &lt;code&gt;DropInServiceResult.Finished&lt;\\\/code&gt;, and the &lt;code&gt;resultCode&lt;\\\/code&gt; from the &lt;code&gt;\\\/payments&lt;\\\/code&gt; response. &lt;br&gt; 2. Use the &lt;code&gt;resultCode&lt;\\\/code&gt; to &lt;a href=\\&quot;#present-the-payment-result\\&quot;&gt;present the payment result to your shopper&lt;\\\/a&gt;.&lt;\\\/td&gt;\\n&lt;\\\/tr&gt;\\n&lt;tr&gt;\\n&lt;td&gt;&lt;code&gt;action&lt;\\\/code&gt; object &lt;br&gt;&lt;code&gt;type&lt;\\\/code&gt;:&lt;strong&gt;redirect&lt;\\\/strong&gt;&lt;\\\/td&gt;\\n&lt;td&gt;The payment qualifies for 3D Secure.&lt;\\\/td&gt;\\n&lt;td&gt;1. Return &lt;code&gt;DropInServiceResult.Action&lt;\\\/code&gt;, and the &lt;code&gt;action&lt;\\\/code&gt; object. &lt;br&gt; 2. &lt;a href=\\&quot;#handle-the-redirect\\&quot;&gt;Handle the redirect&lt;\\\/a&gt;.&lt;\\\/td&gt;\\n&lt;\\\/tr&gt;\\n&lt;\\\/tbody&gt;\\n&lt;\\\/table&gt;\\n&lt;p&gt;A sample  &lt;a href=\\&quot;https:\\\/\\\/docs.adyen.com\\\/api-explorer\\\/Checkout\\\/latest\\\/post\\\/payments\\&quot; class=\\&quot;codeLabel  external-link no-image\\&quot; target=\\&quot;_blank\\&quot; rel=\\&quot;nofollow noopener noreferrer\\&quot;&gt;\\\/payments&lt;\\\/a&gt; response with &lt;code&gt;action.type&lt;\\\/code&gt;: &lt;strong&gt;redirect&lt;\\\/strong&gt;:&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;\\\/payments response&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;{\\\\n  \\\\\\&quot;resultCode\\\\\\&quot;: \\\\\\&quot;RedirectShopper\\\\\\&quot;,\\\\n  \\\\\\&quot;action\\\\\\&quot;: {\\\\n    \\\\\\&quot;paymentMethodType\\\\\\&quot;: \\\\\\&quot;scheme\\\\\\&quot;,\\\\n    \\\\\\&quot;url\\\\\\&quot;: \\\\\\&quot;https:\\\\\\\/\\\\\\\/checkoutshopper-test.adyen.com\\\\\\\/checkoutshopper\\\\\\\/threeDS\\\\\\\/redirect?MD=M2R...\\\\\\&quot;,\\\\n    \\\\\\&quot;method\\\\\\&quot;: \\\\\\&quot;GET\\\\\\&quot;,\\\\n    \\\\\\&quot;type\\\\\\&quot;: \\\\\\&quot;redirect\\\\\\&quot;\\\\n  }\\\\n}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&quot;,&quot;altTitle&quot;:&quot;v67&quot;,&quot;oldTabId&quot;:&quot;handle-redirect-v67_1&quot;,&quot;relation&quot;:&quot;v67&quot;},{&quot;title&quot;:&quot;Checkout API v66 and earlier&quot;,&quot;content&quot;:&quot;\\n&lt;p&gt;Your next steps depend on whether the response contains an &lt;code&gt;action&lt;\\\/code&gt; object, and on the &lt;code&gt;action.type&lt;\\\/code&gt;.&lt;\\\/p&gt;\\n&lt;table&gt;\\n&lt;thead&gt;\\n&lt;tr&gt;\\n&lt;th&gt;&lt;\\\/th&gt;\\n&lt;th&gt;Description&lt;\\\/th&gt;\\n&lt;th&gt;Next steps&lt;\\\/th&gt;\\n&lt;\\\/tr&gt;\\n&lt;\\\/thead&gt;\\n&lt;tbody&gt;\\n&lt;tr&gt;\\n&lt;td&gt;No &lt;code&gt;action&lt;\\\/code&gt; object&lt;\\\/td&gt;\\n&lt;td&gt;The transaction was either exempted or out-of-scope for 3D Secure 2 authentication.&lt;\\\/td&gt;\\n&lt;td&gt;1. Return &lt;code&gt;DropInServiceResult.Finished&lt;\\\/code&gt;, and the &lt;code&gt;resultCode&lt;\\\/code&gt; from the &lt;code&gt;\\\/payments&lt;\\\/code&gt; response. &lt;br&gt; 2. Use the &lt;code&gt;resultCode&lt;\\\/code&gt; to &lt;a href=\\&quot;#present-the-payment-result\\&quot;&gt;present the payment result to your shopper&lt;\\\/a&gt;.&lt;\\\/td&gt;\\n&lt;\\\/tr&gt;\\n&lt;tr&gt;\\n&lt;td&gt;&lt;code&gt;action&lt;\\\/code&gt; object &lt;br&gt;&lt;code&gt;type&lt;\\\/code&gt;:&lt;strong&gt;redirect&lt;\\\/strong&gt;&lt;\\\/td&gt;\\n&lt;td&gt;The payment qualifies for 3D Secure.&lt;\\\/td&gt;\\n&lt;td&gt;1. Store the &lt;code&gt;action.paymentData&lt;\\\/code&gt; on your server. &lt;br&gt; 2. Return &lt;code&gt;DropInServiceResult.Action&lt;\\\/code&gt;, and the &lt;code&gt;action&lt;\\\/code&gt; object. &lt;br&gt; 3. &lt;a href=\\&quot;#handle-the-redirect\\&quot;&gt;Handle the redirect&lt;\\\/a&gt;.&lt;\\\/td&gt;\\n&lt;\\\/tr&gt;\\n&lt;\\\/tbody&gt;\\n&lt;\\\/table&gt;\\n&lt;p&gt;A sample  &lt;a href=\\&quot;https:\\\/\\\/docs.adyen.com\\\/api-explorer\\\/Checkout\\\/66\\\/post\\\/payments\\&quot; class=\\&quot;codeLabel  external-link no-image\\&quot; target=\\&quot;_blank\\&quot; rel=\\&quot;nofollow noopener noreferrer\\&quot;&gt;\\\/payments&lt;\\\/a&gt; response with &lt;code&gt;action.type&lt;\\\/code&gt;: &lt;strong&gt;redirect&lt;\\\/strong&gt;:&lt;\\\/p&gt;\\n&lt;div data-component-wrapper=\\&quot;code-sample\\&quot;&gt;\\n&lt;code-sample :title=\\&quot;&#039;\\\/payments response&#039;\\&quot; :id=\\&quot;&#039;&#039;\\&quot; :code-data=&#039;[{\\&quot;language\\&quot;:\\&quot;json\\&quot;,\\&quot;tabTitle\\&quot;:\\&quot;\\&quot;,\\&quot;content\\&quot;:\\&quot;{\\\\n   \\\\\\&quot;resultCode\\\\\\&quot;:\\\\\\&quot;RedirectShopper\\\\\\&quot;,\\\\n   \\\\\\&quot;action\\\\\\&quot;:{\\\\n      \\\\\\&quot;method\\\\\\&quot;:\\\\\\&quot;GET\\\\\\&quot;,\\\\n      \\\\\\&quot;paymentData\\\\\\&quot;:\\\\\\&quot;Ab02b4c0!BQABAgCJN1wRZuGJmq8dMncmypvknj9s7l5Tj...\\\\\\&quot;,\\\\n      \\\\\\&quot;paymentMethodType\\\\\\&quot;:\\\\\\&quot;scheme\\\\\\&quot;,\\\\n      \\\\\\&quot;type\\\\\\&quot;:\\\\\\&quot;redirect\\\\\\&quot;,\\\\n      \\\\\\&quot;url\\\\\\&quot;:\\\\\\&quot;https:\\\\\\\/\\\\\\\/checkoutshopper-test.adyen.com\\\\\\\/checkoutshopper\\\\\\\/threeDS\\\\\\\/redirect?MD=M2R...\\\\\\&quot;\\\\n   },\\\\n   \\\\\\&quot;details\\\\\\&quot;:[\\\\n      {\\\\n         \\\\\\&quot;key\\\\\\&quot;:\\\\\\&quot;MD\\\\\\&quot;,\\\\n         \\\\\\&quot;type\\\\\\&quot;:\\\\\\&quot;text\\\\\\&quot;\\\\n      },\\\\n      {\\\\n         \\\\\\&quot;key\\\\\\&quot;:\\\\\\&quot;PaRes\\\\\\&quot;,\\\\n         \\\\\\&quot;type\\\\\\&quot;:\\\\\\&quot;text\\\\\\&quot;\\\\n      }\\\\n   ],\\\\n   ...\\\\n}\\&quot;}]&#039; :enable-copy-link-to-code-block=\\&quot;true\\&quot; :code-sample-card-size=\\&quot;&#039;fullsize&#039;\\&quot;&gt;&lt;\\\/code-sample&gt;\\n&lt;\\\/div&gt;\\n&quot;,&quot;altTitle&quot;:&quot;v66&quot;,&quot;oldTabId&quot;:&quot;handle-redirect-v66_2&quot;,&quot;relation&quot;:&quot;v66&quot;}]\"\n            :should-update-when-url-changes='true'>\n        <\/tabs>\n    <\/div>\n<\/div>\n\n<\/li>\n<\/ol>\n<h2 id=\"handle-the-redirect\">Handle the redirect<\/h2>\n<p>Drop-in redirects the shopper to perform the 3D Secure authentication. When the shopper returns back to your app, Drop-in provides the <code>actionComponentData<\/code> object.<\/p>\n<ol>\n<li>Pass the <code>actionComponentData.details<\/code> to your server.<\/li>\n<li>\n<p>From your server, make a POST  <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments\/details\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">\/payments\/details<\/a> request specifying:<\/p>\n<ul>\n<li><code>details<\/code>: This is the <code>actionComponentData.details<\/code> from the Component.<\/li>\n<li><code>paymentData<\/code>: Required if using Checkout API version 66 or earlier: the value from the last API response that you stored locally in the client-side app.<\/li>\n<\/ul>\n<div class=\"notices green\">\n<p>On Checkout API v67 and later, the payment is authorized after the shopper completes authentication. You make a  <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments\/details\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">\/payments\/details<\/a> request to get the payment result. On earlier versions, you need to complete the payment by making a  <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments\/details\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">\/payments\/details<\/a> request containing payment data.<\/p>\n<\/div>\n<div data-component-wrapper=\"code-sample\">\n<code-sample :title=\"''\" :id=\"'details-request-component-3ds'\" :code-data=\"[{&quot;language&quot;:&quot;bash&quot;,&quot;tabTitle&quot;:&quot;curl&quot;,&quot;content&quot;:&quot;curl https:\\\/\\\/checkout-test.adyen.com\\\/v72\\\/payments\\\/details \\\\\\n-H 'x-api-key: ADYEN_API_KEY' \\\\\\n-H 'content-type: application\\\/json' \\\\\\n-d '{hint:object passed from the front end or client app}STATE_DATA{\\\/hint}'&quot;},{&quot;language&quot;:&quot;java&quot;,&quot;tabTitle&quot;:&quot;Java&quot;,&quot;content&quot;:&quot;\\\/\\\/ Set your X-API-KEY with the API key from the Customer Area.\\nString xApiKey = \\&quot;ADYEN_API_KEY\\&quot;;\\nClient client = new Client(xApiKey,Environment.TEST);\\nCheckout checkout = new Checkout(client);\\n\\\/\\\/ STATE_DATA is an object passed from the front end or client app, deserialized from JSON to a data structure.\\nPaymentsDetailsRequest paymentsDetailsRequest = STATE_DATA;\\nPaymentsResponse paymentsDetailsResponse = checkout.paymentsDetails(paymentsDetailsRequest);&quot;},{&quot;language&quot;:&quot;php&quot;,&quot;tabTitle&quot;:&quot;PHP&quot;,&quot;content&quot;:&quot;\\\/\\\/ Set your X-API-KEY with the API key from the Customer Area.\\n$client = new \\\\Adyen\\\\Client();\\n$client-&gt;setEnvironment(\\\\Adyen\\\\Environment::TEST);\\n$client-&gt;setXApiKey(\\&quot;ADYEN_API_KEY\\&quot;);\\n$service = new \\\\Adyen\\\\Service\\\\Checkout($client);\\n\\n\\\/\\\/ STATE_DATA is an object passed from the front end or client app, deserialized from JSON to a data structure.\\n$params = STATE_DATA;\\n$result = $service-&gt;paymentsDetails($params);\\n\\n\\\/\\\/ Check if further action is needed\\nif (array_key_exists(\\&quot;action\\&quot;, $result)){\\n   \\\/\\\/ Pass the action object to your frontend.\\n   \\\/\\\/ $result[\\&quot;action\\&quot;]\\n}\\nelse {\\n   \\\/\\\/ No further action needed, pass the resultCode to your front end\\n   \\\/\\\/ $result['resultCode']\\n}&quot;},{&quot;language&quot;:&quot;cs&quot;,&quot;tabTitle&quot;:&quot;C#&quot;,&quot;content&quot;:&quot;\\\/\\\/ Set your X-API-KEY with the API key from the Customer Area.\\nstring apiKey = \\&quot;ADYEN_API_KEY\\&quot;;\\nvar client = new Client (apiKey, Environment.Test);\\nvar checkout = new Checkout(client);\\n\\\/\\\/ STATE_DATA is an object passed from the front end or client app, deserialized from JSON to a data structure.\\nvar paymentsDetailsRequest = STATE_DATA;\\nvar paymentsDetailsResponse = checkout.PaymentDetails(paymentsDetailsRequest);&quot;},{&quot;language&quot;:&quot;js&quot;,&quot;tabTitle&quot;:&quot;NodeJS (JavaScript)&quot;,&quot;content&quot;:&quot;const {Client, Config, CheckoutAPI} = require('@adyen\\\/api-library');\\nconst config = new Config();\\n\\\/\\\/ Set your X-API-KEY with the API key from the Customer Area.\\nconfig.apiKey = '[ADYEN_API_KEY]';\\nconst client = new Client({ config });\\nclient.setEnvironment(\\&quot;TEST\\&quot;);\\nconst checkout = new CheckoutAPI(client);\\n\\\/\\\/ STATE_DATA is an object passed from the front end or client app, deserialized from JSON to a data structure.\\ncheckout.paymentsDetails(STATE_DATA).then(res =&gt; res);&quot;},{&quot;language&quot;:&quot;py&quot;,&quot;tabTitle&quot;:&quot;Python&quot;,&quot;content&quot;:&quot;# Set your X-API-KEY with the API key from the Customer Area.\\nadyen = Adyen.Adyen()\\nadyen.payment.client.platform = \\&quot;test\\&quot;\\nadyen.client.xapikey = 'ADYEN_API_KEY'\\n\\n# STATE_DATA is an object passed from the front end or client app, deserialized from JSON to a data structure.\\nrequest = STATE_DATA\\nresult = adyen.checkout.payments_details(request)\\n\\n# Check if further action is needed.\\nif 'action' in result.message:\\n   # Pass the action object to your front end\\n   # result.message['action']\\nelse:\\n   # No further action needed, pass the resultCode to your front end\\n   # result.message['resultCode']&quot;},{&quot;language&quot;:&quot;ruby&quot;,&quot;tabTitle&quot;:&quot;Ruby&quot;,&quot;content&quot;:&quot;require 'adyen-ruby-api-library'\\n\\n# Set your X-API-KEY with the API key from the Customer Area.\\nadyen = Adyen::Client.new\\nadyen.env = :test\\nadyen.api_key = \\&quot;ADYEN_API_KEY\\&quot;\\n\\n# STATE_DATA is an object passed from the front end or client app, deserialized from JSON to a data structure.\\nrequest = STATE_DATA\\nresponse = adyen.checkout.payments.details(request)\\n\\n# Check if further action is needed.\\nif response.body.has_key(:action)\\n   # Pass the action object to your frontend\\n   puts response.body[:action]\\nelse\\n   # No further action needed, pass the resultCode to your frontend\\n   puts response.body[:resultCode]\\nend&quot;}]\" :enable-copy-link-to-code-block=\"true\" :code-sample-card-size=\"'fullsize'\"><\/code-sample>\n<\/div>\n<p>You receive a response containing:<\/p>\n<ul>\n<li><code>resultCode<\/code>: Use this to present the result to your shopper.<\/li>\n<li><code>pspReference<\/code>: Our unique identifier for the transaction.<\/li>\n<\/ul>\n<div data-component-wrapper=\"code-sample\">\n<code-sample :title=\"'\/payments\/details response'\" :id=\"''\" :code-data='[{\"language\":\"json\",\"tabTitle\":\"\",\"content\":\"{\\n  \\\"resultCode\\\": \\\"Authorised\\\",\\n  \\\"pspReference\\\": \\\"V4HZ4RBFJGXXGN82\\\"\\n}\"}]' :enable-copy-link-to-code-block=\"true\" :code-sample-card-size=\"'fullsize'\"><\/code-sample>\n<\/div>\n<\/li>\n<\/ol>\n<div class=\"notices green\">\n<p>For more information and detailed instructions, refer to our <a href=\"\/pt\/online-payments\/build-your-integration\/advanced-flow\/?platform=Android&amp;integration=Drop-in#send-additional-payment-details\">Android Drop-in integration guide<\/a>.<\/p>\n<\/div>\n<h2 id=\"present-the-payment-result\">Present the payment result<\/h2>\n<p>Use the\u00a0 <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments#responses-200-resultCode\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">resultCode<\/a> from the  <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">\/payments<\/a> or  <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments\/details\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">\/payments\/details<\/a> response to present the payment result to your shopper. You will also receive the outcome of the payment asynchronously in a <a href=\"\/pt\/development-resources\/webhooks\">webhook<\/a>.<\/p>\n<p><\/p>\n<p>For card payments, you can receive the following <code>resultCode<\/code> values:<\/p>\n<table>\n<thead>\n<tr>\n<th>resultCode<\/th>\n<th>Description<\/th>\n<th>Action to take<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><strong>Authorised<\/strong><\/td>\n<td>The payment was successful.<\/td>\n<td>Inform the shopper that the payment has been successful. <br> If you are using <a href=\"\/pt\/online-payments\/capture#manual-capture\">manual capture<\/a>, you also need to <a href=\"\/pt\/online-payments\/capture\">capture<\/a> the payment.<\/td>\n<\/tr>\n<tr>\n<td><strong>Cancelled<\/strong><\/td>\n<td>The shopper cancelled the payment.<\/td>\n<td>Ask the shopper if they want to continue with the order, or ask them to select a different payment method.<\/td>\n<\/tr>\n<tr>\n<td><strong>Error<\/strong><\/td>\n<td>There was an error when the payment was being processed. For more information, check the <a href=\"\/pt\/development-resources\/refusal-reasons\">\n  <code>refusalReason<\/code>\n<\/a> field.<\/td>\n<td>Inform the shopper that there was an error processing their payment.<\/td>\n<\/tr>\n<tr>\n<td><strong>Refused<\/strong><\/td>\n<td>The payment was refused.  For more information, check the <a href=\"\/pt\/development-resources\/refusal-reasons\">\n  <code>refusalReason<\/code>\n<\/a> field.<\/td>\n<td>Ask the shopper to try the payment again using a different payment method.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h2 id=\"test-and-go-live\">Test and go live<\/h2>\n<p>Use our test card numbers to <a href=\"\/pt\/development-resources\/testing\/3d-secure-2-authentication\">test how your integration handles different 3D Secure authentication scenarios<\/a>.<\/p>\n<p>When you are ready to <a href=\"\/pt\/get-started-with-adyen\/#apply-for-your-live-account\">go live<\/a>, follow our <a href=\"\/pt\/online-payments\/go-live-checklist\/\">go-live checklist<\/a>.<\/p>\n<p>When using our <a href=\"\/pt\/development-resources\/live-endpoints\/\">live endpoints<\/a>, make sure that all API requests you make for the same payment session use the same live endpoint region. Using different regions for  <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">\/payments<\/a> and  <a href=\"https:\/\/docs.adyen.com\/api-explorer\/Checkout\/latest\/post\/payments\/details\" class=\"codeLabel  external-link no-image\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">\/payments\/details<\/a> requests may result in errors when authenticating with 3D Secure.<\/p>\n<h2 id=\"see-also\">See also<\/h2>\n<div class=\"see-also-links output-inline\" id=\"see-also\">\n<ul><li><a href=\"\/online-payments\/build-your-integration\/sessions-flow\/?platform=Android&amp;integration=Drop-in\"\n                        target=\"_self\"\n                        >\n                    Android Drop-in integration guide\n                <\/a><\/li><li><a href=\"\/online-payments\/3d-secure\/api-reference\"\n                        target=\"_self\"\n                        >\n                    3D Secure 2 API Reference\n                <\/a><\/li><li><a href=\"\/development-resources\/webhooks\"\n                        target=\"_self\"\n                        >\n                    Webhooks\n                <\/a><\/li><li><a href=\"\/payment-methods\"\n                        target=\"_self\"\n                        >\n                    Payment methods\n                <\/a><\/li><\/ul><\/div>\n","url":"https:\/\/docs.adyen.com\/pt\/online-payments\/3d-secure\/redirect-3ds2\/android-drop-in","articleFields":{"description":"Support cards with 3D Secure authentication through a redirect in your Android app.","feedback_component":true,"parameters":{"country_code":"NL","currency":"EUR","channel":"Android","return_url":"adyencheckout:\/\/your.package.name","shopper_locale":"nl-NL","user_agent":"Mozilla\/5.0 (Linux; Android 6.0.1; Nexus 6P Build\/MMB29P) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/47.0.2526.83 Mobile Safari\/537.36"},"last_edit_on":"11-05-2021 17:35"},"algolia":{"url":"https:\/\/docs.adyen.com\/pt\/online-payments\/3d-secure\/redirect-3ds2\/android-drop-in","title":"Redirect 3DS Drop-in integration","content":"Our Android Drop-in renders the available cards in your payment form, and securely collects any sensitive card information, so it doesn't touch your server. Drop-in also redirects the shopper to perform 3D Secure 2 authentication.\nWhen adding card payments with redirect 3D Secure authentication to your integration, you additionally need to:\n\nConfigure Drop-in to collect the card holder name.\nProvide the required 3D Secure parameters when making a payment request.\nHandle the redirect after the shopper returns to your website.\n\n\nThis page describes the integration steps for Android Drop-in v4.0.0 or later.\n\nRequirements\nThis page explains how to add cards with redirect 3D Secure authentication to your existing Android Drop-in integration. The Android Drop-in integration works the same way for all payment methods. If you haven't done this integration yet, refer to our Drop-in integration guide.\nBefore you begin your integration:\n\nMake sure that you have set up your back end implementation, and added Drop-in to your payment form.\nAdd the cards that you want to accept in your test Customer Area.\nIf you are using 3D Secure for PSD2 compliance, read our comprehensive PSD2 SCA guide.\n\nCollect additional parameters in your payment form\nFor higher authentication rates, we strongly recommend that you collect the shopper's billing address and email address in advance in your payment form. Deliver these parameters to your backend when making a payment as they are required by the card schemes.\nShow the available cards in your payment form\n\nFor information about the supported countries\/regions and currencies for each card, refer to Payment methods.\n\nTo show cards in your payment form:\n\n\nSpecify in your  \/paymentMethods request a combination of  countryCode and  amount.currency. Drop-in uses this information to show the available cards to your shopper.\n\n\nWhen creating an instance of Drop-in, create a configuration object, and pass your client key. To make sure you collect the cardholder name, set holderNameRequired to true.\n\n\nval cardConfiguration = CardConfiguration.Builder(context, \"YOUR_CLIENT_KEY\")\n  \/\/ Makes the cardholder name required\n  .setHolderNameRequired(true)\n  \/\/ When you are ready to accept live payments, change the value to one of our live environments.\n  .setEnvironment(Environment.TEST)\n  .build()\n\nval dropInConfiguration = DropInConfiguration.Builder(context, YourDropInService::class.java, \"YOUR_CLIENT_KEY\")\n   \/\/ When you are ready to accept live payments, change the value to one of our live environments.\n   .setEnvironment(Environment.TEST)\n   .addCardConfiguration(cardConfiguration)\n   .build()\nMake a payment\nWhen the shopper proceeds to pay, Drop-in returns the paymentComponentData.paymentMethod.\n\nPass the paymentComponentData.paymentMethod object to your server.\n\nWhen you make a payment request, include the following additional 3D Secure 2 parameters.\n\nSee additional 3D Secure 2 parameters that we recommend to include in your request to increase authentication performance in our API reference.\n\n\n\n\n\n\nParameter name\nRequired\nDescription\n\n\n\n\n paymentMethod\n\nThe type and required details for a card payment method. The paymentComponentData.paymentMethod object from your client app.\n\n\n paymentMethod.holderName\n\nUse case: required for Visa and JCB transactions.  The cardholder's name.\n\n\n channel\n\nThe platform where the transaction takes place. Set to Android.\n\n\n returnUrl\n\nThe URL where the shopper will be redirected back to after completing 3D Secure authentication. Get this URL from Drop-in in the RedirectComponent.getReturnUrl(context).  Format: Maximum characters: 1024.Must not include \/\/ (double slash) after the top-level domain.\n\n\n browserInfo\n\nThe shopper's browser information. The following sub-fields are required:  acceptHeader: The accept header value of the shopper's browser. You can use a dummy value.  userAgent: Get it using \n  WebSettings.getDefaultUserAgent(Context);\n.\n\n\n shopperIP\n\nUse case: required for Visa and JCB transactions.  The shopper's IP address.\n\n\n shopperEmail\n\nUse case: required for Visa and JCB transactions.  The cardholder's email address. If you do not include the shopper email, you must include the shopper's phone number in your request.\n\n\n telephoneNumber\n\nUse case: required for Visa and JCB transactions if you did not include the shopperEmail field. The shopper's phone number. To be more specific, you can use the mobilePhone, homePhone, and workPhone fields in the threeDS2RequestData object.   Format: The phone number must include a plus sign (+) and a country code (1-3 digits), followed by the number (4-15 digits).   Example: +4912345678901  If the value you provide does not follow the guidelines, we drop the value and do not submit it for authentication. \n\n\n\n Required for all transactions.  Required for particular setups, or issuers and card schemes.  Recommended for all transactions, but not required.\n\n    \n\n\n\nIn the response, check if there is an action object.\n\n\n    \n        \n        \n    \n\n\n\n\nHandle the redirect\nDrop-in redirects the shopper to perform the 3D Secure authentication. When the shopper returns back to your app, Drop-in provides the actionComponentData object.\n\nPass the actionComponentData.details to your server.\n\nFrom your server, make a POST  \/payments\/details request specifying:\n\ndetails: This is the actionComponentData.details from the Component.\npaymentData: Required if using Checkout API version 66 or earlier: the value from the last API response that you stored locally in the client-side app.\n\n\nOn Checkout API v67 and later, the payment is authorized after the shopper completes authentication. You make a  \/payments\/details request to get the payment result. On earlier versions, you need to complete the payment by making a  \/payments\/details request containing payment data.\n\n\n\n\nYou receive a response containing:\n\nresultCode: Use this to present the result to your shopper.\npspReference: Our unique identifier for the transaction.\n\n\n\n\n\n\n\nFor more information and detailed instructions, refer to our Android Drop-in integration guide.\n\nPresent the payment result\nUse the\u00a0 resultCode from the  \/payments or  \/payments\/details response to present the payment result to your shopper. You will also receive the outcome of the payment asynchronously in a webhook.\n\nFor card payments, you can receive the following resultCode values:\n\n\n\nresultCode\nDescription\nAction to take\n\n\n\n\nAuthorised\nThe payment was successful.\nInform the shopper that the payment has been successful.  If you are using manual capture, you also need to capture the payment.\n\n\nCancelled\nThe shopper cancelled the payment.\nAsk the shopper if they want to continue with the order, or ask them to select a different payment method.\n\n\nError\nThere was an error when the payment was being processed. For more information, check the \n  refusalReason\n field.\nInform the shopper that there was an error processing their payment.\n\n\nRefused\nThe payment was refused.  For more information, check the \n  refusalReason\n field.\nAsk the shopper to try the payment again using a different payment method.\n\n\n\nTest and go live\nUse our test card numbers to test how your integration handles different 3D Secure authentication scenarios.\nWhen you are ready to go live, follow our go-live checklist.\nWhen using our live endpoints, make sure that all API requests you make for the same payment session use the same live endpoint region. Using different regions for  \/payments and  \/payments\/details requests may result in errors when authenticating with 3D Secure.\nSee also\n\n\n                    Android Drop-in integration guide\n                \n                    3D Secure 2 API Reference\n                \n                    Webhooks\n                \n                    Payment methods\n                \n","type":"page","locale":"pt","boost":16,"hierarchy":{"lvl0":"Home","lvl1":"Online payments","lvl2":"3D Secure 2 authentication","lvl3":"3D Secure 2 redirect authentication","lvl4":"Redirect 3DS Drop-in integration"},"hierarchy_url":{"lvl0":"https:\/\/docs.adyen.com\/pt","lvl1":"https:\/\/docs.adyen.com\/pt\/online-payments","lvl2":"https:\/\/docs.adyen.com\/pt\/online-payments\/3d-secure","lvl3":"https:\/\/docs.adyen.com\/pt\/online-payments\/3d-secure\/redirect-3ds2","lvl4":"\/pt\/online-payments\/3d-secure\/redirect-3ds2\/android-drop-in"},"levels":5,"category":"Online Payments","category_color":"green","tags":["Redirect","Drop-in","integration"]}}
