Overview
Cartevo webhooks notify your system in near real‑time about account events (card creation, funding, withdrawals, errors, etc.).- Method: POST
- Format: JSON
- Headers:
Content-Type: application/json - Expected response: any HTTP 2xx is treated as success (response body is ignored)
Webhook Headers
Retry policy
If delivery fails (non‑2xx response or network error), Cartevo automatically retries up to 3 attempts, with 5 seconds between attempts.| Attempt | Delay | Total Time |
|---|---|---|
| 1 | 0s | 0s |
| 2 | 5s | 5s |
| 3 | 5s | 10s |
| 4 | 5s | 15s |
- Max retries: 3
- Timeout: 10 seconds per attempt
- Logging: every attempt is logged; after 3 failures, delivery is marked permanently failed.
transaction_id, card.id, wallet_id).
Setting Up Webhooks
Configure Your Webhook URL
Set your webhook URL in your company settings:Supported Events
Payment Events
payment.collect
Emitted when a payment collection (pay‑in) is initiated.Card Events
card.created
Emitted when a new card is successfully created for a customer. Payload:| Field | Type | Description |
|---|---|---|
id | string | Unique card identifier |
customer_id | string | Customer who owns the card |
brand | string | Card brand (VISA, MASTERCARD) |
masked_number | string | Masked card number for display |
balance | number | Initial card balance |
currency | string | Card currency (always USD) |
card.fund
Emitted when a card is funded with money from a wallet. Payload:| Field | Type | Description |
|---|---|---|
transaction_id | string | Transaction reference |
card_id | string | Card being funded |
amount | number | Amount added to card |
currency | string | Transaction currency |
fee_amount | number | Fee charged for funding (usually 0) |
card.withdraw
Emitted when money is withdrawn from a card back to the wallet. Payload:| Field | Type | Description |
|---|---|---|
transaction_id | string | Transaction reference |
card_id | string | Card being withdrawn from |
amount | number | Amount withdrawn |
currency | string | Transaction currency |
fee_amount | number | Fee charged for withdrawal (usually 0) |
card.withdraw.failed
Emitted when a card withdrawal attempt fails. Payload:| Field | Type | Description |
|---|---|---|
transaction_id | string | Failed transaction reference |
card_id | string | Card attempted to withdraw from |
amount | number | Amount that failed to withdraw |
error | string | Error message describing failure reason |
card.terminated
Emitted when a card is permanently terminated and any remaining balance is refunded to the company’s USD wallet. Payload:| Field | Type | Description |
|---|---|---|
cardId | string | Unique identifier of the terminated card (UUID) |
cardNumber | string | Masked card number showing only the last 4 digits (e.g., ****1234) |
status | string | Always "TERMINATED" for this event |
terminatedAt | string | ISO 8601 timestamp when the card was terminated |
refundAmount | number | Amount refunded to the company’s USD wallet (0 if card had no balance) |
refundProcessed | boolean | Indicates whether the refund was successfully processed (true or false) |
reason | string | Reason for termination (typically "Card terminated") |
- When a card is terminated, any remaining balance is automatically refunded to the company’s USD wallet
- The card balance is set to zero and the card becomes unusable
- This action is irreversible - once terminated, a card cannot be reactivated
- Webhook failures do not prevent card termination from completing
Transaction Events
transaction.settlement.completed
Emitted when a transaction is settled/cleared.transaction.authorization.created
Emitted when a card payment authorization succeeds. Payload:| Field | Type | Description |
|---|---|---|
transactionId | string | Transaction identifier |
cardId | string | Card used for transaction |
amount | number | Transaction amount |
currency | string | Transaction currency |
type | string | Transaction type (AUTHORIZATION) |
status | string | Transaction status (SUCCESS) |
createdAt | string | ISO 8601 timestamp |
merchant | object | Merchant information (name, country, city) |
mcc | string | Merchant Category Code (optional) |
mid | string | Merchant ID (optional) |
approvalCode | string | Authorization approval code (optional) |
cardBalanceBefore | number | Card balance before (optional) |
cardBalanceAfter | number | Card balance after (optional) |
transaction.authorization.declined
Emitted when a payment authorization is declined. Payload:| Field | Type | Description |
|---|---|---|
transactionId | string | Transaction identifier |
cardId | string | Card used for transaction |
customerId | string | Customer identifier |
amount | number | Transaction amount |
currency | string | Transaction currency |
type | string | Transaction type (AUTHORIZATION) |
status | string | Transaction status (FAILED) |
createdAt | string | ISO 8601 timestamp |
merchant | object | Merchant information |
declineReason | string | Reason for decline |
transaction.reversal.completed
Emitted when a transaction is reversed (usually within 24 hours). Payload:| Field | Type | Description |
|---|---|---|
transactionId | string | Transaction identifier |
cardId | string | Card used for transaction |
amount | number | Reversed amount |
currency | string | Transaction currency |
type | string | Transaction type (REVERSAL) |
status | string | Transaction status (SUCCESS) |
merchant | object | Merchant information |
reversalReason | string | Reason for reversal |
createdAt | string | ISO 8601 timestamp |
transaction.refund.completed
Emitted when a refund is processed (usually after settlement). Payload:| Field | Type | Description |
|---|---|---|
transactionId | string | Transaction identifier |
cardId | string | Card used for transaction |
amount | number | Refunded amount |
currency | string | Transaction currency |
type | string | Transaction type (REFUND) |
status | string | Transaction status (SUCCESS) |
merchant | object | Merchant information |
refundReason | string | Reason for refund |
createdAt | string | ISO 8601 timestamp |
transaction.funding.completed
Emitted when a card funding transaction completes.transaction.withdrawal.completed
Emitted when a withdrawal from card completes.transaction.crossborder.charged
Emitted when a cross‑border charge related to a purchase is recorded.transaction.terminated
Emitted when a termination‑type transaction is recorded for a card.Fee Events
fee.payment_failure.charged
Emitted when a fee is charged for a failed payment transaction. Payload:fee.crossborder.charged
Emitted when a cross-border transaction fee is charged. Payload:Debts Events
debt.recovery.pending
Recently Added: This webhook notifies companies in real-time when a payment fee debt has been created due to the incapacity to collect fee from the card. Triggered In 2 Scenarios:- Payment Failure Fee - When a card payment fails and the company wallet cannot cover the failure fee
- Cross-Border Fee - When a cross-border transaction occurs and the company wallet cannot cover the fee
Purpose:
- Immediately notify companies when debts are created
- Maintain transparency in the debt recovery proce
type is crossborder.
Cross-Border Fee Calculation:
- Card Balance – Fees are first deducted from the available balance on the card.
- Debt Creation – If the card balance is insufficient, the system automatically records the remaining amount as a debt to be settled.
Customer Events
customer.created
Emitted when a new customer is created in the system. Payload:| Field | Type | Description |
|---|---|---|
id | string | Unique customer identifier |
firstName | string | Customer’s first name |
lastName | string | Customer’s last name |
email | string | Customer’s email address |
phone_number | string | Customer’s phone number |
country | string | Customer’s country |
createdAt | string | ISO 8601 timestamp |
Best Practices
Response Handling
Always return200 OK within 10 seconds, before processing:
Idempotency
Webhooks may be delivered more than once. Always check for duplicates usingtransaction_id, card.id, or wallet_id:
Security
- Use HTTPS only - HTTP endpoints are not supported
- Verify webhook signatures (when configured) using the
X-Webhook-Signatureheader - Validate request format - Ensure payload matches expected structure
- Implement rate limiting - Protect your endpoint from abuse
- IP whitelisting - Whitelist Cartevo IP addresses (when available)
Error Handling
Handle errors gracefully without exposing internal details:Logging
Record important fields for supportability:Sample Receiver Response
Troubleshooting
| Issue | Solution |
|---|---|
| Receiving nothing | Verify the configured webhook URL and public reachability |
| 4xx errors | Your receiver rejected the request (auth/validation). Adjust your endpoint to accept the format above |
| 5xx errors | Your receiver errored; Cartevo will retry up to 3 times |
| Timeout errors | Respond within 10 seconds. Process webhooks asynchronously |
| Duplicate webhooks | Implement idempotency checks using transaction IDs |
Complete Event Reference
Card Events (5 events)
card.created- Card successfully createdcard.fund- Card funded with moneycard.withdraw- Money withdrawn from cardcard.withdraw.failed- Withdrawal failedcard.terminated- Card permanently terminated
Transaction Events (4 events)
transaction.authorization.created- Payment authorizedtransaction.authorization.declined- Payment declinedtransaction.reversal.completed- Transaction reversedtransaction.refund.completed- Refund processed
Fee Events (2 events)
fee.payment_failure.charged- Failure payment fee charged ($0.50)fee.crossborder.charged- Cross-border fee charged (2.5% + $0.50)
Customer Events (1 event)
customer.created- Customer created