<p>As per <a href="https://github.com/cardano-foundation/CIPs/blob/master/CIP-0014/CIP-0014.md" rel="noreferrer">CIP14: User-Facing Asset Fingerprint</a>, we calculate it as:</p>
<pre><code>assetFingerprint := encodeBech32
  ( datapart = hash
    ( algorithm = 'blake2b'
    , digest-length = 20
    , message = policyId | assetName
    )
  , humanReadablePart = 'asset'
  )
</code></pre>
<p>Or you can just use an existing library, such as <a href="https://github.com/Emurgo/cip14-js" rel="noreferrer">cip14-js</a> by Emurgo.</p>

CC BY-SA 4.0
2021-05-29T19:57:45.927Z
do you know of any java implementation of it?
wutzebaer
CC BY-SA 4.0
2021-05-30T07:20:29.363Z
See Satya's answer to the question, he could not reply a comment as his user is too new.
Marek Mahut - StakeNuts
CC BY-SA 4.0
2021-05-28T22:15:14.943Z
2021-05-28T22:15:14.943Z
Marek Mahut - StakeNuts
<p>A Java implementation will be available in <a href="https://github.com/bloxbean/cardano-client-lib" rel="nofollow noreferrer">cardano-client-lib</a> next release. (0.2.0)</p>
<p>For now, you can refer to &quot;calculateFingerPrint&quot; method of <a href="https://github.com/bloxbean/cardano-client-lib/blob/master/src/main/java/com/bloxbean/cardano/client/util/AssetUtil.java" rel="nofollow noreferrer">this</a> class (see <a href="https://github.com/bloxbean/cardano-client-lib/blob/master/src/test/java/com/bloxbean/cardano/client/util/AssetUtilTest.java" rel="nofollow noreferrer">here</a> for tests).</p>

CC BY-SA 4.0
2021-05-30T00:52:30.847Z
2021-05-30T03:18:37.057Z
2021-05-30T03:18:37.057Z
Satya
<p>If I have an asset with</p>
<p>policy id: <code>2697bec9e609932eaaaafb34c8e1ea706549d268166ef60285026b85</code></p>
<p>asset name: <code>redomgrun</code></p>
<p>How do I calculate the fingerprint <code>asset107k0vzcplp8rjc3d2y8cew6z2gdhvnqru2uluu</code>?</p>

<token>
How do I calculate the fingerprint of an asset?
# How do I calculate the fingerprint of an asset?

(Asked by: username_0 on 2021-05-28)

If I have an asset with

policy id: `2697bec9e609932eaaaafb34c8e1ea706549d268166ef60285026b85`

asset name: `redomgrun`

How do I calculate the fingerprint `asset107k0vzcplp8rjc3d2y8cew6z2gdhvnqru2uluu`?

**Tags:** token

---

## 2 answers

### Answer by username_1 on 2021-05-28. Score: 6 | Accepted answer

As per CIP14: User-Facing Asset Fingerprint, we calculate it as:
assetFingerprint := encodeBech32
  ( datapart = hash
    ( algorithm = 'blake2b'
    , digest-length = 20
    , message = policyId | assetName
    )
  , humanReadablePart = 'asset'
  )

Or you can just use an existing library, such as cip14-js by Emurgo.

> **Comments:**
> **username_0**: do you know of any java implementation of it?  
> **username_1**: See Satya's answer to the question, he could not reply a comment as his user is too new.  

---

### Answer by username_2 on 2021-05-30. Score: 3

A Java implementation will be available in [cardano-client-lib](https://github.com/bloxbean/cardano-client-lib) next release. (0.2.0)

For now, you can refer to "calculateFingerPrint" method of [this](https://github.com/bloxbean/cardano-client-lib/blob/master/src/main/java/com/bloxbean/cardano/client/util/AssetUtil.java) class (see [here](https://github.com/bloxbean/cardano-client-lib/blob/master/src/test/java/com/bloxbean/cardano/client/util/AssetUtilTest.java) for tests).


---

