Skip to content

Logo

NMI

Powering Every Possibility in Payments

Supports in this guide: Payments

Provider website: nmi.com


What you need to do for start processing transactions (brief summary)

  1. Get your credentials (from NMI)
  2. Connect in Dashboard
  3. Send an API request

Prerequisites: get from NMI

Contact your NMI account manager to get your account verified and receive the following credentials.

  • API Key -> Corefy field api_key.
  • Callback Secret Key -> Corefy field callback_secret_key -> used to verify callback notifications from NMI.
  • Save Instant Token -> Corefy field save_instant_token -> enable to save the card as a token (NMI Customer Vault) during a sale, so you can charge it again later without resending card data. You must decide this when connecting - it can't be left unset.
  • API URL (optional) -> Corefy field api_url -> leave as default unless your account manager tells you otherwise.
  • Acquirer BIN (optional) -> Corefy field acquirer_bin.
  • Acquirer Merchant ID (optional) -> Corefy field acquirer_merchant_id.
  • Acquirer Country Code (optional) -> Corefy field acquirer_country_code.
  • Acquirer Country Code Source (optional) -> Corefy field acquirer_country_code_source.

Important

The four Acquirer fields are schema-optional, but required if you enable 3D Secure (the three_ds_enabled option below). If 3D Secure is enabled and Acquirer BIN or Acquirer Merchant ID is missing, every sale that needs 3DS fails outright ("unable to determine 3DS enrolment") instead of falling back to a non-3DS sale. If you don't use 3D Secure, you can leave all four blank.


Payments processing (connect H2H Merchant account, create payment-invoice)

Connect H2H Merchant account in Corefy Dashboard

Step 1 - Open connection form

Open NMI in the provider directory and press Connect at NMI Provider Overview page in the New connection section. Choose H2H Merchant account.

Step 2 - Fill in fields and select settings

  • API Key
  • Callback Secret Key
  • Save Instant Token
  • API URL (optional)
  • Acquirer BIN (optional)
  • Acquirer Merchant ID (optional)
  • Acquirer Country Code (optional)
  • Acquirer Country Code Source (optional)

Choose Currency / Features; check with your Corefy account manager which are enabled for your account.

Success

You have connected NMI H2H Merchant account!


First request to Corefy API (MIN)

What it does: creates a payment-invoice; card data itself is collected and submitted separately by Corefy's checkout/SDK layer, not as part of this request. If 3D Secure is enabled for your account, NMI performs full EMV 3D Secure 2 authentication, which may require a challenge redirect before the sale completes. Non-CVV sales are supported.

Payment - MIN

POST /api/payment-invoices

{
  "data": {
    "type": "payment-invoice",
    "attributes": {
      "reference_id": "8e3dbbb0-17af-4c9a-bedb-93bdac6900a2",
      "service": "payment_card_usd_hpp",
      "currency": "USD",
      "amount": 10
    }
  }
}

Note

This connector currently supports USD only.

Payment - MAX

POST /api/payment-invoices

{
  "data": {
    "type": "payment-invoice",
    "attributes": {
      "reference_id": "6795502c-e27d-4d07-85e0-93245aab9a3f",
      "service": "payment_card_usd_hpp",
      "currency": "USD",
      "amount": 10,
      "customer": {
        "reference_id": "cus_123",
        "name": "John Smith",
        "email": "johnsmith@gmail.com",
        "phone": "+15551234567",
        "address": {
          "country": "US",
          "city": "New York",
          "full_address": "1 Main street",
          "post_code": "10001"
        }
      }
    }
  }
}

customer is entirely optional - everything is only used to enrich the sale.


Extended request (MAX)

Why add extra fields (typical reasons): - Provide additional customer details for compliance/reconciliation - Positively influence conversion rate - Include optional fields required by your specific flow


Options

Configured separately for card payments, Apple Pay, and Google Pay - confirm with your account manager whether Apple Pay/Google Pay are enabled for your account.

  • three_ds_enabled -> optional, boolean - enables 3D Secure authentication for sales; requires Acquirer BIN and Acquirer Merchant ID to be set (see the important note above).
  • send_descriptor -> optional, boolean - sends a custom transaction descriptor to NMI, either from your request or from the DESCRIPTOR constant if you don't send one.
  • address_source -> optional, enum (street_field / full_address_field, default full_address_field) - chooses whether the address sent to NMI comes from customer.address.street or the combined customer.address.full_address.
  • send_shipping_address -> optional, boolean - includes a shipping address with the sale, if available.
  • retry_sale_on_customer_duplicate -> optional, boolean - only relevant when Save Instant Token is enabled: if NMI rejects a sale with a "Duplicate Customer Vault Id" error, automatically retries it as an update instead of a new Customer Vault record.
  • retry_auth_on_customer_duplicate -> optional, boolean - same as above, but for Auth transactions.

Constants (fallback fields)

Constants are static values that Corefy can send to the provider instead of dynamic data from your API request, when those fields are missing in the request. Configured separately for card payments, Apple Pay, and Google Pay.

Currently available constants (constant -> Corefy API field)

  • DESCRIPTOR -> used as the transaction descriptor sent to NMI when send_descriptor is enabled and your request doesn't include one

Refunds

NMI supports partial refunds, but only one refund per payment (no multiple partial refunds against the same payment).


Authorize / Capture / Void and Recurring

This connector also supports the standard Corefy Authorize->Capture/Void flow (hold funds first, then capture or release them separately), and charging a previously saved token (via Save Instant Token / NMI's Customer Vault) without resubmitting card data - ask your account manager if you need either set up for your integration.


Additional info

  1. Callback routing is automatic - Corefy generates the callback/return URLs per transaction, nothing to configure in NMI's own back-office.
  2. No payouts - this connector does not support payouts through Corefy.

FAQ / Troubleshooting

  • Sale fails with "unable to determine 3DS enrolment" -> if you have three_ds_enabled turned on, make sure Acquirer BIN and Acquirer Merchant ID are set on your connection - both are required for 3D Secure to work
  • Sale fails with a "Duplicate Customer Vault Id" error -> enable retry_sale_on_customer_duplicate (or retry_auth_on_customer_duplicate for Auth) if you use Save Instant Token
  • Invalid credentials / auth error -> verify API Key/Callback Secret Key for the selected environment
  • Refund fails on a second attempt -> only one refund is allowed per payment
  • Currency or service is not supported -> confirm allowed currencies/features in your NMI account and in Corefy

Question

Still looking for help connecting your NMI account? Please contact our support team!