UNPKG

@avalanche-sdk/client

Version:

A TypeScript SDK for interacting with the Avalanche network through JSON-RPC APIs. This SDK provides a comprehensive set of tools to interact with all Avalanche chains (P-Chain, X-Chain, C-Chain) and various APIs, including wallet functionality for transa

34 lines (29 loc) 862 B
import { RequestErrorType } from "viem/utils"; /** * The parameters for the `avax.getAtomicTx` method. * * @param txID - The ID of the atomic transaction. It should be in cb58 format. * @param encoding - The encoding of the transaction. */ export type GetAtomicTxParameters = { txID: string; encoding?: "hex"; }; /** * The return type for the `avax.getAtomicTx` method. * * @param tx - The atomic transaction. * @param blockHeight - The height of the block which the transaction was included in. * @param encoding - The encoding of the transaction. */ export type GetAtomicTxReturnType = { tx: string; blockHeight: string; encoding: "hex"; }; export type GetAtomicTxErrorType = RequestErrorType; export type GetAtomicTxMethod = { Method: "avax.getAtomicTx"; Parameters: GetAtomicTxParameters; ReturnType: GetAtomicTxReturnType; };