Skip to main content

ERC721Portal

The ERC721Portal allows anyone to perform transfers of ERC-721 tokens to a dApp while informing the off-chain machine.

depositERC721Token

function depositERC721Token(contract IERC721 _token, address _dapp, uint256 _tokenId, bytes _baseLayerData, bytes _execLayerData) external

Transfer an ERC-721 token to a dApp and add an input to the dApp's input box to signal such operation.

The caller must change the approved address for the ERC-721 token to the portal address beforehand, by calling the approve function in the token contract.

Parameters

NameTypeDescription
_tokencontract IERC721The ERC-721 token contract
_dappaddressThe address of the dApp
_tokenIduint256The identifier of the token being transferred
_baseLayerDatabytesAdditional data to be interpreted by the base layer
_execLayerDatabytesAdditional data to be interpreted by the execution layer

On this page

© 2024 Cartesi Foundation Ltd. All rights reserved.

The Cartesi Project is commissioned by the Cartesi Foundation.

We use cookies to ensure that we give you the best experience on our website. By using the website, you agree to the use of cookies.