increaseAllowance is a method that helps developers to increase allowance from payment method token for the marketplace contract if the paymentToken of marketplace contract is an erc20 token. It is commonly used before buy method in Sale page and bid method in auction page.
Parameter
Argument
Type
Description
tokenAddress
string
one of the payment method token of the presale contract
getAllowance is a method that helps get the allowance amount of a given erc20 contract for marketplace contract to spend. It is commonly used to check allowance of payment contract before increaseAllowance
Approve is a method that helps developers to set approval from any ERC721 contract for the marketplace contract. It is commonly used before createSale and editSale in Sale page and createAuction and editAuction in auction page
getApproved is a method that helps get the approved status of a given erc721 contract for marketplace contract to spend. It is commonly used to check approval of nft contract before approve
Parameter
Argument
Type
Description
contractAddress
string
the token address of the ERC721 contract
tokenId
string
the nftId of the nft under the contractAddress
Response
Property
Type
Description
Promise
boolean
the approved status of the nft which indicates whether the multiSend contract is allowed to transfer this nft
setApproveForAll is a method that helps developers to set approval from ERC1155 contract for marketplace contract. It is commonly used before createSale and editSale in Sale page and createAuction and editAuction in auction page
Parameter
Argument
Type
Description
tokenAddress
string
contract address of erc1155 contract
approve
boolean
boolean indication approval for erc1155 transfer, if true, transfer is allowed
getApprovalForAll is a method that helps get the approved status of a given erc1155 contract for marketplace contract to spend. It is commonly used to check approval of nft token before setApproveForAll
Parameter
Argument
Type
Description
contractAddress
string
the token address of the ERC1155 contract
ownerAddress
string
the wallet address of the owner of the ERC1155 token
Response
Property
Type
Description
Promise
boolean
appoved status of ERC1155 contract which indicates whether the multiSend contract is allowed to transfer all of the ERC1155 tokens under the contract address