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.mdSao 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
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
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 yourjlTokenworth more underlyingUSDC. - 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_AMOUNTandMAX_REPAY_AMOUNTthat 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).
Độ 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
Bình luận
- …
Thêm skill từ kho mã này
internet-court
7.0kGiúp agent của bạn thanh toán, thuê hoặc giao dịch an toàn với một agent AI khác hoặc dịch vụ trả phí, và chỉ đến hướng dẫn chuyên sâu phù hợp.
genlayer-erc7710-connector
7.0kGiúp agent của bạn kết nối kết quả đánh giá AI với hệ thống quyền hạn, để một đánh giá xấu có thể hạn chế hoặc hủy quyền của agent.
genlayer-intelligent-contracts
7.0kGiúp agent của bạn xác định quy tắc, bằng chứng và đầu ra của một AI judge kiểm tra xem agent khác có làm đúng nhiệm vụ được ủy quyền hay không.
x402-erc7710
7.0kGiúp agent của bạn trả tiền cho dịch vụ web theo từng yêu cầu, và thiết lập chi tiêu định kỳ nằm trong ngân sách quyền hạn.
Skill tương tự
api-connector-builder
280kGiúp agent của bạn xây dựng kết nối API mới theo đúng mẫu đã có, dùng khi bạn cần thêm một tích hợp mà không tạo cách làm mới.
api-design
280kGiúp agent của bạn thiết kế REST API theo các thực hành tốt nhất, hữu ích để định nghĩa cách API giao tiếp, hiển thị lỗi và tổ chức dữ liệu.
backend-patterns
280kGiúp agent của bạn với các mẫu kiến trúc phía máy chủ và tối ưu cơ sở dữ liệu, hữu ích khi xây dựng hoặc rà soát code chạy trên máy chủ.