<p>There is one catch: the blockchain has no idea what your wallet is, it only sees different address. There is not a guaranteed way to achieve this.</p>
<p>You might want to group these by their stake key, so after listing all the addresses you need to sum these sharing the same stake key.</p>
<p>That being said, just because the address contains a specific stake key, it does not mean that it is the same wallet. This is what we call mengled addresses.</p>

CC BY-SA 4.0
2021-11-23T18:51:50.533Z
2021-11-23T18:51:50.533Z
Marek Mahut - StakeNuts
<p>I'm using the Blockfrost API to get a list of the top holders of an asset. ie. The people with the highest quantity of this asset in their wallet.</p>
<p>I'm using Blockfrost's API, and the specific call I'm using is : <a href="https://cardano-mainnet.blockfrost.io/api/v0/assets/%7Basset%7D/addresses" rel="nofollow noreferrer">https://cardano-mainnet.blockfrost.io/api/v0/assets/{asset}/addresses</a></p>
<p>This returns a list of addresses and the quantity held by each address:</p>
<pre><code>[
  {
    &quot;address&quot;: &quot;addr1qxqs59lphg8g6qndelq8xwqn60ag3aeyfcp33c2kdp46a09re5df3pzwwmyq946axfcejy5n4x0y99wqpgtp2gd0k09qsgy6pz&quot;,
    &quot;quantity&quot;: &quot;1&quot;
  },
  {
    &quot;address&quot;: &quot;addr1qyhr4exrgavdcn3qhfcc9f939fzsch2re5ry9cwvcdyh4x4re5df3pzwwmyq946axfcejy5n4x0y99wqpgtp2gd0k09qdpvhza&quot;,
    &quot;quantity&quot;: &quot;100000&quot;
  },
  {
    &quot;address&quot;: &quot;addr1q8zup8m9ue3p98kxlxl9q8rnyan8hw3ul282tsl9s326dfj088lvedv4zckcj24arcpasr0gua4c5gq4zw2rpcpjk2lq8cmd9l&quot;,
    &quot;quantity&quot;: &quot;18605647&quot;
  }
]
</code></pre>
<p>So... I thought - just sort the list descending and display the top 10, right?</p>
<p>Well that works and it gives me the list of the top 10, but here's the catch...</p>
<p>If anybody uses a different receiving address to purchase the same asset from the same wallet, each receiving address is listed and returned separately by the API. In other words, if anyone buys the same asset (any amount) from the same wallet multiple times, using different receiving addresses, the purchases are not added together and represented as the total holdings for that wallet.</p>
<p>So my top 10 are not really the top 10...! (Just the top 10 biggest purchases...)</p>
<p>Is there any way to get the top 10 holders of a particular asset using the Blockfrost API or any other method?</p>

<native-assets><api><blockfrost>
Get a list of top asset hodlers for a specific asset
# Get a list of top asset hodlers for a specific asset

(Asked by: username_0 on 2021-11-20)

I'm using the Blockfrost API to get a list of the top holders of an asset. ie. The people with the highest quantity of this asset in their wallet.
I'm using Blockfrost's API, and the specific call I'm using is : https://cardano-mainnet.blockfrost.io/api/v0/assets/{asset}/addresses
This returns a list of addresses and the quantity held by each address:
[
  {
    "address": "addr1qxqs59lphg8g6qndelq8xwqn60ag3aeyfcp33c2kdp46a09re5df3pzwwmyq946axfcejy5n4x0y99wqpgtp2gd0k09qsgy6pz",
    "quantity": "1"
  },
  {
    "address": "addr1qyhr4exrgavdcn3qhfcc9f939fzsch2re5ry9cwvcdyh4x4re5df3pzwwmyq946axfcejy5n4x0y99wqpgtp2gd0k09qdpvhza",
    "quantity": "100000"
  },
  {
    "address": "addr1q8zup8m9ue3p98kxlxl9q8rnyan8hw3ul282tsl9s326dfj088lvedv4zckcj24arcpasr0gua4c5gq4zw2rpcpjk2lq8cmd9l",
    "quantity": "18605647"
  }
]

So... I thought - just sort the list descending and display the top 10, right?
Well that works and it gives me the list of the top 10, but here's the catch...
If anybody uses a different receiving address to purchase the same asset from the same wallet, each receiving address is listed and returned separately by the API. In other words, if anyone buys the same asset (any amount) from the same wallet multiple times, using different receiving addresses, the purchases are not added together and represented as the total holdings for that wallet.
So my top 10 are not really the top 10...! (Just the top 10 biggest purchases...)
Is there any way to get the top 10 holders of a particular asset using the Blockfrost API or any other method?

**Tags:** native-assets, api, blockfrost

---

## 1 answers

### Answer by username_1 on 2021-11-23. Score: 0 | Accepted answer

There is one catch: the blockchain has no idea what your wallet is, it only sees different address. There is not a guaranteed way to achieve this.

You might want to group these by their stake key, so after listing all the addresses you need to sum these sharing the same stake key.

That being said, just because the address contains a specific stake key, it does not mean that it is the same wallet. This is what we call mengled addresses.


---

