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

Withdraw Assets

How to remove collateral from your Varla account — partial or full withdrawals, and the health factor check.

How Withdrawal Works

Call withdraw(tokenId, amount) on VarlaCore. The contract simulates your post-withdrawal health factor. If it stays ≥ 1.0 (or you have zero debt), the ERC-1155 positions are transferred back to your wallet.

Withdrawal check
remainingCollateral = currentCollateral - withdrawAmount
newHF = weightedValue(remainingCollateral) / currentDebt

if newHF >= 1.0 OR currentDebt == 0:
  ✓ Transfer positions back to borrower
else:
  ✗ Revert — would make position unhealthy

Full vs Partial Withdrawal

  • Full withdrawal — requires zero outstanding debt. Repay everything first, then withdraw all collateral.
  • Partial withdrawal — remove some collateral while maintaining a healthy position. Your health factor must remain ≥ 1.0 after withdrawal.
⚠Oracle must be fresh
Withdrawals require non-stale oracle data. If the oracle is stale (>15 minutes), withdrawals are blocked until fresh prices arrive.

Best Practices

  • Leave a buffer — don't withdraw to exactly HF 1.0. Price movements could immediately trigger liquidation.
  • Repay first — if you want to withdraw significant collateral, reduce debt first to maintain a comfortable health factor.
  • Check oracle freshness — if the oracle is stale, your withdrawal will revert. Wait for fresh data.

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