Chuyển đến nội dung
Skillpedia
API và máy chủ (backend)7.0k · #13634

jupiter-lend

Skill này làm gì

Skill này bao gồm Jupiter Lend, một giao thức cho vay và đi vay trên Solana với các pool thanh khoản, thị trường cho vay và vault. Nó giải thích thư viện chỉ đọc và thư viện ghi để kiểm tra lãi suất và quản lý vị thế, dành cho lập trình viên xây tính năng cho vay hoặc đi vay.

Khi nào nên dùng

  • ✓Khi bạn muốn liệt kê các vault hoặc kiểm tra lãi suất cho vay trên Jupiter Lend.
  • ✓Khi bạn cần gửi, rút, vay hoặc trả nợ qua Jupiter Lend.
  • ✓Khi bạn muốn kiểm tra các vị thế cho vay và số dư của một người dùng.

Liên kết skill

https://github.com/internet-court/internet-court-skill/blob/main/vendored/jupiter/jupiter-lend/SKILL.md

Sao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.

Cách dùng

Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.

Tin nhắn có sẵn để dán

Hãy dùng skill này để giúp tôi: https://github.com/internet-court/internet-court-skill/blob/main/vendored/jupiter/jupiter-lend/SKILL.md Đọc tệp SKILL.md tại liên kết đó và làm theo hướng dẫn cho việc của tôi.
Bạn muốn AI tự tìm những skill như thế này?Cài MCP Skillpedia miễn phí: chỉ một dòng, và AI sẽ tìm trong 15.000+ skill trước mỗi việc.Cài đặt trong 1 phút →

Ví dụ cách nhờ AI

“Tôi muốn ứng dụng của mình hiển thị các vị thế Jupiter Lend của người dùng và số dư hiện tại của họ.”

5 skill mới mỗi tuần. Đọc chỉ 1 phút.

Cách hoạt động

Agent dùng thư viện chỉ đọc để tra cứu pool, thị trường và vị thế vault, và thư viện ghi cho gửi tiền, rút tiền, vay và trả nợ. Nó giải thích các thuật ngữ của giao thức trước để mã khớp với cách Jupiter Lend hoạt động.

Nội dung kỹ thuật (SKILL.md gốc)

Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.

Jupiter Lend Protocol

Jupiter Lend (powered by Fluid Protocol) is a lending and borrowing protocol on Solana. It offers Liquidity Pools, Lending Markets (jlTokens), and Vaults for leveraged positions.

The protocol uses two main SDKs:

  • @jup-ag/lend-read: Read-only queries for all programs (Liquidity, Lending, Vaults)
  • @jup-ag/lend: Write operations (deposit, withdraw, borrow, repay)

Agent usage

Example prompts you can use to demo Jupiter Lend integrations:

  • Discover all available vaults and list them
  • Fetch all vault positions for a user
  • Deposit collateral and borrow in a single transaction
  • Repay max debt and withdraw max collateral for a position
  • Get user Earn (jlToken) positions and underlying balances
  • Build a flashloan for arbitrage or liquidation
  • Get liquidity rates and APY for a token
  • Create a new vault position (positionId 0), deposit collateral, and borrow

SDK Installation

# For read operations (queries, prices, positions)
npm install @jup-ag/lend-read

# For write operations (transactions)
npm install @jup-ag/lend

1. Key Concepts & Protocol Jargon

Understanding the architecture and terminology of Jupiter Lend will help you build better integrations.

Architecture: The Two-Layer Model

  • Liquidity Layer (Single Orderbook): The foundational layer where all assets reside. It manages token limits, rate curves, and unified liquidity. Users never interact with this directly.
  • Protocol Layer: User-facing modules (Lending and Vaults) that sit on top of the Liquidity Layer and interact with it via Cross-Program Invocations (CPIs).

