The smart contract function returns an error.
async function bulkTransfer() {
const transfers = [
{
items: [
{
itemType: 2,
token: "0x030b5a223e86410d038c28dc9dc2d63716784427",
identifier: 1,
amount: 1,
},
{
itemType: 2,
token: "0x030b5a223e86410d038c28dc9dc2d63716784427",
identifier: 2,
amount: 1,
},
],
recipient: "0x9481d8bc76fb1b7d2f95733a6ec0b40d0cb1fffc",
validateERC721Receiver: true,
},
];
let options = {
contractAddress: "0x0000000000c2d145a2526bD8C716263bFeBe1A72",
functionName: "bulkTransfer",
abi: [{
"inputs": [{
"components": [{
"components": [{
"internalType": "enum ConduitItemType",
"name": "itemType",
"type": "uint8"
}, {
"internalType": "address",
"name": "token",
"type": "address"
}, {
"internalType": "uint256",
"name": "identifier",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}],
"internalType": "struct TransferHelperItem[]",
"name": "items",
"type": "tuple[]"
}, {
"internalType": "address",
"name": "recipient",
"type": "address"
}, {
"internalType": "bool",
"name": "validateERC721Receiver",
"type": "bool"
}],
"internalType": "struct TransferHelperItemsWithRecipient[]",
"name": "items",
"type": "tuple[]"
}, {
"internalType": "bytes32",
"name": "conduitKey",
"type": "bytes32"
}],
"name": "bulkTransfer",
"outputs": [{
"internalType": "bytes4",
"name": "magicValue",
"type": "bytes4"
}],
"stateMutability": "nonpayable",
"type": "function"
}],
params:
{
items: transfers,
conduitKey: "0x0000007b02230091a7ed01230072f7006a004d60a8d4e71d599b8104250f0000"
},
}
await Moralis.executeFunction(options)
}
```