Update Address
curl --request PATCH \
--url https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId} \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"disableAutoSweep": "OPTIONAL_BOOLEAN",
"enableGaslessWithdraw": "OPTIONAL_BOOLEAN",
"isActive": "OPTIONAL_BOOLEAN",
"metadata": "OPTIONAL_METADATA",
"name": "OPTIONAL_ADDRESS_NAME",
"showPrivateKey": "OPTIONAL_BOOLEAN"
}
'import requests
url = "https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}"
payload = {
"disableAutoSweep": "OPTIONAL_BOOLEAN",
"enableGaslessWithdraw": "OPTIONAL_BOOLEAN",
"isActive": "OPTIONAL_BOOLEAN",
"metadata": "OPTIONAL_METADATA",
"name": "OPTIONAL_ADDRESS_NAME",
"showPrivateKey": "OPTIONAL_BOOLEAN"
}
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({
disableAutoSweep: 'OPTIONAL_BOOLEAN',
enableGaslessWithdraw: 'OPTIONAL_BOOLEAN',
isActive: 'OPTIONAL_BOOLEAN',
metadata: 'OPTIONAL_METADATA',
name: 'OPTIONAL_ADDRESS_NAME',
showPrivateKey: 'OPTIONAL_BOOLEAN'
})
};
fetch('https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}', 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}",
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([
'disableAutoSweep' => 'OPTIONAL_BOOLEAN',
'enableGaslessWithdraw' => 'OPTIONAL_BOOLEAN',
'isActive' => 'OPTIONAL_BOOLEAN',
'metadata' => 'OPTIONAL_METADATA',
'name' => 'OPTIONAL_ADDRESS_NAME',
'showPrivateKey' => 'OPTIONAL_BOOLEAN'
]),
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}"
payload := strings.NewReader("{\n \"disableAutoSweep\": \"OPTIONAL_BOOLEAN\",\n \"enableGaslessWithdraw\": \"OPTIONAL_BOOLEAN\",\n \"isActive\": \"OPTIONAL_BOOLEAN\",\n \"metadata\": \"OPTIONAL_METADATA\",\n \"name\": \"OPTIONAL_ADDRESS_NAME\",\n \"showPrivateKey\": \"OPTIONAL_BOOLEAN\"\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}")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"disableAutoSweep\": \"OPTIONAL_BOOLEAN\",\n \"enableGaslessWithdraw\": \"OPTIONAL_BOOLEAN\",\n \"isActive\": \"OPTIONAL_BOOLEAN\",\n \"metadata\": \"OPTIONAL_METADATA\",\n \"name\": \"OPTIONAL_ADDRESS_NAME\",\n \"showPrivateKey\": \"OPTIONAL_BOOLEAN\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}")
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 \"disableAutoSweep\": \"OPTIONAL_BOOLEAN\",\n \"enableGaslessWithdraw\": \"OPTIONAL_BOOLEAN\",\n \"isActive\": \"OPTIONAL_BOOLEAN\",\n \"metadata\": \"OPTIONAL_METADATA\",\n \"name\": \"OPTIONAL_ADDRESS_NAME\",\n \"showPrivateKey\": \"OPTIONAL_BOOLEAN\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"address": "0x3ec2a234DE95cC783291241B7070b19786b25d5b",
"blockchain": {
"createdAt": "2024-05-27T08:31:14.966Z",
"derivationPath": "m/44'/60'/0'/0",
"id": "74733889-4ecd-403e-9840-94e87c043f24",
"isActive": true,
"isEvmCompatible": true,
"logoUrl": "https://res.cloudinary.com/blockradar/image/upload/v1716800080/crypto-assets/Base_Network_Logo_vqyh7r.png",
"name": "base",
"slug": "base",
"symbol": "eth",
"tokenStandard": null,
"updatedAt": "2024-10-27T07:52:16.115Z"
},
"configurations": {
"aml": {
"message": "Address is not sanctioned",
"provider": "ofac",
"status": "success"
},
"disableAutoSweep": true,
"enableGaslessWithdraw": true,
"showPrivateKey": false
},
"createdAt": "2024-11-11T16:48:19.682Z",
"derivationPath": "m/44'/60'/0'/0/104",
"id": "4982f18a-e9ec-43e8-b8a7-39de40f45e6f",
"isActive": true,
"metadata": null,
"name": "Customer 2",
"network": "testnet",
"type": "INTERNAL",
"updatedAt": "2024-11-11T16:55:05.320Z"
},
"message": "Address updated successfully",
"statusCode": 200
}Update Address
This endpoint allows the client to update the status of a specific address within a wallet.
Body Parameters
| Key | Required | Type | Description |
|---|---|---|---|
| isActive | false | boolean | The status state you want to set the address |
| name | false | string | The name of the address. |
| metadata | false | object | Additional metadata for the address. This will be part of any transaction tied to this. |
| showPrivateKey | false | boolean | If you want the address private key to be part of the response. |
| disableAutoSweep | false | boolean | Disable automatic sweeping of assets sent to the address into your master wallet. |
| enableGaslessWithdraw | false | boolean | Enable gasless transactions from this address. |
| privateKey | false | string | The private key associated with the address. Required for executing actions securely. |
PATCH
/
v1
/
wallets
/
{walletId}
/
addresses
/
{addressId}
Update Address
curl --request PATCH \
--url https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId} \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"disableAutoSweep": "OPTIONAL_BOOLEAN",
"enableGaslessWithdraw": "OPTIONAL_BOOLEAN",
"isActive": "OPTIONAL_BOOLEAN",
"metadata": "OPTIONAL_METADATA",
"name": "OPTIONAL_ADDRESS_NAME",
"showPrivateKey": "OPTIONAL_BOOLEAN"
}
'import requests
url = "https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}"
payload = {
"disableAutoSweep": "OPTIONAL_BOOLEAN",
"enableGaslessWithdraw": "OPTIONAL_BOOLEAN",
"isActive": "OPTIONAL_BOOLEAN",
"metadata": "OPTIONAL_METADATA",
"name": "OPTIONAL_ADDRESS_NAME",
"showPrivateKey": "OPTIONAL_BOOLEAN"
}
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({
disableAutoSweep: 'OPTIONAL_BOOLEAN',
enableGaslessWithdraw: 'OPTIONAL_BOOLEAN',
isActive: 'OPTIONAL_BOOLEAN',
metadata: 'OPTIONAL_METADATA',
name: 'OPTIONAL_ADDRESS_NAME',
showPrivateKey: 'OPTIONAL_BOOLEAN'
})
};
fetch('https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}', 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}",
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([
'disableAutoSweep' => 'OPTIONAL_BOOLEAN',
'enableGaslessWithdraw' => 'OPTIONAL_BOOLEAN',
'isActive' => 'OPTIONAL_BOOLEAN',
'metadata' => 'OPTIONAL_METADATA',
'name' => 'OPTIONAL_ADDRESS_NAME',
'showPrivateKey' => 'OPTIONAL_BOOLEAN'
]),
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}"
payload := strings.NewReader("{\n \"disableAutoSweep\": \"OPTIONAL_BOOLEAN\",\n \"enableGaslessWithdraw\": \"OPTIONAL_BOOLEAN\",\n \"isActive\": \"OPTIONAL_BOOLEAN\",\n \"metadata\": \"OPTIONAL_METADATA\",\n \"name\": \"OPTIONAL_ADDRESS_NAME\",\n \"showPrivateKey\": \"OPTIONAL_BOOLEAN\"\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}")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"disableAutoSweep\": \"OPTIONAL_BOOLEAN\",\n \"enableGaslessWithdraw\": \"OPTIONAL_BOOLEAN\",\n \"isActive\": \"OPTIONAL_BOOLEAN\",\n \"metadata\": \"OPTIONAL_METADATA\",\n \"name\": \"OPTIONAL_ADDRESS_NAME\",\n \"showPrivateKey\": \"OPTIONAL_BOOLEAN\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.blockradar.co/v1/wallets/{walletId}/addresses/{addressId}")
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 \"disableAutoSweep\": \"OPTIONAL_BOOLEAN\",\n \"enableGaslessWithdraw\": \"OPTIONAL_BOOLEAN\",\n \"isActive\": \"OPTIONAL_BOOLEAN\",\n \"metadata\": \"OPTIONAL_METADATA\",\n \"name\": \"OPTIONAL_ADDRESS_NAME\",\n \"showPrivateKey\": \"OPTIONAL_BOOLEAN\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"address": "0x3ec2a234DE95cC783291241B7070b19786b25d5b",
"blockchain": {
"createdAt": "2024-05-27T08:31:14.966Z",
"derivationPath": "m/44'/60'/0'/0",
"id": "74733889-4ecd-403e-9840-94e87c043f24",
"isActive": true,
"isEvmCompatible": true,
"logoUrl": "https://res.cloudinary.com/blockradar/image/upload/v1716800080/crypto-assets/Base_Network_Logo_vqyh7r.png",
"name": "base",
"slug": "base",
"symbol": "eth",
"tokenStandard": null,
"updatedAt": "2024-10-27T07:52:16.115Z"
},
"configurations": {
"aml": {
"message": "Address is not sanctioned",
"provider": "ofac",
"status": "success"
},
"disableAutoSweep": true,
"enableGaslessWithdraw": true,
"showPrivateKey": false
},
"createdAt": "2024-11-11T16:48:19.682Z",
"derivationPath": "m/44'/60'/0'/0/104",
"id": "4982f18a-e9ec-43e8-b8a7-39de40f45e6f",
"isActive": true,
"metadata": null,
"name": "Customer 2",
"network": "testnet",
"type": "INTERNAL",
"updatedAt": "2024-11-11T16:55:05.320Z"
},
"message": "Address updated successfully",
"statusCode": 200
}Authorizations
Path Parameters
Example:
"YOUR_WALLET_ID"
Example:
"ADDRESS_ID"
Body
application/json
⌘I

