powersun-tron-mcp

v1.3.0
io.github.Hovsteder/powersun-tron-mcp Checked 6 hours ago Published 9 months ago

TRON Energy marketplace + DEX swap aggregator for AI agents.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

get_prices Get Current Prices

Get current TRON Energy and Bandwidth minimum prices for all duration tiers. Returns price per unit in SUN for each available duration.

ParameterTypeDescription
resourceTypestringFilter by resource type (default: all)

estimate_cost Estimate Cost

Calculate the cost of purchasing TRON Energy or Bandwidth. Exact resourceAmount takes priority. Derived Bandwidth is an estimate for standard USDT TRC-20 transfers (345 units plus 5%); other transaction templates require an explicit resourceAmount. Minimum order sizes still apply.

ParameterTypeDescription
txCount *integerNumber of transactions
durationMinutesnumberDuration in minutes. Allowed: 2, 5, 10, 15, 30, 60, 180, 360, 1440, 10080, 43200. Default: 60.
resourceAmountintegerExact resource amount; otherwise derived from transaction count.
resourceTypestringResource type (default: ENERGY)
targetAddressstringTRON target address. Required for an executable market quote.
txTypestringTransaction type (default: trc20_transfer). trc20_transfer_new = first-time transfer to an address.

get_available_resources Get Available Resources

Get total available Energy and Bandwidth across all active pools. Shows how much resource can be purchased right now.

ParameterTypeDescription
durationMinutesnumberFilter pools that support this duration
resourceTypestringFilter by resource type (default: both)

get_market_overview Market Overview

Comprehensive market overview: prices, availability, allowed durations, order constraints, and transaction types. Useful for agents to understand what they can purchase.

get_balance Get Balance

Get your current TRX balance and deposit information. Requires API key authentication.

buy_energy Buy Energy

Purchase TRON Energy for a target address. Creates a MARKET order that will be filled by available pools. Deducts cost from your balance.

ParameterTypeDescription
targetAddress *stringTRON address to delegate energy to (T-address format)
txCount *integerNumber of transactions you need energy for
durationMinutesnumberDuration in minutes. Allowed: 2, 5, 10, 15, 30, 60, 180, 360, 1440, 10080, 43200. Default: 60.
resourceTypestringResource type (default: ENERGY)
txTypestringTransaction type (default: trc20_transfer)

broadcast_transaction Broadcast Transaction

Broadcast a pre-signed TRON transaction with auto energy delegation. Send your signed transaction data and PowerSun will delegate energy before broadcasting. Works with API key (balance deduction) or x402 USDC payment. Without authentication, returns cost estimate.

ParameterTypeDescription
txData *objectPre-signed transaction object with txID, raw_data, raw_data_hex, and signature

get_orders Get Orders

Get your order history with optional status filter. Returns recent orders sorted by creation time.

ParameterTypeDescription
limitintegerMaximum number of orders to return (default: 20)
statusstringFilter by order status

get_order_status Get Order Status

Get detailed status of a specific order including delegation progress.

ParameterTypeDescription
orderId *stringOrder ID (UUID format)

get_deposit_info Get Deposit Info

Get the deposit address to top up your account balance with TRX.

get_swap_quote Get Swap Quote

Get a price quote and unsigned transaction for swapping tokens on SunSwap DEX. Returns an unsigned TX for client-side signing. After signing, submit via execute_swap. Requires API key.

ParameterTypeDescription
amountIn *stringAmount to swap in smallest unit (SUN for TRX, base units for tokens)
fromToken *stringToken to sell — symbol (USDT, TRX, SUN, ...) or TRC-20 contract address
toToken *stringToken to buy — symbol or TRC-20 contract address
slippageBpsintegerSlippage tolerance in basis points (default: 50 = 0.5%)

execute_swap Execute Swap

Execute a pre-signed swap transaction with automatic energy delegation. Get the unsigned TX from get_swap_quote, sign it, and submit here. Energy is delegated before broadcast. Works with API key (balance deduction) or x402 USDC payment.

ParameterTypeDescription
txData *objectPre-signed swap transaction from get_swap_quote

get_pool_stats Pool Statistics

Get comprehensive statistics for your energy/bandwidth pools: delegations, revenue, utilization, APY. Requires API key.

get_earnings Get Earnings

Get earnings breakdown by pool: total earned, pending payout, paid out. Optionally filter by date range.

ParameterTypeDescription
endDatestringEnd date (ISO 8601)
startDatestringStart date (ISO 8601, e.g. 2026-01-01)

get_auto_selling_config Auto-Selling Config

Get current auto-selling configuration for your pools. Shows which resources are being sold, duration constraints, and reserves.

configure_auto_selling Configure Auto-Selling

Update auto-selling configuration for a pool. Toggle energy/bandwidth selling, set reserves, duration constraints. Pass the configId from get_auto_selling_config.

