WebSocket
Get Whitelisted Addresses
Returns an array of the user's whitelisted addresses, both fiat and crypto.
Auth:API Key
Tags:
Funding
Addresses
Command Name
GetWhitelistedAddressesCommand Arguments
| Field | Type | Required | Description |
|---|---|---|---|
ClientId | string | Required | Custom client ID for tracking (max 36 characters) Example: "my-client-123" |
ClientIdRequired
Type:
string
Description:
Custom client ID for tracking (max 36 characters)
Example:
"my-client-123"Command Invocation
Command Arguments Example:
[
"my-client-123"
]Invocation Example:
connection.invoke('GetWhitelistedAddresses', 'my-client-123')Response Event
Event Name
executionEventsSubject
account.externalAddresses.snapshotWhitelisted addresses snapshot response containing an array of address records
| Field | Type | Description |
|---|---|---|
id | string | Address ID |
name | string | Address name |
userId | string | User ID |
asset | string | Asset name |
address | string | Address |
addressParams | object | Address parameters |
network | string | Address network |
status | number | Address status 0→ Pending1→ Refused2→ Approved3→ Deleted |
comment | string | Comments on address |
auditBy | string | Auditor informations |
auditDate | string | Datetime of audit |
enabled | boolean | Enabled flag |
deleted | boolean | Deleted flag |
creationDate | string | Datetime of address creation |
Example Response
{
"data": [
{
"id": "xxxx",
"name": "BTC 01",
"userId": "yyyy",
"asset": "BTC",
"address": "zzzz",
"addressParams": {},
"network": "Bitcoin",
"status": 2,
"comment": "",
"auditBy": "",
"auditDate": "",
"enabled": true,
"deleted": false,
"creationDate": "2023-10-05T14:07:59+00:00"
}
]
}Code Examples
const signalR = require('@microsoft/signalr');
const apiKey = 'YOUR_API_KEY_HERE';
const connection = new signalR.HubConnectionBuilder()
.withUrl('https://publicapi.sandbox.hercle.financial/ExecutionLiveServer/v1', {
accessTokenFactory: () => apiKey,
})
.build();
connection.start()
.then(() => {
console.log('Connected to WebSocket');
// Invoke command
connection.invoke('GetWhitelistedAddresses', "my-client-123")
.then(() => {
console.log('Command sent successfully');
})
.catch(err => {
console.error('Command failed:', err);
});
})
.catch(err => {
console.error('Connection failed:', err);
});
// Listen for events
connection.on('executionEvents', (data) => {
console.log('Received event:', data);
});SignalR API Tester
Test this command in the sandbox environment
Disconnected
Your API key is only used locally and never stored