IListingMarket

Interface for a marketplace where NFTs can be listed for sale, bought, and delisted

Listed

event Listed(address seller, address collection, uint256 tokenId, address erc20, uint256 price)

Emitted when a token is listed for sale.

Delisted

event Delisted(address seller, address collection, uint256 tokenId, address erc20)

Emitted when a token is delisted from sale.

list

function list(address _collection, uint256 _tokenId, address _erc20, uint256 _price) external

Lists an NFT for sale

Parameters

Name
Type
Description

_collection

address

The address of the NFT contract

_tokenId

uint256

The ID of the NFT to list

_erc20

address

The token contract address to be used for payment

_price

uint256

The listing price

permitList

Lists an NFT for sale with permitted signature

Parameters

Name
Type
Description

_collection

address

The address of the collection contract to which the token belongs.

_tokenId

uint256

The ID of the token to be listed for sale.

_erc20

address

The address of the ERC20 token to be used as the payment currency.

_price

uint256

The price for which the token is listed.

_signature

struct Signature

The seller's signature, deadline and address

delist

Delists an NFT from sale

Parameters

Name
Type
Description

_collection

address

The address of the NFT contract

_tokenId

uint256

The ID of the NFT to delist

_erc20

address

The token contract address used for payment

permitDelist

Delists an NFT from sale with permitted signature

Parameters

Name
Type
Description

_collection

address

The address of the collection contract from which the token is to be delisted.

_tokenId

uint256

The ID of the token to be delisted.

_erc20

address

The address of the ERC20 token that was to be used as the payment currency.

_signature

struct Signature

The seller's signature, deadline and address

buy

Buys an NFT listed for sale

Parameters

Name
Type
Description

_collection

address

The address of the collection contract to which the token belongs.

_tokenId

uint256

The ID of the token to be bought.

_erc20

address

The address of the ERC20 token to be used as the payment currency.

permitBuy

Buys an NFT listed for sale with permitted signature

Parameters

Name
Type
Description

_collection

address

The address of the collection contract from which the token is to be bought.

_tokenId

uint256

The ID of the token to be bought.

_erc20

address

The address of the ERC20 token to be used as the payment currency.

_signature

struct Signature

The buyer's signature, deadline and address

permitOffChainPaymentBuy

Buys an NFT listed for sale with off-chain payment and permitted signature

Parameters

Name
Type
Description

_collection

address

The address of the collection contract from which the token is to be bought.

_tokenId

uint256

The ID of the token to be bought.

_erc20

address

The address of the ERC20 token to be used as the payment currency.

_signature

struct Signature

The buyer's signature, deadline and address

getListedPrice

Gets the listed price of an NFT

Parameters

Name
Type
Description

_collection

address

The address of the NFT contract

_tokenId

uint256

The ID of the NFT

_erc20

address

The token contract address used for payment

Return Values

Name
Type
Description

[0]

uint256

The listing price of the NFT

Last updated