import { BinaryReader, BinaryWriter } from '../../../../binary.js'; import { type JsonSafe } from '../../../../json-safe.js'; /** PacketStatus specifies the status of a RecvPacketResult. */ export declare enum PacketStatus { /** PACKET_STATUS_UNSPECIFIED - PACKET_STATUS_UNSPECIFIED indicates an unknown packet status. */ PACKET_STATUS_UNSPECIFIED = 0, /** PACKET_STATUS_SUCCESS - PACKET_STATUS_SUCCESS indicates a successful packet receipt. */ PACKET_STATUS_SUCCESS = 1, /** PACKET_STATUS_FAILURE - PACKET_STATUS_FAILURE indicates a failed packet receipt. */ PACKET_STATUS_FAILURE = 2, /** PACKET_STATUS_ASYNC - PACKET_STATUS_ASYNC indicates an async packet receipt. */ PACKET_STATUS_ASYNC = 3, UNRECOGNIZED = -1 } export declare const PacketStatusSDKType: typeof PacketStatus; export declare function packetStatusFromJSON(object: any): PacketStatus; export declare function packetStatusToJSON(object: PacketStatus): string; /** * Packet defines a type that carries data across different chains through IBC * @name Packet * @package ibc.core.channel.v2 * @see proto type: ibc.core.channel.v2.Packet */ export interface Packet { /** * number corresponds to the order of sends and receives, where a Packet * with an earlier sequence number must be sent and received before a Packet * with a later sequence number. */ sequence: bigint; /** * identifies the sending client on the sending chain. */ sourceClient: string; /** * identifies the receiving client on the receiving chain. */ destinationClient: string; /** * timeout timestamp in seconds after which the packet times out. */ timeoutTimestamp: bigint; /** * a list of payloads, each one for a specific application. */ payloads: Payload[]; } export interface PacketProtoMsg { typeUrl: '/ibc.core.channel.v2.Packet'; value: Uint8Array; } /** * Packet defines a type that carries data across different chains through IBC * @name PacketSDKType * @package ibc.core.channel.v2 * @see proto type: ibc.core.channel.v2.Packet */ export interface PacketSDKType { sequence: bigint; source_client: string; destination_client: string; timeout_timestamp: bigint; payloads: PayloadSDKType[]; } /** * Payload contains the source and destination ports and payload for the application (version, encoding, raw bytes) * @name Payload * @package ibc.core.channel.v2 * @see proto type: ibc.core.channel.v2.Payload */ export interface Payload { /** * specifies the source port of the packet. */ sourcePort: string; /** * specifies the destination port of the packet. */ destinationPort: string; /** * version of the specified application. */ version: string; /** * the encoding used for the provided value. */ encoding: string; /** * the raw bytes for the payload. */ value: Uint8Array; } export interface PayloadProtoMsg { typeUrl: '/ibc.core.channel.v2.Payload'; value: Uint8Array; } /** * Payload contains the source and destination ports and payload for the application (version, encoding, raw bytes) * @name PayloadSDKType * @package ibc.core.channel.v2 * @see proto type: ibc.core.channel.v2.Payload */ export interface PayloadSDKType { source_port: string; destination_port: string; version: string; encoding: string; value: Uint8Array; } /** * Acknowledgement contains a list of all ack results associated with a single packet. * In the case of a successful receive, the acknowledgement will contain an app acknowledgement * for each application that received a payload in the same order that the payloads were sent * in the packet. * If the receive is not successful, the acknowledgement will contain a single app acknowledgment * which will be a constant error acknowledgment as defined by the IBC v2 protocol. * @name Acknowledgement * @package ibc.core.channel.v2 * @see proto type: ibc.core.channel.v2.Acknowledgement */ export interface Acknowledgement { appAcknowledgements: Uint8Array[]; } export interface AcknowledgementProtoMsg { typeUrl: '/ibc.core.channel.v2.Acknowledgement'; value: Uint8Array; } /** * Acknowledgement contains a list of all ack results associated with a single packet. * In the case of a successful receive, the acknowledgement will contain an app acknowledgement * for each application that received a payload in the same order that the payloads were sent * in the packet. * If the receive is not successful, the acknowledgement will contain a single app acknowledgment * which will be a constant error acknowledgment as defined by the IBC v2 protocol. * @name AcknowledgementSDKType * @package ibc.core.channel.v2 * @see proto type: ibc.core.channel.v2.Acknowledgement */ export interface AcknowledgementSDKType { app_acknowledgements: Uint8Array[]; } /** * RecvPacketResult speecifies the status of a packet as well as the acknowledgement bytes. * @name RecvPacketResult * @package ibc.core.channel.v2 * @see proto type: ibc.core.channel.v2.RecvPacketResult */ export interface RecvPacketResult { /** * status of the packet */ status: PacketStatus; /** * acknowledgement of the packet */ acknowledgement: Uint8Array; } export interface RecvPacketResultProtoMsg { typeUrl: '/ibc.core.channel.v2.RecvPacketResult'; value: Uint8Array; } /** * RecvPacketResult speecifies the status of a packet as well as the acknowledgement bytes. * @name RecvPacketResultSDKType * @package ibc.core.channel.v2 * @see proto type: ibc.core.channel.v2.RecvPacketResult */ export interface RecvPacketResultSDKType { status: PacketStatus; acknowledgement: Uint8Array; } /** * Packet defines a type that carries data across different chains through IBC * @name Packet * @package ibc.core.channel.v2 * @see proto type: ibc.core.channel.v2.Packet */ export declare const Packet: { typeUrl: "/ibc.core.channel.v2.Packet"; aminoType: "cosmos-sdk/Packet"; is(o: any): o is Packet; isSDK(o: any): o is PacketSDKType; encode(message: Packet, writer?: BinaryWriter): BinaryWriter; decode(input: BinaryReader | Uint8Array, length?: number): Packet; fromJSON(object: any): Packet; toJSON(message: Packet): JsonSafe; fromPartial(object: Partial): Packet; fromProtoMsg(message: PacketProtoMsg): Packet; toProto(message: Packet): Uint8Array; toProtoMsg(message: Packet): PacketProtoMsg; }; /** * Payload contains the source and destination ports and payload for the application (version, encoding, raw bytes) * @name Payload * @package ibc.core.channel.v2 * @see proto type: ibc.core.channel.v2.Payload */ export declare const Payload: { typeUrl: "/ibc.core.channel.v2.Payload"; aminoType: "cosmos-sdk/Payload"; is(o: any): o is Payload; isSDK(o: any): o is PayloadSDKType; encode(message: Payload, writer?: BinaryWriter): BinaryWriter; decode(input: BinaryReader | Uint8Array, length?: number): Payload; fromJSON(object: any): Payload; toJSON(message: Payload): JsonSafe; fromPartial(object: Partial): Payload; fromProtoMsg(message: PayloadProtoMsg): Payload; toProto(message: Payload): Uint8Array; toProtoMsg(message: Payload): PayloadProtoMsg; }; /** * Acknowledgement contains a list of all ack results associated with a single packet. * In the case of a successful receive, the acknowledgement will contain an app acknowledgement * for each application that received a payload in the same order that the payloads were sent * in the packet. * If the receive is not successful, the acknowledgement will contain a single app acknowledgment * which will be a constant error acknowledgment as defined by the IBC v2 protocol. * @name Acknowledgement * @package ibc.core.channel.v2 * @see proto type: ibc.core.channel.v2.Acknowledgement */ export declare const Acknowledgement: { typeUrl: "/ibc.core.channel.v2.Acknowledgement"; aminoType: "cosmos-sdk/Acknowledgement"; is(o: any): o is Acknowledgement; isSDK(o: any): o is AcknowledgementSDKType; encode(message: Acknowledgement, writer?: BinaryWriter): BinaryWriter; decode(input: BinaryReader | Uint8Array, length?: number): Acknowledgement; fromJSON(object: any): Acknowledgement; toJSON(message: Acknowledgement): JsonSafe; fromPartial(object: Partial): Acknowledgement; fromProtoMsg(message: AcknowledgementProtoMsg): Acknowledgement; toProto(message: Acknowledgement): Uint8Array; toProtoMsg(message: Acknowledgement): AcknowledgementProtoMsg; }; /** * RecvPacketResult speecifies the status of a packet as well as the acknowledgement bytes. * @name RecvPacketResult * @package ibc.core.channel.v2 * @see proto type: ibc.core.channel.v2.RecvPacketResult */ export declare const RecvPacketResult: { typeUrl: "/ibc.core.channel.v2.RecvPacketResult"; aminoType: "cosmos-sdk/RecvPacketResult"; is(o: any): o is RecvPacketResult; isSDK(o: any): o is RecvPacketResultSDKType; encode(message: RecvPacketResult, writer?: BinaryWriter): BinaryWriter; decode(input: BinaryReader | Uint8Array, length?: number): RecvPacketResult; fromJSON(object: any): RecvPacketResult; toJSON(message: RecvPacketResult): JsonSafe; fromPartial(object: Partial): RecvPacketResult; fromProtoMsg(message: RecvPacketResultProtoMsg): RecvPacketResult; toProto(message: RecvPacketResult): Uint8Array; toProtoMsg(message: RecvPacketResult): RecvPacketResultProtoMsg; }; //# sourceMappingURL=packet.d.ts.map