curl --request PATCH \
--url https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id} \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"type": "swap",
"destination": {
"address": "0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22",
"asset": "USDC",
"blockchain": "optimism"
},
"isActive": true,
"name": "Swap from USDT to OP USDC",
"order": "FASTEST",
"slippageTolerance": "5",
"source": {
"assets": [
"USDT"
],
"blockchain": "base",
"maxAmount": "1000",
"minAmount": "1"
}
}
'import requests
url = "https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id}"
payload = {
"type": "swap",
"destination": {
"address": "0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22",
"asset": "USDC",
"blockchain": "optimism"
},
"isActive": True,
"name": "Swap from USDT to OP USDC",
"order": "FASTEST",
"slippageTolerance": "5",
"source": {
"assets": ["USDT"],
"blockchain": "base",
"maxAmount": "1000",
"minAmount": "1"
}
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
type: 'swap',
destination: {
address: '0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22',
asset: 'USDC',
blockchain: 'optimism'
},
isActive: true,
name: 'Swap from USDT to OP USDC',
order: 'FASTEST',
slippageTolerance: '5',
source: {assets: ['USDT'], blockchain: 'base', maxAmount: '1000', minAmount: '1'}
})
};
fetch('https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id}', 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://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'type' => 'swap',
'destination' => [
'address' => '0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22',
'asset' => 'USDC',
'blockchain' => 'optimism'
],
'isActive' => true,
'name' => 'Swap from USDT to OP USDC',
'order' => 'FASTEST',
'slippageTolerance' => '5',
'source' => [
'assets' => [
'USDT'
],
'blockchain' => 'base',
'maxAmount' => '1000',
'minAmount' => '1'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$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://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id}"
payload := strings.NewReader("{\n \"type\": \"swap\",\n \"destination\": {\n \"address\": \"0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22\",\n \"asset\": \"USDC\",\n \"blockchain\": \"optimism\"\n },\n \"isActive\": true,\n \"name\": \"Swap from USDT to OP USDC\",\n \"order\": \"FASTEST\",\n \"slippageTolerance\": \"5\",\n \"source\": {\n \"assets\": [\n \"USDT\"\n ],\n \"blockchain\": \"base\",\n \"maxAmount\": \"1000\",\n \"minAmount\": \"1\"\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("x-api-key", "<api-key>")
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.patch("https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id}")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"type\": \"swap\",\n \"destination\": {\n \"address\": \"0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22\",\n \"asset\": \"USDC\",\n \"blockchain\": \"optimism\"\n },\n \"isActive\": true,\n \"name\": \"Swap from USDT to OP USDC\",\n \"order\": \"FASTEST\",\n \"slippageTolerance\": \"5\",\n \"source\": {\n \"assets\": [\n \"USDT\"\n ],\n \"blockchain\": \"base\",\n \"maxAmount\": \"1000\",\n \"minAmount\": \"1\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"type\": \"swap\",\n \"destination\": {\n \"address\": \"0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22\",\n \"asset\": \"USDC\",\n \"blockchain\": \"optimism\"\n },\n \"isActive\": true,\n \"name\": \"Swap from USDT to OP USDC\",\n \"order\": \"FASTEST\",\n \"slippageTolerance\": \"5\",\n \"source\": {\n \"assets\": [\n \"USDT\"\n ],\n \"blockchain\": \"base\",\n \"maxAmount\": \"1000\",\n \"minAmount\": \"1\"\n }\n}"
response = http.request(request)
puts response.read_body{
"data": {
"type": "swap",
"createdAt": "2025-08-26T17:28:38.273Z",
"destination": {
"address": "0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22",
"asset": "USDC",
"blockchain": "optimism"
},
"id": "48c52f4a-c0bf-45c9-a322-1fef00f00431",
"isActive": true,
"name": "Swap from USDT to OP USDC",
"order": "FASTEST",
"slippageTolerance": "5",
"source": {
"assets": [
"USDT"
],
"blockchain": "base",
"maxAmount": "1000",
"minAmount": "1"
},
"updatedAt": "2025-08-26T17:32:08.108Z"
},
"message": "Auto settlement rule updated successfully",
"statusCode": 200
}Child Address Update Rule
This endpoint allows you to update an existing auto-settlement rule for a specific address. By providing the necessary parameters in the request body, you can modify the conditions and actions for the auto-settlement process.
Send the complete rule, not just the fields you are changing. Unlike the master-wallet update, this endpoint validates the body as a whole rule: source and destination are mandatory, and any optional field you leave out is reset to its default rather than kept — order becomes RECOMMENDED, slippageTolerance and deductionPercentage become "0", useTransactionAmount becomes false, isActive becomes true, source.minAmount becomes "0", and source.maxAmount becomes "-1". Read the rule first, change the fields you need, and send the whole object back.
inheritance is ignored here — it only applies to master-wallet rules.
Request Body Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| type | string | No | The settlement rule type: withdraw, swap, gateway, or earn. Sending it on an update migrates a legacy rule onto the explicit type system and applies the type validations; omit it to keep the rule’s current behavior. |
| name | string | No | The name of the auto-settlement rule. A descriptive title reflecting its purpose. |
| isActive | boolean | No | Indicates whether the rule is currently active. true = enabled, false = disabled. Resets to true when omitted. |
| order | string | No | Routing preference for the swap leg. Possible values: FASTEST, CHEAPEST, RECOMMENDED, NO_SLIPPAGE. Resets to RECOMMENDED when omitted. |
| slippageTolerance | string | No | The acceptable slippage tolerance (as a percentage). Example: "5" = 5% tolerance; "-1" for unlimited. Resets to "0" when omitted. |
| isGateway | boolean | No | Route the settlement through Circle’s Gateway. Must be true when the rule’s type is gateway. |
| isReward | boolean | No | Settle into an Earn position. Must be true when the rule’s type is earn. Mainnet only, and cannot be combined with isGateway. |
| rewardProvider | string | Conditional | Required whenever isReward is true. One of aave or compound. |
| rewardType | string | No | Strategy class (defi). Optional — defaults from the resolved product. |
| useTransactionAmount | boolean | No | false settles the address’s current balance of the source asset; true settles only the triggering deposit amount. Resets to false when omitted. |
| deductionPercentage | string | No | Percentage withheld from the settled amount before execution, e.g. "2.5". Resets to "0" when omitted. |
| source | object | Yes | Details about the source of the settlement. |
| ├─ assets | array of strings | Yes | List of asset symbols this rule settles (e.g., ["USDT"]). |
| ├─ minAmount | string | No | The minimum amount required for settlement (e.g., "1"). Resets to "0" when omitted. |
| ├─ maxAmount | string | No | The maximum amount that can be settled (e.g., "1000"). Resets to "-1" when omitted. |
| ├─ blockchain | string | No | The blockchain network used for the settlement. |
| destination | object | Yes | Details about the destination of the settlement. |
| ├─ asset | string | Yes | The asset the settlement is directed to. |
| ├─ address | string | Conditional | The address the settlement is sent to. Required once the rule’s type is withdraw. |
| ├─ blockchain | string | Yes | The blockchain network for the destination. Must equal the source blockchain once the rule’s type is withdraw. |
curl --request PATCH \
--url https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id} \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"type": "swap",
"destination": {
"address": "0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22",
"asset": "USDC",
"blockchain": "optimism"
},
"isActive": true,
"name": "Swap from USDT to OP USDC",
"order": "FASTEST",
"slippageTolerance": "5",
"source": {
"assets": [
"USDT"
],
"blockchain": "base",
"maxAmount": "1000",
"minAmount": "1"
}
}
'import requests
url = "https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id}"
payload = {
"type": "swap",
"destination": {
"address": "0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22",
"asset": "USDC",
"blockchain": "optimism"
},
"isActive": True,
"name": "Swap from USDT to OP USDC",
"order": "FASTEST",
"slippageTolerance": "5",
"source": {
"assets": ["USDT"],
"blockchain": "base",
"maxAmount": "1000",
"minAmount": "1"
}
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
type: 'swap',
destination: {
address: '0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22',
asset: 'USDC',
blockchain: 'optimism'
},
isActive: true,
name: 'Swap from USDT to OP USDC',
order: 'FASTEST',
slippageTolerance: '5',
source: {assets: ['USDT'], blockchain: 'base', maxAmount: '1000', minAmount: '1'}
})
};
fetch('https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id}', 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://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'type' => 'swap',
'destination' => [
'address' => '0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22',
'asset' => 'USDC',
'blockchain' => 'optimism'
],
'isActive' => true,
'name' => 'Swap from USDT to OP USDC',
'order' => 'FASTEST',
'slippageTolerance' => '5',
'source' => [
'assets' => [
'USDT'
],
'blockchain' => 'base',
'maxAmount' => '1000',
'minAmount' => '1'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$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://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id}"
payload := strings.NewReader("{\n \"type\": \"swap\",\n \"destination\": {\n \"address\": \"0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22\",\n \"asset\": \"USDC\",\n \"blockchain\": \"optimism\"\n },\n \"isActive\": true,\n \"name\": \"Swap from USDT to OP USDC\",\n \"order\": \"FASTEST\",\n \"slippageTolerance\": \"5\",\n \"source\": {\n \"assets\": [\n \"USDT\"\n ],\n \"blockchain\": \"base\",\n \"maxAmount\": \"1000\",\n \"minAmount\": \"1\"\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("x-api-key", "<api-key>")
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.patch("https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id}")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"type\": \"swap\",\n \"destination\": {\n \"address\": \"0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22\",\n \"asset\": \"USDC\",\n \"blockchain\": \"optimism\"\n },\n \"isActive\": true,\n \"name\": \"Swap from USDT to OP USDC\",\n \"order\": \"FASTEST\",\n \"slippageTolerance\": \"5\",\n \"source\": {\n \"assets\": [\n \"USDT\"\n ],\n \"blockchain\": \"base\",\n \"maxAmount\": \"1000\",\n \"minAmount\": \"1\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}/auto-settlements/rules/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"type\": \"swap\",\n \"destination\": {\n \"address\": \"0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22\",\n \"asset\": \"USDC\",\n \"blockchain\": \"optimism\"\n },\n \"isActive\": true,\n \"name\": \"Swap from USDT to OP USDC\",\n \"order\": \"FASTEST\",\n \"slippageTolerance\": \"5\",\n \"source\": {\n \"assets\": [\n \"USDT\"\n ],\n \"blockchain\": \"base\",\n \"maxAmount\": \"1000\",\n \"minAmount\": \"1\"\n }\n}"
response = http.request(request)
puts response.read_body{
"data": {
"type": "swap",
"createdAt": "2025-08-26T17:28:38.273Z",
"destination": {
"address": "0x2455eC6700092991Ce0782365A89d5Cd89c8Fa22",
"asset": "USDC",
"blockchain": "optimism"
},
"id": "48c52f4a-c0bf-45c9-a322-1fef00f00431",
"isActive": true,
"name": "Swap from USDT to OP USDC",
"order": "FASTEST",
"slippageTolerance": "5",
"source": {
"assets": [
"USDT"
],
"blockchain": "base",
"maxAmount": "1000",
"minAmount": "1"
},
"updatedAt": "2025-08-26T17:32:08.108Z"
},
"message": "Auto settlement rule updated successfully",
"statusCode": 200
}
