github.com/0chain/gosdk@v1.17.11/znft/README.MD (about) 1 <!-- Code generated by gomarkdoc. DO NOT EDIT --> 2 3 # znft 4 5 ```go 6 import "github.com/0chain/gosdk/znft" 7 ``` 8 9 ## Index 10 11 - [Constants](<#constants>) 12 - [Variables](<#variables>) 13 - [func AccountExists\(homedir, address string\) bool](<#AccountExists>) 14 - [func CreateEthClient\(ethereumNodeURL string\) \(\*ethclient.Client, error\)](<#CreateEthClient>) 15 - [func CreateKeyStorage\(homedir, password string\) error](<#CreateKeyStorage>) 16 - [func DeleteAccount\(homedir, address string\) bool](<#DeleteAccount>) 17 - [func GetConfigDir\(\) string](<#GetConfigDir>) 18 - [func ImportAccount\(homedir, mnemonic, password string\) \(string, error\)](<#ImportAccount>) 19 - [func ListStorageAccounts\(homedir string\) \[\]common.Address](<#ListStorageAccounts>) 20 - [func UpdateClientEthereumAddress\(homedir, address string\) \(err error\)](<#UpdateClientEthereumAddress>) 21 - [type Configuration](<#Configuration>) 22 - [type FactoryERC721](<#FactoryERC721>) 23 - [func \(s \*FactoryERC721\) CreateToken\(owner, name, symbol, uri string, max \*big.Int, data \[\]byte\) error](<#FactoryERC721.CreateToken>) 24 - [type FactoryFixed](<#FactoryFixed>) 25 - [func \(s \*FactoryFixed\) CreateToken\(owner, name, symbol, uri string, max, price, batch \*big.Int, calldata \[\]byte\) error](<#FactoryFixed.CreateToken>) 26 - [type FactoryPack](<#FactoryPack>) 27 - [func \(s \*FactoryPack\) CreateToken\(owner, name, symbol, uri string, max, price, batch \*big.Int, calldata \[\]byte\) error](<#FactoryPack.CreateToken>) 28 - [type FactoryRandom](<#FactoryRandom>) 29 - [func \(s \*FactoryRandom\) CreateToken\(owner, name, symbol, uri string, max, price, batch \*big.Int, calldata \[\]byte\) error](<#FactoryRandom.CreateToken>) 30 - [type IFactoryERC721](<#IFactoryERC721>) 31 - [type IFactoryFixed](<#IFactoryFixed>) 32 - [type IFactoryPack](<#IFactoryPack>) 33 - [type IFactoryRandom](<#IFactoryRandom>) 34 - [type IStorageECR721](<#IStorageECR721>) 35 - [type IStorageECR721Fixed](<#IStorageECR721Fixed>) 36 - [type IStorageECR721Pack](<#IStorageECR721Pack>) 37 - [type IStorageECR721Random](<#IStorageECR721Random>) 38 - [type StorageECR721](<#StorageECR721>) 39 - [func \(s \*StorageECR721\) Allocation\(\) \(string, error\)](<#StorageECR721.Allocation>) 40 - [func \(s \*StorageECR721\) Batch\(\) \(\*big.Int, error\)](<#StorageECR721.Batch>) 41 - [func \(s \*StorageECR721\) Max\(\) \(\*big.Int, error\)](<#StorageECR721.Max>) 42 - [func \(s \*StorageECR721\) Mint\(amount \*big.Int\) error](<#StorageECR721.Mint>) 43 - [func \(s \*StorageECR721\) MintOwner\(amount \*big.Int\) error](<#StorageECR721.MintOwner>) 44 - [func \(s \*StorageECR721\) Mintable\(\) \(bool, error\)](<#StorageECR721.Mintable>) 45 - [func \(s \*StorageECR721\) Price\(\) \(\*big.Int, error\)](<#StorageECR721.Price>) 46 - [func \(s \*StorageECR721\) Receiver\(\) \(string, error\)](<#StorageECR721.Receiver>) 47 - [func \(s \*StorageECR721\) Royalty\(\) \(\*big.Int, error\)](<#StorageECR721.Royalty>) 48 - [func \(s \*StorageECR721\) RoyaltyInfo\(tokenId, salePrice \*big.Int\) \(string, \*big.Int, error\)](<#StorageECR721.RoyaltyInfo>) 49 - [func \(s \*StorageECR721\) SetAllocation\(allocation string\) error](<#StorageECR721.SetAllocation>) 50 - [func \(s \*StorageECR721\) SetMintable\(status bool\) error](<#StorageECR721.SetMintable>) 51 - [func \(s \*StorageECR721\) SetReceiver\(receiver string\) error](<#StorageECR721.SetReceiver>) 52 - [func \(s \*StorageECR721\) SetRoyalty\(sum \*big.Int\) error](<#StorageECR721.SetRoyalty>) 53 - [func \(s \*StorageECR721\) SetURI\(uri string\) error](<#StorageECR721.SetURI>) 54 - [func \(s \*StorageECR721\) SetURIFallback\(uri string\) error](<#StorageECR721.SetURIFallback>) 55 - [func \(s \*StorageECR721\) TokenURIFallback\(token \*big.Int\) \(string, error\)](<#StorageECR721.TokenURIFallback>) 56 - [func \(s \*StorageECR721\) Total\(\) \(\*big.Int, error\)](<#StorageECR721.Total>) 57 - [func \(s \*StorageECR721\) Uri\(\) \(string, error\)](<#StorageECR721.Uri>) 58 - [func \(s \*StorageECR721\) UriFallback\(\) \(string, error\)](<#StorageECR721.UriFallback>) 59 - [func \(s \*StorageECR721\) Withdraw\(\) error](<#StorageECR721.Withdraw>) 60 - [type StorageECR721Fixed](<#StorageECR721Fixed>) 61 - [func \(s \*StorageECR721Fixed\) Allocation\(\) \(string, error\)](<#StorageECR721Fixed.Allocation>) 62 - [func \(s \*StorageECR721Fixed\) Batch\(\) \(\*big.Int, error\)](<#StorageECR721Fixed.Batch>) 63 - [func \(s \*StorageECR721Fixed\) Max\(\) \(\*big.Int, error\)](<#StorageECR721Fixed.Max>) 64 - [func \(s \*StorageECR721Fixed\) Mint\(amount \*big.Int\) error](<#StorageECR721Fixed.Mint>) 65 - [func \(s \*StorageECR721Fixed\) MintOwner\(amount \*big.Int\) error](<#StorageECR721Fixed.MintOwner>) 66 - [func \(s \*StorageECR721Fixed\) Mintable\(\) \(bool, error\)](<#StorageECR721Fixed.Mintable>) 67 - [func \(s \*StorageECR721Fixed\) Price\(\) \(\*big.Int, error\)](<#StorageECR721Fixed.Price>) 68 - [func \(s \*StorageECR721Fixed\) Receiver\(\) \(string, error\)](<#StorageECR721Fixed.Receiver>) 69 - [func \(s \*StorageECR721Fixed\) Royalty\(\) \(\*big.Int, error\)](<#StorageECR721Fixed.Royalty>) 70 - [func \(s \*StorageECR721Fixed\) RoyaltyInfo\(tokenId, salePrice \*big.Int\) \(string, \*big.Int, error\)](<#StorageECR721Fixed.RoyaltyInfo>) 71 - [func \(s \*StorageECR721Fixed\) SetAllocation\(allocation string\) error](<#StorageECR721Fixed.SetAllocation>) 72 - [func \(s \*StorageECR721Fixed\) SetMintable\(status bool\) error](<#StorageECR721Fixed.SetMintable>) 73 - [func \(s \*StorageECR721Fixed\) SetReceiver\(receiver string\) error](<#StorageECR721Fixed.SetReceiver>) 74 - [func \(s \*StorageECR721Fixed\) SetRoyalty\(sum \*big.Int\) error](<#StorageECR721Fixed.SetRoyalty>) 75 - [func \(s \*StorageECR721Fixed\) SetURI\(uri string\) error](<#StorageECR721Fixed.SetURI>) 76 - [func \(s \*StorageECR721Fixed\) SetURIFallback\(uri string\) error](<#StorageECR721Fixed.SetURIFallback>) 77 - [func \(s \*StorageECR721Fixed\) TokenURI\(token \*big.Int\) \(string, error\)](<#StorageECR721Fixed.TokenURI>) 78 - [func \(s \*StorageECR721Fixed\) TokenURIFallback\(token \*big.Int\) \(string, error\)](<#StorageECR721Fixed.TokenURIFallback>) 79 - [func \(s \*StorageECR721Fixed\) Total\(\) \(\*big.Int, error\)](<#StorageECR721Fixed.Total>) 80 - [func \(s \*StorageECR721Fixed\) Uri\(\) \(string, error\)](<#StorageECR721Fixed.Uri>) 81 - [func \(s \*StorageECR721Fixed\) UriFallback\(\) \(string, error\)](<#StorageECR721Fixed.UriFallback>) 82 - [func \(s \*StorageECR721Fixed\) Withdraw\(\) error](<#StorageECR721Fixed.Withdraw>) 83 - [type StorageECR721Pack](<#StorageECR721Pack>) 84 - [func \(s \*StorageECR721Pack\) Allocation\(\) \(string, error\)](<#StorageECR721Pack.Allocation>) 85 - [func \(s \*StorageECR721Pack\) Batch\(\) \(\*big.Int, error\)](<#StorageECR721Pack.Batch>) 86 - [func \(s \*StorageECR721Pack\) Max\(\) \(\*big.Int, error\)](<#StorageECR721Pack.Max>) 87 - [func \(s \*StorageECR721Pack\) Mint\(amount \*big.Int\) error](<#StorageECR721Pack.Mint>) 88 - [func \(s \*StorageECR721Pack\) MintOwner\(amount \*big.Int\) error](<#StorageECR721Pack.MintOwner>) 89 - [func \(s \*StorageECR721Pack\) Mintable\(\) \(bool, error\)](<#StorageECR721Pack.Mintable>) 90 - [func \(s \*StorageECR721Pack\) Price\(\) \(\*big.Int, error\)](<#StorageECR721Pack.Price>) 91 - [func \(s \*StorageECR721Pack\) Receiver\(\) \(string, error\)](<#StorageECR721Pack.Receiver>) 92 - [func \(s \*StorageECR721Pack\) Redeem\(tokenId \*big.Int\) error](<#StorageECR721Pack.Redeem>) 93 - [func \(s \*StorageECR721Pack\) Reveal\(tokenId \*big.Int\) error](<#StorageECR721Pack.Reveal>) 94 - [func \(s \*StorageECR721Pack\) Royalty\(\) \(\*big.Int, error\)](<#StorageECR721Pack.Royalty>) 95 - [func \(s \*StorageECR721Pack\) RoyaltyInfo\(tokenId, salePrice \*big.Int\) \(string, \*big.Int, error\)](<#StorageECR721Pack.RoyaltyInfo>) 96 - [func \(s \*StorageECR721Pack\) SetAllocation\(allocation string\) error](<#StorageECR721Pack.SetAllocation>) 97 - [func \(s \*StorageECR721Pack\) SetClosed\(closed string\) error](<#StorageECR721Pack.SetClosed>) 98 - [func \(s \*StorageECR721Pack\) SetMintable\(status bool\) error](<#StorageECR721Pack.SetMintable>) 99 - [func \(s \*StorageECR721Pack\) SetOpened\(opened string\) error](<#StorageECR721Pack.SetOpened>) 100 - [func \(s \*StorageECR721Pack\) SetReceiver\(receiver string\) error](<#StorageECR721Pack.SetReceiver>) 101 - [func \(s \*StorageECR721Pack\) SetRoyalty\(sum \*big.Int\) error](<#StorageECR721Pack.SetRoyalty>) 102 - [func \(s \*StorageECR721Pack\) SetURI\(uri string\) error](<#StorageECR721Pack.SetURI>) 103 - [func \(s \*StorageECR721Pack\) SetURIFallback\(uri string\) error](<#StorageECR721Pack.SetURIFallback>) 104 - [func \(s \*StorageECR721Pack\) TokenURI\(tokenId \*big.Int\) \(string, error\)](<#StorageECR721Pack.TokenURI>) 105 - [func \(s \*StorageECR721Pack\) TokenURIFallback\(tokenId \*big.Int\) \(string, error\)](<#StorageECR721Pack.TokenURIFallback>) 106 - [func \(s \*StorageECR721Pack\) Total\(\) \(\*big.Int, error\)](<#StorageECR721Pack.Total>) 107 - [func \(s \*StorageECR721Pack\) Uri\(\) \(string, error\)](<#StorageECR721Pack.Uri>) 108 - [func \(s \*StorageECR721Pack\) UriFallback\(\) \(string, error\)](<#StorageECR721Pack.UriFallback>) 109 - [func \(s \*StorageECR721Pack\) Withdraw\(\) error](<#StorageECR721Pack.Withdraw>) 110 - [type StorageECR721Random](<#StorageECR721Random>) 111 - [func \(s \*StorageECR721Random\) Mint\(amount \*big.Int\) error](<#StorageECR721Random.Mint>) 112 - [func \(s \*StorageECR721Random\) MintOwner\(amount \*big.Int\) error](<#StorageECR721Random.MintOwner>) 113 - [func \(s \*StorageECR721Random\) Price\(\) \(\*big.Int, error\)](<#StorageECR721Random.Price>) 114 - [func \(s \*StorageECR721Random\) Reveal\(tokens \[\]\*big.Int\) error](<#StorageECR721Random.Reveal>) 115 - [func \(s \*StorageECR721Random\) SetHidden\(hidden string\) error](<#StorageECR721Random.SetHidden>) 116 - [func \(s \*StorageECR721Random\) SetPack\(address common.Address\) error](<#StorageECR721Random.SetPack>) 117 - [func \(s \*StorageECR721Random\) SetRevealable\(status bool\) error](<#StorageECR721Random.SetRevealable>) 118 - [func \(s \*StorageECR721Random\) TokenURI\(token \*big.Int\) \(string, error\)](<#StorageECR721Random.TokenURI>) 119 - [func \(s \*StorageECR721Random\) TokenURIFallback\(token \*big.Int\) \(string, error\)](<#StorageECR721Random.TokenURIFallback>) 120 - [type Znft](<#Znft>) 121 - [func NewNFTApplication\(c \*Configuration\) \*Znft](<#NewNFTApplication>) 122 - [func \(app \*Znft\) CreateFactoryERC721FixedSession\(ctx context.Context, addr string\) \(IFactoryFixed, error\)](<#Znft.CreateFactoryERC721FixedSession>) 123 - [func \(app \*Znft\) CreateFactoryERC721PackSession\(ctx context.Context, addr string\) \(IFactoryPack, error\)](<#Znft.CreateFactoryERC721PackSession>) 124 - [func \(app \*Znft\) CreateFactoryERC721RandomSession\(ctx context.Context, addr string\) \(IFactoryRandom, error\)](<#Znft.CreateFactoryERC721RandomSession>) 125 - [func \(app \*Znft\) CreateFactoryERC721Session\(ctx context.Context, addr string\) \(IFactoryERC721, error\)](<#Znft.CreateFactoryERC721Session>) 126 - [func \(app \*Znft\) CreateStorageERC721FixedSession\(ctx context.Context, addr string\) \(IStorageECR721Fixed, error\)](<#Znft.CreateStorageERC721FixedSession>) 127 - [func \(app \*Znft\) CreateStorageERC721PackSession\(ctx context.Context, addr string\) \(IStorageECR721Pack, error\)](<#Znft.CreateStorageERC721PackSession>) 128 - [func \(app \*Znft\) CreateStorageERC721RandomSession\(ctx context.Context, addr string\) \(IStorageECR721Random, error\)](<#Znft.CreateStorageERC721RandomSession>) 129 - [func \(app \*Znft\) CreateStorageERC721Session\(ctx context.Context, addr string\) \(IStorageECR721, error\)](<#Znft.CreateStorageERC721Session>) 130 131 132 ## Constants 133 134 <a name="ContractStorageERC721Name"></a> 135 136 ```go 137 const ( 138 ContractStorageERC721Name = "StorageERC721" 139 ContractStorageERC721FixedName = "StorageERC721Fixed" 140 ContractStorageERC721PackName = "StorageERC721Pack" 141 ContractStorageERC721RandomName = "StorageERC721Random" 142 Withdraw = "withdraw" 143 SetReceiver = "setReceiver" 144 SetRoyalty = "setRoyalty" 145 SetMintable = "setMintable" 146 SetAllocation = "setAllocation" 147 SetURI = "setURI" 148 TokenURIFallback = "tokenURIFallback" 149 TokenURI = "tokenURI" 150 Price = "price" 151 Mint = "mint" 152 MintOwner = "mintOwner" 153 RoyaltyInfo = "royaltyInfo" 154 ) 155 ``` 156 157 <a name="ConfigFile"></a> 158 159 ```go 160 const ( 161 ConfigFile = "config.yaml" 162 WalletDir = "wallets" 163 ) 164 ``` 165 166 ## Variables 167 168 <a name="Logger"></a> 169 170 ```go 171 var Logger logger.Logger 172 ``` 173 174 <a name="AccountExists"></a> 175 ## func [AccountExists](<https://github.com/0chain/gosdk/blob/doc/initial/znft/keystore.go#L49>) 176 177 ```go 178 func AccountExists(homedir, address string) bool 179 ``` 180 181 AccountExists checks if account exists 182 183 <a name="CreateEthClient"></a> 184 ## func [CreateEthClient](<https://github.com/0chain/gosdk/blob/doc/initial/znft/ethereum_wallet.go#L18>) 185 186 ```go 187 func CreateEthClient(ethereumNodeURL string) (*ethclient.Client, error) 188 ``` 189 190 191 192 <a name="CreateKeyStorage"></a> 193 ## func [CreateKeyStorage](<https://github.com/0chain/gosdk/blob/doc/initial/znft/keystore.go#L70>) 194 195 ```go 196 func CreateKeyStorage(homedir, password string) error 197 ``` 198 199 CreateKeyStorage create, restore or unlock key storage 200 201 <a name="DeleteAccount"></a> 202 ## func [DeleteAccount](<https://github.com/0chain/gosdk/blob/doc/initial/znft/keystore.go#L25>) 203 204 ```go 205 func DeleteAccount(homedir, address string) bool 206 ``` 207 208 DeleteAccount deletes account from wallet 209 210 <a name="GetConfigDir"></a> 211 ## func [GetConfigDir](<https://github.com/0chain/gosdk/blob/doc/initial/znft/znft.go#L58>) 212 213 ```go 214 func GetConfigDir() string 215 ``` 216 217 218 219 <a name="ImportAccount"></a> 220 ## func [ImportAccount](<https://github.com/0chain/gosdk/blob/doc/initial/znft/keystore.go#L109>) 221 222 ```go 223 func ImportAccount(homedir, mnemonic, password string) (string, error) 224 ``` 225 226 ImportAccount imports account using mnemonic password is used to lock and unlock keystorage before signing transaction 227 228 <a name="ListStorageAccounts"></a> 229 ## func [ListStorageAccounts](<https://github.com/0chain/gosdk/blob/doc/initial/znft/keystore.go#L17>) 230 231 ```go 232 func ListStorageAccounts(homedir string) []common.Address 233 ``` 234 235 ListStorageAccounts List available accounts 236 237 <a name="UpdateClientEthereumAddress"></a> 238 ## func [UpdateClientEthereumAddress](<https://github.com/0chain/gosdk/blob/doc/initial/znft/keystore.go#L83>) 239 240 ```go 241 func UpdateClientEthereumAddress(homedir, address string) (err error) 242 ``` 243 244 UpdateClientEthereumAddress updates Ethereum address 245 246 <a name="Configuration"></a> 247 ## type [Configuration](<https://github.com/0chain/gosdk/blob/doc/initial/znft/znft.go#L33-L44>) 248 249 250 251 ```go 252 type Configuration struct { 253 FactoryAddress string // FactoryAddress address 254 FactoryModuleERC721Address string // FactoryModuleERC721Address address 255 FactoryModuleERC721PackedAddress string // FactoryModuleERC721PackedAddress address 256 FactoryModuleERC721FixedAddress string // FactoryModuleERC721FixedAddress address 257 FactoryModuleERC721RandomAddress string // FactoryModuleERC721RandomAddress address 258 EthereumNodeURL string // EthereumNodeURL URL of ethereum RPC node (infura or alchemy) 259 WalletAddress string // WalletAddress client address 260 VaultPassword string // VaultPassword used to sign transactions on behalf of the client 261 Homedir string // Homedir is a client config folder 262 Value int64 // Value to execute Ethereum smart contracts (default = 0) 263 } 264 ``` 265 266 <a name="FactoryERC721"></a> 267 ## type [FactoryERC721](<https://github.com/0chain/gosdk/blob/doc/initial/znft/factoryerc721.go#L31-L34>) 268 269 270 271 ```go 272 type FactoryERC721 struct { 273 // contains filtered or unexported fields 274 } 275 ``` 276 277 <a name="FactoryERC721.CreateToken"></a> 278 ### func \(\*FactoryERC721\) [CreateToken](<https://github.com/0chain/gosdk/blob/doc/initial/znft/factoryerc721.go#L36>) 279 280 ```go 281 func (s *FactoryERC721) CreateToken(owner, name, symbol, uri string, max *big.Int, data []byte) error 282 ``` 283 284 285 286 <a name="FactoryFixed"></a> 287 ## type [FactoryFixed](<https://github.com/0chain/gosdk/blob/doc/initial/znft/factoryerc721fixed.go#L30-L33>) 288 289 290 291 ```go 292 type FactoryFixed struct { 293 // contains filtered or unexported fields 294 } 295 ``` 296 297 <a name="FactoryFixed.CreateToken"></a> 298 ### func \(\*FactoryFixed\) [CreateToken](<https://github.com/0chain/gosdk/blob/doc/initial/znft/factoryerc721fixed.go#L35>) 299 300 ```go 301 func (s *FactoryFixed) CreateToken(owner, name, symbol, uri string, max, price, batch *big.Int, calldata []byte) error 302 ``` 303 304 305 306 <a name="FactoryPack"></a> 307 ## type [FactoryPack](<https://github.com/0chain/gosdk/blob/doc/initial/znft/factoryerc721pack.go#L30-L33>) 308 309 310 311 ```go 312 type FactoryPack struct { 313 // contains filtered or unexported fields 314 } 315 ``` 316 317 <a name="FactoryPack.CreateToken"></a> 318 ### func \(\*FactoryPack\) [CreateToken](<https://github.com/0chain/gosdk/blob/doc/initial/znft/factoryerc721pack.go#L35>) 319 320 ```go 321 func (s *FactoryPack) CreateToken(owner, name, symbol, uri string, max, price, batch *big.Int, calldata []byte) error 322 ``` 323 324 325 326 <a name="FactoryRandom"></a> 327 ## type [FactoryRandom](<https://github.com/0chain/gosdk/blob/doc/initial/znft/factoryerc721random.go#L30-L33>) 328 329 330 331 ```go 332 type FactoryRandom struct { 333 // contains filtered or unexported fields 334 } 335 ``` 336 337 <a name="FactoryRandom.CreateToken"></a> 338 ### func \(\*FactoryRandom\) [CreateToken](<https://github.com/0chain/gosdk/blob/doc/initial/znft/factoryerc721random.go#L35>) 339 340 ```go 341 func (s *FactoryRandom) CreateToken(owner, name, symbol, uri string, max, price, batch *big.Int, calldata []byte) error 342 ``` 343 344 345 346 <a name="IFactoryERC721"></a> 347 ## type [IFactoryERC721](<https://github.com/0chain/gosdk/blob/doc/initial/znft/factoryerc721.go#L27-L29>) 348 349 350 351 ```go 352 type IFactoryERC721 interface { 353 CreateToken(owner, name, symbol, uri string, max *big.Int, data []byte) error 354 } 355 ``` 356 357 <a name="IFactoryFixed"></a> 358 ## type [IFactoryFixed](<https://github.com/0chain/gosdk/blob/doc/initial/znft/factoryerc721fixed.go#L26-L28>) 359 360 361 362 ```go 363 type IFactoryFixed interface { 364 CreateToken(owner, name, symbol, uri string, max, price, batch *big.Int, calldata []byte) error 365 } 366 ``` 367 368 <a name="IFactoryPack"></a> 369 ## type [IFactoryPack](<https://github.com/0chain/gosdk/blob/doc/initial/znft/factoryerc721pack.go#L26-L28>) 370 371 372 373 ```go 374 type IFactoryPack interface { 375 CreateToken(owner, name, symbol, uri string, max, price, batch *big.Int, calldata []byte) error 376 } 377 ``` 378 379 <a name="IFactoryRandom"></a> 380 ## type [IFactoryRandom](<https://github.com/0chain/gosdk/blob/doc/initial/znft/factoryerc721random.go#L26-L28>) 381 382 383 384 ```go 385 type IFactoryRandom interface { 386 CreateToken(owner, name, symbol, uri string, max, price, batch *big.Int, calldata []byte) error 387 } 388 ``` 389 390 <a name="IStorageECR721"></a> 391 ## type [IStorageECR721](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L58-L80>) 392 393 394 395 ```go 396 type IStorageECR721 interface { 397 Withdraw() error 398 SetReceiver(receiver string) error 399 SetRoyalty(sum *big.Int) error 400 SetMintable(status bool) error 401 SetAllocation(allocation string) error 402 SetURI(uri string) error 403 SetURIFallback(uri string) error 404 TokenURIFallback(token *big.Int) (string, error) 405 Price() (*big.Int, error) 406 Mint(amount *big.Int) error 407 MintOwner(amount *big.Int) error 408 RoyaltyInfo(tokenId, salePrice *big.Int) (string, *big.Int, error) 409 Max() (*big.Int, error) // Fields 410 Total() (*big.Int, error) 411 Batch() (*big.Int, error) 412 Mintable() (bool, error) 413 Allocation() (string, error) 414 Uri() (string, error) 415 UriFallback() (string, error) 416 Royalty() (*big.Int, error) 417 Receiver() (string, error) 418 } 419 ``` 420 421 <a name="IStorageECR721Fixed"></a> 422 ## type [IStorageECR721Fixed](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L17-L19>) 423 424 425 426 ```go 427 type IStorageECR721Fixed interface { 428 IStorageECR721 429 } 430 ``` 431 432 <a name="IStorageECR721Pack"></a> 433 ## type [IStorageECR721Pack](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L23-L33>) 434 435 436 437 ```go 438 type IStorageECR721Pack interface { 439 IStorageECR721Fixed 440 MintOwner(amount *big.Int) error 441 Mint(amount *big.Int) error 442 Reveal(tokenId *big.Int) error 443 Redeem(tokenId *big.Int) error 444 TokenURI(tokenId *big.Int) (string, error) 445 TokenURIFallback(tokenId *big.Int) (string, error) 446 SetClosed(closed string) error 447 SetOpened(opened string) error 448 } 449 ``` 450 451 <a name="IStorageECR721Random"></a> 452 ## type [IStorageECR721Random](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721random.go#L24-L34>) 453 454 455 456 ```go 457 type IStorageECR721Random interface { 458 MintOwner(amount *big.Int) error 459 Mint(amount *big.Int) error 460 Reveal(tokens []*big.Int) error 461 TokenURI(token *big.Int) (string, error) 462 TokenURIFallback(token *big.Int) (string, error) 463 SetHidden(hidden string) error 464 SetPack(address common.Address) error 465 SetRevealable(status bool) error 466 Price() (*big.Int, error) 467 } 468 ``` 469 470 <a name="StorageECR721"></a> 471 ## type [StorageECR721](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L86-L89>) 472 473 474 475 ```go 476 type StorageECR721 struct { 477 // contains filtered or unexported fields 478 } 479 ``` 480 481 <a name="StorageECR721.Allocation"></a> 482 ### func \(\*StorageECR721\) [Allocation](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L137>) 483 484 ```go 485 func (s *StorageECR721) Allocation() (string, error) 486 ``` 487 488 489 490 <a name="StorageECR721.Batch"></a> 491 ### func \(\*StorageECR721\) [Batch](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L115>) 492 493 ```go 494 func (s *StorageECR721) Batch() (*big.Int, error) 495 ``` 496 497 498 499 <a name="StorageECR721.Max"></a> 500 ### func \(\*StorageECR721\) [Max](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L192>) 501 502 ```go 503 func (s *StorageECR721) Max() (*big.Int, error) 504 ``` 505 506 507 508 <a name="StorageECR721.Mint"></a> 509 ### func \(\*StorageECR721\) [Mint](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L203>) 510 511 ```go 512 func (s *StorageECR721) Mint(amount *big.Int) error 513 ``` 514 515 516 517 <a name="StorageECR721.MintOwner"></a> 518 ### func \(\*StorageECR721\) [MintOwner](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L227>) 519 520 ```go 521 func (s *StorageECR721) MintOwner(amount *big.Int) error 522 ``` 523 524 525 526 <a name="StorageECR721.Mintable"></a> 527 ### func \(\*StorageECR721\) [Mintable](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L126>) 528 529 ```go 530 func (s *StorageECR721) Mintable() (bool, error) 531 ``` 532 533 534 535 <a name="StorageECR721.Price"></a> 536 ### func \(\*StorageECR721\) [Price](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L252>) 537 538 ```go 539 func (s *StorageECR721) Price() (*big.Int, error) 540 ``` 541 542 Price returns price 543 544 <a name="StorageECR721.Receiver"></a> 545 ### func \(\*StorageECR721\) [Receiver](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L181>) 546 547 ```go 548 func (s *StorageECR721) Receiver() (string, error) 549 ``` 550 551 552 553 <a name="StorageECR721.Royalty"></a> 554 ### func \(\*StorageECR721\) [Royalty](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L170>) 555 556 ```go 557 func (s *StorageECR721) Royalty() (*big.Int, error) 558 ``` 559 560 561 562 <a name="StorageECR721.RoyaltyInfo"></a> 563 ### func \(\*StorageECR721\) [RoyaltyInfo](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L216>) 564 565 ```go 566 func (s *StorageECR721) RoyaltyInfo(tokenId, salePrice *big.Int) (string, *big.Int, error) 567 ``` 568 569 570 571 <a name="StorageECR721.SetAllocation"></a> 572 ### func \(\*StorageECR721\) [SetAllocation](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L278>) 573 574 ```go 575 func (s *StorageECR721) SetAllocation(allocation string) error 576 ``` 577 578 SetAllocation updates allocation 579 580 <a name="StorageECR721.SetMintable"></a> 581 ### func \(\*StorageECR721\) [SetMintable](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L292>) 582 583 ```go 584 func (s *StorageECR721) SetMintable(status bool) error 585 ``` 586 587 SetMintable updates mintable state 588 589 <a name="StorageECR721.SetReceiver"></a> 590 ### func \(\*StorageECR721\) [SetReceiver](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L320>) 591 592 ```go 593 func (s *StorageECR721) SetReceiver(receiver string) error 594 ``` 595 596 SetReceiver eth balance from token contract \- setReceiver\(address receiver_\) 597 598 <a name="StorageECR721.SetRoyalty"></a> 599 ### func \(\*StorageECR721\) [SetRoyalty](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L306>) 600 601 ```go 602 func (s *StorageECR721) SetRoyalty(sum *big.Int) error 603 ``` 604 605 SetRoyalty eth balance from token contract \- setReceiver\(address receiver_\) 606 607 <a name="StorageECR721.SetURI"></a> 608 ### func \(\*StorageECR721\) [SetURI](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L264>) 609 610 ```go 611 func (s *StorageECR721) SetURI(uri string) error 612 ``` 613 614 SetURI updates uri 615 616 <a name="StorageECR721.SetURIFallback"></a> 617 ### func \(\*StorageECR721\) [SetURIFallback](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L91>) 618 619 ```go 620 func (s *StorageECR721) SetURIFallback(uri string) error 621 ``` 622 623 624 625 <a name="StorageECR721.TokenURIFallback"></a> 626 ### func \(\*StorageECR721\) [TokenURIFallback](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L240>) 627 628 ```go 629 func (s *StorageECR721) TokenURIFallback(token *big.Int) (string, error) 630 ``` 631 632 633 634 <a name="StorageECR721.Total"></a> 635 ### func \(\*StorageECR721\) [Total](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L104>) 636 637 ```go 638 func (s *StorageECR721) Total() (*big.Int, error) 639 ``` 640 641 642 643 <a name="StorageECR721.Uri"></a> 644 ### func \(\*StorageECR721\) [Uri](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L148>) 645 646 ```go 647 func (s *StorageECR721) Uri() (string, error) 648 ``` 649 650 651 652 <a name="StorageECR721.UriFallback"></a> 653 ### func \(\*StorageECR721\) [UriFallback](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L159>) 654 655 ```go 656 func (s *StorageECR721) UriFallback() (string, error) 657 ``` 658 659 660 661 <a name="StorageECR721.Withdraw"></a> 662 ### func \(\*StorageECR721\) [Withdraw](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721.go#L336>) 663 664 ```go 665 func (s *StorageECR721) Withdraw() error 666 ``` 667 668 Withdraw eth balance from token contract \- withdraw\(\) 669 670 <a name="StorageECR721Fixed"></a> 671 ## type [StorageECR721Fixed](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L25-L28>) 672 673 674 675 ```go 676 type StorageECR721Fixed struct { 677 // contains filtered or unexported fields 678 } 679 ``` 680 681 <a name="StorageECR721Fixed.Allocation"></a> 682 ### func \(\*StorageECR721Fixed\) [Allocation](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L76>) 683 684 ```go 685 func (s *StorageECR721Fixed) Allocation() (string, error) 686 ``` 687 688 689 690 <a name="StorageECR721Fixed.Batch"></a> 691 ### func \(\*StorageECR721Fixed\) [Batch](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L54>) 692 693 ```go 694 func (s *StorageECR721Fixed) Batch() (*big.Int, error) 695 ``` 696 697 698 699 <a name="StorageECR721Fixed.Max"></a> 700 ### func \(\*StorageECR721Fixed\) [Max](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L131>) 701 702 ```go 703 func (s *StorageECR721Fixed) Max() (*big.Int, error) 704 ``` 705 706 707 708 <a name="StorageECR721Fixed.Mint"></a> 709 ### func \(\*StorageECR721Fixed\) [Mint](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L142>) 710 711 ```go 712 func (s *StorageECR721Fixed) Mint(amount *big.Int) error 713 ``` 714 715 716 717 <a name="StorageECR721Fixed.MintOwner"></a> 718 ### func \(\*StorageECR721Fixed\) [MintOwner](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L166>) 719 720 ```go 721 func (s *StorageECR721Fixed) MintOwner(amount *big.Int) error 722 ``` 723 724 725 726 <a name="StorageECR721Fixed.Mintable"></a> 727 ### func \(\*StorageECR721Fixed\) [Mintable](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L65>) 728 729 ```go 730 func (s *StorageECR721Fixed) Mintable() (bool, error) 731 ``` 732 733 734 735 <a name="StorageECR721Fixed.Price"></a> 736 ### func \(\*StorageECR721Fixed\) [Price](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L202>) 737 738 ```go 739 func (s *StorageECR721Fixed) Price() (*big.Int, error) 740 ``` 741 742 Price returns price 743 744 <a name="StorageECR721Fixed.Receiver"></a> 745 ### func \(\*StorageECR721Fixed\) [Receiver](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L120>) 746 747 ```go 748 func (s *StorageECR721Fixed) Receiver() (string, error) 749 ``` 750 751 752 753 <a name="StorageECR721Fixed.Royalty"></a> 754 ### func \(\*StorageECR721Fixed\) [Royalty](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L109>) 755 756 ```go 757 func (s *StorageECR721Fixed) Royalty() (*big.Int, error) 758 ``` 759 760 761 762 <a name="StorageECR721Fixed.RoyaltyInfo"></a> 763 ### func \(\*StorageECR721Fixed\) [RoyaltyInfo](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L155>) 764 765 ```go 766 func (s *StorageECR721Fixed) RoyaltyInfo(tokenId, salePrice *big.Int) (string, *big.Int, error) 767 ``` 768 769 770 771 <a name="StorageECR721Fixed.SetAllocation"></a> 772 ### func \(\*StorageECR721Fixed\) [SetAllocation](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L228>) 773 774 ```go 775 func (s *StorageECR721Fixed) SetAllocation(allocation string) error 776 ``` 777 778 SetAllocation updates allocation 779 780 <a name="StorageECR721Fixed.SetMintable"></a> 781 ### func \(\*StorageECR721Fixed\) [SetMintable](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L242>) 782 783 ```go 784 func (s *StorageECR721Fixed) SetMintable(status bool) error 785 ``` 786 787 SetMintable updates mintable state 788 789 <a name="StorageECR721Fixed.SetReceiver"></a> 790 ### func \(\*StorageECR721Fixed\) [SetReceiver](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L270>) 791 792 ```go 793 func (s *StorageECR721Fixed) SetReceiver(receiver string) error 794 ``` 795 796 SetReceiver eth balance from token contract \- setReceiver\(address receiver_\) 797 798 <a name="StorageECR721Fixed.SetRoyalty"></a> 799 ### func \(\*StorageECR721Fixed\) [SetRoyalty](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L256>) 800 801 ```go 802 func (s *StorageECR721Fixed) SetRoyalty(sum *big.Int) error 803 ``` 804 805 SetRoyalty eth balance from token contract \- setReceiver\(address receiver_\) 806 807 <a name="StorageECR721Fixed.SetURI"></a> 808 ### func \(\*StorageECR721Fixed\) [SetURI](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L214>) 809 810 ```go 811 func (s *StorageECR721Fixed) SetURI(uri string) error 812 ``` 813 814 SetURI updates uri 815 816 <a name="StorageECR721Fixed.SetURIFallback"></a> 817 ### func \(\*StorageECR721Fixed\) [SetURIFallback](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L30>) 818 819 ```go 820 func (s *StorageECR721Fixed) SetURIFallback(uri string) error 821 ``` 822 823 824 825 <a name="StorageECR721Fixed.TokenURI"></a> 826 ### func \(\*StorageECR721Fixed\) [TokenURI](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L179>) 827 828 ```go 829 func (s *StorageECR721Fixed) TokenURI(token *big.Int) (string, error) 830 ``` 831 832 833 834 <a name="StorageECR721Fixed.TokenURIFallback"></a> 835 ### func \(\*StorageECR721Fixed\) [TokenURIFallback](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L190>) 836 837 ```go 838 func (s *StorageECR721Fixed) TokenURIFallback(token *big.Int) (string, error) 839 ``` 840 841 842 843 <a name="StorageECR721Fixed.Total"></a> 844 ### func \(\*StorageECR721Fixed\) [Total](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L43>) 845 846 ```go 847 func (s *StorageECR721Fixed) Total() (*big.Int, error) 848 ``` 849 850 851 852 <a name="StorageECR721Fixed.Uri"></a> 853 ### func \(\*StorageECR721Fixed\) [Uri](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L87>) 854 855 ```go 856 func (s *StorageECR721Fixed) Uri() (string, error) 857 ``` 858 859 860 861 <a name="StorageECR721Fixed.UriFallback"></a> 862 ### func \(\*StorageECR721Fixed\) [UriFallback](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L98>) 863 864 ```go 865 func (s *StorageECR721Fixed) UriFallback() (string, error) 866 ``` 867 868 869 870 <a name="StorageECR721Fixed.Withdraw"></a> 871 ### func \(\*StorageECR721Fixed\) [Withdraw](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721fixed.go#L286>) 872 873 ```go 874 func (s *StorageECR721Fixed) Withdraw() error 875 ``` 876 877 Withdraw eth balance from token contract \- withdraw\(\) 878 879 <a name="StorageECR721Pack"></a> 880 ## type [StorageECR721Pack](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L39-L42>) 881 882 883 884 ```go 885 type StorageECR721Pack struct { 886 // contains filtered or unexported fields 887 } 888 ``` 889 890 <a name="StorageECR721Pack.Allocation"></a> 891 ### func \(\*StorageECR721Pack\) [Allocation](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L203>) 892 893 ```go 894 func (s *StorageECR721Pack) Allocation() (string, error) 895 ``` 896 897 898 899 <a name="StorageECR721Pack.Batch"></a> 900 ### func \(\*StorageECR721Pack\) [Batch](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L181>) 901 902 ```go 903 func (s *StorageECR721Pack) Batch() (*big.Int, error) 904 ``` 905 906 907 908 <a name="StorageECR721Pack.Max"></a> 909 ### func \(\*StorageECR721Pack\) [Max](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L159>) 910 911 ```go 912 func (s *StorageECR721Pack) Max() (*big.Int, error) 913 ``` 914 915 916 917 <a name="StorageECR721Pack.Mint"></a> 918 ### func \(\*StorageECR721Pack\) [Mint](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L269>) 919 920 ```go 921 func (s *StorageECR721Pack) Mint(amount *big.Int) error 922 ``` 923 924 925 926 <a name="StorageECR721Pack.MintOwner"></a> 927 ### func \(\*StorageECR721Pack\) [MintOwner](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L258>) 928 929 ```go 930 func (s *StorageECR721Pack) MintOwner(amount *big.Int) error 931 ``` 932 933 934 935 <a name="StorageECR721Pack.Mintable"></a> 936 ### func \(\*StorageECR721Pack\) [Mintable](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L192>) 937 938 ```go 939 func (s *StorageECR721Pack) Mintable() (bool, error) 940 ``` 941 942 943 944 <a name="StorageECR721Pack.Price"></a> 945 ### func \(\*StorageECR721Pack\) [Price](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L137>) 946 947 ```go 948 func (s *StorageECR721Pack) Price() (*big.Int, error) 949 ``` 950 951 952 953 <a name="StorageECR721Pack.Receiver"></a> 954 ### func \(\*StorageECR721Pack\) [Receiver](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L247>) 955 956 ```go 957 func (s *StorageECR721Pack) Receiver() (string, error) 958 ``` 959 960 961 962 <a name="StorageECR721Pack.Redeem"></a> 963 ### func \(\*StorageECR721Pack\) [Redeem](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L280>) 964 965 ```go 966 func (s *StorageECR721Pack) Redeem(tokenId *big.Int) error 967 ``` 968 969 970 971 <a name="StorageECR721Pack.Reveal"></a> 972 ### func \(\*StorageECR721Pack\) [Reveal](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L291>) 973 974 ```go 975 func (s *StorageECR721Pack) Reveal(tokenId *big.Int) error 976 ``` 977 978 979 980 <a name="StorageECR721Pack.Royalty"></a> 981 ### func \(\*StorageECR721Pack\) [Royalty](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L236>) 982 983 ```go 984 func (s *StorageECR721Pack) Royalty() (*big.Int, error) 985 ``` 986 987 988 989 <a name="StorageECR721Pack.RoyaltyInfo"></a> 990 ### func \(\*StorageECR721Pack\) [RoyaltyInfo](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L148>) 991 992 ```go 993 func (s *StorageECR721Pack) RoyaltyInfo(tokenId, salePrice *big.Int) (string, *big.Int, error) 994 ``` 995 996 997 998 <a name="StorageECR721Pack.SetAllocation"></a> 999 ### func \(\*StorageECR721Pack\) [SetAllocation](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L111>) 1000 1001 ```go 1002 func (s *StorageECR721Pack) SetAllocation(allocation string) error 1003 ``` 1004 1005 1006 1007 <a name="StorageECR721Pack.SetClosed"></a> 1008 ### func \(\*StorageECR721Pack\) [SetClosed](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L324>) 1009 1010 ```go 1011 func (s *StorageECR721Pack) SetClosed(closed string) error 1012 ``` 1013 1014 1015 1016 <a name="StorageECR721Pack.SetMintable"></a> 1017 ### func \(\*StorageECR721Pack\) [SetMintable](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L98>) 1018 1019 ```go 1020 func (s *StorageECR721Pack) SetMintable(status bool) error 1021 ``` 1022 1023 1024 1025 <a name="StorageECR721Pack.SetOpened"></a> 1026 ### func \(\*StorageECR721Pack\) [SetOpened](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L335>) 1027 1028 ```go 1029 func (s *StorageECR721Pack) SetOpened(opened string) error 1030 ``` 1031 1032 1033 1034 <a name="StorageECR721Pack.SetReceiver"></a> 1035 ### func \(\*StorageECR721Pack\) [SetReceiver](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L70>) 1036 1037 ```go 1038 func (s *StorageECR721Pack) SetReceiver(receiver string) error 1039 ``` 1040 1041 1042 1043 <a name="StorageECR721Pack.SetRoyalty"></a> 1044 ### func \(\*StorageECR721Pack\) [SetRoyalty](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L85>) 1045 1046 ```go 1047 func (s *StorageECR721Pack) SetRoyalty(sum *big.Int) error 1048 ``` 1049 1050 1051 1052 <a name="StorageECR721Pack.SetURI"></a> 1053 ### func \(\*StorageECR721Pack\) [SetURI](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L124>) 1054 1055 ```go 1056 func (s *StorageECR721Pack) SetURI(uri string) error 1057 ``` 1058 1059 1060 1061 <a name="StorageECR721Pack.SetURIFallback"></a> 1062 ### func \(\*StorageECR721Pack\) [SetURIFallback](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L44>) 1063 1064 ```go 1065 func (s *StorageECR721Pack) SetURIFallback(uri string) error 1066 ``` 1067 1068 1069 1070 <a name="StorageECR721Pack.TokenURI"></a> 1071 ### func \(\*StorageECR721Pack\) [TokenURI](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L302>) 1072 1073 ```go 1074 func (s *StorageECR721Pack) TokenURI(tokenId *big.Int) (string, error) 1075 ``` 1076 1077 1078 1079 <a name="StorageECR721Pack.TokenURIFallback"></a> 1080 ### func \(\*StorageECR721Pack\) [TokenURIFallback](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L313>) 1081 1082 ```go 1083 func (s *StorageECR721Pack) TokenURIFallback(tokenId *big.Int) (string, error) 1084 ``` 1085 1086 1087 1088 <a name="StorageECR721Pack.Total"></a> 1089 ### func \(\*StorageECR721Pack\) [Total](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L170>) 1090 1091 ```go 1092 func (s *StorageECR721Pack) Total() (*big.Int, error) 1093 ``` 1094 1095 1096 1097 <a name="StorageECR721Pack.Uri"></a> 1098 ### func \(\*StorageECR721Pack\) [Uri](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L214>) 1099 1100 ```go 1101 func (s *StorageECR721Pack) Uri() (string, error) 1102 ``` 1103 1104 1105 1106 <a name="StorageECR721Pack.UriFallback"></a> 1107 ### func \(\*StorageECR721Pack\) [UriFallback](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L225>) 1108 1109 ```go 1110 func (s *StorageECR721Pack) UriFallback() (string, error) 1111 ``` 1112 1113 1114 1115 <a name="StorageECR721Pack.Withdraw"></a> 1116 ### func \(\*StorageECR721Pack\) [Withdraw](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721pack.go#L57>) 1117 1118 ```go 1119 func (s *StorageECR721Pack) Withdraw() error 1120 ``` 1121 1122 1123 1124 <a name="StorageECR721Random"></a> 1125 ## type [StorageECR721Random](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721random.go#L40-L43>) 1126 1127 1128 1129 ```go 1130 type StorageECR721Random struct { 1131 // contains filtered or unexported fields 1132 } 1133 ``` 1134 1135 <a name="StorageECR721Random.Mint"></a> 1136 ### func \(\*StorageECR721Random\) [Mint](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721random.go#L58>) 1137 1138 ```go 1139 func (s *StorageECR721Random) Mint(amount *big.Int) error 1140 ``` 1141 1142 1143 1144 <a name="StorageECR721Random.MintOwner"></a> 1145 ### func \(\*StorageECR721Random\) [MintOwner](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721random.go#L45>) 1146 1147 ```go 1148 func (s *StorageECR721Random) MintOwner(amount *big.Int) error 1149 ``` 1150 1151 1152 1153 <a name="StorageECR721Random.Price"></a> 1154 ### func \(\*StorageECR721Random\) [Price](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721random.go#L145>) 1155 1156 ```go 1157 func (s *StorageECR721Random) Price() (*big.Int, error) 1158 ``` 1159 1160 1161 1162 <a name="StorageECR721Random.Reveal"></a> 1163 ### func \(\*StorageECR721Random\) [Reveal](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721random.go#L71>) 1164 1165 ```go 1166 func (s *StorageECR721Random) Reveal(tokens []*big.Int) error 1167 ``` 1168 1169 1170 1171 <a name="StorageECR721Random.SetHidden"></a> 1172 ### func \(\*StorageECR721Random\) [SetHidden](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721random.go#L106>) 1173 1174 ```go 1175 func (s *StorageECR721Random) SetHidden(hidden string) error 1176 ``` 1177 1178 1179 1180 <a name="StorageECR721Random.SetPack"></a> 1181 ### func \(\*StorageECR721Random\) [SetPack](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721random.go#L119>) 1182 1183 ```go 1184 func (s *StorageECR721Random) SetPack(address common.Address) error 1185 ``` 1186 1187 1188 1189 <a name="StorageECR721Random.SetRevealable"></a> 1190 ### func \(\*StorageECR721Random\) [SetRevealable](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721random.go#L132>) 1191 1192 ```go 1193 func (s *StorageECR721Random) SetRevealable(status bool) error 1194 ``` 1195 1196 1197 1198 <a name="StorageECR721Random.TokenURI"></a> 1199 ### func \(\*StorageECR721Random\) [TokenURI](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721random.go#L84>) 1200 1201 ```go 1202 func (s *StorageECR721Random) TokenURI(token *big.Int) (string, error) 1203 ``` 1204 1205 1206 1207 <a name="StorageECR721Random.TokenURIFallback"></a> 1208 ### func \(\*StorageECR721Random\) [TokenURIFallback](<https://github.com/0chain/gosdk/blob/doc/initial/znft/storageerc721random.go#L95>) 1209 1210 ```go 1211 func (s *StorageECR721Random) TokenURIFallback(token *big.Int) (string, error) 1212 ``` 1213 1214 1215 1216 <a name="Znft"></a> 1217 ## type [Znft](<https://github.com/0chain/gosdk/blob/doc/initial/znft/znft.go#L46-L48>) 1218 1219 1220 1221 ```go 1222 type Znft struct { 1223 // contains filtered or unexported fields 1224 } 1225 ``` 1226 1227 <a name="NewNFTApplication"></a> 1228 ### func [NewNFTApplication](<https://github.com/0chain/gosdk/blob/doc/initial/znft/znft.go#L54>) 1229 1230 ```go 1231 func NewNFTApplication(c *Configuration) *Znft 1232 ``` 1233 1234 1235 1236 <a name="Znft.CreateFactoryERC721FixedSession"></a> 1237 ### func \(\*Znft\) [CreateFactoryERC721FixedSession](<https://github.com/0chain/gosdk/blob/doc/initial/znft/znft.go#L263>) 1238 1239 ```go 1240 func (app *Znft) CreateFactoryERC721FixedSession(ctx context.Context, addr string) (IFactoryFixed, error) 1241 ``` 1242 1243 1244 1245 <a name="Znft.CreateFactoryERC721PackSession"></a> 1246 ### func \(\*Znft\) [CreateFactoryERC721PackSession](<https://github.com/0chain/gosdk/blob/doc/initial/znft/znft.go#L239>) 1247 1248 ```go 1249 func (app *Znft) CreateFactoryERC721PackSession(ctx context.Context, addr string) (IFactoryPack, error) 1250 ``` 1251 1252 1253 1254 <a name="Znft.CreateFactoryERC721RandomSession"></a> 1255 ### func \(\*Znft\) [CreateFactoryERC721RandomSession](<https://github.com/0chain/gosdk/blob/doc/initial/znft/znft.go#L287>) 1256 1257 ```go 1258 func (app *Znft) CreateFactoryERC721RandomSession(ctx context.Context, addr string) (IFactoryRandom, error) 1259 ``` 1260 1261 1262 1263 <a name="Znft.CreateFactoryERC721Session"></a> 1264 ### func \(\*Znft\) [CreateFactoryERC721Session](<https://github.com/0chain/gosdk/blob/doc/initial/znft/znft.go#L215>) 1265 1266 ```go 1267 func (app *Znft) CreateFactoryERC721Session(ctx context.Context, addr string) (IFactoryERC721, error) 1268 ``` 1269 1270 1271 1272 <a name="Znft.CreateStorageERC721FixedSession"></a> 1273 ### func \(\*Znft\) [CreateStorageERC721FixedSession](<https://github.com/0chain/gosdk/blob/doc/initial/znft/znft.go#L361>) 1274 1275 ```go 1276 func (app *Znft) CreateStorageERC721FixedSession(ctx context.Context, addr string) (IStorageECR721Fixed, error) 1277 ``` 1278 1279 1280 1281 <a name="Znft.CreateStorageERC721PackSession"></a> 1282 ### func \(\*Znft\) [CreateStorageERC721PackSession](<https://github.com/0chain/gosdk/blob/doc/initial/znft/znft.go#L313>) 1283 1284 ```go 1285 func (app *Znft) CreateStorageERC721PackSession(ctx context.Context, addr string) (IStorageECR721Pack, error) 1286 ``` 1287 1288 1289 1290 <a name="Znft.CreateStorageERC721RandomSession"></a> 1291 ### func \(\*Znft\) [CreateStorageERC721RandomSession](<https://github.com/0chain/gosdk/blob/doc/initial/znft/znft.go#L337>) 1292 1293 ```go 1294 func (app *Znft) CreateStorageERC721RandomSession(ctx context.Context, addr string) (IStorageECR721Random, error) 1295 ``` 1296 1297 1298 1299 <a name="Znft.CreateStorageERC721Session"></a> 1300 ### func \(\*Znft\) [CreateStorageERC721Session](<https://github.com/0chain/gosdk/blob/doc/initial/znft/znft.go#L385>) 1301 1302 ```go 1303 func (app *Znft) CreateStorageERC721Session(ctx context.Context, addr string) (IStorageECR721, error) 1304 ``` 1305 1306 1307 1308 Generated by [gomarkdoc](<https://github.com/princjef/gomarkdoc>)