Skip to main content
Glama
justlend

mcp-server-justlend

Official
by justlend

approve_underlying

Idempotent

Approve the jToken contract to spend your underlying TRC20 tokens, required before supply or repay. Pass exact amount or 'max' for unlimited (user must opt in).

Instructions

Approve the jToken contract to spend your underlying TRC20 tokens. Required before supply() or repay() for TRC20-backed markets (not needed for jTRX). Pass the EXACT amount you intend to use (recommended). Pass amount='max' for unlimited approval ONLY when the user explicitly opts in — it lets the jToken contract spend the user's entire balance, present and future, until revoked. Typical cost: ~23,000 energy + ~265 bandwidth.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
amountYesExact amount to approve (e.g. '100'), or 'max' for unlimited (NOT recommended; user must opt in).
marketYesjToken symbol (e.g. 'jUSDT')
networkNoNetwork. Default: mainnet
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Discloses important behavioral traits: cost (~23k energy + 265 bandwidth), idempotent (safe to call repeatedly), and risk of unlimited approval. Annotations (idempotent=true, destructive=false) are consistent, and description adds significant context beyond them.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Very concise: four sentences covering purpose, prerequisite, amount recommendation with caveat, and cost. No filler; each sentence earns its place. Front-loaded with core action.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no output schema, the description fully covers what an agent needs: prerequisites (TRC20 markets), parameter usage (amount, market, network), edge cases (max approval), and cost. Complete for a transaction tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, but description adds value by explaining the amount parameter's practical meaning (exact vs. max with security warning) and the context of market parameter (jToken symbol). Does not merely repeat schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Clearly states the tool approves jToken contract to spend underlying TRC20 tokens. Specifies when required (before supply/repay for TRC20 markets, not for jTRX), distinguishing it from sibling approve tools like approve_jst_for_voting.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly states when to use (required before supply/repay for TRC20 markets) and when not (jTRX). Provides clear guidance on amount: recommend exact, 'max' only with explicit user opt-in. No ambiguity.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/justlend/mcp-server-justlend'

If you have feedback or need assistance with the MCP directory API, please join our Discord server