Skip to main content

Merchant Help

 

Affirm Merchant Help

Miva Integration

Overview

This guide describes how to integrate Affirm into the Miva Ecommerce platform so that you can provide Affirm as a payment option to your customers. After integrating Affirm, your Miva site will:

  • Offer Affirm as payment option on the checkout page
  • Process Affirm charges in your order management system
  • Display Affirm promotional messaging

The integration steps are:

  1. Install Affirm
  2. Configure Affirm as a payment method
  3. Add Affirm promotional messaging
  4. Review your order management functions
  5. Test your integration
  6. Deploy to production

Before you begin

Before beginning integration, you should review:

Sandbox development

You should have received an email inviting you to create an Affirm account. Click here for information about accessing your account.

Develop and test the Affirm integration in your development environment connected to our sandbox. To use our sandbox, retrieve your sandbox API keys at https://sandbox.affirm.com/dashboard/#/apikeys for use during integration.

After development and testing, you'll need to update your integration to use your live API keys, which you can find at https://affirm.com/dashboard/#/apikeys.

1. Install Affirm

  1. Download the free Affirm module
  2. Unzip the file
  3. Sign in to the Miva Merchant Admin page
  4. On the left-side menu, click Modules
  5. Click the large + button on the right
  6. Click Upload
  7. Click Choose File
  8. Select affirm.mvc from the unzipped module files
  9. Click Upload
  10. In the Add Module window, Click the + Add button
  11. On the main Miva Merchant Admin screen, choose Payment on the left-side menu
  12. In the Payment Settings window, click the Add/Remove Modules tab
  13. Verify that the Available Modules group displays Affirm module (Buy with Affirm)
  14. In the Affirm module (Buy with Affirm) window, click Install

2. Configure Affirm as a payment method

To use the Affirm as a payment method, you must use an OPAY screen with the Global Head item included and assigned to the checkout page, which is the default setup. The snippet, mvt:item name="affirm" />,  is automatically inserted into the Global Head template. To use Affirm banners and promotional messaging, the Global Head item must be included and assigned to the BASK, PROD and SFNT pages, which is the default setup.

After installing the module, enable Affirm as a payment method by updating these configurations:

  1. Sign in to your Miva Merchant admin page
  2. Go to Menu > Payment
  3. Click on the Buy with Affirm tab
  4. In the Runtime Settings section, set Operation Mode to Sandbox
  5. If your checkout process automatically captures the charge, set Authorization Mode to Auth/Capture
  6. Verify that Active checkbox is checked
  7. Enter the Sandbox Public Key and Sandbox Private Key you retrieved from the Affirm sandbox merchant dashboard
  8. Click Save Settings

Screen Shot 2018-07-31 at 12.46.49 PM.png

3. Add Affirm promotional messaging

Add Affirm promotional messaging—which includes monthly payment messaging and educational modals—on your product, category, and cart pages.
Note that Miva Merchant software updates may replace page templates, including BASK, PROD and SFNT templates. You’ll need to manually copy the Affirm MVT items to their proper locations in each of the affected templates or Affirm promotional messaging won’t display.

Add promotional messaging

  1. Add monthly payment messaging by inserting <mvt:item name="affirm" param="showmonthly" /> near the price display in the BASK/Basket Contents template and PROD/Product Display Layout template (monthly payment messaging tags have the class affirm-as-low-as for styling with CSS)
  2. On the Miva Merchant admin main page, go to  Menu > Payment
  3. Click on the Buy with Affirm tab
  4. In the Monthly Promotional Messaging section, check the Show monthly promo checkbox
  5. If you do not want to display the Learn More link in the messaging, uncheck the Show Learn More Link checkbox
  6. Select Blue or Black as the Affirm logo
  7. You can optionally enter a BASK page promo ID (cart page) and a PROD page promo ID (product page) to customize the messaging on those pages (the Affirm Client Success team provides these promo ID’s)
  8. Click Save Settings

Screen Shot 2018-07-31 at 12.58.54 PM.png

Add promotional banners

To add Affirm banner images to various pages on your site:

  1. In the Miva Merchant admin panel, go to Menu > Payment
  2. Click on the Buy with Affirm tab
  3. In the Banner Messaging section, check Show banner on BASK page (cart page), Show banner on PROD pages (product pages), Show banner on SFNT page (home page) to show promotional banners on those pages
  4. For each page where you want a banner displayed, select the desired Banner size
  5. Click Save Settings

Screen Shot 2018-07-31 at 1.01.07 PM.png

4. Review your order management functions

Processing orders (authorize, void, refund, and partial refund) in Miva updates the order status in the Affirm dashboard. While you can process orders in the dashboard, we strongly recommend using Miva to keep order status synced with Affirm. To process orders in Miva, sign in to the Miva Merchant admin page and go to Orders > Payment. You have access to the following order management functions:

  • Capture
  • Void
  • Refund

For more information on processing orders in Miva, refer to their documentation.

5. Test your integration

After completing your integration, do a thorough testing of both your front-end and order management functions in our sandbox to ensure that everything works as expected. Click here for our recommended test plan. However, you’ll need to tailor your testing plan to your specific systems, processes, and integration.

6. Deploy to production

Coordinate testing with Affirm

Before deploying the Affirm integration to your production site, Affirm will need to test it in your development or staging environment connected to our live environment. Contact your Client Success Manager to coordinate this test.

Connect to the live Affirm environment

  1. Retrieve your live API keys at https://affirm.com/dashboard/#/apikeys
  2. Sign in to your Miva Merchant admin page and go to Menu > Payment > Buy with Affirm
  3. Enter the Production Public Key and Production Private Key you just retrieved from the Affirm merchant dashboard
  4. Remove the Sandbox Public Key and Sandbox Private Key values
  5. Set Operation Mode to Production

Launch to production

After you’ve connected to our live environment and we’ve tested your integration, you’re ready to deploy to your production environment and offer Affirm as a payment option to your customers.