Skip to content

@ecp.eth/sdk


@ecp.eth/sdk / indexer/webhooks / ChannelUpdatedEvent

Type Alias: ChannelUpdatedEvent

type ChannelUpdatedEvent = {
  blockNumber: bigint;
  chainId: number;
  data: {
     channel: {
        description: string;
        id: bigint;
        metadata: {
           key: `0x${string}`;
           value: `0x${string}`;
        }[];
        name: string;
        updatedAt: Date;
     };
  };
  event: "channel:updated";
  logIndex: number;
  txHash: `0x${string}`;
  uid: string;
  version: 1;
};

Defined in: packages/sdk/src/indexer/webhooks/schemas/channel.ts:131

An event sent to webhook when a channel is updated.

Type declaration

blockNumber

blockNumber: bigint = StringBigintSchema;

Block number. On wire it is a stringified bigint.

chainId

chainId: number;

Chain ID

data

data: {
  channel: {
     description: string;
     id: bigint;
     metadata: {
        key: `0x${string}`;
        value: `0x${string}`;
     }[];
     name: string;
     updatedAt: Date;
  };
};

Data of the event

data.channel

channel: {
  description: string;
  id: bigint;
  metadata: {
     key: `0x${string}`;
     value: `0x${string}`;
  }[];
  name: string;
  updatedAt: Date;
};

Updated channel data

data.channel.description

description: string;

Description of the channel

data.channel.id

id: bigint = StringBigintSchema;

ID of the channel

data.channel.metadata

metadata: {
  key: `0x${string}`;
  value: `0x${string}`;
}[] = MetadataArraySchema;

Metadata of the channel

data.channel.name

name: string;

Name of the channel

data.channel.updatedAt

updatedAt: Date = ISO8601DateSchema;

Updated at date

event

event: "channel:updated";

Event type

logIndex

logIndex: number;

Log index

txHash

txHash: `0x${string}` = HexSchema;

Transaction hash

uid

uid: string;

Unique identifier for the event. You can use it to deduplicate events. In case of retry attempts the id is the same.

version

version: 1;

Version of the event