Odoo 19 app

n1co Payment Gateway

n1co for Odoo 19: card payments through n1co business payment links, with signed webhooks and the order status read back from n1co

What it does

n1co business - CheckoutLink API - Card payments - El Salvador - Sandbox and production - Signed webhooks - USD

n1co business is a payment and online sales platform from El Salvador. This module adds it to Odoo as a payment provider. When the customer pays an order or an invoice, Odoo creates an n1co payment link with the amount (or the order lines) and sends the customer to it. n1co webhooks are checked against their HMAC-SHA256 signature before Odoo reads them, each event is handled once, and Odoo then reads the order from n1co itself, as n1co recommends, and checks the total and the currency before it marks the payment as paid.

Who it is for

  • Online stores in El Salvador. You sell in US dollars through an Odoo webshop and already have an n1co business account. At checkout the customer is sent to an n1co payment link to pay by card, then comes back to the order confirmation.
  • Businesses that invoice and want card payment on the invoice. Customers paying from the invoice portal can choose n1co, and the payment is matched to the invoice once n1co reports it as paid.
  • Shops with several branches on one n1co store. Each provider can send the branch code of the location that should receive the payment. Leave it empty to use the store's default branch.
  • Teams that have been caught by fake payment notices. Webhooks are only accepted with a valid HMAC-SHA256 signature, and Odoo reads the order status back from n1co and checks the amount and currency before it marks anything as paid.

Features

n1co payment linkPOST /paymentlink/checkout with the Odoo reference; card details are typed on the n1co page
Order lines or totalsend the sales order lines to the payment link, or only the amount
Signed webhooksX-H4B-Hmac-Sha256 checked on the raw body with your webhook secret key
Each event onceX-H4B-Event-Id is kept, so a resent event changes nothing
Status read backthe order is read from n1co on return, on webhook, on a button and every five minutes
Amount and currency checkthe order total and the store currency from n1co must match the Odoo payment
Cancelled ordersa cancelled n1co order cancels the Odoo payment
Sandbox and productionTest mode uses the n1co sandbox host, Enabled uses production
Payment detailsorder code, order ID, authorization code and the voucher link on the transaction
Link optionslink lifetime and branch code
API logevery call and webhook, with buyer details masked

Setting it up

  1. In n1co business go to Settings > Developer options > Checkout Link and copy the secret key. Use the sandbox key first.
  2. In Odoo open Accounting > Configuration > Payment Providers, open n1co, set it to Test mode and paste the key into Checkout Link Secret Key.
  3. Copy the Webhook URL shown on the provider form, create the webhook in n1co under Settings > Developer options > Webhook and paste the webhook secret it generates back into Odoo.
  4. Check the currency (USD by default), the link lifetime in minutes and whether order lines are shown on the payment link.
  5. Publish the provider, place a test order with an n1co sandbox card and open the transaction to see the n1co order code and status.
  6. When the test passes, swap in the production keys and set the provider to Enabled.

n1co Payment Gateway: questions

What happens without the webhook secret?

Every webhook is refused. Payments still get confirmed, because a scheduled check every 5 minutes asks n1co for the status of pending payments, but it is slower.

Can I refund from Odoo?

No. The module takes payments through n1co payment links only. Refunds are done in n1co business and then recorded in Odoo by hand.

Which currency can I charge in?

The currency of your n1co store, which is USD in El Salvador. The payment link carries no currency of its own, so the provider only shows up for orders in the currencies listed on it, and the paid amount and currency are checked again when n1co confirms.

Does it store cards for repeat customers?

No. Each payment opens a new n1co link, and no card data passes through Odoo.

Do I need Enterprise or eCommerce?

Neither is required. It depends on payment and account_payment, which come with Community Invoicing, and the website checkout works once eCommerce is installed.

Where can I see what n1co sent?

System administrators find every call and webhook under Accounting > Configuration > Payments > n1co API Log, with the request, response and source IP. Old log lines are deleted after 90 days by default.