ERC1155BatchPortal
The ERC1155BatchPortal allows anyone to perform batch transfers of ERC-1155 tokens to a dApp while informing the off-chain machine.
depositBatchERC1155Token()
function depositBatchERC1155Token( IERC1155 token, address appContract, uint256[] calldata tokenIds, uint256[] calldata values, bytes calldata baseLayerData, bytes calldata execLayerData) external;
Transfer a batch of ERC-1155 tokens to a dApp and add an input to the dApp's input box to signal such operation.
The caller must enable approval for the portal to manage all of their tokens
beforehand, by calling the setApprovalForAll function in the token contract.
Please make sure tokenIds and values have the same length.
Parameters
| Name | Type | Description |
|---|---|---|
| token | IERC1155 | The ERC-1155 token contract |
| appContract | address | The address of the dApp |
| tokenIds | uint256[] | The identifiers of the tokens being transferred |
| values | uint256[] | Transfer amounts per token type |
| baseLayerData | bytes | Additional data to be interpreted by the base layer |
| execLayerData | bytes | Additional data to be interpreted by the execution layer |