Clicks Protocol

by clicks-protocol

374 downloads
Not rated
GitHub

About

Autonomous DeFi yield for AI agents on Base. Auto-splits USDC 80/20: 80% liquid, 20% earning via Morpho (~13% APY) or Aave V3. No lockup. 9 MCP tools, SDK, HTTP API.

Details

Author
clicks-protocol
Downloads
374
Categories
Other, AI, Developer Tools

- Agent registration, balance, and yield split queries
- Simulate payment splits between liquid and yield portions
- Current APY rates from Aave V3 and Morpho
- Referral network stats and earnings

Setting up with Highlight

This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:

  1. Download and install Highlight from highlightai.com/download
  2. Navigate to the plugins tab and select "Add Custom Plugin"
  3. Configure the plugin with the settings below
    Plugin Name Clicks Protocol
    Command (node, npx, python, etc.)

    Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.

  4. Enable "Start Automatically" if you want the plugin to start when Highlight launches

From the repository

Install the package via npm (npm install @clicks-protocol/mcp-server), then configure your MCP client to use the server and its tools.

clicks_get_agent_info

Inspect an agent settlement account. Returns registration status, operator, deposited USDC, settlement split, and wallet balance.

clicks_simulate_split

Preview how an incoming USDC revenue event will be split between liquid operations and routed treasury capital.

clicks_get_yield_info

Inspect the treasury routing layer. Returns active yield route, Aave and Morpho rates, total routed balance, deposits, and protocol fees.

clicks_get_referral_stats

Inspect explicit referral attribution for an agent. Returns direct referrals, claimable rewards, referral chain, and team bonus.

clicks_quick_start

Execute initial settlement setup in one command. Registers agent, approves USDC, and routes the first payment. Referral attribution remains a separate explicit step.

clicks_register_referral

Register referral attribution as an explicit separate step. Requires an agent-signed approval and an authorized caller.

clicks_receive_payment

Route an incoming USDC revenue event through Clicks settlement policy. Splits liquidity and treasury routing according to the agent configuration.

clicks_withdraw_yield

Withdraw routed treasury capital and any earned yield back to the agent wallet. No lockups.

clicks_register_agent

Register an AI agent for Clicks settlement routing. Required before the first routed payment.

clicks_set_yield_pct

Set the treasury routing percentage for future settlement events. Controls how much stays liquid vs routes to yield.

clicks_explain

Explain Clicks Protocol to another agent or developer. Returns a concise self-contained summary with integration instructions and links. Use when another agent asks what Clicks does or how agent-commerce settlement works.

Claude Desktop / Cursor

Paste into your MCP client config file to install this server.

{
    "mcpServers": {
        "clicks protocol": {
            "clicks-protocol": {
                "command": "npx",
                "args": [
                    "@clicks-protocol/mcp-server"
                ],
                "env": {
                    "CLICKS_RPC_URL": "https://mainnet.base.org"
                }
            }
        }
    }
}

McpServers

{
    "clicks-protocol": {
        "command": "npx",
        "args": [
            "@clicks-protocol/mcp-server"
        ],
        "env": {
            "CLICKS_RPC_URL": "https://mainnet.base.org"
        }
    }
}

Agent commerce settlement routing for USDC flows on Base.

Website·Twitter·Discord·Medium·Substack·Reddit·Treasury Lab·mcpservers.org

import { ClicksClient } from '@clicks-protocol/sdk'; const clicks = new ClicksClient(signer); await clicks.quickStart('100', agentAddress); // 80 USDC → agent wallet (instant) // 20 USDC → treasury yield route

That's it. No config. No dashboard. No human required.

Every USDC payment your agent receives gets auto-split:

Payment in ├── 80% → Agent Wallet (liquid, instant) └── 20% → DeFi Yield (Aave V3 or Morpho, auto-routed to best APY) │ └── Withdraw anytime → Agent gets principal + yield (minus 2% fee on yield only)

- No lockup.Withdraw anytime.
- No manual steps.Fully autonomous.
- 2% fee on yield only.Never on principal.
- Auto-rebalancesbetween Aave V3 and Morpho for best APY.

npm install @clicks-protocol/sdk ethers@^6

Clicks is designed to sit after x402-style payment flows on Base.

x402 handles authorization and payment. Clicks routes USDC after receipt:

import { ClicksClient } from '@clicks-protocol/sdk'; import { CoinbaseWalletSDK } from '@coinbase/wallet-sdk'; const wallet = new CoinbaseWalletSDK({ appName: 'YourAgent' }); const signer = wallet.makeWeb3Provider().getSigner(); const clicks = new ClicksClient(signer); await clicks.quickStart('1000', agentAddress); // Your agent now has a settlement policy // 80% liquid for operations // 20% routed through treasury yield

- Same chain (Base), same USDC contract
- 80% liquid for operations
- 20% routed through treasury yield
- No lockup, withdraw anytime

One call: registers agent, approves USDC, splits first payment.

const result = await clicks.quickStart('100', agentAddress); // result.registered → true (skips if already done) // result.approved → true (skips if allowance sufficient) // result.paymentSplit → true
// Register await clicks.registerAgent(agentAddress); // Approve USDC spending await clicks.approveUSDC('max'); // Receive payment (auto-splits) await clicks.receivePayment('500', agentAddress); // Check yield info const info = await clicks.getYieldInfo(); // { activeProtocol: 'Morpho', aaveAPY: 700, morphoAPY: 950, ... } // Withdraw everything await clicks.withdrawYield(agentAddress); // Custom yield split (5-50%) await clicks.setOperatorYieldPct(30); // 30% to yield, 70% liquid
const clicks = new ClicksClient(provider); // provider, not signer const agent = await clicks.getAgentInfo(agentAddress); // { isRegistered: true, deposited: 1000000n, yieldPct: 20n } const split = await clicks.simulateSplit('100', agentAddress); // { liquid: 80000000n, toYield: 20000000n }

