If I have an asset with
policy id: 2697bec9e609932eaaaafb34c8e1ea706549d268166ef60285026b85
asset name: redomgrun
How do I calculate the fingerprint asset107k0vzcplp8rjc3d2y8cew6z2gdhvnqru2uluu
?
Cardano Stack Exchange is a question and answer site for users and developers of the Cardano cryptocurrency ecosystem. It only takes a minute to sign up.
Sign up to join this communityAs 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.
A Java implementation will be available in cardano-client-lib next release. (0.2.0)
For now, you can refer to "calculateFingerPrint" method of this class (see here for tests).