Preview Leffel Consulting Payments is in active development and migrating to Finix — the API isn't publicly live yet, and some examples still reflect the outgoing build. Request early access →

Guides

Refunds

Refund a payment in full or in part, with optional proportional refund of the platform fee.

Refund a completed payment by its lcPaymentId.

Full refund

Omit amountCents to refund the entire payment:

curl https://payments.leffelconsulting.com/v1/payments/lcpay_9f2c.../refund \
  -H "X-Api-Key: lc_live_XXXXXXXXXXXXXXXXXXXX" \
  -H "Content-Type: application/json" \
  -d '{ "reason": "requested_by_customer" }'

The payment’s status becomes refunded.

Partial refund

Pass an amountCents smaller than the payment total:

curl https://payments.leffelconsulting.com/v1/payments/lcpay_9f2c.../refund \
  -H "X-Api-Key: lc_live_XXXXXXXXXXXXXXXXXXXX" \
  -H "Content-Type: application/json" \
  -d '{ "amountCents": 2000, "reason": "requested_by_customer" }'

The status becomes partially_refunded. You can issue multiple partial refunds up to the original amount.

Options

FieldDescription
amountCentsAmount to refund. Omit for a full refund.
reasonrequested_by_customer, duplicate, or fraudulent.
refundApplicationFeeWhether to refund the platform fee proportionally. Defaults to true.

Note

By default the platform fee is refunded in proportion to the refunded amount. Set refundApplicationFee to false to keep the fee.

You’ll also receive a charge.refunded callback so your systems can update.