{
  "markdown": "# [PowerSun.vip](https://powersun.vip) — TRON Energy & Bandwidth MCP Server + DEX Swap Aggregator\n\n> **The first TRON Energy marketplace and DEX swap aggregator for AI agents.**\n> Buy energy, sell resources, swap tokens on SunSwap DEX, and earn passive income — fully autonomous via MCP, REST API, or HTTP 402.\n> **Only 10% commission** — the lowest on the market.\n\n[![MCP](https://img.shields.io/badge/MCP-Streamable_HTTP-blue)](https://powersun.vip/mcp)\n[![Tools](https://img.shields.io/badge/Tools-27-green)](https://powersun.vip/agents)\n[![OpenAPI](https://img.shields.io/badge/OpenAPI-3.0-orange)](https://powersun.vip/openapi.json)\n[![Commission](https://img.shields.io/badge/Commission-10%25-brightgreen)](https://powersun.vip)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://github.com/Hovsteder/powersun-tron-mcp/blob/main/LICENSE)\n\n<a href=\"https://glama.ai/mcp/servers/Hovsteder/powersun-tron-mcp\">\n  <img width=\"380\" height=\"200\" src=\"https://glama.ai/mcp/servers/Hovsteder/powersun-tron-mcp/badge\" alt=\"PowerSun MCP server\" />\n</a>\n\n**MCP Endpoint:** `https://powersun.vip/mcp`\n**Transport:** Streamable HTTP (remote — no installation required)\n**Auth:** Optional `X-API-Key` header (public tools work without authentication)\n\n---\n\n## About [PowerSun.vip](https://powersun.vip)\n\n[PowerSun.vip](https://powersun.vip) is a full-featured **TRON Energy & Bandwidth marketplace and DEX swap aggregator** where users and AI agents can buy and sell network resources required for TRON transactions, and swap any TRC-20 tokens via SunSwap V2 Smart Router.\n\n### Platform Highlights\n\n- **Only 10% commission** — competitors charge 15–30%. [PowerSun.vip](https://powersun.vip) offers the lowest fees on the market.\n- **Save 20–50%** on TRON transaction fees by renting Energy instead of burning TRX.\n- **DEX Token Swaps** — swap any TRC-20 token pair (TRX, USDT, USDC, USDD, SUN, BTT, WIN, JST, or any contract address) via SunSwap V2 Smart Router with automatic energy delegation.\n- **Instant delegation** — Energy is delegated to your address within seconds after payment.\n- **Flexible durations** — rent from 5 minutes to 30 days, pay only for what you need.\n- **Autonomous selling** — AI agents can register pools, verify permissions, vote for SRs, and earn passive income entirely through MCP.\n- **Human + AI friendly** — full web interface for humans, MCP + REST API + HTTP 402 for agents.\n- **No registration required** — use HTTP 402 pay-per-use or x402 (USDC on Base) without creating an account.\n\n### Why TRON Energy Matters\n\nEvery TRON transaction (USDT transfers, smart contract calls) requires Energy. Without it, TRX tokens are burned as fees. For example, a single USDT transfer burns ~27 TRX (~$7) without Energy. With [PowerSun.vip](https://powersun.vip), the same transfer costs as little as ~$1.\n\n---\n\n## MCP Server — Quick Start\n\n### Connect from Claude Desktop / Cursor / any MCP client\n\n```json\n{\n  \"mcpServers\": {\n    \"powersun\": {\n      \"url\": \"https://powersun.vip/mcp\"\n    }\n  }\n}\n```\n\nThat's it — no API keys, no npm install, no Docker. The server is hosted and always available.\n\n### With authentication (for balance, orders, selling & swaps)\n\n```json\n{\n  \"mcpServers\": {\n    \"powersun\": {\n      \"url\": \"https://powersun.vip/mcp\",\n      \"headers\": {\n        \"X-API-Key\": \"ps_your_api_key_here\"\n      }\n    }\n  }\n}\n```\n\n---\n\n## MCP Tools (27 total)\n\n### Onboarding Tools — 4 tools (self-service registration via MCP)\n\nThese tools let agents register, authenticate, and grant permissions — entirely within a single MCP session. No REST API needed.\n\n| Tool | Description |\n|------|-------------|\n| `register` | Start registration — get a challenge to sign with your TRON wallet |\n| `verify_registration` | Submit wallet signature → get API key, session upgrades automatically |\n| `build_permission_transaction` | Build an unsigned AccountPermissionUpdate tx to grant platform permissions |\n| `broadcast_signed_permission_tx` | Broadcast the signed permission tx and verify on-chain |\n\n> **Returning users:** If the wallet is already registered, `verify_registration` returns the existing API key + account status (pools, permissions, balance).\n\n### Market Tools — 4 tools (public, no auth required)\n\n| Tool | Description |\n|------|-------------|\n| `get_prices` | Current Energy & Bandwidth prices for all duration tiers (5min to 30d) |\n| `estimate_cost` | Calculate exact cost for a specific energy amount and duration |\n| `get_available_resources` | Check available Energy & Bandwidth in the marketplace |\n| `get_market_overview` | Full market snapshot — prices, availability, order stats |\n\n### Buyer Tools — 6 tools (auth recommended)\n\n| Tool | Description |\n|------|-------------|\n| `buy_energy` | Purchase Energy delegation for any TRON address |\n| `get_balance` | Account balance and deposit address |\n| `get_orders` | List your recent orders |\n| `get_order_status` | Detailed order status with delegation progress |\n| `get_deposit_info` | Get deposit address and payment instructions |\n| `broadcast_transaction` | Broadcast a pre-signed TRON transaction with automatic Energy delegation. Works with API key (balance), x402 USDC, or 402 pay-per-use — no registration required. |\n\n### Swap Tools — 2 tools (auth recommended)\n\n| Tool | Description |\n|------|-------------|\n| `get_swap_quote` | Get a swap quote from SunSwap V2 Smart Router — returns expected output, minimum output with slippage, energy cost, and unsigned TX to sign. Supports TRX, USDT, USDC, USDD, SUN, BTT, WIN, JST, or any TRC-20 contract address. |\n| `execute_swap` | Broadcast a pre-signed swap transaction with automatic Energy delegation. Get the unsigned TX from `get_swap_quote`, sign it with your private key, then submit here. Works with API key, x402, or 402. |\n\n> **Swap flow:** `get_swap_quote` → agent signs unsigned TX → `execute_swap` → tokens swapped with energy delegation included.\n\n### Seller Tools — 11 tools (auth required)\n\n#### Pool Management\n| Tool | Description |\n|------|-------------|\n| `register_pool` | Register a TRON address as a selling pool (autonomous onboarding) |\n| `get_pool_stats` | Pool performance and delegation statistics |\n| `get_earnings` | Earnings breakdown and history |\n| `get_auto_selling_config` | Current auto-selling configuration |\n| `configure_auto_selling` | Enable/disable auto-selling with price settings |\n| `get_pool_delegations` | Active delegations from your pool |\n| `withdraw_earnings` | Withdraw earned TRX to your wallet |\n\n#### On-Chain Operations\n| Tool | Description |\n|------|-------------|\n| `get_onchain_status` | Live blockchain state — balance, frozen TRX, energy/bandwidth, votes, claimable rewards |\n| `check_pool_permissions` | Verify platform has required on-chain permissions (delegate, undelegate, vote) |\n| `trigger_vote` | Vote for Super Representative to earn staking rewards |\n| `get_auto_action_history` | View auto-action execution logs (stake, vote, claim) |\n\n---\n\n## Full Autonomous Onboarding\n\nAI agents can go from \"I have a TRON wallet with a private key\" to \"I'm earning passive income\" — in a single MCP session:\n\n### Step 1: Register & Authenticate\n```\nMCP: register { address: \"TMyWallet...\" }\n→ challengeId + challenge text\n\nAgent signs: tronWeb.trx.signMessageV2(challenge, privateKey)\n\nMCP: verify_registration { challengeId, address, signature }\n→ API key + balance + session upgraded\n→ All authenticated tools now work in this session\n```\n\n### Step 2: Grant Permissions\n```\nMCP: build_permission_transaction { poolAddress: \"TMyWallet...\" }\n→ unsigned AccountPermissionUpdate transaction\n→ Grants: DelegateResource(57), UnDelegateResource(58), VoteWitness(4)\n\nAgent signs: tronWeb.trx.sign(unsignedTx, privateKey)\n\nMCP: broadcast_signed_permission_tx { signedTransaction, poolAddress }\n→ txHash + permissions verified on-chain\n```\n\n> **Security:** Agent permissions are limited to delegate, undelegate, and vote only. No access to FreezeBalanceV2 or WithdrawBalance. Staking and reward claiming are managed by the platform automatically.\n\n### Step 3: Register Pool\n```\nMCP: register_pool { paymentAddress: \"TMyWallet...\" }\n→ Pool created, auto-selling enabled\n```\n\n### Step 4: Vote & Monitor\n```\nMCP: trigger_vote → Vote for highest-APY Super Representative\nMCP: get_onchain_status → Balance, frozen TRX, energy, votes, rewards\nMCP: get_earnings → Selling earnings breakdown\nMCP: get_auto_action_history → Auto-action execution logs\n```\n\n---\n\n## Token Swap (SunSwap DEX)\n\nPowerSun integrates with **SunSwap V2 Smart Router** to provide non-custodial token swaps on the TRON network. Energy is automatically delegated for the swap transaction, so you save on gas compared to burning TRX.\n\n### Supported Tokens\n\nTRX, USDT, USDC, USDD, SUN, BTT, WIN, JST — or any TRC-20 contract address.\n\n### Swap via MCP\n\n```\nMCP: get_swap_quote {\n  fromToken: \"TRX\",\n  toToken: \"USDT\",\n  amountIn: \"10000000\",     // 10 TRX in SUN\n  slippageBps: 50,          // 0.5%\n  senderAddress: \"TMyWallet...\"\n}\n→ quote (expected output, minimum output, price impact)\n→ energy (cost, savings vs burn)\n→ unsignedTx (raw transaction to sign)\n\nAgent signs: tronWeb.trx.sign(unsignedTx, privateKey)\n\nMCP: execute_swap { signedTransaction: \"...\" }\n→ txHash + swap result\n```\n\n### Swap via REST API\n\n```bash\ncurl -X POST https://powersun.vip/api/v2/agent/swap \\\n  -H \"X-API-Key: ps_your_key\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n    \"fromToken\": \"TRX\",\n    \"toToken\": \"USDT\",\n    \"amountIn\": \"10000000\",\n    \"slippageBps\": 50,\n    \"senderAddress\": \"TYourAddress...\"\n  }'\n```\n\n---\n\n## Payment Methods\n\n[PowerSun.vip](https://powersun.vip) supports three payment flows — choose what's most convenient:\n\n### 1. API Key + TRX Balance\nRegister a TRON wallet, deposit TRX, buy from balance. Best for repeat usage.\n\n### 2. HTTP 402 Pay-per-use (TRX)\nNo registration needed. Works with all endpoints: buy-energy, broadcast, and swap. Request → receive 402 response with platform deposit address and unique TRX amount → send exact amount to the platform wallet on TRON → poll for completion. Payment is matched by unique amount. Fully autonomous.\n\n### 3. x402 Protocol (USDC on Base)\nNo registration needed. Works with all endpoints: buy-energy, broadcast, and swap. Request → receive 402 with x402 payment requirements → sign EIP-3009 `transferWithAuthorization` → resend with `X-PAYMENT` header → instant settlement. Cross-chain payments powered by [Coinbase x402](https://www.coinbase.com/x402).\n\n---\n\n## REST API\n\nFull REST API available alongside MCP:\n\n| Endpoint | Description |\n|----------|-------------|\n| `POST /api/v2/agent/register` | Start wallet registration |\n| `POST /api/v2/agent/verify` | Verify signature, get API key |\n| `POST /api/v2/agent/estimate` | Estimate cost |\n| `POST /api/v2/agent/buy-energy` | Purchase energy (API key, 402, or x402) |\n| `POST /api/v2/agent/swap` | Get swap quote from SunSwap DEX (returns unsigned TX) |\n| `POST /api/v2/agent/broadcast` | Broadcast signed transaction with auto Energy (API key, 402, or x402) |\n| `GET /api/v2/agent/balance` | Check balance |\n| `GET /api/v2/agent/order/{id}` | Order status |\n| `GET /api/v2/agent/payment-status/{id}` | 402 payment status |\n\n---\n\n## Pricing\n\n### Energy Prices\n\n| Duration | Min Price (SUN/unit) |\n|----------|---------------------|\n| 5 min | 80 |\n| 10 min | 75 |\n| 15 min | 70 |\n| 30 min | 65 |\n| 1 hour | 60 |\n| 6 hours | 57 |\n| 1 day | 55 |\n| 7 days | 52 |\n| 30 days | 50 |\n\nBandwidth prices follow a 10x ratio (e.g. 800 SUN for 5 min, 500 SUN for 30 days).\n\n| | |\n|----------|---------|\n| Commission | **Only 10%** — lowest on the market |\n| Savings | **20–50%** vs TRX burn |\n\n**Available durations:** 5min, 10min, 15min, 30min, 1h, 6h, 1d, 7d, 30d\n\n**Swap energy cost:** When swapping tokens, PowerSun automatically delegates 5-minute Energy for the swap transaction. The energy cost is included in the swap quote — no separate purchase needed.\n\n### Commission Comparison\n\n| Platform | Commission |\n|----------|-----------|\n| **[PowerSun.vip](https://powersun.vip)** | **10%** |\n| Competitor A | 15–20% |\n| Competitor B | 20–30% |\n\n---\n\n## SDKs\n\n| Package | Language | Install | Tools |\n|---------|----------|---------|-------|\n| [@powersun/mcp-client](https://www.npmjs.com/package/@powersun/mcp-client) | TypeScript | `npm i @powersun/mcp-client` | Energy + Swap |\n| [langchain-powersun](https://pypi.org/project/langchain-powersun/) | Python | `pip install langchain-powersun` | 12 LangChain tools |\n| [crewai-powersun](https://pypi.org/project/crewai-powersun/) | Python | `pip install crewai-powersun` | 9 CrewAI tools |\n| [Hovsteder/tron-energy-action](https://github.com/Hovsteder/tron-energy-action) | GitHub Action | `uses: Hovsteder/tron-energy-action@v1` | CI/CD energy rental |\n\n---\n\n## Supported Networks\n\n| Network | Asset | Usage |\n|---------|-------|-------|\n| TRON mainnet | TRX | Native payment + resource delegation + token swaps |\n| Base (EVM) | USDC | x402 payment via Coinbase facilitator |\n\n---\n\n## Use Cases\n\n- **Wallet agents** — Automatically rent Energy before sending USDT/TRX, reducing fees by 20–50%\n- **Trading bots** — Bulk Energy purchases for high-frequency TRON transactions\n- **DEX swap agents** — Swap any TRC-20 token pair on SunSwap DEX with automatic energy delegation and slippage protection\n- **DApp backends** — Provide free transactions to users by delegating Energy\n- **Multi-chain agents** — Pay with USDC on Base, receive Energy on TRON\n- **Autonomous sellers** — Register a pool via MCP, vote for SRs, earn staking + selling rewards with zero manual intervention\n\n---\n\n## Discovery & Documentation\n\n| Resource | URL |\n|----------|-----|\n| Platform | [powersun.vip](https://powersun.vip) |\n| Agent Landing Page | [powersun.vip/agents](https://powersun.vip/agents) |\n| MCP Endpoint | [powersun.vip/mcp](https://powersun.vip/mcp) |\n| OpenAPI Spec | [powersun.vip/openapi.json](https://powersun.vip/openapi.json) |\n| LLM Guide (short) | [powersun.vip/llms.txt](https://powersun.vip/llms.txt) |\n| LLM Guide (full) | [powersun.vip/llms-full.txt](https://powersun.vip/llms-full.txt) |\n| Agent Descriptor | [powersun.vip/.well-known/agents.json](https://powersun.vip/.well-known/agents.json) |\n| AI Plugin Manifest | [powersun.vip/ai-plugin.json](https://powersun.vip/ai-plugin.json) |\n| Full API Docs | [powersun.vip/api-docs](https://powersun.vip/api-docs) |\n| Blog | [powersun.vip/blog](https://powersun.vip/blog) |\n\n---\n\n## Architecture\n\n```\n┌─────────────────────────────────────────────┐\n│              AI Agent / LLM                  │\n│         (Claude, GPT, custom agent)          │\n└──────────┬──────────────┬───────────────────┘\n           │ MCP          │ REST API\n           ▼              ▼\n┌──────────────────────────────────────────────┐\n│            PowerSun.vip Server                │\n│                                              │\n│  ┌─────────┐ ┌──────────┐ ┌──────────────┐  │\n│  │27 MCP   │ │ REST API │ │ HTTP 402     │  │\n│  │Tools    │ │ Endpoints│ │ + x402 USDC  │  │\n│  └────┬────┘ └────┬─────┘ └──────┬───────┘  │\n│       └───────────┴──────────────┘           │\n│                    │                          │\n│       ┌────────────┴────────────┐            │\n│       │    Order Engine +       │            │\n│       │    Pool Management +    │            │\n│       │    SunSwap Router +     │            │\n│       │    Auto-Actions         │            │\n│       └────────────┬────────────┘            │\n└────────────────────┼─────────────────────────┘\n                     │\n        ┌────────────┴────────────┐\n        ▼                         ▼\n   TRON Mainnet              Base (EVM)\n   (Energy + Swaps)       (USDC settlement)\n```\n\n---\n\n## GitHub Topics\n\n`tron` `tron-energy` `tron-bandwidth` `mcp` `mcp-server` `ai-agent` `blockchain` `trx` `usdt` `energy-rental` `bandwidth` `http-402` `x402` `rest-api` `crypto` `defi` `passive-income` `staking` `sunswap` `dex-swap` `token-swap`\n\n---\n\n## Links\n\n- **Platform:** [powersun.vip](https://powersun.vip)\n- **Agent API:** [powersun.vip/agents](https://powersun.vip/agents)\n- **Blog:** [powersun.vip/blog](https://powersun.vip/blog)\n- **API Docs:** [powersun.vip/api-docs](https://powersun.vip/api-docs)\n\n---\n\n## License\n\nMIT License. See [LICENSE](LICENSE) for details.\n\nThe [PowerSun.vip](https://powersun.vip) platform is a hosted service available at [powersun.vip](https://powersun.vip).\n",
  "bytes": 16423,
  "sha": "0be8ab860aee458389ea241c434d578aff3f696a06fec4a43d86ea6b4987e429",
  "repo_slug": "hovsteder/powersun-tron-mcp",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_hovsteder_powersun_tron_mcp_b7206c8f/readme"
}