NMI
On this page
This topic explains how to configure NMI as a third party payment provider in StoreConnect, for card payments at standard checkout.
To take direct debit payments from a US bank account, set up the separate NMI ACH provider instead. See NMI ACH.
What you need
- An NMI account set up with an embedded payment component
- Minimal code and admin know-how
Get credentials from NMI
NMI provides credentials that you can use in the API key and API secret fields in the StoreConnect config. They also provide unique keys for testing the integration in a sandbox.
NMI sandbox credentials
- Sign into your NMI account.
- Go to My Sandbox Keys.
- Copy the following keys:
- Private Security Key for api (Payment and Query APIs)
- Partner key (for gateway).
NMI production credentials
When you set up the embedded payment component in NMI, you will be provided with credentials for use in production.
Configure NMI in StoreConnect
- Open StoreConnect and go to Settings > Payments > Payment providers.
- Select New. Complete the fields as follows, then Save:
| StoreConnect field | Select or enter |
|---|---|
| Name | NMI or NMI - test (for sandbox) |
| Provider | Select NMI from the list |
| API Mode | sandbox or production |
| API Key | Your NMI Tokenization key |
| API Secret | Your Private Security Key (Payment and Query APIs). For example, mK9vXpL2nQwR7jHsY4cTbF6uAeZ3dGiN |
| API Options | Leave blank unless you use a reseller gateway or 3D Secure 2. See the two sections below |
The API Key field must contain your NMI Tokenization key. StoreConnect passes it to NMI’s Collect.js library, which renders the card fields at checkout. If it is empty, those fields do not appear and customers cannot pay.
The API Secret field takes the Private Security key, which StoreConnect uses server side and never exposes to the browser. The two keys are not interchangeable.
Configure a custom gateway endpoint
NMI reseller gateways, for example Pinnacle Bank, host merchant accounts on their own API endpoints rather than NMI’s default infrastructure. To connect to a reseller gateway, add a gateway_host option to the API Options field on the Payment Provider record.
Add the following line to API Options, on its own line if the field already holds another option:
```yaml
gateway_host:
For example:
```yaml
gateway_host: secure.pinnaclebankpayments.com ```
The gateway_host value is the fully-qualified domain name of the reseller’s gateway. StoreConnect uses this host for all API calls and for loading the Collect.js tokenization script. When gateway_host is not set, StoreConnect falls back to NMI’s default endpoints (sandbox.nmi.com in sandbox mode, secure.nmi.com in production).
:::note Contact your NMI reseller for the correct gateway hostname. This value is specific to each reseller’s infrastructure and cannot be found in the standard NMI documentation. :::
Enable 3D Secure 2
NMI card payments support 3D Secure 2 (3DS2) authentication as an opt-in feature. When enabled, the checkout presents an in-page challenge after card tokenization. Successfully completing the challenge shifts liability for eligible transactions to the card issuer. Authentication data is also forwarded on saved-card renewals and subscription billing.
To use this feature, you need the NMI Payer Authentication add-on to be enabled within your NMI account. Once enabled, add the following to the API Options field on the Payment Provider record in StoreConnect, on its own line if the field already holds another option:
```yaml
three_d_secure: true ```
No additional contract ID is required.
Was this article helpful?
Thanks for your feedback! It helps us improve our docs.