---
title: "Cash App Afterpay Redirect Component"
description: "Add Cash App Afterpay to an existing Components integration."
url: "https://docs.adyen.com/payment-methods/cash-app-afterpay/android-component"
source_url: "https://docs.adyen.com/payment-methods/cash-app-afterpay/android-component.md"
canonical: "https://docs.adyen.com/payment-methods/cash-app-afterpay/android-component"
last_modified: "2026-06-01T15:33:15+02:00"
language: "en"
---

# Cash App Afterpay Redirect Component

Add Cash App Afterpay to an existing Components integration.

[View source](/payment-methods/cash-app-afterpay/android-component.md)

**If you are using Android Components v5.0.0 or later:**

This payment method requires no additional configuration.

Follow the [Components integration guide](/online-payments/build-your-integration/sessions-flow?platform=Android\&integration=Components) and use the following module and Component names:

* To [import the module](/online-payments/build-your-integration/sessions-flow/?platform=Android\&integration=Components#import): **instant**
* To [launch and show the Component](/online-payments/build-your-integration/sessions-flow?platform=Android\&integration=Components#launch-and-show): **InstantPaymentComponent**

You can use our [Redirect Component](/online-payments/build-your-integration/sessions-flow/?platform=Android\&integration=Components#handle-a-redirect) to handle the redirect to Afterpay.

When adding Cash App Afterpay to your existing Components integration, you also need to:

1. [Show Cash App Afterpay in your payment form](#show-in-payment-form).
2. Collect shopper details, and specify these [in your payment request](#make-a-payment). Cash App Afterpay uses these for risk checks.
3. Provide information about the purchased items [in your payment request](#make-a-payment).
4. [Handle the redirect result](#handle-the-redirect) when the shopper returns to your website.

## Requirements

| Requirement          | Description                                                                                                                                                                       |
| -------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Integration type** | Make sure that you have built an Advanced flow [Android Components integration](/online-payments/build-your-integration/advanced-flow/?platform=Android\&integration=Components). |
| **Setup steps**      | Before you begin, [add Cash App Afterpay in your Customer Area](/payment-methods/add-payment-methods).                                                                            |

## Show Cash App Afterpay in your payment form

Include Cash App Afterpay in the list of available payment methods, and collect the required shopper details:

1. Specify in your [/paymentMethods](https://docs.adyen.com/api-explorer/Checkout/latest/post/paymentMethods) request the following combination of [countryCode](https://docs.adyen.com/api-explorer/Checkout/latest/post/paymentMethods) and [amount.currency](https://docs.adyen.com/api-explorer/Checkout/latest/post/paymentMethods#request-amount):

   | Country/region | `countryCode` | `amount.currency` |
   | -------------- | ------------- | ----------------- |
   | United States  | **US**        | **USD**           |

   The response contains `paymentMethod.type`: **afterpaytouch\_US**.

2. Collect the following shopper details:

   * Full name
   * Email address
   * Billing address and delivery address.

   Cash App Afterpay uses these information for risk checks.

We provide an Cash App Afterpay logo which you can use on your payment form. For more information, refer to [Downloading logos](/online-payments/build-your-integration/advanced-flow/?platform=Web\&integration=API%20only#downloading-logos).

## Make a payment

1. When the shopper proceeds to pay, make a [/payments](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments) request from your server, specifying:

   * `paymentMethod.type`: set this to **afterpaytouch\_US** to redirect to Cash App Afterpay.

   * [shopperName](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments#request-shopperName): the shopper's full name. 

   * [shopperEmail](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments#request-shopperEmail): the shopper's email address.  

   * [telephoneNumber](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments#request-telephoneNumber) (Optional): the shopper's phone number.

   * [billingAddress](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments#request-billingAddress): the postal address to be included on the invoice. 

   * [deliveryAddress](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments#request-deliveryAddress): the postal address where the goods will be shipped.

   * [lineItems](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments#request-lineItems): price and product information about the purchased items.  

   * `returnURL`: URL to where the shopper should be redirected back to after they complete the payment. Get this URL from the Component in the `RedirectComponent.getReturnUrl(context)`.

   #### curl

   ```bash
   curl https://checkout-test.adyen.com/v72/payments \
   -H 'x-api-key: ADYEN_API_KEY' \
   -H 'content-type: application/json' \
   -d '{
     "paymentMethod":{
        "type":"afterpaytouch_US"
     },
     "amount":{
        "value":1000,
        "currency":"USD"
     },
     "shopperName":{
        "firstName":"Simon",
        "lastName":"Hopper"
     },
     "shopperEmail":"s.hopper@example.com",
     "shopperReference":"YOUR_UNIQUE_SHOPPER_ID",
     "reference":"YOUR_ORDER_REFERENCE",
     "merchantAccount":"YOUR_MERCHANT_ACCOUNT",
     "returnUrl":"adyencheckout://your.package.name",
     "countryCode":"US",
     "telephoneNumber":"+16123456789",
     "billingAddress":{
        "city":"San Francisco",
        "country":"US",
        "houseNumberOrName":"274",
        "postalCode":"94107",
        "stateOrProvince":"CA",
        "street":"Brennan St."
     },
     "deliveryAddress":{
        "city":"San Francisco",
        "country":"US",
        "houseNumberOrName":"274",
        "postalCode":"94107",
        "stateOrProvince":"CA",
        "street":"Brennan St."
     },
     "lineItems":[
        {
           "description":"Shoes",
           "quantity":"1",
           "amountIncludingTax":"400",
           "amountExcludingTax": "331",
           "taxAmount": "69",
           "id":"Item #1"
        },
        {
           "description":"Socks",
           "quantity":"2",
           "amountIncludingTax":"300",
           "amountExcludingTax": "248",
           "taxAmount": "52",
           "id":"Item #2"
        }
     ]
   }'
   ```

   #### Java

   ```java
   // Set ADYEN_API_KEY with the API key from the Customer Area.
   // Change to Environment.LIVE and add the Live URL prefix when you are ready to accept live payments.
   Client client = new Client("ADYEN_API_KEY", Environment.TEST);
       Checkout checkout = new Checkout(client);

       PaymentsRequest paymentsRequest = new PaymentsRequest();

       String merchantAccount = "YOUR_MERCHANT_ACCOUNT";
       paymentsRequest.setMerchantAccount(merchantAccount);

       Amount amount = new Amount();
       amount.setCurrency("USD");
       amount.setValue(1000L);
       paymentsRequest.setAmount(amount);

       DefaultPaymentMethodDetails paymentMethodDetails = new DefaultPaymentMethodDetails();
       paymentMethodDetails.setType("afterpaytouch_US");
       paymentsRequest.setPaymentMethod(paymentMethodDetails);

       paymentsRequest.setReference("YOUR_ORDER_NUMBER");
       paymentsRequest.setReturnUrl("adyencheckout://your.package.name");

       Name shopperDetails = new Name();
       shopperDetails.setFirstName("Simon");
       shopperDetails.setLastName("Hopper");

       paymentsRequest.setShopperName(shopperDetails);
       paymentsRequest.setShopperReference("YOUR_UNIQUE_SHOPPER_ID");
       paymentsRequest.setCountryCode("US");
       paymentsRequest.setTelephoneNumber("+16123456789");
       paymentsRequest.setShopperEmail("s.hopper@example.com");


       BillingAddress billingAddress = new BillingAddress();
       billingAddress.setCountry("US");
       billingAddress.setCity("San Francisco");
       billingAddress.setHouseNumberOrName("274");
       billingAddress.setStreet("Brennan St.");
       billingAddress.setPostalCode("94107");
       billingAddress.setStateOrProvince("CA");

       paymentsRequest.setBillingAddress(billingAddress);

       DeliveryAddress deliveryAddress = new DeliveryAddress();
       deliveryAddress.setCountry("US");
       deliveryAddress.setCity("San Francisco");
       deliveryAddress.setHouseNumberOrName("274");
       deliveryAddress.setStreet("Brennan St.");
       deliveryAddress.setPostalCode("94107");
       deliveryAddress.setStateOrProvince("CA");

       paymentsRequest.setDeliveryAddress(deliveryAddress);

       List<LineItem> lineItems = new ArrayList<>();
       lineItems.add(
           new LineItem()
               .quantity(1L)
               .description("Shoes")
               .id("Item #1")
               .amountIncludingTax(400L)
               .amountExcludingTax(331L)
               .taxAmount(69L)
       );
       lineItems.add(
           new LineItem()
               .quantity(2L)
               .description("Socks")
               .id("Item #2")
               .amountIncludingTax(300L)
               .amountExcludingTax(248L)
               .taxAmount(52L)
       );

       paymentsRequest.setLineItems(lineItems);

       PaymentsResponse paymentsResponse = checkout.payments(paymentsRequest);
   ```

   #### PHP

   ```php
   // Set your X-API-KEY with the API key from the Customer Area.
   $client = new \Adyen\Client();
   $client->setXApiKey("ADYEN_API_KEY");
   $service = new \Adyen\Service\Checkout($client);

   $params = [
     "merchantAccount" => "YOUR_MERCHANT_ACCOUNT",
     "reference" => "YOUR_ORDER_NUMBER",
     "amount" => [
       "currency" => "USD",
       "value" => 1000
     ],
     "paymentMethod" => [
       "type" => "afterpaytouch_US"
     ],
     "returnUrl" => "adyencheckout://your.package.name",
     "countryCode" => "US",
     "shopperName" => [
          "firstName" => "Simon",
          "lastName" => "Hopper"
     ],
     "shopperEmail" => "s.hopper@example.com",
     "shopperReference" => "YOUR_UNIQUE_SHOPPER_ID",
     "telephoneNumber" => "+16123456789",
     "billingAddress" => [
          "city" => "San Francisco",
          "country" => "US",
          "houseNumberOrName" => "274",
          "postalCode" => "94107",
          "stateOrProvince" => "CA",
          "street" => "Brennan St."
     ],
     "deliveryAddress" => [
          "city" => "San Francisco",
          "country" => "US",
          "houseNumberOrName" => "274",
          "postalCode" => "94107",
          "stateOrProvince" => "CA",
          "street" => "Brennan St."
     ],
     "lineItems" => [
        [
           "description" => "Shoes",
           "quantity" => "1",
           "amountIncludingTax" => "400",
           "amountExcludingTax" => "331",
           "taxAmount" => "69",
           "id" => "Item #1"
        ],
        [
           "description" => "Socks",
           "quantity" => "2",
           "amountIncludingTax" => "300",
           "amountExcludingTax" => "248",
           "taxAmount" => "52",
           "id" => "Item #2"
        ]
       ]
   ];
   $result = $service->payments($params);
   ```

   #### C\#

   ```cs
   // Set your X-API-KEY with the API key from the Customer Area.
   var client = new Client ("ADYEN_API_KEY", Environment.Test);
   var checkout = new Checkout(client);

   var paymentsRequest = new Adyen.Model.Checkout.PaymentRequest
   {
      MerchantAccount = "YOUR_MERCHANT_ACCOUNT",
      Reference = "YOUR_ORDER_REFERENCE",
      PaymentMethod = new DefaultPaymentMethodDetails { Type = "afterpaytouch_US" },
      Amount = new Adyen.Model.Checkout.Amount(currency: "USD", value: 1000),
      CountryCode = "US",
      TelephoneNumber = "+16123456789",
      ShopperEmail = "s.hopper@example.com",
      ShopperName = new Adyen.Model.Checkout.Name
      {
          FirstName = "Simon",
          LastName = "Hopper"
      },
      ShopperReference = "YOUR_UNIQUE_SHOPPER_ID",
      BillingAddress = new Adyen.Model.Checkout.Address
      {
          City = "San Francisco",
          Country = "US",
          HouseNumberOrName = "274",
          PostalCode = "94107",
          StateOrProvince = "CA",
          Street = "Brennan St."
      },
      DeliveryAddress = new Adyen.Model.Checkout.Address
      {
          City = "San Francisco",
          Country = "US",
          HouseNumberOrName = "274",
          PostalCode = "94107",
          StateOrProvince = "CA",
          Street = "Brennan St."
      },
      ReturnUrl = "adyencheckout://your.package.name",
      LineItems = new List<LineItem>
      {
        new LineItem(quantity:1, description: "Shoes", id: "Item #1", amountIncludingTax: 400, amountExcludingTax: 331, taxAmount: 69),
        new LineItem(quantity:2, description: "Socks", id: "Item #2", amountIncludingTax: 300, amountExcludingTax: 248, taxAmount: 52)
      }
   };
   ```

   #### NodeJS (JavaScript)

   ```js
   // Adyen Node API Library v16.1.0
   // Require the parts of the module you want to use
   const { Client, CheckoutAPI } = require('@adyen/api-library');

   // Initialize the client object
   const client = new Client({apiKey: "YOUR_X_API_KEY", environment: "TEST"});

   // Create the request object
   const paymentRequest = {
     paymentMethod: {
       type: "afterpaytouch_US"
     },
     amount: {
       value: 1000,
       currency: "USD"
     },
     shopperName: {
       firstName: "Simon",
       lastName: "Hopper"
     },
     shopperEmail: "s.hopper@example.com",
     shopperReference: "YOUR_UNIQUE_SHOPPER_ID",
     reference: "YOUR_ORDER_REFERENCE",
     merchantAccount: "YOUR_MERCHANT_ACCOUNT",
     returnUrl: "adyencheckout://your.package.name",
     countryCode: "US",
     telephoneNumber: "+16123456789",
     billingAddress: {
       city: "San Francisco",
       country: "US",
       houseNumberOrName: "274",
       postalCode: "94107",
       stateOrProvince: "CA",
       street: "Brennan St."
     },
     deliveryAddress: {
       city: "San Francisco",
       country: "US",
       houseNumberOrName: "274",
       postalCode: "94107",
       stateOrProvince: "CA",
       street: "Brennan St."
     },
     lineItems: [ {
       description: "Shoes",
       quantity: "1",
       amountIncludingTax: "400",
       amountExcludingTax: "331",
       taxAmount: "69",
       id: "Item #1"
     }, {
       description: "Socks",
       quantity: "2",
       amountIncludingTax: "300",
       amountExcludingTax: "248",
       taxAmount: "52",
       id: "Item #2"
     } ]
   }

   // Make the request
   const checkoutAPI = new CheckoutAPI(client);
   const response = checkoutAPI.PaymentsApi.payments(paymentRequest, { idempotencyKey: "UUID" });
   ```

   #### Python

   ```py
   # Adyen Python API Library v12.0.0
   import Adyen

   adyen = Adyen.Adyen()
   adyen.client.xapikey = "YOUR_X_API_KEY"
   adyen.client.platform = "test" # The environment to use library in.

   json_request = {
     "paymentMethod": {
       "type": "afterpaytouch_US"
     },
     "amount": {
       "value": 1000,
       "currency": "USD"
     },
     "shopperName": {
       "firstName": "Simon",
       "lastName": "Hopper"
     },
     "shopperEmail": "s.hopper@example.com",
     "shopperReference": "YOUR_UNIQUE_SHOPPER_ID",
     "reference": "YOUR_ORDER_REFERENCE",
     "merchantAccount": "YOUR_MERCHANT_ACCOUNT",
     "returnUrl": "adyencheckout://your.package.name",
     "countryCode": "US",
     "telephoneNumber": "+16123456789",
     "billingAddress": {
       "city": "San Francisco",
       "country": "US",
       "houseNumberOrName": "274",
       "postalCode": "94107",
       "stateOrProvince": "CA",
       "street": "Brennan St."
     },
     "deliveryAddress": {
       "city": "San Francisco",
       "country": "US",
       "houseNumberOrName": "274",
       "postalCode": "94107",
       "stateOrProvince": "CA",
       "street": "Brennan St."
     },
     "lineItems": [ {
       "description": "Shoes",
       "quantity": "1",
       "amountIncludingTax": "400",
       "amountExcludingTax": "331",
       "taxAmount": "69",
       "id": "Item #1"
     }, {
       "description": "Socks",
       "quantity": "2",
       "amountIncludingTax": "300",
       "amountExcludingTax": "248",
       "taxAmount": "52",
       "id": "Item #2"
     } ]
   }

   result = adyen.checkout.payments_api.payments(request=json_request, idempotency_key="UUID")
   ```

   #### Ruby

   ```rb
   # Adyen Ruby API Library v9.1.0
   require "adyen-ruby-api-library"

   adyen = Adyen::Client.new
   adyen.api_key = 'YOUR_X_API_KEY'
   adyen.env = :test # Set to "live" for live environment

   request_body = {
     :paymentMethod => {
       :type => 'afterpaytouch_US'
     },
     :amount => {
       :value => 1000,
       :currency => 'USD'
     },
     :shopperName => {
       :firstName => 'Simon',
       :lastName => 'Hopper'
     },
     :shopperEmail => 's.hopper@example.com',
     :shopperReference => 'YOUR_UNIQUE_SHOPPER_ID',
     :reference => 'YOUR_ORDER_REFERENCE',
     :merchantAccount => 'YOUR_MERCHANT_ACCOUNT',
     :returnUrl => 'adyencheckout://your.package.name',
     :countryCode => 'US',
     :telephoneNumber => '+16123456789',
     :billingAddress => {
       :city => 'San Francisco',
       :country => 'US',
       :houseNumberOrName => '274',
       :postalCode => '94107',
       :stateOrProvince => 'CA',
       :street => 'Brennan St.'
     },
     :deliveryAddress => {
       :city => 'San Francisco',
       :country => 'US',
       :houseNumberOrName => '274',
       :postalCode => '94107',
       :stateOrProvince => 'CA',
       :street => 'Brennan St.'
     },
     :lineItems => [ {
       :description => 'Shoes',
       :quantity => '1',
       :amountIncludingTax => '400',
       :amountExcludingTax => '331',
       :taxAmount => '69',
       :id => 'Item #1'
     }, {
       :description => 'Socks',
       :quantity => '2',
       :amountIncludingTax => '300',
       :amountExcludingTax => '248',
       :taxAmount => '52',
       :id => 'Item #2'
     } ]
   }

   result = adyen.checkout.payments_api.payments(request_body, headers: { 'Idempotency-Key' => 'UUID' })
   ```

   In the [/payments](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments) response, check the `action` object for the information that you must use to redirect the shopper.

   **/payments response**

   ```json
   {
     "resultCode":"RedirectShopper",
     "action":{
       "paymentMethodType":"afterpaytouch_US",
       "method":"GET",
       "url":"https://checkoutshopper-test.adyen.com/checkoutshopper/checkoutPaymentRedirect?redirectData=...",
       "type":"redirect"
     }
   }
   ```

2. Pass the `action` object to your client app. You need this to initialize the Redirect Component.

## Handle the redirect

1. Use the [Redirect Component](/online-payments/build-your-integration/sessions-flow/?platform=Android\&integration=Components#handle-a-redirect) to redirect the shopper to Cash App Afterpay.

2. After the shopper returns to your app, make a POST [/payments/details](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments/details) request from your server, providing:

   * `details`: The `actionComponentData.details` object from the Redirect Component.

**/payments/details request**

```bash
curl https://checkout-test.adyen.com/v72/payments/details \
-H 'x-api-key: ADYEN_API_KEY' \
-H 'content-type: application/json' \
-d '{
     "details": {
       "redirectResult": "eyJ0cmFuc1N0YXR1cyI6IlkifQ=="
   }
}'
```

You receive a response containing:

* `resultCode`: Use this to present the payment result to your shopper.
* `pspReference`: Our unique identifier for the transaction.

**/payments/details response**

```json
{
      "resultCode": "Authorised",
      "pspReference": "PPKFQ89R6QRXGN82"
}
```

## Present the payment result

Use the `resultCode` that you received in the [/payments/details](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments/details) response to present the payment result to your shopper.

The `resultCode` values you can receive for Cash App Afterpay are:

| resultCode                  | Description                                                                                                                | Action to take                                                                                                                                                                                                                        |
| --------------------------- | -------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Authorised**              | The payment was successful.                                                                                                | Inform the shopper that the payment was successful.                                                                                                                                                                                   |
| **Cancelled**               | The shopper cancelled the payment.                                                                                         | Ask the shopper whether they want to continue with the order, or ask them to select a different payment method.                                                                                                                       |
| **Pending** or **Received** | The shopper has completed the payment but the final result is not yet known. It may take minutes or hours to confirm this. | Inform the shopper that you have received their order, and are waiting for the payment to be completed. To know the final result of the payment, wait for the [AUTHORISATION webhook](/development-resources/webhooks/webhook-types). |
| **Refused**                 | The payment was refused by Cash App Afterpay.                                                                              | Ask the shopper to try the payment again using a different payment method.                                                                                                                                                            |

[]()If the shopper failed to return to your website or app, wait for webhooks to know the outcome of the payment:

| eventCode         | success field | Description                                     | Action to take                                                                 |
| ----------------- | ------------- | ----------------------------------------------- | ------------------------------------------------------------------------------ |
| **AUTHORISATION** | **false**     | The transaction failed.                         | Cancel the order and inform the shopper that the payment failed.               |
| **AUTHORISATION** | **true**      | The shopper successfully completed the payment. | Inform the shopper that the payment was successful and proceed with the order. |

## Capture the payment

Depending on your merchant account configuration, Cash App Afterpay payments are captured automatically after authorisation, or manually captured. If you prefer to capture the payment after the goods have been sent, you need to set up a [capture delay](/online-payments/capture#delayed-automatic-capture) or use [manual capture](/online-payments/capture#capture-a-payment). To partially capture a payment, you also need to use manual capture.

Cash App Afterpay payments have to be captured within 13 days after authorisation.

During authorisation, the shopper is charged for the first installment. If the payment is not captured within 13 days, before the second installment, Cash App Afterpay cancels the payment and refunds the first installment to the shopper.

For testing purposes, Cash App Afterpay authorisations expire in one day. When you use manual capture, you need to capture test Cash App Afterpay payments within one day after authorisation.

### Full or partial manual captures

When you use manual capture, in your [/payments/{paymentPspReference}/captures](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments/\(paymentPspReference\)/captures) request specify:

* [amount.value](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments/\(paymentPspReference\)/captures#request-amount-value): the full or partial amount that the shopper should pay.
* [lineItems](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments/\(paymentPspReference\)/captures#request-lineItems): (optional) price and product information for the items that the shopper should pay for.

Any unclaimed amount that is left over after partially capturing a payment is automatically cancelled. When your account is enabled for *multiple* partial captures, the unclaimed amount after an initial capture is not automatically cancelled.

To set up multiple partial captures, contact our [Support Team](https://ca-test.adyen.com/ca/ca/contactUs/support.shtml?form=other). Multiple partial captures will create a new invoice for each capture.

## Refunds and cancellations

If a payment has not yet been captured, you can [cancel](/online-payments/cancel) it. If a payment has already been captured and you want to return the funds to the shopper, you need to [refund](/online-payments/refund) the payment.

### Full or partial refunds

To fully or partially refund a payment, in your [/payments/{paymentPspReference}/refunds](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments/\(paymentPspReference\)/refunds) request specify:

* [amount.value](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments/\(paymentPspReference\)/refunds#request-amount-value): the full or partial amount to be refunded to the shopper.
* [lineItems](https://docs.adyen.com/api-explorer/Checkout/latest/post/payments/\(paymentPspReference\)/refunds#request-lineItems): (optional) price and product information about the refunded items.

## Discounts

To offer discounts, your payment request must include the negative amount to be added to the original price. The following example shows how to specify a discount of 1 USD on Item #2:

```json
{
  "amount":{
     "value":800,
     "currency":"USD"
  },
  ...
  "lineItems":[

     {
        "description":"Test Cash App Afterpay 1",
        "quantity":"1",
        "amountIncludingTax":"400",
        "id":"Item #1"
     },
     {
        "description":"Test Cash App Afterpay 2",
        "quantity":"2",
        "amountIncludingTax":"300",
        "id":"Item #2"
     }

     {
        "description":"Discount",
        "quantity":"2",
        "amountIncludingTax":"-100",
        "id":"Item #2 Discount"
     }
  ]
}
```

## Test and go live

To test Cash App Afterpay payments, you need a test shopper account in the Afterpay sandbox environment.

To create a test account:

1. Go to <https://portal.sandbox.afterpay.com/>.
2. Enter a real email address and select **Continue**. You will get confirmations of payments and refunds like any other shopper on this email address.
3. From the drop-down menu, select the country/region for which you want to create a test shopper account: **US**.
4. Enter any mobile telephone number that is formatted correctly, and select **Continue**. Check the input box for hints on the format. The phone number will not be used.
5. When you are prompted to enter your SMS verification code, enter **111111**.
6. Follow the instructions on your screen to complete your profile, accept the terms and conditions, and select **Continue**.

To test payments, add a test card to your Afterpay test shopper account.\
You can use the card details provided in the Afterpay [developer documentation](https://developers.afterpay.com/afterpay-online/docs/customer-accounts), or use one of the Adyen [test cards](/development-resources/test-cards-and-credentials/test-card-numbers). Use CVV 000 to simulate authorised payments, or CVV 051 to simulate refused payments.

You can check the status of test payments in your [Customer Area](https://ca-test.adyen.com/) > **Transactions** > **Payments**.

Before you can accept live Cash App Afterpay payments, you need to [submit a request for Cash App Afterpay](/payment-methods/add-payment-methods) in your [live Customer Area](https://ca-live.adyen.com/).

## See also

* [Android Components integration guide](/online-payments/build-your-integration/sessions-flow?platform=Android\&integration=Components)
* [Webhooks](/development-resources/webhooks)
* [API Explorer](https://docs.adyen.com/api-explorer/#/CheckoutService/latest/overview)
