Wallets
Link Wallet
Link a wallet address to a customer created with a reference key
POST
/
customers
/
api
/
manage
/
link-wallet
curl -X POST "https://api.trusset.org/customers/api/manage/link-wallet" \
-H "Content-Type: application/json" \
-H "X-API-Key: trusset_abc123xy_secret..." \
-d '{
"referenceKey": "ref_a1b2c3d4e5f67890abcdef1234567890",
"walletAddress": "0xaBc123DEf456789012345678901234567890aBCD"
}'
const response = await fetch('https://api.trusset.org/customers/api/manage/link-wallet', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'X-API-Key': 'trusset_abc123xy_secret...'
},
body: JSON.stringify({
referenceKey: 'ref_a1b2c3d4e5f67890abcdef1234567890',
walletAddress: '0xaBc123DEf456789012345678901234567890aBCD'
})
});
const { data: customer } = await response.json();
{
"success": true,
"data": {
"id": "cmt0k3b9x0004cghxw7r2d5ya",
"instanceId": "cmrz4d1v20000cghx8k6p3m7t",
"issuerId": "cmrz3a8q10000cghxf5w2n9k4",
"walletAddress": "0xaBc123DEf456789012345678901234567890aBCD",
"externalId": null,
"name": "Acme Corp",
"country": "DEU",
"investorType": "PROFESSIONAL",
"customerType": "COMPANY",
"companyUrl": null,
"companyId": null,
"status": "pending",
"frozen": false,
"kycHash": null,
"onChainTxHash": null,
"sumsubApplicantId": null,
"idLinkId": null,
"referenceKey": "ref_a1b2c3d4e5f67890abcdef1234567890",
"contactChannels": [],
"metadata": null,
"archived": false,
"archivedAt": null,
"verifiedAt": null,
"revokedAt": null,
"onChainSyncedAt": null,
"createdAt": "2026-09-30T12:00:00.000Z",
"updatedAt": "2026-09-30T12:05:00.000Z"
},
"metadata": {
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"timestamp": "2026-09-30T12:05:00.000Z"
}
}
{
"success": false,
"error": {
"code": "CUSTOMER_NOT_FOUND",
"message": "No customer found with this reference key"
},
"metadata": {
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"timestamp": "2026-09-30T12:05:00.000Z"
}
}
{
"success": false,
"error": {
"code": "WALLET_ALREADY_LINKED",
"message": "This customer already has a linked wallet"
},
"metadata": {
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"timestamp": "2026-09-30T12:05:00.000Z"
}
}
{
"success": false,
"error": {
"code": "WALLET_IN_USE",
"message": "This wallet address is already assigned to another customer"
},
"metadata": {
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"timestamp": "2026-09-30T12:05:00.000Z"
}
}
Links an Ethereum wallet address to an existing customer that was created without a wallet. This is the second step of the deferred wallet flow. First create a customer without a
walletAddress to receive a referenceKey. Then call this endpoint when the end-customer connects their wallet in your application.
The reference key must belong to a customer on your instance that is not archived and has no wallet yet. The wallet must be neither another active customer’s primary nor any other customer’s linked wallet.
Body Parameters
string
required
The reference key returned when the customer was created without a wallet address. Format:
ref_ followed by 32 hex characters.string
required
Ethereum wallet address to link, as the customer’s primary. Must be a valid checksummed or lowercased address. Stored checksummed.
Response Fields
boolean
Request status
object
The updated customer record with the linked wallet address, with the fields listed on Get Customer other than its linked wallets, company links, Sumsub applicant record and audit entries.
referenceKey stays set.status becomes verified when the registry already holds a verified identity for the wallet, registered by the Trusset platform verifier or by one of your instance’s verified wallets. On an instance bound to its own register, any verifier counts. Otherwise status is unchanged, and a registry read that fails does not fail the call.curl -X POST "https://api.trusset.org/customers/api/manage/link-wallet" \
-H "Content-Type: application/json" \
-H "X-API-Key: trusset_abc123xy_secret..." \
-d '{
"referenceKey": "ref_a1b2c3d4e5f67890abcdef1234567890",
"walletAddress": "0xaBc123DEf456789012345678901234567890aBCD"
}'
const response = await fetch('https://api.trusset.org/customers/api/manage/link-wallet', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'X-API-Key': 'trusset_abc123xy_secret...'
},
body: JSON.stringify({
referenceKey: 'ref_a1b2c3d4e5f67890abcdef1234567890',
walletAddress: '0xaBc123DEf456789012345678901234567890aBCD'
})
});
const { data: customer } = await response.json();
{
"success": true,
"data": {
"id": "cmt0k3b9x0004cghxw7r2d5ya",
"instanceId": "cmrz4d1v20000cghx8k6p3m7t",
"issuerId": "cmrz3a8q10000cghxf5w2n9k4",
"walletAddress": "0xaBc123DEf456789012345678901234567890aBCD",
"externalId": null,
"name": "Acme Corp",
"country": "DEU",
"investorType": "PROFESSIONAL",
"customerType": "COMPANY",
"companyUrl": null,
"companyId": null,
"status": "pending",
"frozen": false,
"kycHash": null,
"onChainTxHash": null,
"sumsubApplicantId": null,
"idLinkId": null,
"referenceKey": "ref_a1b2c3d4e5f67890abcdef1234567890",
"contactChannels": [],
"metadata": null,
"archived": false,
"archivedAt": null,
"verifiedAt": null,
"revokedAt": null,
"onChainSyncedAt": null,
"createdAt": "2026-09-30T12:00:00.000Z",
"updatedAt": "2026-09-30T12:05:00.000Z"
},
"metadata": {
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"timestamp": "2026-09-30T12:05:00.000Z"
}
}
{
"success": false,
"error": {
"code": "CUSTOMER_NOT_FOUND",
"message": "No customer found with this reference key"
},
"metadata": {
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"timestamp": "2026-09-30T12:05:00.000Z"
}
}
{
"success": false,
"error": {
"code": "WALLET_ALREADY_LINKED",
"message": "This customer already has a linked wallet"
},
"metadata": {
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"timestamp": "2026-09-30T12:05:00.000Z"
}
}
{
"success": false,
"error": {
"code": "WALLET_IN_USE",
"message": "This wallet address is already assigned to another customer"
},
"metadata": {
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"timestamp": "2026-09-30T12:05:00.000Z"
}
}
Error Codes
| Code | HTTP | Cause |
|---|---|---|
MISSING_REFERENCE_KEY | 400 | referenceKey is missing or not a string |
INVALID_ADDRESS | 400 | walletAddress is missing or not a valid address |
INVALID_REFERENCE | 400 | referenceKey does not start with ref_ |
CUSTOMER_NOT_FOUND | 404 | No customer on your instance that is not archived has this reference key |
WALLET_ALREADY_LINKED | 409 | The customer already has a primary wallet |
WALLET_IN_USE | 409 | The wallet is another active customer’s primary or any other customer’s linked wallet |
LINK_FAILED | 500 | The link could not be written |
⌘I
curl -X POST "https://api.trusset.org/customers/api/manage/link-wallet" \
-H "Content-Type: application/json" \
-H "X-API-Key: trusset_abc123xy_secret..." \
-d '{
"referenceKey": "ref_a1b2c3d4e5f67890abcdef1234567890",
"walletAddress": "0xaBc123DEf456789012345678901234567890aBCD"
}'
const response = await fetch('https://api.trusset.org/customers/api/manage/link-wallet', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'X-API-Key': 'trusset_abc123xy_secret...'
},
body: JSON.stringify({
referenceKey: 'ref_a1b2c3d4e5f67890abcdef1234567890',
walletAddress: '0xaBc123DEf456789012345678901234567890aBCD'
})
});
const { data: customer } = await response.json();
{
"success": true,
"data": {
"id": "cmt0k3b9x0004cghxw7r2d5ya",
"instanceId": "cmrz4d1v20000cghx8k6p3m7t",
"issuerId": "cmrz3a8q10000cghxf5w2n9k4",
"walletAddress": "0xaBc123DEf456789012345678901234567890aBCD",
"externalId": null,
"name": "Acme Corp",
"country": "DEU",
"investorType": "PROFESSIONAL",
"customerType": "COMPANY",
"companyUrl": null,
"companyId": null,
"status": "pending",
"frozen": false,
"kycHash": null,
"onChainTxHash": null,
"sumsubApplicantId": null,
"idLinkId": null,
"referenceKey": "ref_a1b2c3d4e5f67890abcdef1234567890",
"contactChannels": [],
"metadata": null,
"archived": false,
"archivedAt": null,
"verifiedAt": null,
"revokedAt": null,
"onChainSyncedAt": null,
"createdAt": "2026-09-30T12:00:00.000Z",
"updatedAt": "2026-09-30T12:05:00.000Z"
},
"metadata": {
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"timestamp": "2026-09-30T12:05:00.000Z"
}
}
{
"success": false,
"error": {
"code": "CUSTOMER_NOT_FOUND",
"message": "No customer found with this reference key"
},
"metadata": {
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"timestamp": "2026-09-30T12:05:00.000Z"
}
}
{
"success": false,
"error": {
"code": "WALLET_ALREADY_LINKED",
"message": "This customer already has a linked wallet"
},
"metadata": {
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"timestamp": "2026-09-30T12:05:00.000Z"
}
}
{
"success": false,
"error": {
"code": "WALLET_IN_USE",
"message": "This wallet address is already assigned to another customer"
},
"metadata": {
"requestId": "550e8400-e29b-41d4-a716-446655440000",
"timestamp": "2026-09-30T12:05:00.000Z"
}
}
