Invoices
Refund a settled invoice, wholly or in part
No API key can call this route. It needs a signed-in dashboard user with the right role; a key answers 403. About scopes
POST
/
api/v1/invoices/{id}/refundsAuthorization
AuthorizationRequiredBearer <token>
An API key: gpy_test_… or gpy_live_… (or an agent key, agk_…).
In: header
Request Body
application/jsonOptionalamount_centsstring
Amount to refund in minor units, as a decimal string. Omit to refund everything still refundable.
Pattern:
"^\\d+$"reasonRequiredstring
Minimum length:
1Maximum length: 500Path Parameters
idRequiredstring
Format:
"uuid"Header Parameters
Idempotency-KeyRequiredstring
Required. A unique value for this operation, chosen by you. A retry with the same key and the same body returns the first response instead of running again. The same key with a different body answers 409 idempotency_key_reused; a key whose first request is still running answers 409 idempotency_in_progress.
Refund submitted, pending settlement.