Terminology

  • jlToken (Jupiter Lend Token): The yield-bearing asset you receive when supplying tokens to the Lending protocol (e.g., jlUSDC). As interest accrues, the exchange rate increases, making your jlToken worth more underlying USDC.
  • Exchange Price: The conversion rate used to translate between "raw" stored amounts and actual token amounts. It continuously increases as interest is earned on supply or accrued on debt.
  • Collateral Factor (CF): The maximum Loan-to-Value (LTV) ratio allowed when opening or managing a position.
  • Liquidation Threshold (LT): The LTV at which a position becomes undercollateralized and eligible for liquidation.
  • Liquidation Max Limit (LML): The absolute maximum LTV limit. If a position's risk ratio exceeds this boundary, it is automatically absorbed by the protocol to protect liquidity providers.
  • Liquidation Penalty: The discount percentage offered to liquidators when they repay debt on behalf of a risky position.
  • Rebalance: An operation that synchronizes the upper protocol layer's accounting (Vaults/Lending) with its actual position on the Liquidity layer. It also syncs the orderbook to account for any active accrued rewards.
  • Tick-based Architecture: The Vaults protocol groups positions into "ticks" based on their risk level (debt-to-collateral ratio). This allows the protocol to efficiently manage risk and process liquidations at scale.
  • Dust Borrow: A tiny residual amount of debt intentionally kept on positions to handle division rounding complexities.
  • Sentinel Values: Constants like MAX_WITHDRAW_AMOUNT and MAX_REPAY_AMOUNT that tell the protocol to dynamically calculate and withdraw/repay the maximum mathematically possible amount for a position.

Amounts and units

All SDK amounts use base units (smallest token unit, e.g. 1_000_000 = 1 USDC for 6 decimals).


2. Jupiter Earn (Lending)

Jupiter Earn allows users to supply assets to earn yield. In return, users receive yield-bearing jlTokens (e.g., jlUSDC).

Lending Module (jlTokens)

Access jlToken (Jupiter Lend token) markets, exchange prices, and user positions.

// Get all jlToken details at once
const allDetails = await client.lending.getAllJlTokenDetails();

// Get user's jlToken balance
const position = await client.lending.getUserPosition(USDC, userPublicKey);

Lending (Earn)

Deposit underlying assets to receive yield-bearing tokens, or withdraw them.

import { getDepositIxs, getWithdrawIxs } from "@jup-ag/lend/earn";
import BN from "bn.js";

// Deposit 1 USDC (base units: 1_000_000 for 6 decimals)
const { ixs: depositIxs } = await getDepositIxs({
  amount: new BN(1_000_000),
  asset: USDC_PUBKEY,
  signer: userPublicKey,
  connection,
});

// Withdraw 0.1 USDC (100_000 base units @ 6 decimals
Câu hỏi thường gặp

Vault trong Jupiter Lend là gì?

Vault cho phép người dùng gửi tài sản thế chấp và vay dựa trên đó, có thể tạo ra các vị thế đòn bẩy.

Tôi có thể kiểm tra vị thế mà không ký gì không?

Có. Thư viện chỉ đọc xử lý các truy vấn, nên không cần ký giao dịch.

Tôi nên cài thư viện nào?

Thư viện chỉ đọc cho truy vấn, và thư viện đầy đủ cho các thao tác ghi như gửi tiền và vay.

Chi tiết

Mô tả gốc của tác giả

Interact with Jupiter Lend Protocol. Read-only SDK (@jup-ag/lend-read) for querying liquidity pools, lending markets (jlTokens), and vaults. Write SDK (@jup-ag/lend) for lending (deposit/withdraw) and vault operations (deposit collateral, borrow, repay, manage positions).

repo: internet-court/internet-court-skill

Độ phổ biến

Sao GitHub
7.0k
Vị trí xếp hạng
#13634
Giấy phép
—
Cập nhật
26/10/2026

Skill này có hữu ích không?

0

Đăng nhập để bình chọn.

Bình luận

  • …

Thêm skill từ kho mã này

Skill tương tự