Afterpay {#uc-pay-methods-bnpl-afterpay}
========================================

Afterpay is a Buy Now, Pay Later service that allows customers to purchase items immediately and pay for them in four interest-free installments over a period of 6 weeks. Afterpay is also known as Clearpay in the UK, and Cash App Afterpay in the US. For more information, see the [*Afterpay and Clearpay Developer Guide*](https://developer.cybersource.com/docs/cybs/en-us/afterpay/developer/all/so/afterpay/afterpay-intro.md "").  
When the total amount of the order is outside the range of accepted transaction amounts, the Afterpay/Clearpay payment button is not displayed in `Unified Checkout`. These are the accepted transaction amounts:

* **Minimum transaction amount**: 1 (CAD, AUD, NZD, USD, and GBP)
* **Maximum transaction amount**: Not applicable

Billing Details for Afterpay
----------------------------

The captureMandate.billingType field value determines whether `Unified Checkout` displays the full billing details form when Afterpay requires full billing details.  
When the captureMandate.billingType field is set to `FULL` and Afterpay requires full billing details, `Unified Checkout` displays the full billing details form.

* If the merchant includes all required fields in the capture context request, and the billing country is compatible with the payment type, the consumer currency, or both, the consumer sees a billing summary confirmation screen.
* If the merchant does not include all required fields in the capture context request, the consumer sees the full billing details form.

When the captureMandate.billingType field is set to `PARTIAL` and Afterpay requires full billing details, `Unified Checkout` displays the full billing details form.

* If the merchant includes all required fields in the capture context request, and the billing country is compatible with the payment type, the consumer currency, or both, the consumer sees a billing summary confirmation screen.
* If the merchant does not include all required fields in the capture context request, the consumer sees the full billing details form.

When the captureMandate.billingType field is set to `NONE` and Afterpay requires full billing details, the Afterpay payment button is not displayed within `Unified Checkout`.

Opt in to Afterpay on `Unified Checkout`
----------------------------------------

You can enable Afterpay from the `Unified Checkout` merchant experience section in the `Business Center`. For information about how to enable Afterpay using the `Business Center`, see [Configure Payment Options](/docs/cybs/en-us/digital-accept-flex/developer/all/rest/digital-accept-flex/uc-intro/uc-intro-setup/uc-intro-setup-ebc/uc-intro-payment-options.md "").  
You can also enable Afterpay using the `Unified Checkout` `v1/sessions` API. Follow these steps to opt in to the Afterpay payment method using the API:

1. Add Afterpay to your integration by adding `AFTERPAY` to the allowedPaymentTypes field within the capture context request. The default field value is `AFTERPAY` even if you want to support Cash App Afterpay in the US or Clear Pay in the UK.
2. Set the completeMandate.type field value to `AUTH`, `CAPTURE` or `PREFER_AUTH`.  
   You can perform a sale and capture the funds immediately if you include the completeMandate.type field in the capture context request and set the value to `CAPTURE`.  
   You can capture the funds later if you include the completeMandate.type field in the capture context request and set the value to `AUTH`. When you capture the funds later, you must perform a capture using the payments API. See [Captures](/docs/cybs/en-us/digital-accept-flex/developer/all/rest/digital-accept-flex/uc-intro/uc-pay-methods-intro/uc-altpay-methods-intro/uc-pay-methods-bnpl/uc-pay-methods-bnpl-captures.md "").  
   If you accept more than one payment type and must perform an authorization where funds are collected at a later time, set the completeMandate.type field to `PREFER_AUTH`. You must perform a capture using the payments API when an authorization is performed. A capture is performed automatically if an authorization is not allowed by the payment type.
3. Include these required fields in the capture context request:
   * data.orderInformation.billTo.email
   * data.orderInformation.billTo.firstName
   * data.orderInformation.billTo.lastName
   * data.orderInformation.billTo.address1
   * data.orderInformation.billTo.locality
   * data.orderInformation.billTo.postalCode
   * data.orderInformation.billTo.administrativeArea
   * data.orderInformation.billTo.country
4. Include these optional fields in the capture context request:

   > IMPORTANT
   > These fields are required when the requestShipping field is set to ` true `.

   * data.orderInformation.shipTo.firstName
   * data.orderInformation.shipTo.lastName
   * data.orderInformation.shipTo.address1
   * data.orderInformation.shipTo.locality
   * data.orderInformation.shipTo.postalCode
   * data.orderInformation.shipTo.administrativeArea
   * data.orderInformation.shipTo.country

IMPORTANT When you do not include the billing and shipping information in the capture context request, a pop-up will appear for the merchant to provide this information during checkout.
