Currently, we can fetch asset metadata by genesis asset ID:
|
// FetchAssetMetaForAsset fetches the asset meta for a given asset. |
|
FetchAssetMetaForAsset(ctx context.Context, |
|
assetID []byte) (AssetMeta, error) |
For the supply commitment feature, we need two separate queries for better flexibility:
-
List asset IDs in a group
- Return all asset IDs (minted tranches) for a given asset group.
- Order by mint block height.
- Output format could be a map of block height → asset ID.
-
Fetch metadata for any asset ID
- Support retrieving asset metadata for any tranche within an asset group, not just the genesis asset.
This would also allow fetching the latest supply commitment delegation key if needed later.
Currently, we can fetch asset metadata by genesis asset ID:
taproot-assets/tapdb/addrs.go
Lines 228 to 230 in e3690c5
For the supply commitment feature, we need two separate queries for better flexibility:
List asset IDs in a group
Fetch metadata for any asset ID
This would also allow fetching the latest supply commitment delegation key if needed later.