getAssetProof
Last updated:
getAssetProof returns the Merkle proof for a single compressed NFT (cNFT),
looked up by its Digital Asset Standard (DAS) asset ID. Compressed NFTs are not
stored as individual on-chain accounts — they live as leaves in a concurrent
Merkle tree, and their authenticity is established by a proof against that
tree's root. This method gives you exactly that proof: the leaf, the tree's
current root, and the sibling hashes along the path from the leaf to the root.
Use it whenever you need to verify or act on a compressed NFT on-chain — for
example, when constructing a Bubblegum transfer, burn, or delegate instruction,
which require the proof as input so the program can recompute and check the root.
Pair it with getAsset, which returns the asset's metadata and
ownership, while getAssetProof returns the cryptographic proof for the same
asset.
This method belongs to the sol_das category and requires the basic tier or
higher. It is not available on the free tier — a free-tier key will be rejected
with an authorization error.
Parameters
This method takes no parameters.
Returns
| Field | Type |
|---|---|
| result | object |
Examples
curl https://triport.io/sol \
-X POST -H 'Content-Type: application/json' \
-H 'Authorization: Bearer <api-key>' \
-d '{"id":1,"method":"getAssetProof","params":[],"jsonrpc":"2.0"}'const res = await fetch("https://triport.io/sol", {
method: "POST",
headers: { "Content-Type": "application/json", Authorization: "Bearer <api-key>" },
body: JSON.stringify({
"id": 1,
"method": "getAssetProof",
"params": [],
"jsonrpc": "2.0"
}),
});
const data = await res.json();import requests
resp = requests.post(
"https://triport.io/sol",
headers={"Authorization": "Bearer <api-key>"},
json={"id":1,"method":"getAssetProof","params":[],"jsonrpc":"2.0"},
)
print(resp.json())Usage
- Transport: HTTP (JSON-RPC).
- Networks: mainnet.
- Credit cost: 10 per call.
FAQ
- What does getAssetProof do?
- Returns the Merkle proof for a compressed NFT asset, for on-chain verification.
- How many credits does getAssetProof cost?
- getAssetProof costs 10 credit(s) per call on Triport by default.
- Is getAssetProof available over WebSocket?
- getAssetProof is an HTTP JSON-RPC method.