NFT ID

The ID of a non-fungible token (NFT). The NFT ID is composed of the token ID and a serial number. The token ID is the ID of the NFT when it was created.

Constructor

Description

new NftId(<tokenId>,<serial>)

Initializes the NftId object

new NftId()

Methods

V2
V1
V2

Method

Type

Requirement

NftId.fromString(<id>)

String

Optional

NftId.fromBytes(<id>)

bytes []

Optional

Java
new NftId(new TokenId(0,0,2), 56562);
// v2.0.11
JavaScript
new NftId(new TokenId(0,0,2), 56562);
// v2.0.28
Go
nftId := hedera.NftID{
TokenID: tokenId,
SerialNumber: serialNum,
}
// v2.1.13
V1

Method

Type

Requirement

NftId.fromString(<id>)

String

Optional

Java
new NftId(new TokenId(0,0,2), 56562);
// v1.5.0
JavaScript
new NftId(new TokenId(0,0,2), 56562);
// v1.4.10