---
updatedAt: 2025-12-10T21:55:30.000Z
agentTools:
  siteIndex: https://docs.affirm.com/llms.txt
  projectIndex: https://docs.affirm.com/platforms/llms.txt
---

# Fiserv

Integrate Affirm with Fiserv using Hosted Checkout or Direct API to increase AOV, reduce fraud risk, and deliver a seamless BNPL checkout.

<HTMLBlock>{`
<style>
  .dropdown-menu {
    font-family: Arial, sans-serif;
    max-width: 250px;
    margin-left: auto; /* Align to the right */
  	margin-right: 0; /* Ensure it's flush to the right */
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 10px;
    background: #4A4AF4;
    overflow: hidden; /* Ensure the container grows with content */
  }

  .dropdown-item {
    margin-bottom: 10px;
  }

  .dropdown-toggle {
    display: block;
    width: 100%;
    text-align: left;
    padding: 10px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
  }

  .dropdown-toggle:hover {
    background: #f0f0f0;
  }

  .dropdown-content {
    display: none;
    margin-top: 5px;
    padding: 10px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
  }

  .dropdown-item.open .dropdown-content {
    display: block;
  }

  .flag-icon {
    width: 20px;
    height: 20px;
    margin-right: 10px;
  }

  .product-item {
    margin-bottom: 5px;
  }

  .product-icon {
    width: 20px;
    height: 20px;
    margin-right: 10px;
  }
  
  .country-title {
    font-family: Arial, sans-serif;
    font-size:20px;
    text-align: center;
    font-weight: bold;
    color: #ffffff;
  } 

</style>
  <div class="dropdown-menu">
    <p class="country-title" alt="Countries where this product is available">Country Availability</p>

    <div class="dropdown-item">
      <button class="dropdown-toggle" onclick="toggleDropdown(event)" alt="Drop down menu displaying the available countries for this product">
        <b>Country List</b> ⬇️
      </button>
      <div class="dropdown-content">
        <div class="product-item">
          <img src="https://files.readme.io/a4c8b3d6596d943e2b93c82cb1d432a2edaf6998667835c2e97ef4a31d460c7e-us-circle-01.png" alt="USA" class="flag-icon">
          USA
        </div>
        <div class="product-item">
          <img src="https://files.readme.io/3ca294a1b4b8b8506c3ff32876abc6e3e33d0e65a509dab81398915094bdbc5c-61TcZ33ZrJL._AC_UY1000_.jpg" alt="Canada" class="flag-icon">
          Canada
        </div>
      </div>
    </div>

  </div>
`}</HTMLBlock>

## Overview

Fiserv supports Affirm as a Buy Now, Pay Later (BNPL) payment method across its online and mobile checkout solutions utilizing their enterprise gateway, CommerceHub. Merchants can enable Affirm using either Hosted Checkout (SDK, Hosted Pages, Hosted Components) or Direct API integrations.

<Image align="center" border={false} src="https://files.readme.io/b4bc02cd1ecf6c922c100783cdd3f1b0865bc9c1eb5e2c407de5487a8e5977b0-Affirm_and_Fiserv.svg" />

## How Affirm works

### Customer experience

1. Customer selects Affirm as the payment method during checkout.
2. Merchant initiates a payment request through CommerceHub (Hosted Checkout or Checkouts Orders API).
3. Customer is redirected to Affirm to log in, review the loan, and approve.
4. Customer is redirected back to the merchant’s site with the transaction decision.
5. Merchant captures the payment if required (authorization → capture).
6. CommerceHub processes and returns final transaction details to the merchant.

### Who Affirm pays

Affirm pays the merchant after approval.

### Fraud, repayment, and risk

* Affirm owns fraud risk and consumer repayment risk for all approved transactions.
* Merchants receive guaranteed funds once the transaction is captured.

## Integration steps

CommerceHub offers three primary integration methods for enabling Affirm:

* Hosted Checkout SDK
* Hosted pages and hosted components
* Direct API (full control integration)

### 1. Hosted Checkout SDK

Ideal for minimizing development lift. CommerceHub manages data collection, tokenization, and transmission to Affirm.

#### Steps

1. **Whitelist domains** used in production. (Localhost testing allowed.)
2. **Start PaymentSession** by submitting a server-side Security Credentials API request (returns: `accessToken`, `sessionId`, `publicKey`, `clientEncryptionAlgorithm`).
3. **Initialize the SDK** using `window.fiserv.init`.
4. **Initialize the Affirm component** with `window.fiserv.components.affirm()`.
5. **Submit a Checkouts Orders request** using values returned via the `onApprove` hook (`orderId`, `transactionId`).

