curl --request POST \
--url 'https://rpc-mainnet.solanatracker.io/?api_key=' \
--header 'Content-Type: application/json' \
--data '
{
"jsonrpc": "2.0",
"id": 1,
"method": "getAssetsByGroup",
"params": {
"groupKey": "collection",
"groupValue": "J1S9H3QjnRtBbbuD4HjPV6RpRhwuk4zKbxsnCHuTgh9w",
"limit": 100
}
}
'{
"jsonrpc": "2.0",
"id": 1,
"result": {
"total": 1,
"limit": 1,
"cursor": "F9Lw3ki3hJ7PF9HQXsBzoY8GyE6sPoEZZdXJBsTTD2rk",
"items": [
{
"interface": "ProgrammableNFT",
"id": "F9Lw3ki3hJ7PF9HQXsBzoY8GyE6sPoEZZdXJBsTTD2rk",
"content": {
"$schema": "https://schema.metaplex.com/nft1.0.json",
"json_uri": "https://madlads.s3.us-west-2.amazonaws.com/json/8420.json",
"files": [
{
"uri": "https://madlads.s3.us-west-2.amazonaws.com/images/8420.png",
"mime": "image/png",
"cdn_uri": "https://image.solanatracker.io/proxy?url=https%3A%2F%2Fmadlads.s3.us-west-2.amazonaws.com%2Fimages%2F8420.png"
}
],
"metadata": {
"name": "Mad Lads #8420",
"symbol": "MAD",
"json_name": "Mad Lads #8420",
"description": "Fock it.",
"attributes": [
{
"trait_type": "Gender",
"value": "Male"
},
{
"trait_type": "Type",
"value": "Light"
}
],
"token_standard": "ProgrammableNonFungible"
},
"links": {
"image": "https://madlads.s3.us-west-2.amazonaws.com/images/8420.png",
"external_url": "https://madlads.com"
},
"category": "image"
},
"authorities": [
{
"address": "2RtGg6fsFiiF1EQzHqbd66AhW7R5bWeQGpTbv2UMkCdW",
"scopes": [
"full"
]
}
],
"compression": {
"eligible": false,
"compressed": false,
"data_hash": "",
"creator_hash": "",
"asset_hash": "",
"tree": "",
"seq": 0,
"leaf_id": 0
},
"grouping": [
{
"group_key": "collection",
"group_value": "J1S9H3QjnRtBbbuD4HjPV6RpRhwuk4zKbxsnCHuTgh9w"
}
],
"royalty": {
"royalty_model": "creators",
"target": null,
"percent": 0.042,
"basis_points": 420,
"primary_sale_happened": true,
"locked": false
},
"creators": [
{
"address": "5XvhfmRjwXkGp3jHGmaKpqeerNYjkuZZBYLVQYdeVcRv",
"share": 0,
"verified": true
},
{
"address": "2RtGg6fsFiiF1EQzHqbd66AhW7R5bWeQGpTbv2UMkCdW",
"share": 100,
"verified": true
}
],
"ownership": {
"frozen": true,
"delegated": false,
"delegate": null,
"ownership_model": "single",
"owner": "4zdNGgAtFsW1cQgHqkiWyRsxaAgxrSRRynnuunxzjxue"
},
"supply": {
"print_max_supply": 0,
"print_current_supply": 0,
"edition_nonce": 254
},
"mutable": true,
"burnt": false,
"token_info": {
"supply": 1,
"decimals": 0,
"token_program": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
}
}
],
"last_indexed_slot": 386120417
}
}DAS API
getAssetsByGroup DAS 方法
列出集合或 Core 分组中的资产(包括压缩 NFT),支持游标或页码分页。查看 getAssetsByGroup 的参数和代码示例。
POST
/
curl --request POST \
--url 'https://rpc-mainnet.solanatracker.io/?api_key=' \
--header 'Content-Type: application/json' \
--data '
{
"jsonrpc": "2.0",
"id": 1,
"method": "getAssetsByGroup",
"params": {
"groupKey": "collection",
"groupValue": "J1S9H3QjnRtBbbuD4HjPV6RpRhwuk4zKbxsnCHuTgh9w",
"limit": 100
}
}
'{
"jsonrpc": "2.0",
"id": 1,
"result": {
"total": 1,
"limit": 1,
"cursor": "F9Lw3ki3hJ7PF9HQXsBzoY8GyE6sPoEZZdXJBsTTD2rk",
"items": [
{
"interface": "ProgrammableNFT",
"id": "F9Lw3ki3hJ7PF9HQXsBzoY8GyE6sPoEZZdXJBsTTD2rk",
"content": {
"$schema": "https://schema.metaplex.com/nft1.0.json",
"json_uri": "https://madlads.s3.us-west-2.amazonaws.com/json/8420.json",
"files": [
{
"uri": "https://madlads.s3.us-west-2.amazonaws.com/images/8420.png",
"mime": "image/png",
"cdn_uri": "https://image.solanatracker.io/proxy?url=https%3A%2F%2Fmadlads.s3.us-west-2.amazonaws.com%2Fimages%2F8420.png"
}
],
"metadata": {
"name": "Mad Lads #8420",
"symbol": "MAD",
"json_name": "Mad Lads #8420",
"description": "Fock it.",
"attributes": [
{
"trait_type": "Gender",
"value": "Male"
},
{
"trait_type": "Type",
"value": "Light"
}
],
"token_standard": "ProgrammableNonFungible"
},
"links": {
"image": "https://madlads.s3.us-west-2.amazonaws.com/images/8420.png",
"external_url": "https://madlads.com"
},
"category": "image"
},
"authorities": [
{
"address": "2RtGg6fsFiiF1EQzHqbd66AhW7R5bWeQGpTbv2UMkCdW",
"scopes": [
"full"
]
}
],
"compression": {
"eligible": false,
"compressed": false,
"data_hash": "",
"creator_hash": "",
"asset_hash": "",
"tree": "",
"seq": 0,
"leaf_id": 0
},
"grouping": [
{
"group_key": "collection",
"group_value": "J1S9H3QjnRtBbbuD4HjPV6RpRhwuk4zKbxsnCHuTgh9w"
}
],
"royalty": {
"royalty_model": "creators",
"target": null,
"percent": 0.042,
"basis_points": 420,
"primary_sale_happened": true,
"locked": false
},
"creators": [
{
"address": "5XvhfmRjwXkGp3jHGmaKpqeerNYjkuZZBYLVQYdeVcRv",
"share": 0,
"verified": true
},
{
"address": "2RtGg6fsFiiF1EQzHqbd66AhW7R5bWeQGpTbv2UMkCdW",
"share": 100,
"verified": true
}
],
"ownership": {
"frozen": true,
"delegated": false,
"delegate": null,
"ownership_model": "single",
"owner": "4zdNGgAtFsW1cQgHqkiWyRsxaAgxrSRRynnuunxzjxue"
},
"supply": {
"print_max_supply": 0,
"print_current_supply": 0,
"edition_nonce": 254
},
"mutable": true,
"burnt": false,
"token_info": {
"supply": 1,
"decimals": 0,
"token_program": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
}
}
],
"last_indexed_slot": 386120417
}
}在同一个列表中返回基于账户的 NFT、Core 资产和压缩 NFT。也可使用
get_assets_by_group 调用。
groupKey为collection或group;其他键不返回任何条目。- 只列出已验证的成员。设置
options.showUnverifiedCollections可包含未验证成员。 limit默认为 1000,且不能超过 1000。total是当前页的条目数。- 未传入
page、before或after时,响应会带有cursor。将其作为cursor传回以获取下一页;items为空时停止。 page从 1 开始。page、before/after和cursor不能组合使用。- 默认按
id降序排序。created、updated和recent_action按 slot 排序,需要使用page分页,且最多支持 50,000 个匹配资产。 - 一次请求最多检查 200,000 个候选资产。在大型集合中翻到很深的页时,请使用
cursor分页,而不是很大的page页码。 - 消耗 1 积分,并计入套餐的 DAS RPS 限制。
请求体
application/json
此页面对您有帮助吗?