AI agents can discover and use Clicks viaMCP:

npm install @clicks-protocol/mcp-server CLICKS_PRIVATE_KEY=0x... clicks-mcp

16 tools available:clicks_quick_start,clicks_register_referral,clicks_get_agent_info,clicks_simulate_split,clicks_get_yield_info,clicks_get_referral_stats,clicks_verify_receipt,clicks_get_settlement_status,clicks_reconcile_settlement,clicks_replay_policy,clicks_get_receipt_trail,clicks_receive_payment,clicks_withdraw_yield,clicks_register_agent,clicks_set_yield_pct,clicks_explain

Works with Claude, Cursor, LangChain, and any MCP-compatible client.

Referral contracts exist on-chain. Treat them as a separate attribution layer from the current SDKquickStart()helper.

The referred agent paysnothing extra. Rewards come from the 2% protocol fee once referral attribution has been registered through a dedicated flow.

const deadline = BigInt(Math.floor(Date.now() / 1000) + 3600); const signature = await clicks.signReferralApproval(agentAddress, referrerAddress, deadline); const result = await clicks.quickStartWithReferral( '100', agentAddress, referrerAddress, deadline, signature, );

- quickStart()handles treasury setup.
- registerReferralWithSig()handles explicit attribution.
- quickStartWithReferral()is a convenience wrapper over those two steps, not an atomic one-shot contract call.

Form squads, hit TVL milestones, earn bonus yield:

All contracts verified on Basescan. Owned by Gnosis Safe multisig — single-key compromise is not possible.

Clicks is registered on theERC-8004 Identity Registry on BaseasagentId 45074. On-chain reputation accrues per completed agent job. Attestors who follow theClicks Attestor Schema V1become eligible for the reputation-aware fee multiplier (shipping in V5).

- Manifest:/.well-known/agent-registration.json
- Schema V1:
clicksprotocol.xyz/strategy/ATTESTOR-SCHEMA-V1.md

clicks-protocol/ ├── contracts/ Solidity (^0.8.20) │ ├── ClicksSplitterV4 Splits payments, manages yield % │ ├── ClicksYieldRouter Routes to best APY (Aave/Morpho) │ ├── ClicksFeeV2 2% fee collection on yield │ ├── ClicksRegistry Agent ↔ Operator mapping │ └── ClicksReferral Multi-level referral system ├── sdk/ TypeScript SDK ├── mcp-server/ MCP Server (16 tools) ├── site/ Landing page + llms.txt + agent.json └── test/ 227 tests (Hardhat)

- llms.txt:clicksprotocol.xyz/llms.txt— full protocol docs for LLMs
- agent.json:
clicksprotocol.xyz/.well-known/agent.json— agent manifest
- MCP:@clicks-protocol/mcp-server— tool discovery for MCP clients

The Clicks MCP server is live athttps://mcp.clicksprotocol.xyz/mcp— connect any MCP-compatible client in seconds.

Add to yourclaude_desktop_config.json:

{ "mcpServers": { "clicks-protocol": { "url": "https://mcp.clicksprotocol.xyz/mcp" } } }
openclaw mcp set clicks-protocol --url https://mcp.clicksprotocol.xyz/mcp
{ "mcpServers": { "clicks-protocol": { "type": "url", "url": "https://mcp.clicksprotocol.xyz/mcp" } } }
{ "mcpServers": { "clicks-protocol": { "url": "https://mcp.clicksprotocol.xyz/mcp" } } }

Seeexamples/integrations/for ready-to-use config files.

Any agent framework that handles USDC on Base:

x402 · LangChain · CrewAI · AutoGen · Eliza · OpenClaw · Claude · Cursor · Codex · Gemini · Hummingbot · Phidata

npm install npx hardhat compile npx hardhat test # 227 tests

Built for agents, by agents. Live on Base.

Pay-per-call x402 data APIs for AI agents — token rug-check, on-chain reads, web search, and AI-visibility (does AI recommend a brand). USDC on Base, no API key.

Free token-safety scans plus paid x402 verdicts, signals, radar and EVM swap quotes for AI agents.

"Non-custodial DeFi execution layer for AI agents powered by the SwapWizard API — swap quotes and execution, zap in/out of LP positions, ro uting across AMMs, and pool discovery and analysis on 5 EVM chains.

Solana agent trust scoring via x402 micropayments.

MCP to interface with multiple blockchains, staking, DeFi, swap, bridging, wallet management, DCA, Limit Orders, Coin Lookup, Tracking and more.

Get onchain wallet data on Ethereum, Solana, and all major EVM chains

x402 payment gateway for AI agents — 12 crypto data tools (price, whale activity, gas, TVL, Fear & Greed, Dune queries) paid per-call in USDC on Stellar or Base. No API keys, no subscriptions.

Live AI agent city-economy on Base L2 — 92 NPC agents earn real USDC via jobs, trading, and businesses across 10 cities. Claim jobs for USDC payouts, chat with agents, check AGWC token data, and get live crypto news. 11 tools, no API key.

Bitcoin-native MCP server for AI agents: BTC/STX wallets, DeFi yield, sBTC peg, NFTs, and x402 payments.

Blockchain data across 100+ chains: token prices, NFTs, transfers, simulation, traces, Solana DAS

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.