#### After checkout

Use Checkouts Orders API to authorize, capture, cancel, refund, or update orders.

<Callout icon="📘" theme="info">
  Fiserv Hosted Checkout SDK documentation

  For more details on this integration, please review the [Affirm Hosted Checkout SDK integration guide](https://developer.fiserv.com/product/CommerceHub/docs/?path=docs/Online-Mobile-Digital/Wallets-AltPayments/BNPL/Affirm/Affirm-Checkout.md\&branch=main) on Fiserv’s developer site.
</Callout>

### 2. Hosted pages and hosted components

These options allow merchants to enable Affirm without building custom UI.

#### Hosted pages

Customers are redirected to a secure, branded CommerceHub-hosted checkout page with Affirm enabled.

#### Steps

1. Access Checkout Configurator.
2. Create a Checkout Page.
3. Customize layout & payment fields.
4. Configure appearance.
5. Preview & test.
6. Promote to production.

#### Hosted components

Embeddable iFrame/WebView/Modal components that support Affirm as a payment option.

Both Hosted Pages and Hosted Components use the same Checkout Configurator for design and layout.

<Callout icon="📘" theme="info">
  Fiserv Hosted pages and hosted components documentation

  For more details on this integration, please review the [Creating and managing Checkout Pages](https://developer.fiserv.com/product/CommerceHub/docs/?path=docs/Online-Mobile-Digital/Hosted-Checkout/Checkout-Pages/Checkout-Pages-Manage.md\&branch=main) on Fiserv’s developer site.
</Callout>

### 3. Direct API (full control integration)

Ideal for merchants wanting full backend control over their Affirm checkout flow.

#### Steps

1. Create a checkout order using the Checkouts Orders API.
2. Redirect the customer to the actions.url returned in the API response.
3. Submit a payment request:
   1. Can be sale or authorization.
   2. If authorization, follow with a capture request.

#### Additional actions available

* **Update** checkout order
* **Cancel** order
* **Refund** captured order
* **Inquiry** request to retrieve transaction history

<Callout icon="📘" theme="info">
  Fiserv Direct API documentation

  For more details on this integration, please review the [Affirm Direct API integration guide](https://developer.fiserv.com/product/CommerceHub/docs/?path=docs/Online-Mobile-Digital/Wallets-AltPayments/BNPL/Affirm/Affirm-API-Guide.md\&branch=main) on Fiserv’s developer site.
</Callout>

## Next steps

Please reach out to your Fiserv Relationship Manager for more information on how to get started with Affirm.

## Additional resources

CommerceHub developer documentation:

* [CommerceHub Affirm overview](https://developer.fiserv.com/product/CommerceHub/docs/?path=docs/Online-Mobile-Digital/Wallets-AltPayments/BNPL/Affirm/Affirm.md\&branch=main#affirm)
* [Affirm Hosted Checkout SDK integration guide](https://developer.fiserv.com/product/CommerceHub/docs/?path=docs/Online-Mobile-Digital/Wallets-AltPayments/BNPL/Affirm/Affirm-Checkout.md\&branch=main#affirm-hosted-checkout-sdk-integration-guide)
* [Creating and managing Checkout Pages](https://developer.fiserv.com/product/CommerceHub/docs/?path=docs/Online-Mobile-Digital/Hosted-Checkout/Checkout-Pages/Checkout-Pages-Manage.md\&branch=main#creating-and-managing-checkout-pages)
* [Affirm Direct API integration guide](https://developer.fiserv.com/product/CommerceHub/docs/?path=docs/Online-Mobile-Digital/Wallets-AltPayments/BNPL/Affirm/Affirm-API-Guide.md\&branch=main#affirm-direct-api-integration-guide)

<br />

# Sibling pages

* [About PSP Integrations](https://docs.affirm.com/platforms/docs/payment-providers-overview.md)
* [Adyen](https://docs.affirm.com/platforms/docs/adyen.md)
* [APEXX](https://docs.affirm.com/platforms/docs/apexx.md)
* [Bolt](https://docs.affirm.com/platforms/docs/bolt.md)
* [BridgerPay](https://docs.affirm.com/platforms/docs/bridgerpay.md)
* [Fexco](https://docs.affirm.com/platforms/docs/fexco.md)
* [Global Payments](https://docs.affirm.com/platforms/docs/global-payments.md)
* [Stripe](https://docs.affirm.com/platforms/docs/stripe.md)
* [UATP](https://docs.affirm.com/platforms/docs/uatp.md)
* [Verifone](https://docs.affirm.com/platforms/docs/verifone.md)
* [Worldpay](https://docs.affirm.com/platforms/docs/worldpay.md)