-
Notifications
You must be signed in to change notification settings - Fork 198
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
EN-9416/new api to get NFT data #2925
Conversation
Co-authored-by: bogdan-rosianu <51945539+bogdan-rosianu@users.noreply.github.com>
Name string `json:"name"` | ||
Creator string `json:"creator"` | ||
Royalties string `json:"royalties"` | ||
Hash []byte `json:"hash"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why Hash
field is not a string?
Ask this question because everywhere on the API we return hash (hash of a block or hash of a transaction, etc) as string hex-encoded.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in case of address codehash is returned as byte array.
return | ||
} | ||
|
||
nonceAsStr := c.Param("nonce") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you make a method here getNonceParam
where you read the nonce parameter and do the cast?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would leave as it is.
@@ -34,12 +34,18 @@ var ErrGetESDTTokens = errors.New("get esdt tokens for account error") | |||
// ErrGetESDTBalance signals an error in getting esdt balance for given address | |||
var ErrGetESDTBalance = errors.New("get esdt balance for account error") | |||
|
|||
// ErrGetESDTNFTData signals an error in getting esdt nft data for given address, tokenID and nonce | |||
var ErrGetESDTNFTData = errors.New("get esdt nft data for account error") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you change please the text of this error? ("cannot get esdt nft data for account" )
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
followed all the error messages from this file
implemented new api to get NFT data