Skip to main content
Version: 0.1.0

Protocol Documentation

Table of Contents​

Top

centerchain/nft/v1/nft.proto​

ClassData​

FieldTypeLabelDescription
product_refstring

ClassMeta​

FieldTypeLabelDescription
class_idstring
issuerstring
product_refstring
restrictedbool
token_metadata_immutablebool

ClassSequence​

FieldTypeLabelDescription
class_idstring
sequenceuint64

GenesisState​

FieldTypeLabelDescription
paramsParams
classesClassMetarepeated
sequencesClassSequencerepeated
locksNFTLockrepeated

MsgBurnNFT​

FieldTypeLabelDescription
senderstring
class_idstring
token_idstring

MsgBurnNFTResponse​

MsgChangeClassIssuer​

FieldTypeLabelDescription
authoritystring
class_idstring
new_issuerstring

MsgChangeClassIssuerResponse​

MsgCreateClass​

FieldTypeLabelDescription
senderstring
class_idstring
namestring
symbolstring
descriptionstring
uristring
uri_hashstring
restrictedbool
token_metadata_immutablebool

MsgCreateClassResponse​

MsgMintNFT​

FieldTypeLabelDescription
senderstring
class_idstring
tostring
uristring
uri_hashstring

MsgMintNFTResponse​

FieldTypeLabelDescription
token_idstring

MsgSetNFTMetadata​

FieldTypeLabelDescription
senderstring
class_idstring
token_idstring
uristring
uri_hashstring

MsgSetNFTMetadataResponse​

NFTData​

FieldTypeLabelDescription
product_refstring

NFTLock​

FieldTypeLabelDescription
class_idstring
token_idstring
order_idstring
holderstring

Params​

FieldTypeLabelDescription
class_creation_feecosmos.base.v1beta1.Coinrepeated
class_creation_gas_consumeuint64

QueryClassDetailRequest​

FieldTypeLabelDescription
class_idstring
paginationcosmos.base.query.v1beta1.PageRequest

QueryClassDetailResponse​

FieldTypeLabelDescription
classClassMeta
total_supplyuint64
holder_countuint64DEPRECATED: no longer computed on-chain. It previously required an unbounded scan of every token in the class and is now always 0. Use the paginated tokens / TokensByClass, or an off-chain indexer, for holder counts. Field number is preserved for wire compatibility.
tokensTokenSummaryrepeated
paginationcosmos.base.query.v1beta1.PageResponse

QueryClassIssuerRequest​

FieldTypeLabelDescription
class_idstring

QueryClassIssuerResponse​

FieldTypeLabelDescription
classClassMeta

QueryClassesByIssuerRequest​

FieldTypeLabelDescription
issuerstring
paginationcosmos.base.query.v1beta1.PageRequest

QueryClassesByIssuerResponse​

FieldTypeLabelDescription
classesClassMetarepeated
paginationcosmos.base.query.v1beta1.PageResponse

QueryNFTLockRequest​

FieldTypeLabelDescription
class_idstring
token_idstring

QueryNFTLockResponse​

FieldTypeLabelDescription
lockedbool
lockNFTLock

QueryParamsRequest​

QueryParamsResponse​

FieldTypeLabelDescription
paramsParams

QueryTokensByClassRequest​

FieldTypeLabelDescription
class_idstring
paginationcosmos.base.query.v1beta1.PageRequest

QueryTokensByClassResponse​

FieldTypeLabelDescription
tokensTokenSummaryrepeated
paginationcosmos.base.query.v1beta1.PageResponse

QueryTokensByOwnerRequest​

FieldTypeLabelDescription
ownerstring
paginationcosmos.base.query.v1beta1.PageRequest

QueryTokensByOwnerResponse​

FieldTypeLabelDescription
tokensTokenSummaryrepeated
paginationcosmos.base.query.v1beta1.PageResponse

TokenSummary​

FieldTypeLabelDescription
class_idstring
token_idstring
ownerstring
uristring
uri_hashstring

Msg​

Method NameRequest TypeResponse TypeDescription
CreateClassMsgCreateClassMsgCreateClassResponse
MintNFTMsgMintNFTMsgMintNFTResponse
BurnNFTMsgBurnNFTMsgBurnNFTResponse
SetNFTMetadataMsgSetNFTMetadataMsgSetNFTMetadataResponse
ChangeClassIssuerMsgChangeClassIssuerMsgChangeClassIssuerResponse

Query​

Method NameRequest TypeResponse TypeDescription
ParamsQueryParamsRequestQueryParamsResponse
ClassIssuerQueryClassIssuerRequestQueryClassIssuerResponse
NFTLockQueryNFTLockRequestQueryNFTLockResponse
ClassesByIssuerQueryClassesByIssuerRequestQueryClassesByIssuerResponse
TokensByClassQueryTokensByClassRequestQueryTokensByClassResponse
TokensByOwnerQueryTokensByOwnerRequestQueryTokensByOwnerResponse
ClassDetailQueryClassDetailRequestQueryClassDetailResponse

Scalar Value Types​

.proto TypeNotesC++JavaPythonGoC#PHPRuby
doubledoubledoublefloatfloat64doublefloatFloat
floatfloatfloatfloatfloat32floatfloatFloat
int32Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead.int32intintint32intintegerBignum or Fixnum (as required)
int64Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead.int64longint/longint64longinteger/stringBignum
uint32Uses variable-length encoding.uint32intint/longuint32uintintegerBignum or Fixnum (as required)
uint64Uses variable-length encoding.uint64longint/longuint64ulonginteger/stringBignum or Fixnum (as required)
sint32Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s.int32intintint32intintegerBignum or Fixnum (as required)
sint64Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s.int64longint/longint64longinteger/stringBignum
fixed32Always four bytes. More efficient than uint32 if values are often greater than 2^28.uint32intintuint32uintintegerBignum or Fixnum (as required)
fixed64Always eight bytes. More efficient than uint64 if values are often greater than 2^56.uint64longint/longuint64ulonginteger/stringBignum
sfixed32Always four bytes.int32intintint32intintegerBignum or Fixnum (as required)
sfixed64Always eight bytes.int64longint/longint64longinteger/stringBignum
boolboolbooleanbooleanboolboolbooleanTrueClass/FalseClass
stringA string must always contain UTF-8 encoded or 7-bit ASCII text.stringStringstr/unicodestringstringstringString (UTF-8)
bytesMay contain any arbitrary sequence of bytes.stringByteStringstr[]byteByteStringstringString (ASCII-8BIT)