Create refund
Creates a new refund for a business or updates existing refund. This endpoint is idempotent using the external_id
field as the idempotency key, so subsequent requests with the same external_id
will update or no-op.
Authorizations
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Headers
Content-Type must be set to application/json
Path Parameters
The UUID of the business to create a refund for.
Body
An external identifier for the refund transaction.
The amount of the refund in cents. This value must be positive.
The time the refund was completed.
Refund payments that have been made towards the balance of the refund. For a refund that is owed but not yet paid, this will be an empty list. If null, a refund payment will implicitly be created from the fields below.
Only used in order to create a refund payment if the payments
field is null. The fee associated with the implicit refund payment in cents. This value must be positive.
Only used in order to create a refund payment if the payments
field is null. The method used to refund the payment.
CASH
, CHECK
, CREDIT_CARD
, ACH
, CREDIT_BALANCE
, OTHER
Only used in order to create a refund payment if the payments
field is null. The payment processor used to refund the payment.
Only used in order to create a refund payment if the payments
field is null. List of fees associated with the payment. These are refunded from the payment processor rather than the business.
The targets of the refund. Each can refer to an Invoice, Invoice Line Item, Invoice Payment, or Customer. If null, a refund allocation will be implicitly created from the fields below.
Only used in order to create a refund allocation if the allocations
field is null. The ID of the invoice to refund.
Only used in order to create a refund allocation if the allocations
field is null. The external ID of the invoice to refund.
Only used in order to create a refund allocation if the allocations
field is null. The ID of the invoice line item to refund.
Only used in order to create a refund allocation if the allocations
field is null. The external ID of the invoice line item to refund.
Only used in order to create a refund allocation if the allocations
field is null. The ID of the invoice payment to refund.
Only used in order to create a refund allocation if the allocations
field is null. The external ID of the invoice payment to refund.
Only used in order to create a refund allocation if the allocations
field is null. The ID of the customer to refund.
Only used in order to create a refund allocation if the allocations
field is null. The external ID of the customer to refund.
Response
A refund represents a transaction that returns value to from a business to a customer. A specific payment can be refunded or a general refund can be applied to an invoice.
Unique identifier for the refund.
Unique ID of the refund in your system for linking purposes. Idempotency key.
"31415926535"
Amount refunded to the customer in cents.
Status of the refund.
"PAID"
Time when the refund was completed.
Payments associated with this refund.
A payment represents a transaction that moves value from a customer to a business. A specific payment can be refunded or a general refund can be applied to an invoice.
Allocations associated with this refund.