FILTER BY TAG

PayPal

PayPal is a secure and convenient payment service that your customers can use to make payments without directly using their bank accounts or credit cards. PayPal gives yours customers the option to pay in installments over time with PayPal Pay Later while also giving you the full payment immediately. These installments are available:
  • Pay in 3
    : Pay in three installments. Available in the UK.
  • Pay in 4
    : Pay in four installments. Available in the US.
  • Pay Monthly
    : Pay in monthly recurring installments.

Opt in to PayPal on
Unified Checkout

You can enable PayPal from the
Unified Checkout
merchant experience section in the
Business Center
. For information about how to enable PayPal using the
Business Center
, see Configure Payment Options.
You can also enable PayPal using the
Unified Checkout
v1/sessions
API. Follow these steps to opt in to the PayPal payment method using the API:
  1. Add PayPal to your integration by adding
    PAYPAL
    to the
    allowedPaymentTypes
    field within the capture context request.
  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.
    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:
    • orderInformation.amountDetails.currency
    • orderInformation.amountDetails.taxAmount
      • This field is the sum of all
        orderInformation.lineItems[].taxAmount
        values.
    • orderInformation.amountDetails.totalAmount
      • This field is the sum of (
        orderInformation.lineItems[].quantity
        ×
        orderInformation.lineItems[].unitPrice
        ) +
        orderInformation.lineItems[].taxAmount
        for all line items.
    • orderInformation.lineItems[].productDescription
    • orderInformation.lineItems[].productName
    • orderInformation.lineItems[].productSKU
    • orderInformation.lineItems[].quantity
    • orderInformation.lineItems[].taxAmount
      IMPORTANT
      This field is required for all line items when you include
      orderInformation.lineItems[].taxAmount
      for one line item.
      • You can set this field value to
        0.00
        if tax is not applicable.
    • orderInformation.lineItems[].typeOfSupply
    • orderInformation.lineItems[].unitPrice
  4. Include these optional fields in the capture context request:
    • buyerInformation.dateOfBirth
    • buyerInformation.language
    • buyerInformation.personalIdentification[].id
    • buyerInformation.personalIdentification[].type
    • clientReferenceInformation.reconciliationId
    • merchantInformation.merchantDescriptor.name
      • This field affects the name that the customers see on their card statement. If the merchant is Candy Shop and passes this as their name - customer will see
        PAYPAL * Candy Shop
        in their bank statement.
    • orderInformation.amountDetails.taxDetails.taxId
    • orderInformation.amountDetails.taxDetails.type
    • data.orderInformation.billTo.address1
    • data.orderInformation.billTo.company.name
    • data.orderInformation.billTo.country
    • data.orderInformation.billTo.email
    • data.orderInformation.billTo.firstName
    • data.orderInformation.billTo.lastName
    • data.orderInformation.billTo.locality
    • data.orderInformation.billTo.phoneNumber
    • orderInformation.invoiceDetails.invoiceNumber
    • orderInformation.invoiceDetails.productDescription
    • orderInformation.lineItems[].totalAmount
    • data.orderInformation.shipTo.country
    • data.orderInformation.shipTo.locality
    • data.orderInformation.shipTo.postalCode
    • paymentInformation.customer.customerid
    • processingInformation.processingInstruction
      • Set this field to
        ORDER_SAVED_EXPLICITLY
        to save the customer's payment credentials using the save an order follow-on request.

Currencies

Currencies are two-decimal currencies unless otherwise specified.

Zero-Decimal Currencies

PayPal treats Hungarian Forint (HUF), New Taiwan Dollar (TWD), and Japanese Yen (JPY) as zero-decimal currencies. For these currencies, currency amounts must be submitted as whole-unit values only.
These currencies must meet these formatting requirements:
Currency Formatting
Currency
Supported Format
Unsupported Format
HUF
800.00
800.45
JPY
800
800.00, 800.45
TWD
800.00
800.45
IMPORTANT
When using PayPal, HUF and TWD currency amounts must be submitted as whole-unit values. Any amount containing a non-zero fractional component, such as 800.95, 800.50, or 800.01, will be rejected by PayPal. For JPY, the currency amounts must be a whole number, such as 800.

Example: Multiple Line-Items

This example includes multiple line items in the
amountDetails
field object:
{ "amountDetails": { "totalAmount": "221.91", "currency": "USD", "taxAmount": "14.42" }, "lineItems": [ { "productName": "501 Original Fit Jeans Blues", "productSku": "00501019403432", "quantity": 1, "unitPrice": "100.0", "totalAmount": "100.00", "taxAmount": "8.63" }, { "productName": "Levi Blue shirt Plaid", "productSku": "0094784142", "quantity": 1, "unitPrice": "100.00", "totalAmount": "100.00", "taxAmount": "5.79" }, { "productName": "shipping_and_handling", "productSku": "shipping_and_handling", "quantity": 1, "unitPrice": "7.49", "totalAmount": "7.49", "taxAmount": "0.00" } ] }