Payments, refunds and payouts in one API

Send customers to our ready-made payment page, or take card details in your own checkout. Test everything in Sandbox first, with your own keys.

Read the docs

POST/v1/payments/hppSandbox key

curl -X POST https://api.ecomm365.eu/v1/payments/hpp \  -H "Authorization: Bearer $ECOMM_API_KEY" \  -H "Idempotency-Key: order-2345678901-hpp-1" \  -H "Content-Type: application/json" \  -d '{    "amount": 12900,    "currency": "EUR",    "customer_ip_address": "203.0.113.7",    "return_url": "https://shop.example/checkout/complete"  }'

201 CreatedRequest-Id: req_7Hn2Qx9Lw4Bd

{  "id": "pay_q7Mk2Np8Vr4Xt6Yz9Ab3Cd5E",  "status": "REQUIRES_ACTION",  "next_action": { "reason": "hosted_payment_page", … }}
Sandbox Key api_test_sk_•••• Base URL api.ecomm365.eu/v1 Quickstart ↗

Two ways to take a payment

Both start with one request from your site and end with the same payment in your portal.

Hosted Payment Page The quick way. Your site starts the payment and sends the customer to our page. They pay there by card and come back to your site. POST /v1/payments/hpp
Direct API Full control. Take card details in your own checkout and send them to us. When the bank asks for it, the customer confirms the payment with 3-D Secure. POST /v1/payments

Nine endpoints. That's the whole API.

Every request except the health check uses your secret key. The same address serves Sandbox and Live; the key decides which one you're in.

Every field and answer in the API docs
PaymentsTake a payment and check on it POST/v1/paymentsCard details from your checkout POST/v1/payments/hppA payment on our page GET/v1/paymentsYour payments GET/v1/payments/{id}One payment
RefundsGive back all of a payment or part of it POST/v1/refundsFull or partial HealthIs the API up GET/v1/healthAPI availability
PayoutsSend money to a Visa or Mastercard POST/v1/payoutsA card payout GET/v1/payoutsYour payouts GET/v1/payouts/{payout_id}One payout

Safe to send twice

Every request that creates something carries an Idempotency-Key. If the connection drops and you send the same request again, no second payment is made.

  • One key, one paymentUse your order number and attempt number in the key, so a retry is easy to recognise.
  • A Request-Id on every answerInclude it when you contact support, and we find the request.

Webhooks for every change

Add an endpoint in the portal and we tell your server each time a payment, refund or payout changes.

15 events

One for each change of a payment, refund or payout, sent to your server as it happens.

Signed by usEvery delivery carries a signature made with your endpoint's secret, so your server can check it came from us.
Tried again if your server is downA delivery that fails is sent again on a fixed schedule: nine tries in Live, three in Sandbox.

Keys for each purpose

Create up to ten keys in Sandbox and ten in Live, one for each server or shop. A key is shown once, when you create it.

  • Sandbox and Live apartTest keys start with api_test_sk_, live ones with api_live_sk_.
  • Revoked in a minuteRevoking a key needs your password, and the key stops working within a minute.
  • Developers get their own roleThey manage keys and webhooks, and only view payments and balances.

Try every answer before you go live

Once your test account is set up, pay with a test card and choose the amount: a few amounts always give the same result, so you can see how your shop handles a decline or an error.

  • Visa test card4635 4400 0000 2207
  • Mastercard test card5520 3300 0000 2205

Tell us what you sell. We'll show you how ecomm can help.

[email protected]