Concepts

Core concepts behind Credo's payment system - transactions, references, fees, and settlements.

Before diving deeper into the API, it helps to understand how Credo's payment system works at a high level.

Transaction lifecycle

Every payment goes through a series of states from initialization to settlement:

Transaction statuses

CodeStatusDescription
0SuccessfulPayment completed successfully
1RefundedTransaction has been refunded
2RefundQueued for refund
3FailedPayment failed
4SettleQueued for settlement
5SettledFunds have been paid out
6ReviewFlagged for manual review
7DeclinedFailed fraud check
9CancelledCancelled by customer
10CancelledCancelled by merchant
12AttemptedAccount generated, awaiting credit
13AttemptedCustomer attempted payment
14InitializedPayment page loaded
15InitializingPayment URL generated

Statuses 14 and 15 represent pre-payment states. These records may not appear in your transaction history.

References

Credo uses three identifiers to track every transaction:

Always store both the transRef and your businessReference together. This makes reconciliation and support much easier.

Amounts

All monetary values in the API are expressed in the lowest currency unit - kobo for NGN, cents for USD.

You want to chargeYou send
NGN 150.0015000
NGN 1,000.00100000
USD 25.002500
// Converting Naira to kobo
const amountInKobo = nairaAmount * 100;

Fee bearer

The bearer field controls who pays the transaction processing fee:

ValueWho paysWhat happens
0CustomerFee is added on top of the amount. Customer pays more.
1MerchantFee is deducted from the amount. You receive less.

Example - charging NGN 150.00 with a NGN 3.25 fee:

  • Customer is charged: NGN 153.25
  • You receive: NGN 150.00
  • Customer is charged: NGN 150.00
  • You receive: NGN 146.75

Payment channels

Control which payment methods are shown to the customer using the channel array:

ChannelDescription
CARDCredit and debit cards (Visa, Mastercard, Verve)
BANKDirect bank transfers
{
  "channels": ["BANK", "BANK"]
}

If you omit the channel field, all available methods are presented to the customer.

Settlement

Settlement is the process of transferring funds from Credo to your bank account after a successful transaction.

How it works

Settlement Amount = Transaction Amount - Fee (if merchant bears fee)

Paused settlement

You can hold funds in escrow by setting pauseSettlement to 1:

{
  "pauseSettlement": 1,
  "pauseSettlementDate": "2026-03-15"
}

Funds are held until the specified date. Useful for escrow services, milestone-based delivery, or dispute resolution.

Split settlement

Automatically distribute transaction proceeds to multiple accounts. You can configure splits from the dashboard (using a serviceCode) or dynamically at transaction time (using splitConfiguration). See the Settlement System guide for details.

API keys

Credo uses two types of API keys:

KeyPrefixUsage
Public key0PUBInitializing payments. Safe for client-side use.
Secret key-Verifying transactions and sensitive operations. Server-side only.

Keep your secret key safe

Never expose your secret key in frontend code, mobile apps, or version control. Use environment variables and keep it on your server.

Webhooks

Webhooks are HTTP POST notifications sent to your server when events occur. They're the most reliable way to confirm transaction outcomes — callbacks can be missed if a customer closes their browser.

Credo sends webhooks for 4 event types:

EventWhen it fires
transaction.successfulPayment processed successfully
transaction.failedPayment declined (bad card, insufficient funds, etc.)
transaction.transaction.transfer.reverseBank transfer underpaid/overpaid — amount reversed to customer
transaction.settlement.successMerchant settlement has been paid out

Key points:

  • Verify the credo-signature header (HMAC-SHA512) before processing
  • Respond with HTTP 200 immediately
  • Credo retries up to 5 times if your endpoint doesn't respond

Learn more in the Webhooks guide.

Next steps

Was this page helpful?

Last updated on

On this page