Skip to content
LogoLogo

Railnet SDK

TypeScript SDK for the Railnet protocol, built on viem. It reads the protocol's contracts and builds the calls that write to them. It sends nothing. Every write is a call you simulate and send with viem or wagmi.

Quick Start

import { ,  } from 'viem'
import {  } from 'viem/chains'
import {  } from '@railnetorg/railnet-sdk'
 
const  = ({
  : ,
  : (),
})
 
const  = await (, {
  : '0x...',
  : '0x...',
})
 
.(.) // shares held
.(.) // equivalent asset value

Packages

ExportContents
@railnetorg/railnet-sdkactions, call builders, ABIs, addresses, types
@railnetorg/railnet-sdk/reacthooks and query options, on wagmi and TanStack Query
@railnetorg/railnet-sdk/stagingaddresses of the staging deployments

The protocol itself is documented at docs.railnet.org.