Varla
OverviewWhat it is and why it matters.How It WorksLending against prediction markets, step by step.FeaturesLending, borrowing, leverage, and risk management.Supported MarketsPolymarket, Opinion, Kalshi, and more.
DocumentationProtocol docs, guides, and architecture.Smart ContractsPool, Collateral Manager, Oracle, Liquidation Engine.SDK ReferenceTypeScript SDK for protocol interactions.API ReferenceREST and GraphQL endpoints for market data.
BlogLatest news and announcements from Varla.FAQsFrequently asked questions about the protocol.Security & AuditsProtocol security, audits, and trust assumptions.Brand AssetsLogos, colors, and typography guidelines.
Try Varla
Varla
Protocol
OverviewWhat it is and why it matters.
How It WorksLending against prediction markets, step by step.
FeaturesLending, borrowing, leverage, and risk management.
Supported MarketsPolymarket, Opinion, Kalshi, and more.
Developers
DocumentationProtocol docs, guides, and architecture.
Smart ContractsPool, Collateral Manager, Oracle, Liquidation Engine.
SDK ReferenceTypeScript SDK for protocol interactions.
API ReferenceREST and GraphQL endpoints for market data.
Resources
BlogLatest news and announcements from Varla.
FAQsFrequently asked questions about the protocol.
Security & AuditsProtocol security, audits, and trust assumptions.
Brand AssetsLogos, colors, and typography guidelines.
Try Varla

Introduction

Overview
Varla 101

Protocol

Overview
Lending Model
Supply & BorrowInterest RatesReserves
User Positions
Open PositionsSupply AssetsBorrow AssetsWithdraw AssetsRepay Loans
Risk Engine
Health FactorLTV & ThresholdsLiquidationsMarket ResolutionOracle System

Markets

Overview
Polymarket
Opinion
Kalshi
Adapters

Token

Overview
Distribution
Utility & Governance
Varla Gems

Security

Overview
Trust Assumptions
Risk Disclosure
Risk Parameters

Resources

FAQ
Glossary
Links
Brand Assets

Getting Started

Overview
TypeScript SDK
GraphQL API
Smart Contracts

Smart Contracts

Overview
Core Protocol
VarlaPoolVarlaOracleInterest RateLiquidatorsMarket Adapters
Governance & Access
Governance

References

SDK Reference
API Reference

Operations

Testing & Debugging
Contract Addresses

Security

Overview
Trust Assumptions
Risk Disclosure
Risk Parameters

TypeScript SDK

The SDK is the recommended integration surface. It gives you chain-aware addresses, ABIs, and higher-level read helpers.

Install

Install @varla/sdkbash
bun add @varla/sdk

Pick a Chain

Polygon (Polymarket) uses USDC as the collateral token. BSC (Opinion) uses USDT.


Read-Only Example (Pool Snapshot)

Pool snapshotts
import { createPublicClient, http } from "viem";
import { polygon } from "viem/chains";
import * as views from "@varla/sdk/views";
import { getVarlaContracts } from "@varla/sdk";

const client = createPublicClient({ chain: polygon, transport: http() });
const { pool } = getVarlaContracts({ chainId: polygon.id });

const snap = await views.readPoolSnapshot({ client, pool });
console.log(snap.utilizationWad, snap.supplyApyRay);

Borrower Example (Account Snapshot)

Account snapshotts
import * as views from "@varla/sdk/views";
import { getVarlaContracts } from "@varla/sdk";

const { core } = getVarlaContracts({ chainId: polygon.id });
const user = "0xYourAddress";

const a = await views.readAccountSnapshot({ client, core, user });
console.log(a.healthFactor, a.maxBorrow);

Recommended Import Style

Import patternts
import * as views from "@varla/sdk/views";
import * as actions from "@varla/sdk/actions";
import { addresses } from "@varla/sdk/addresses";
💡Next steps
See SDK Reference for the full list of read and write helpers, or Smart Contracts for deployment details.

Menu

  • Overview
  • How it works
  • Features
  • Docs
  • FAQs

Ecosystem

  • Prediction markets
  • Builders
  • Integrations
  • Governance

Company

  • About
  • Terms
  • Privacy
  • Support

©2026 Varla Labs Inc. All rights reserved