RefundRequest contract on-chain.
About the
nonce parameter: Every refund method requires a nonce: bigint parameter. This is the record index from the PaymentIndexRecorder and identifies which charge within a payment you are requesting a refund for. For the first (and most common) charge, use 0n.requestRefund
Submit a refund request for a payment that is in escrow. The request goes on-chain and is visible to the merchant and any assigned arbiter.cancelRefundRequest
Cancel a pending refund request that you submitted. Only the original requester (payer) can cancel, and only while the request status isPending.
Query Refund State
These methods read on-chain state for refund requests. None require a wallet client.Check existence and status
Get full refund request data
List your refund requests
Refund Request Lifecycle
Method Reference
| Method | Parameters | Returns |
|---|---|---|
requestRefund | paymentInfo, amount, nonce | { txHash } |
cancelRefundRequest | paymentInfo, nonce | { txHash } |
hasRefundRequest | paymentInfo, nonce | boolean |
getRefundStatus | paymentInfo, nonce | RequestStatus |
getRefundRequest | paymentInfo, nonce | RefundRequestData |
getRefundRequestByKey | compositeKey | RefundRequestData |
getMyRefundRequests | offset, count | { keys, total } |
getMyRefundRequestCount | none | bigint |
Next Steps
Escrow Management
Freeze payments and check escrow period timing.
Event Subscriptions
Watch for refund status updates in real-time.
Payment Queries
Query payment state and details.
Client Quickstart
Full setup guide for the Client SDK.
