Skip to main content
POST
/
v1
/
paymentIntents
/
{id}
/
refund
Refund a payment intent
curl --request POST \
  --url https://api-sandbox.circle.com/v1/paymentIntents/{id}/refund \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "idempotencyKey": "ba943ff1-ca16-49b2-ba55-1057e70ca5c7",
  "destination": {
    "address": "0x8381470ED67C3802402dbbFa0058E8871F017A6F",
    "addressTag": "123456789",
    "chain": "ALGO"
  },
  "amount": {
    "currency": "USD"
  },
  "toAmount": {
    "amount": "3.14",
    "currency": "USD"
  }
}'
{
  "data": {
    "id": "3389f4ba-aafd-4eef-aaa2-3292df8f62e6",
    "type": "refund",
    "status": "pending",
    "amount": {
      "currency": "USD"
    },
    "merchantId": "5ffea093-d210-44b4-a7ca-ad33b9498188",
    "merchantWalletId": "1000999922",
    "paymentIntentId": "77c91fe9-e603-4e7b-9672-1ef8ac502cf6",
    "settlementAmount": {
      "amount": "1.00",
      "currency": "ETH"
    },
    "fromAddresses": {
      "chain": "ETH",
      "addresses": [
        "0x0d4344cFF68F72A5B9Abded37CA5862941a62050"
      ]
    },
    "depositAddress": {
      "chain": "ETH",
      "address": "0x97de855690955e0da79ce5c1b6804847e7070c7f"
    },
    "createDate": "2022-07-21T20:16:35.092852Z",
    "updateDate": "2022-07-21T20:19:24.719313Z"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string<uuid>
required

Universally unique identifier (UUID v4) of a resource.

Example:

"b3d9d2d5-4c12-4946-a09d-953e82fae2b0"

Body

application/json
idempotencyKey
string<uuid>
required

Universally unique identifier (UUID v4) idempotency key. This key is utilized to ensure exactly-once execution of mutating requests.

Example:

"ba943ff1-ca16-49b2-ba55-1057e70ca5c7"

destination
object
required

The destination of a crypto refund.

amount
object
required

The source amount of the refund, it can be in either the original payment currency or the settlement currency.

toAmount
object
required

The destination amount of the refund, it must be in the original payment currency.

Response

Crypto refund successfully created for the given payment intent.

data
object

Status information of the related payment.