Skip to main content
The AbstractJS SDK provides a type-safe TypeScript interface for building gas-abstracted, cross-chain applications on the Biconomy stack.

Installation

npm install @biconomy/abstractjs viem

Quick Reference

Core Imports

import {
  // Account
  toMultichainNexusAccount,
  toNexusAccount,
  
  // Client
  createMeeClient,
  
  // Runtime
  runtimeERC20BalanceOf,
  runtimeNativeBalanceOf,
  runtimeERC20AllowanceOf,
  runtimeParamViaCustomStaticCall,
  
  // Constraints
  greaterThanOrEqualTo,
  lessThanOrEqualTo,
  equalTo,
  
  // Conditions
  createCondition,
  ConditionType,
  
  // Sessions
  toSmartSessionsModule,
  meeSessionActions,
  getSudoPolicy,
  getUniversalActionPolicy,
  
  // Utilities
  getMeeScanLink,
  getMEEVersion,
  MEEVersion,
  
  // Types
  type MeeClient,
  type MultichainSmartAccount,
  type Instruction,
  type FeeTokenInfo,
  type Trigger,
} from "@biconomy/abstractjs";

Version Constants

enum MEEVersion {
  V2_1_0 = "2.1.0",
  V2_2_0 = "2.2.0"
}

// Get version config
const version = getMEEVersion(MEEVersion.V2_1_0);

Type Definitions

FeeTokenInfo

type FeeTokenInfo = {
  address: Address;
  chainId: number;
};

Trigger

type Trigger = {
  chainId: number;
  tokenAddress: Address;
  amount: bigint;
};

Instruction

type Instruction = {
  chainId: number;
  calls: Call[];
  // Optional time bounds
  lowerBoundTimestamp?: number;
  upperBoundTimestamp?: number;
};

type Call = {
  to: Address;
  data?: Hex;
  value?: bigint;
};