ParameterTypeDescription
configId *stringConfiguration ID to update (from get_auto_selling_config)
activebooleanEnable/disable auto-selling
allowRenewalsbooleanAllow order renewals
maxDurationstringMaximum rental duration
minDurationstringMinimum rental duration (e.g., "5min", "1h", "1d")
reservedBandwidthintegerBandwidth to keep reserved (not sold)
reservedEnergyintegerEnergy to keep reserved (not sold)
sellBandwidthbooleanEnable/disable bandwidth selling
sellEnergybooleanEnable/disable energy selling

get_pool_delegations Pool Delegations

Get active delegations from your pools. Shows who received energy/bandwidth and when delegations expire.

ParameterTypeDescription
poolAddressstringFilter by specific pool address. If not provided, shows all your pools.

withdraw_earnings Withdraw Earnings

Withdrawal execution is not available through MCP. Use the withdrawal flow at https://powersun.vip. This tool does not create a withdrawal request or move funds.

ParameterTypeDescription
amount *numberRequested TRX amount (retained for compatibility; MCP does not execute withdrawals)

register_pool Register Selling Pool

Register a TRON address as an energy/bandwidth selling pool on PowerSun. This creates a pool and auto-selling configuration. After registering, you must grant active permissions to the platform address (DelegateResource, UnDelegateResource, VoteWitness) so the platform can delegate resources to buyers and vote on your behalf. Use check_pool_permissions to verify permissions after granting them. Requires API key.

ParameterTypeDescription
paymentAddress *stringTRON address to register as pool (starts with T, 34 characters). This is the address where you hold/stake TRX.
autoVotebooleanAuto-vote for the best Super Representative to earn rewards (default: true)
sellBandwidthbooleanEnable bandwidth selling (default: false)
sellEnergybooleanEnable energy selling (default: true)

get_onchain_status On-Chain Pool Status

Get live blockchain state for your pool: TRX balance, frozen resources (Energy/Bandwidth), voting status, claimable rewards, and delegated resources. Data is fetched directly from TRON blockchain. Requires API key.

ParameterTypeDescription
poolAddressstringPool address to check. If omitted, uses your first registered pool.

check_pool_permissions Check Pool Permissions

Verify that the platform has the required active permissions on your pool address. Required: DelegateResource (to sell energy), UnDelegateResource (to reclaim). Optional: VoteWitness (to vote for SRs and earn rewards). Run this after granting permissions to confirm the platform can operate your pool. Requires API key.

ParameterTypeDescription
poolAddressstringPool address to check. If omitted, uses your first registered pool.

trigger_vote Vote for SR

Vote for the best Super Representative (SR) with the highest APY to earn voting rewards. The platform automatically selects the SR with the best return. Requires VoteWitness permission granted to the platform. Voting rewards accumulate and can be claimed automatically if auto-claim is enabled. Requires API key.

ParameterTypeDescription
poolAddressstringPool address to vote from. If omitted, uses your first registered pool.

get_auto_action_history Auto-Action History

View execution history of automatic actions (stake, vote, claim) for your pool. Shows status (success/failed/skipped), amounts, transaction hashes, and timestamps. Requires API key.

ParameterTypeDescription
actionTypestringFilter by action type
limitintegerNumber of records to return (default: 20, max: 100)
poolAddressstringPool address to get history for. If omitted, uses your first registered pool.

register Register Agent

Start agent registration by providing your TRON address. Returns a challenge string that you must sign with your TRON private key using tronWeb.trx.signMessageV2(). After signing, call verify_registration with the signature to receive your API key. No authentication required.

ParameterTypeDescription
address *stringYour TRON wallet address (T-address format, 34 characters)

verify_registration Verify Registration

Complete agent registration by verifying your signed challenge. Returns an API key and upgrades the current session to authenticated. After verification, all authenticated tools (buy_energy, get_balance, register_pool, etc.) will work in this session without needing to reconnect. No authentication required.

ParameterTypeDescription
address *stringYour TRON wallet address (must match the register call)
challengeId *stringChallenge ID from the register tool
signature *stringSignature from tronWeb.trx.signMessageV2(challenge, privateKey)

build_permission_transaction Build Permission Transaction

Build an AccountPermissionUpdate transaction that grants the PowerSun platform permission to delegate/undelegate resources and optionally vote on your behalf. Returns an unsigned transaction that you must sign with your private key and then broadcast using broadcast_signed_permission_tx. All existing account permissions are preserved. Requires authentication.

ParameterTypeDescription
poolAddress *stringTRON address to grant permissions on (your pool address, T-address format)
includeVotebooleanInclude VoteWitness permission for earning SR rewards (default: true)

broadcast_signed_permission_tx Broadcast Signed Permission Transaction

Broadcast a signed AccountPermissionUpdate transaction to the TRON blockchain. After broadcasting, verifies that the platform permissions were correctly applied. Use this after signing the transaction from build_permission_transaction. Requires authentication.

ParameterTypeDescription
poolAddress *stringThe pool address that the permission was granted on
signedTransaction *objectThe complete signed permission transaction from tronWeb.trx.sign(), including visible, raw_data_hex, and signature