@interchainjs/types

March 1, 2026 · View on GitHub

Core TypeScript interfaces and types for the InterchainJS ecosystem.

Usage

npm install @interchainjs/types

Core Interfaces

IUniSigner

The universal signer interface that provides consistent signing across all blockchain networks:

interface IUniSigner<
  TTxResp = unknown,
  TAccount extends IAccount = IAccount,
  TSignArgs = unknown,
  TBroadcastOpts = unknown,
  TBroadcastResponse extends IBroadcastResult<TTxResp> = IBroadcastResult<TTxResp>,
  TQueryClient extends IQueryClient = IQueryClient,
> {
  queryClient: TQueryClient;
  getAccounts(): Promise<readonly TAccount[]>;
  signArbitrary(data: Uint8Array, index?: number): Promise<ICryptoBytes>;
  sign(args: TSignArgs): Promise<ISigned<TBroadcastOpts, TBroadcastResponse>>;
  broadcast(signed: ISigned<TBroadcastOpts, TBroadcastResponse>, options?: TBroadcastOpts): Promise<TBroadcastResponse>;
  signAndBroadcast(args: TSignArgs, options?: TBroadcastOpts): Promise<TBroadcastResponse>;
  broadcastArbitrary(data: Uint8Array, options?: TBroadcastOpts): Promise<TBroadcastResponse>;
}

IWallet

Interface for managing cryptographic accounts and signing operations:

interface IWallet {
  getAccounts(): Promise<IAccount[]>;
  getAccountByIndex(index: number): Promise<IAccount>;
  signByIndex(data: Uint8Array, index?: number): Promise<ICryptoBytes>;
}

IAccount

Represents a single cryptographic account:

interface IAccount {
  address: string;
  algo: string;
  getPublicKey(): IPublicKey;
}

HDPath

Utility for generating hierarchical deterministic wallet paths:

class HDPath {
  static cosmos(account?: number, change?: number, addressIndex?: number): HDPath;
  static ethereum(account?: number, change?: number, addressIndex?: number): HDPath;
  toString(): string;
}

Interchain JavaScript Stack ⚛️

A unified toolkit for building applications and smart contracts in the Interchain ecosystem

CategoryToolsDescription
Chain InformationChain Registry, Utils, ClientEverything from token symbols, logos, and IBC denominations for all assets you want to support in your application.
Wallet ConnectorsInterchain Kit, Cosmos KitExperience the convenience of connecting with a variety of web3 wallets through a single, streamlined interface.
Signing ClientsInterchainJS, CosmJSA single, universal signing interface for any network
SDK ClientsTelescopeYour Frontend Companion for Building with TypeScript with Cosmos SDK Modules.
Starter KitsCreate Interchain App, Create Cosmos AppSet up a modern Interchain app by running one command.
UI KitsInterchain UIThe Interchain Design System, empowering developers with a flexible, easy-to-use UI kit.
Testing FrameworksStarshipUnified Testing and Development for the Interchain.
TypeScript Smart ContractsCreate Hyperweb AppBuild and deploy full-stack blockchain applications with TypeScript
CosmWasm ContractsCosmWasm TS CodegenConvert your CosmWasm smart contracts into dev-friendly TypeScript classes.

Credits

🛠 Built by the Constructive team — makers of Hyperweb

Disclaimer

AS DESCRIBED IN THE LICENSES, THE SOFTWARE IS PROVIDED “AS IS”, AT YOUR OWN RISK, AND WITHOUT WARRANTIES OF ANY KIND.

No developer or entity involved in creating this software will be liable for any claims or damages whatsoever associated with your use, inability to use, or your interaction with other users of the code, including any direct, indirect, incidental, special, exemplary, punitive or consequential damages, or loss of profits, cryptocurrencies, tokens, or anything else of value.