P2P NFT/wNFT trading service
Last updated
Last updated
This is the group of the smart contracts which give the opportunity to sell and buy NFTs and wNFTs ERC721. There are two smart contracts: P2POrderManager.sol and OrderBook721.sol.
The first one responses for the actions, the second one responses for the storing the informations about the orders. There are sell orders and buy offers. The owners of NFTs/wNFTs can create the sell orders only. The buyers can create offers to buy any NFTs/wNFTs. The sell orders can be created with the native and ERC20 tokens as the price. The buy offers can be created with ERC20 tokens as the price only. The sellers of NFTs/wNFTs should give the allowance to P2POrderManager to use them. The buyers of NFTs/wNFTs and creators of the buy offers should give the allowance to P2POrderManager to use their ERC20 tokens to pay.
The method creates the orders.
Input parameters of the method:
Name | Type | Description |
---|---|---|
ET.AssetItem
Name | Type | Description |
---|---|---|
ET.Asset
3 - ERC-721;
ET.Price
The method returns values:
The method emits EnvelopP2PNewOrder event with the follow data:
The method removes the orders.
Input parameters of the method:
The method returns values:
The method emits EnvelopOrderRemoved event with the follow data:
The method marks the orders like closed and run the changing by the assets between the seller and the buyer. If the owner of P2POrderManager smart contract set the fee for the deal this method would charge the fee from the payment asset and make the transfer to fee beneficiary address. If
Input parameters of the method:
The method emits EnvelopP2POrderTaked event with the follow data:
This view method returns the information about all existing orders for the tradable asset.
Input parameters of the method:
The method returns values:
This view method returns the information about all existing orders for the tradable asset.
The method returns values:
The method returns the information about the orders.
Input parameters of the method:
The method returns values:
Name | Type | Type |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|