Skip to main content

Full crypto payment

Complete scenario setup with a fresh unpaid request and an open quote. This example assumes cryptoQuantity is 25.

1. Confirm a deposit

Send POST /v1/collections/simulate-crypto-deposit with your sandbox headers:

{
"paymentRequestReference": "ORDER-10045",
"quotePaymentId": "49122879-6ca4-40d3-a20d-e011501cd185",
"depositId": "0492f319-60c7-423a-8f9f-61d41901475e",
"cryptoAmount": 25,
"status": "CONFIRMED"
}

Expect depositStatus: CONFIRMED, paymentStatus: RECEIVED and paymentRequestStatus: PAID for a quote covering the full outstanding request balance. Save the returned paymentId. Hubpay queues payment.pending, payment.received and payment_request.paid webhooks.

2. Complete settlement and wallet credit

Follow completion using that paymentId. Expect COMPLETE and a payment.completed event. The request remains PAID.

Retry the deposit with the same identifiers and amount to verify alreadyProcessed: true and no additional received funds. Retry completion to verify alreadyCompleted: true and no second wallet credit.