# Requires: npm i -g @infinite_dev/cli && export INFINITE_API_KEY=sk_sandbox_...
infinite transfers cancel tfr_abc123Request transfer cancellation (tfr_abc123).
# Infinite MCP is read-only for this endpoint — use a dedicated MCP tool when one exists, otherwise run the CLI tab.import requests
url = "https://sandbox.api.infinite.dev/v1/transfers/{id}/cancel"
payload = { "reason": "Customer requested cancellation" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({reason: 'Customer requested cancellation'})
};
fetch('https://sandbox.api.infinite.dev/v1/transfers/{id}/cancel', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox.api.infinite.dev/v1/transfers/{id}/cancel",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'reason' => 'Customer requested cancellation'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sandbox.api.infinite.dev/v1/transfers/{id}/cancel"
payload := strings.NewReader("{\n \"reason\": \"Customer requested cancellation\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://sandbox.api.infinite.dev/v1/transfers/{id}/cancel")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"reason\": \"Customer requested cancellation\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.api.infinite.dev/v1/transfers/{id}/cancel")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"reason\": \"Customer requested cancellation\"\n}"
response = http.request(request)
puts response.read_body{
"id": "tfr_1234567890abcdef",
"organizationId": "org_abc123",
"sourceCustomerId": "cus_abc123",
"flow": "CRYPTO_TO_FIAT",
"status": "COMPLETED",
"source": {
"currency": "usd",
"paymentRail": "ACH",
"fundingCurrency": "usdc",
"direction": "CREDIT",
"accountId": "vba_abc123",
"accountType": "VIRTUAL_BANK",
"externalAccountId": "ext_bank_456",
"fromAddress": "0x1234567890abcdef1234567890abcdef12345678",
"refundAccountId": "inw_abc123",
"accountName": "Acme Corporation",
"originator": {
"name": "Acme Suppliers LLC",
"bankName": "Example National Bank",
"routingNumber": "021000021",
"accountNumber": "987654321",
"swiftBic": "CHASUS33",
"bankCountry": "US"
}
},
"destination": {
"currency": "USDC",
"paymentRail": "ETHEREUM",
"accountId": "vwa_def456",
"accountType": "EXTERNAL_BANK",
"externalAccountId": "ext_bank_789",
"toAddress": "0x1234567890abcdef1234567890abcdef12345678",
"accountName": "Acme Corporation",
"bankName": "JPMorgan Chase Bank",
"bankCountryCode": "US",
"wireMessage": "Payment for invoice INV-2026-001",
"achReference": "ORDER123",
"swiftReference": "Payment for invoice INV-2026-001",
"rtpReference": "Payment for invoice INV-2026-001",
"payoutReference": "INV2026"
},
"sourceAmount": {
"currency": "USD",
"exponent": 2,
"value": "12345",
"displayValue": "123.45"
},
"createdAt": "2026-09-15T10:00:00.000Z",
"updatedAt": "2026-09-15T10:00:00.000Z",
"legs": [
{
"id": "tleg_abc123",
"sequence": 0,
"type": "DEPOSIT_CRYPTO",
"inputCurrency": "USDC",
"outputCurrency": "USD",
"inputRail": "ETHEREUM",
"outputRail": "ACH",
"status": "PENDING",
"startedAt": "2023-11-07T05:31:56Z",
"completedAt": "2023-11-07T05:31:56Z",
"uetr": "9b6f37f2-21f0-4b2b-b03c-1893364782ce",
"imad": "20260309EREBBANK000002",
"omad": "20260309MMQFMP0B012345",
"achTraceNumber": "021000021234567",
"txHash": "0x1234567890abcdef...",
"developerFee": {
"currency": "USD",
"exponent": 2,
"value": "12345",
"displayValue": "123.45"
},
"feeTxHash": "0x1234567890abcdef..."
}
],
"fundingNeeded": false,
"clientReferenceId": "order_abc123",
"counterpartyId": "cp_abc123",
"agentId": "agt_abc123",
"agentApprovalStatus": "PENDING",
"destinationAmount": {
"currency": "USD",
"exponent": 2,
"value": "12345",
"displayValue": "123.45"
},
"refund": {
"status": "COMPLETED",
"reason": "Fees exceed deposit amount",
"amount": {
"currency": "USD",
"exponent": 2,
"value": "12345",
"displayValue": "123.45"
},
"address": "0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb",
"txHash": "0x1234567890abcdef...",
"initiatedAt": "2023-11-07T05:31:56Z",
"completedAt": "2023-11-07T05:31:56Z"
},
"quoteId": "quote_abc123",
"exchangeRate": "0.99985",
"referenceRate": "1.158691536019208779",
"referenceRateAsOf": "2026-09-02T18:30:04.000Z",
"referenceProvider": "XE",
"developerFeeFixed": "100",
"developerFeePercent": 0.005,
"developerFee": {
"amount": {
"currency": "USD",
"exponent": 2,
"value": "12345",
"displayValue": "123.45"
},
"fixed": "100",
"percent": 0.005,
"txHash": "0x1234567890abcdef..."
},
"depositInstructions": {
"type": "crypto",
"paymentRail": "ETHEREUM",
"toAddress": "0x1234567890abcdef1234567890abcdef12345678",
"amount": {
"currency": "USD",
"exponent": 2,
"value": "12345",
"displayValue": "123.45"
},
"blockchainMemo": "<string>",
"accountId": "acc_abc123"
},
"returnedToAccountId": "acc_123",
"returnedAt": "2026-09-15T10:00:00.000Z",
"currentLegIndex": 0,
"isThirdParty": false,
"remarks": "Partial payment - remaining balance to be paid next month",
"internalRemarks": "<string>",
"uetr": "9b6f37f2-21f0-4b2b-b03c-1893364782ce",
"imad": "20260309EREBBANK000002",
"omad": "20260309MMQFMP0B012345",
"achTraceNumber": "021000021234567",
"originatingAccount": {
"bankName": "<string>",
"routingNumber": "044016018",
"accountNumber": "37216498313366"
},
"txHash": "0x1234567890abcdef...",
"systemRemark": "Tracking is unavailable for this SWIFT transfer. We will auto-complete it after 24 hours and mark it with an asterisk because settlement is assumed rather than confirmed.",
"metadata": {
"swiftRouting": {
"source": "GPI_ROUTE",
"senderBic": "CHASUS33",
"receiverBic": "CLRBGB22",
"checkedAt": "2026-05-10T16:34:42.597Z",
"steps": [
{
"label": "Sender bank",
"bic": "CHASUS33",
"bankName": "JP Morgan Chase",
"status": "Confirmed Active"
}
]
}
},
"estimatedSettlementAt": "2026-05-26T13:00:00.000Z",
"nextCutoffAt": "2026-05-19T19:00:00.000Z",
"cutoffTimezone": "America/New_York",
"counterparty": {
"id": "cp_abc123",
"name": "Jane Doe",
"beneficiaryType": "INDIVIDUAL",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"address": {
"addressLine1": "123 Main Street",
"city": "San Francisco",
"postalCode": "94102",
"country": "US",
"addressLine2": "Apt 4B",
"state": "CA",
"transliterated": {
"addressLine1": "123 Main Street",
"addressLine2": "Apt 4B",
"city": "Beijing",
"state": "Hebei"
}
}
}
}Request transfer cancellation
Cancel a transfer. If it has not received funds, it becomes CANCELLED. If the transfer is already in review, crypto has been received, and the payout has not been sent, it becomes CANCELLED (funds stay on the deposit wallet) or REVERSED (crypto is sent to the configured refund address). If funds are in motion and the transfer is not already in review, it moves to IN_REVIEW and is not cancelled yet. A transfer already in review that cannot be returned automatically is rejected and its status does not change. Completed, failed, reversed, or already cancelled transfers cannot be cancelled.
# Requires: npm i -g @infinite_dev/cli && export INFINITE_API_KEY=sk_sandbox_...
infinite transfers cancel tfr_abc123Request transfer cancellation (tfr_abc123).
# Infinite MCP is read-only for this endpoint — use a dedicated MCP tool when one exists, otherwise run the CLI tab.import requests
url = "https://sandbox.api.infinite.dev/v1/transfers/{id}/cancel"
payload = { "reason": "Customer requested cancellation" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({reason: 'Customer requested cancellation'})
};
fetch('https://sandbox.api.infinite.dev/v1/transfers/{id}/cancel', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox.api.infinite.dev/v1/transfers/{id}/cancel",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'reason' => 'Customer requested cancellation'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sandbox.api.infinite.dev/v1/transfers/{id}/cancel"
payload := strings.NewReader("{\n \"reason\": \"Customer requested cancellation\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://sandbox.api.infinite.dev/v1/transfers/{id}/cancel")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"reason\": \"Customer requested cancellation\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.api.infinite.dev/v1/transfers/{id}/cancel")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"reason\": \"Customer requested cancellation\"\n}"
response = http.request(request)
puts response.read_body{
"id": "tfr_1234567890abcdef",
"organizationId": "org_abc123",
"sourceCustomerId": "cus_abc123",
"flow": "CRYPTO_TO_FIAT",
"status": "COMPLETED",
"source": {
"currency": "usd",
"paymentRail": "ACH",
"fundingCurrency": "usdc",
"direction": "CREDIT",
"accountId": "vba_abc123",
"accountType": "VIRTUAL_BANK",
"externalAccountId": "ext_bank_456",
"fromAddress": "0x1234567890abcdef1234567890abcdef12345678",
"refundAccountId": "inw_abc123",
"accountName": "Acme Corporation",
"originator": {
"name": "Acme Suppliers LLC",
"bankName": "Example National Bank",
"routingNumber": "021000021",
"accountNumber": "987654321",
"swiftBic": "CHASUS33",
"bankCountry": "US"
}
},
"destination": {
"currency": "USDC",
"paymentRail": "ETHEREUM",
"accountId": "vwa_def456",
"accountType": "EXTERNAL_BANK",
"externalAccountId": "ext_bank_789",
"toAddress": "0x1234567890abcdef1234567890abcdef12345678",
"accountName": "Acme Corporation",
"bankName": "JPMorgan Chase Bank",
"bankCountryCode": "US",
"wireMessage": "Payment for invoice INV-2026-001",
"achReference": "ORDER123",
"swiftReference": "Payment for invoice INV-2026-001",
"rtpReference": "Payment for invoice INV-2026-001",
"payoutReference": "INV2026"
},
"sourceAmount": {
"currency": "USD",
"exponent": 2,
"value": "12345",
"displayValue": "123.45"
},
"createdAt": "2026-09-15T10:00:00.000Z",
"updatedAt": "2026-09-15T10:00:00.000Z",
"legs": [
{
"id": "tleg_abc123",
"sequence": 0,
"type": "DEPOSIT_CRYPTO",
"inputCurrency": "USDC",
"outputCurrency": "USD",
"inputRail": "ETHEREUM",
"outputRail": "ACH",
"status": "PENDING",
"startedAt": "2023-11-07T05:31:56Z",
"completedAt": "2023-11-07T05:31:56Z",
"uetr": "9b6f37f2-21f0-4b2b-b03c-1893364782ce",
"imad": "20260309EREBBANK000002",
"omad": "20260309MMQFMP0B012345",
"achTraceNumber": "021000021234567",
"txHash": "0x1234567890abcdef...",
"developerFee": {
"currency": "USD",
"exponent": 2,
"value": "12345",
"displayValue": "123.45"
},
"feeTxHash": "0x1234567890abcdef..."
}
],
"fundingNeeded": false,
"clientReferenceId": "order_abc123",
"counterpartyId": "cp_abc123",
"agentId": "agt_abc123",
"agentApprovalStatus": "PENDING",
"destinationAmount": {
"currency": "USD",
"exponent": 2,
"value": "12345",
"displayValue": "123.45"
},
"refund": {
"status": "COMPLETED",
"reason": "Fees exceed deposit amount",
"amount": {
"currency": "USD",
"exponent": 2,
"value": "12345",
"displayValue": "123.45"
},
"address": "0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb",
"txHash": "0x1234567890abcdef...",
"initiatedAt": "2023-11-07T05:31:56Z",
"completedAt": "2023-11-07T05:31:56Z"
},
"quoteId": "quote_abc123",
"exchangeRate": "0.99985",
"referenceRate": "1.158691536019208779",
"referenceRateAsOf": "2026-09-02T18:30:04.000Z",
"referenceProvider": "XE",
"developerFeeFixed": "100",
"developerFeePercent": 0.005,
"developerFee": {
"amount": {
"currency": "USD",
"exponent": 2,
"value": "12345",
"displayValue": "123.45"
},
"fixed": "100",
"percent": 0.005,
"txHash": "0x1234567890abcdef..."
},
"depositInstructions": {
"type": "crypto",
"paymentRail": "ETHEREUM",
"toAddress": "0x1234567890abcdef1234567890abcdef12345678",
"amount": {
"currency": "USD",
"exponent": 2,
"value": "12345",
"displayValue": "123.45"
},
"blockchainMemo": "<string>",
"accountId": "acc_abc123"
},
"returnedToAccountId": "acc_123",
"returnedAt": "2026-09-15T10:00:00.000Z",
"currentLegIndex": 0,
"isThirdParty": false,
"remarks": "Partial payment - remaining balance to be paid next month",
"internalRemarks": "<string>",
"uetr": "9b6f37f2-21f0-4b2b-b03c-1893364782ce",
"imad": "20260309EREBBANK000002",
"omad": "20260309MMQFMP0B012345",
"achTraceNumber": "021000021234567",
"originatingAccount": {
"bankName": "<string>",
"routingNumber": "044016018",
"accountNumber": "37216498313366"
},
"txHash": "0x1234567890abcdef...",
"systemRemark": "Tracking is unavailable for this SWIFT transfer. We will auto-complete it after 24 hours and mark it with an asterisk because settlement is assumed rather than confirmed.",
"metadata": {
"swiftRouting": {
"source": "GPI_ROUTE",
"senderBic": "CHASUS33",
"receiverBic": "CLRBGB22",
"checkedAt": "2026-05-10T16:34:42.597Z",
"steps": [
{
"label": "Sender bank",
"bic": "CHASUS33",
"bankName": "JP Morgan Chase",
"status": "Confirmed Active"
}
]
}
},
"estimatedSettlementAt": "2026-05-26T13:00:00.000Z",
"nextCutoffAt": "2026-05-19T19:00:00.000Z",
"cutoffTimezone": "America/New_York",
"counterparty": {
"id": "cp_abc123",
"name": "Jane Doe",
"beneficiaryType": "INDIVIDUAL",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"address": {
"addressLine1": "123 Main Street",
"city": "San Francisco",
"postalCode": "94102",
"country": "US",
"addressLine2": "Apt 4B",
"state": "CA",
"transliterated": {
"addressLine1": "123 Main Street",
"addressLine2": "Apt 4B",
"city": "Beijing",
"state": "Hebei"
}
}
}
}Authorizations
API Key in Bearer format (e.g., Bearer sk_test_...)
Headers
API key
Path Parameters
Body
Optional reason for cancellation. This will be stored in the transfer metadata.
500"Customer requested cancellation"
Response
Cancellation accepted. The response status is CANCELLED or REVERSED when the transfer is finished, IN_REVIEW when cancellation is not finished yet, or the current non-terminal status while cancellation processing completes.
Transfer ID (tfr_xxx)
"tfr_1234567890abcdef"
Organization ID
"org_abc123"
Source customer ID
"cus_abc123"
Transfer flow type describing the asset conversion
CRYPTO_TO_CRYPTO, CRYPTO_TO_FIAT, FIAT_TO_CRYPTO, FIAT_TO_FIAT, FIAT_TO_CRYPTO_TO_FIAT, FX, INTERNAL, FEE_CRYPTO, REFUND_CRYPTO, REFUND_FIAT "CRYPTO_TO_FIAT"
Transfer status
DRAFT, PENDING_AUTHORIZATION, IN_REVIEW, PENDING, PROCESSING, COMPLETED, FAILED, CANCELLED, REVERSED "COMPLETED"
Source payment details
Show child attributes
Show child attributes
Destination payment details
Show child attributes
Show child attributes
Source amount with currency details
Show child attributes
Show child attributes
Transfer creation date
"2026-09-15T10:00:00.000Z"
Transfer last update date
"2026-09-15T10:00:00.000Z"
Transfer route legs (steps in the transfer)
Show child attributes
Show child attributes
Whether the transfer is waiting for the customer to send funds (deposit)
false
Client's internal reference ID
"order_abc123"
Counterparty ID for third-party recipient transfers
"cp_abc123"
Agent whose key created or submitted this transfer. Null when the transfer was not made by an agent key.
"agt_abc123"
Owner approval for an agent payment that went over its limits. PENDING: the draft waits for POST /v1/transfers/{id}/agent-approval. Null when no approval was needed.
PENDING, APPROVED, DECLINED Destination amount with currency details
Show child attributes
Show child attributes
Refund details when this transfer has been refunded or a refund is in progress
Show child attributes
Show child attributes
Quote ID if transfer was created from a quote
"quote_abc123"
Exchange rate applied to the currency conversion, inclusive of all fees. Expressed on minor-unit amounts: destinationAmount = sourceAmount * exchangeRate. Populated for FX trades.
"0.99985"
Independent reference rate used to price this transfer, expressed as destination major units per source major unit. Present for benchmark-priced FX transfers.
"1.158691536019208779"
Timestamp of the independent reference rate used to price this transfer (ISO 8601).
"2026-09-02T18:30:04.000Z"
Independent market that published referenceRate. Present when referenceRate is present.
XE "XE"
Fixed developer fee in minor units of source currency. Prefer the developerFee object, which also carries the collected amount and payout hash.
"100"
Variable developer fee as decimal percentage (e.g., 0.005 = 0.5%). Prefer the developerFee object, which also carries the collected amount and payout hash.
0.005
Developer fee charged on this transfer: the configured components plus the collected amount and the on-chain payout hash for reconciliation against your fee wallet. Null when the transfer has no developer fee. Per-step collected amounts and fee tx hashes are on legs[].
Show child attributes
Show child attributes
Deposit instructions if customer needs to send funds (onramps). Either crypto or fiat instructions depending on the transfer flow.
- Option 1
- Option 2
Show child attributes
Show child attributes
Account credited when a settled payout is returned. Null unless the return is attributed to one account on this transfer.
"acc_123"
When the payout return was recorded. Account history uses this time for returned credits.
"2026-09-15T10:00:00.000Z"
Index of the current active leg in the legs array (0-indexed). Null if all legs are done.
0
Whether this is a third-party payment (destination account belongs to someone other than the customer)
false
Free-form remarks or notes about the transfer
"Partial payment - remaining balance to be paid next month"
Internal remarks visible only within your organization. Never forwarded to payment rails or counterparties.
SWIFT UETR (Universal End-to-End Transaction Reference)
"9b6f37f2-21f0-4b2b-b03c-1893364782ce"
Wire IMAD (Input Message Accountability Data)
"20260309EREBBANK000002"
Wire OMAD (Output Message Accountability Data)
"20260309MMQFMP0B012345"
ACH trace number from the payment network
"021000021234567"
Sending bank and account used for the fiat payout, when known
Show child attributes
Show child attributes
Blockchain transaction hash
"0x1234567890abcdef..."
System-generated status note with important transfer context for the customer
"Tracking is unavailable for this SWIFT transfer. We will auto-complete it after 24 hours and mark it with an asterisk because settlement is assumed rather than confirmed."
Additional non-contractual transfer metadata for UI display
{
"swiftRouting": {
"source": "GPI_ROUTE",
"senderBic": "CHASUS33",
"receiverBic": "CLRBGB22",
"checkedAt": "2026-05-10T16:34:42.597Z",
"steps": [
{
"label": "Sender bank",
"bic": "CHASUS33",
"bankName": "JP Morgan Chase",
"status": "Confirmed Active"
}
]
}
}
Estimated time the recipient will receive funds. Best-effort projection — fiat rails account for bank cutoff times, weekends, and US Federal Reserve holidays; crypto conversions project from recently observed processing times for the route. Not a guarantee.
"2026-05-26T13:00:00.000Z"
Next time the customer can submit and still settle same business day. Past this time, transfers settle next business day.
"2026-05-19T19:00:00.000Z"
IANA timezone for the cutoff time, e.g. "America/New_York".
"America/New_York"
Expanded counterparty details (only included when expand=counterparty)
Show child attributes
Show child attributes
Was this page helpful?