Importing
Update Image
Set or clear the icon on an imported token
PUT
/
external-tokens
/
api
/
{tokenAddress}
/
image
curl -X PUT "https://api.trusset.org/external-tokens/api/0x9f8c1d4b2e7a3056c1b8f4d29e0a7c3518b6d24f/image" \
-H "X-API-Key: trusset_your_key_here" \
-H "Content-Type: application/json" \
-d '{"imageURI": "ipfs://bafkreigh2akiscaildc7fh4dqwv6zqm4"}'
await fetch(
`https://api.trusset.org/external-tokens/api/${tokenAddress}/image`,
{
method: 'PUT',
headers: { 'X-API-Key': 'trusset_your_key_here', 'Content-Type': 'application/json' },
body: JSON.stringify({ imageURI: null })
}
);
{
"success": true,
"data": {
"tokenAddress": "0x9f8c1d4b2e7a3056c1b8f4d29e0a7c3518b6d24f",
"imageURI": "ipfs://bafkreigh2akiscaildc7fh4dqwv6zqm4",
"updatedAt": "2026-09-05T12:22:00.000Z"
}
}
Replaces the icon on an import record. The icon is presentation only. Nothing reads it as a fact about the asset.
Path Parameters
string
required
The imported contract address.
Body Parameters
string
required
An
https:// or ipfs:// URI, at most 1024 characters. Send null to clear the icon.An empty string is not a valid value. It is rejected rather than treated as a clear.Pin a file first with Upload File if you do not host the image yourself.Response Fields
object
curl -X PUT "https://api.trusset.org/external-tokens/api/0x9f8c1d4b2e7a3056c1b8f4d29e0a7c3518b6d24f/image" \
-H "X-API-Key: trusset_your_key_here" \
-H "Content-Type: application/json" \
-d '{"imageURI": "ipfs://bafkreigh2akiscaildc7fh4dqwv6zqm4"}'
await fetch(
`https://api.trusset.org/external-tokens/api/${tokenAddress}/image`,
{
method: 'PUT',
headers: { 'X-API-Key': 'trusset_your_key_here', 'Content-Type': 'application/json' },
body: JSON.stringify({ imageURI: null })
}
);
{
"success": true,
"data": {
"tokenAddress": "0x9f8c1d4b2e7a3056c1b8f4d29e0a7c3518b6d24f",
"imageURI": "ipfs://bafkreigh2akiscaildc7fh4dqwv6zqm4",
"updatedAt": "2026-09-05T12:22:00.000Z"
}
}
Error Codes
| Code | HTTP | Cause |
|---|---|---|
INVALID_ADDRESS | 400 | tokenAddress is not a valid address |
INVALID_IMAGE_URI | 400 | Not a valid https or ipfs URI, or over 1024 characters. Send null to clear |
IMPORT_NOT_FOUND | 400 | No active import for that address on your instance |
⌘I
curl -X PUT "https://api.trusset.org/external-tokens/api/0x9f8c1d4b2e7a3056c1b8f4d29e0a7c3518b6d24f/image" \
-H "X-API-Key: trusset_your_key_here" \
-H "Content-Type: application/json" \
-d '{"imageURI": "ipfs://bafkreigh2akiscaildc7fh4dqwv6zqm4"}'
await fetch(
`https://api.trusset.org/external-tokens/api/${tokenAddress}/image`,
{
method: 'PUT',
headers: { 'X-API-Key': 'trusset_your_key_here', 'Content-Type': 'application/json' },
body: JSON.stringify({ imageURI: null })
}
);
{
"success": true,
"data": {
"tokenAddress": "0x9f8c1d4b2e7a3056c1b8f4d29e0a7c3518b6d24f",
"imageURI": "ipfs://bafkreigh2akiscaildc7fh4dqwv6zqm4",
"updatedAt": "2026-09-05T12:22:00.000Z"
}
}
