import { type BigNumberish, type BytesLike } from 'ethers'; import { type EVMExtraArgsV2, type SVMExtraArgsV1 } from '../extra-args.ts'; /** * BCS codec for decoding EVM extra args on Move chains (Aptos/Sui). * Used when receiving cross-chain messages from EVM source chains. */ export declare const BcsEVMExtraArgsV2Codec: import("@mysten/bcs").BcsStruct<{ gasLimit: import("@mysten/bcs").BcsType; allowOutOfOrderExecution: import("@mysten/bcs").BcsType; }, string>; /** * BCS codec for decoding SVM (Solana) extra args on Move chains (Aptos/Sui). * Used when receiving cross-chain messages from Solana source chains. */ export declare const BcsSVMExtraArgsV1Codec: import("@mysten/bcs").BcsStruct<{ computeUnits: import("@mysten/bcs").BcsType; accountIsWritableBitmap: import("@mysten/bcs").BcsType; allowOutOfOrderExecution: import("@mysten/bcs").BcsType; tokenReceiver: import("@mysten/bcs").BcsType & { length: number; }, string>; accounts: import("@mysten/bcs").BcsType & { length: number; }> & { length: number; }, string>; }, string>; /** * Decodes extra arguments from Move-based chain CCIP messages. * Works for both Aptos and Sui since they share the same BCS encoding. * @param extraArgs - Encoded extra arguments bytes. * @returns Decoded extra arguments or undefined if unknown format. */ export declare function decodeMoveExtraArgs(extraArgs: BytesLike): (EVMExtraArgsV2 & { _tag: 'EVMExtraArgsV2'; }) | (SVMExtraArgsV1 & { _tag: 'SVMExtraArgsV1'; }) | undefined; /** * Converts bytes to a Move-chain address (32-byte zero-padded). * Works for both Aptos and Sui since they share the same address format. * @param bytes - Bytes to convert. * @returns Address as 0x-prefixed hex string, 32 bytes padded. * @throws {@link CCIPDataFormatUnsupportedError} if bytes length exceeds 32 */ export declare function getMoveAddress(bytes: BytesLike | readonly number[]): string; /** * Encodes a numeric value as a 32-byte hex string. * Used for BCS encoding on Move chains (Aptos/Sui). * @param value - Numeric value to encode. * @returns 32-byte hex string representation of the value. */ export declare const encodeNumber: (value: BigNumberish) => string; /** * Encodes dynamic bytes with length prefix for BCS serialization. * Used for BCS encoding on Move chains (Aptos/Sui). * @param value - Bytes to encode. * @returns Encoded bytes with 32-byte aligned padding. */ export declare const encodeRawBytes: (value: BytesLike) => string; //# sourceMappingURL=bcs-codecs.d.ts.map