transferBatchEvent

Creates an event object for the TransferBatch event.

Example

import { getContractEvents } from "thirdweb";
import { transferBatchEvent } from "thirdweb/extensions/erc1155";
const events = await getContractEvents({
contract,
events: [
transferBatchEvent({
_operator: ...,
_from: ...,
_to: ...,
})
],
});
function transferBatchEvent(
filters: Partial<{ _from: string; _operator: string; _to: string }>,
readonly inputs: readonly [
{
readonly indexed: true;
readonly name: "_operator";
readonly type: "address";
},
{
readonly indexed: true;
readonly name: "_from";
readonly type: "address";
},
{
readonly indexed: true;
readonly name: "_to";
readonly type: "address";
},
{ readonly name: "tokenIds"; readonly type: "uint256[]" },
{ readonly name: "_values"; readonly type: "uint256[]" },
];
readonly name: "TransferBatch";
readonly type: "event";
}>;

Parameters

Optional filters to apply to the event.

Type

let filters: Partial<{
_from: string;
_operator: string;
_to: string;
}>;

Returns

let returnType: PreparedEvent<{
readonly inputs: readonly [
{
readonly indexed: true;
readonly name: "_operator";
readonly type: "address";
},
{
readonly indexed: true;
readonly name: "_from";
readonly type: "address";
},
{
readonly indexed: true;
readonly name: "_to";
readonly type: "address";
},
{ readonly name: "tokenIds"; readonly type: "uint256[]" },
{ readonly name: "_values"; readonly type: "uint256[]" },
];
readonly name: "TransferBatch";
readonly type: "event";
}>;

The prepared event object.