TypeScript SDK
Sui Typescript SDK Quick Start

Sui Typescript SDK Quick Start

The Sui Typescript SDK is a modular library of tools for interacting with the Sui blockchain. Use it to send queries to RPC nodes, build and sign transactions, and interact with a Sui or local network.

Installation

npm i -D @mysten/sui.js

Network locations

The following table lists the locations for Sui networks.

NetworkFull nodefaucet
localhttp://127.0.0.1:9000 (default)http://127.0.0.1:9123/gas (default)
Devnethttps://fullnode.devnet.sui.io:443https://faucet.devnet.sui.io/gas
Testnethttps://fullnode.testnet.sui.io:443https://faucet.testnet.sui.io/gas
Mainnethttps://fullnode.mainnet.sui.io:443null

Architecture

The SDK contains a set of modular packages that you can use independently or together. Import just what you need to keep your code light and compact.

  • @mysten/sui.js/client - A client for interacting with Sui RPC nodes.
  • @mysten/sui.js/bcs - A BCS builder with pre-defined types for Sui. nodes.
  • @mysten/sui.js/transaction - Utilities for building and interacting with transactions.
  • @mysten/sui.js/keypairs/* - Modular exports for specific KeyPair implementations.
  • @mysten/sui.js/verify - Methods for verifying transactions and messages.
  • @mysten/sui.js/cryptography - Shared types and classes for cryptography.
  • @mysten/sui.js/multisig - Utilities for working with multisig signatures.
  • @mysten/sui.js/utils - Utilities for formatting and parsing various Sui types.
  • @mysten/sui.js/faucet - Methods for requesting sui from a faucet.