
Company News
Socket Named Top Sales Organization by RepVue
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.
@silo-finance/silo-sdk
Advanced tools
Complete SDK for Silo Finance - a unified package that re-exports all Silo SDK packages.
pnpm add @silo-finance/silo-sdk viem
npm install @silo-finance/silo-sdk viem
import { createPublicClient, http } from "viem";
import { arbitrum } from "viem/chains";
import { SiloSdk, ViemAdapter, percentToDecimal } from "@silo-finance/silo-sdk";
// 1. Create viem client
const publicClient = createPublicClient({ chain: arbitrum, transport: http() });
// 2. Create adapter and SDK
const adapter = new ViemAdapter({ provider: publicClient });
const sdk = new SiloSdk({ chain: "arbitrum", adapter });
// 3. Use namespaced API
const siloAddress = "0x0696e6808ee11a5750733a3d821f9bb847e584fb";
const borrowApr = await sdk.markets.getBorrowAPR(siloAddress);
const borrowApy = sdk.calc.getApy({ apr: borrowApr, periods: 365n });
console.log(`Borrow APY: ${(percentToDecimal(borrowApy) * 100).toFixed(2)}%`);
This package re-exports functionality from all Silo SDK packages:
| Package | Description |
|---|---|
@silo-finance/primitives | Branded types (Amount, Percent, USD), math utilities, formatters |
@silo-finance/address-book | Contract addresses and ABIs for all supported chains |
@silo-finance/core | Pure calculation library - APR, LTV, health factors |
@silo-finance/adapter-common | Abstract adapter interfaces |
@silo-finance/adapter-viem | Viem adapter for blockchain reads/writes |
@silo-finance/indexer | GraphQL client for indexed data |
import {
// SDK class (recommended)
SiloSdk, ViemAdapter,
// Write functions
deposit, withdraw, borrow, repay, approve, approveMax,
// Oracle utilities
fetchQuote, fetchOracleQuotes, fetchQuoteToken,
// Router utilities
fetchRouterPaused,
// Enums
SiloCollateralType, RiskLevel,
} from "@silo-finance/silo-sdk";
// SiloSdk provides namespaced API:
// sdk.markets - getBorrowAPR(), getDepositAPR(), getUtilization(), getLiquidity(), etc.
// sdk.positions - get(), getLtv(), isSolvent(), getBalances(), getData()
// sdk.tokens - getBalance(), getBalances(), getAllowance(), getMetadata()
// sdk.actions - deposit(), withdraw(), borrow(), repay(), approve()
// sdk.calc - getApy(), calculateLtv(), getRiskLevel()
import {
// APR/APY
getApy, getCollateralBaseApr, calculateRewardsApr, calculateLeverageApr,
// LTV analysis
calculateLtv, getMaxBorrowWithBuffer, getMaxWithdrawWithBuffer, getRiskLevel,
} from "@silo-finance/silo-sdk";
import {
// Type constructors
makePercent, makeAmount, makeUSD, makeAddress,
// Formatters
formatPercent, formatAmount, formatUSD,
// Constants
PERCENT_FACTOR, PERCENT_ZERO, PERCENT_ONE,
// Math utilities
abs, min, max, clamp, mulDiv,
} from "@silo-finance/silo-sdk";
import {
// Contract addresses
siloLensAddress, siloRouterV2Address, siloFactoryAddress,
// Chain utilities
chainKeys, chainIds, getChainKeyFromId,
// ABIs
siloAbi, siloLensAbi, erc20Abi,
} from "@silo-finance/silo-sdk";
import {
SiloIndexerClient, createIndexerClient,
} from "@silo-finance/silo-sdk";
While this unified SDK is recommended for most applications, you may want to import individual packages when:
@silo-finance/core + @silo-finance/primitives for pure calculations@silo-finance/adapter-common for other blockchain libraries@silo-finance/indexer for GraphQL-only accessFor detailed documentation of each module, see the individual package READMEs or visit our documentation site.
FAQs
Complete SDK for Silo Finance - aggregates all packages
We found that @silo-finance/silo-sdk demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.

Security News
NIST will stop enriching most CVEs under a new risk-based model, narrowing the NVD's scope as vulnerability submissions continue to surge.

Company News
/Security News
Socket is an initial recipient of OpenAI's Cybersecurity Grant Program, which commits $10M in API credits to defenders securing open source software.