Braintree connection
The extension needs four values from your Braintree account, plus the currency of the merchant account. This chapter shows where to find them and how to enter them.
Sandbox and production
Braintree has two independent environments, each with its own login and credentials:
- Sandbox, for testing, at
https://sandbox.braintreegateway.com. No real money moves. - Production, for real payments, at
https://www.braintreegateway.com.
The extension stores one set of credentials for each. Mode in the Settings tab decides which set is used at checkout: Test uses the sandbox values, Live uses the production values.
The four values
| Value | What it is |
|---|---|
| Merchant ID | Identifies your Braintree gateway account |
| Public API key | The public half of your API key pair |
| Private API key | The secret half of the same key pair. Treat it like a password |
| Merchant account ID | Identifies the processing account that receives the money. Each merchant account settles in one currency |
All four must come from the same Braintree account and the same environment.
Find them in the Braintree Control Panel
- Sign in to the Control Panel of the environment you are configuring.
- Open the settings menu (the gear icon) and choose API.
- In the API keys section, note the Merchant ID and the Public Key. Reveal the Private Key and copy it. If there is no key yet, generate one.
- Open the settings menu again and choose Business. The merchant accounts list shows each merchant account ID with its currency. Note the ID of the account you want to use and its currency.
- Check with Braintree that this merchant account can process cards and, if you keep the 3D Secure requirement, that 3D Secure is enabled on it. If these options are not available in your account, ask Braintree support.
Repeat the steps in the production Control Panel when you go live.
Enter them in the extension
Open the Braintree connection tab. The fields appear in this order.
| Setting | What to enter |
|---|---|
| Test · Merchant ID | Sandbox merchant ID |
| Test · Merchant account ID | Sandbox merchant account ID |
| Test · Public API key | Sandbox public key |
| Test · Private API key | Sandbox private key |
| Live · Merchant ID | Production merchant ID |
| Live · Merchant account ID | Production merchant account ID |
| Live · Public API key | Production public key |
| Live · Private API key | Production private key |
| Sandbox merchant-account currency | Currency of the sandbox merchant account: USD, GBP, JPY or EUR. Default: EUR |
| Live merchant-account currency | Currency of the production merchant account: USD, GBP, JPY or EUR. Default: EUR |
Click Save settings when you finish.
How the credential fields behave
- All eight fields are masked. A saved value is never shown again.
- An empty field shows Not configured. A field with a saved value shows Configured; leave blank to keep.
- Leave a field blank to keep its saved value. Type a new value only when you want to replace it.
- Never type a card number or a security code in these fields.
What is checked when you save
- Each value may contain only letters, digits, hyphens and underscores, up to 256 characters.
- When Payment method is Enabled, the set for the selected Mode must be complete: merchant ID, public key and private key of at least 8 characters, a merchant account ID of up to 128 characters, and a supported currency.
- If anything fails, nothing is saved and you see "Check the settings, key modes and paid order status before saving."
Saving does not contact Braintree. The values are verified against Braintree when a customer opens the payment page: the merchant ID must match the keys, the merchant account must exist and be active, and its currency must be the one you selected. If any of these is wrong, the payment page does not open. Always place a test order after changing credentials.
Currencies
This version processes USD, EUR, GBP and JPY. Amounts are sent with two decimals, except JPY, which has none.
The currency you select must be the real currency of the merchant account. The method is offered only when the customer is buying in that currency. To accept a second currency, use a merchant account in that currency on another store of your installation, since each store has its own credentials.
Still need help?
Open a support ticket from your account and our team will look at your store with you.