← Back to Skills Marketplace
wpank

Uniswap Batch Swap

by wpank · GitHub ↗ · v0.1.0
cross-platform ⚠ suspicious
838
Downloads
0
Stars
2
Active Installs
1
Versions
Install in OpenClaw
/install batch-swap
Description
Execute multiple token swaps in sequence. Use when user wants to rebalance, swap into multiple tokens, or execute a multi-step trading plan. Each swap goes through full safety validation independently.
README (SKILL.md)

Batch Swap

Execute multiple token swaps in sequence with independent safety validation per swap.

Activation

Use this skill when the user says any of:

  • "Swap X for Y and Z"
  • "Rebalance to 50% ETH 50% USDC"
  • "Buy 3 different tokens"
  • "Execute these swaps: ..."

Input Extraction

Parameter Required Default Source
swaps Yes List of {tokenIn, tokenOut, amount}
chain No ethereum Default chain for all swaps
stopOnFailure No true Whether to halt on first failure

Workflow

  1. Parse all swaps from the user's message. Confirm token symbols resolve.

  2. Pre-flight check: Verify total spending within daily limits and sufficient balance for all swaps using check_safety_status and get_agent_balance.

  3. Sequential execution: For each swap:

    • Launch Task(subagent_type:trade-executor) with swap parameters
    • Wait for confirmation before starting next swap
    • Update running balance between swaps
    • If stopOnFailure=true and swap fails, halt remaining swaps
  4. Report summary:

Batch Swap Complete (3/3 succeeded)

  #  Swap              Amount In    Amount Out   Tx
  1  USDC → WETH      1,000 USDC   0.307 WETH   0xABC...
  2  USDC → WBTC      1,000 USDC   0.015 WBTC   0xDEF...
  3  USDC → UNI       1,000 USDC   142.3 UNI    0xGHI...

  Total gas: $1.26

Error Handling

Error User Message Suggested Action
BATCH_PARTIAL_FAILURE "Swap #N failed. Remaining halted." Review failed swap, re-run remaining
INSUFFICIENT_BALANCE "Insufficient balance for full batch." Reduce amounts
SAFETY_AGGREGATE_LIMIT "Total batch exceeds daily limit." Reduce total batch size
Usage Guidance
This skill looks like a legitimate batch-swap workflow, but it leaves out where and how transactions are signed and what the trade-executor subagent/microservices are permitted to do. Before installing or using it: 1) Ask the publisher where signing keys and RPC credentials reside and who/what will sign transactions (your wallet, a custodian, or the subagent). 2) Verify the implementation and trust boundaries of Task(subagent_type:trade-executor) and the mcp__uniswap__* microservices (what permissions they have, whether they can exfiltrate keys or deploy other actions). 3) Require least-privilege access: prefer a read-only balance check and manual confirmation for high-value trades or transaction signing performed locally. 4) Test with very small amounts in a controlled environment and ensure audit/logging of every submitted tx. Because of the unexplained credential handling, treat this skill as suspicious until the above is clarified.
Capability Analysis
Type: OpenClaw Skill Name: batch-swap Version: 0.1.0 The skill is classified as suspicious due to the broad file system access granted to the AI agent via `Read`, `Glob`, and `Grep` in the `allowed-tools` section of `SKILL.md`. While the skill's stated purpose and workflow are benign (executing token swaps), these powerful tools introduce a significant prompt injection vulnerability. An attacker could craft a malicious prompt to instruct the agent to read sensitive files (e.g., credentials, configuration) or list directories, potentially leading to unauthorized information disclosure, even though the skill itself does not explicitly instruct such actions.
Capability Assessment
Purpose & Capability
Name/description (batch token swaps) align with the workflow in SKILL.md, but a trading skill normally requires wallet signing credentials, RPC endpoints, or an explicit integration with an exchange/bridge. This skill declares no credentials or config paths yet instructs launching a Task(subagent_type:trade-executor) to submit trades, which is an unexplained gap.
Instruction Scope
Instructions stay within a swapping/rebalancing scope (parse swaps, pre-flight safety, sequential execution, reporting) and do not ask to read arbitrary files or unrelated env vars. However they delegate critical actions to an external subagent and microservice tools (mcp__uniswap__check_safety_status, mcp__uniswap__get_agent_balance) without describing their trust model, data flow, or how transaction signing is performed.
Install Mechanism
Instruction-only skill with no install steps or downloaded code; this minimizes on-disk risk. The README references installation commands for package managers, but the skill package itself contains only docs and no install script.
Credentials
No environment variables, credentials, or config paths are declared despite functionality that normally requires private keys, provider RPCs, or API keys. The allowed-tools indicate the skill will call internal microservices and launch a trade-executor subagent — both of which may need sensitive credentials but those are not declared or scoped here.
Persistence & Privilege
Skill is not always-enabled and does not request persistent presence. Autonomous invocation is allowed by default, and the skill's ability to spawn subagents increases its effective privilege during execution; this is normal for agent skills but should be considered when combined with the missing credential details above.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install batch-swap
  3. After installation, invoke the skill by name or use /batch-swap
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v0.1.0
Initial release: Batch Swap skill for sequential multi-token trading with independent safety checks. - Execute multiple token swaps in a single workflow, ideal for rebalancing or multi-step trading plans. - Each swap is validated for safety and balance before execution. - Supports halting on the first failure or continuing batch execution. - Detailed summary reports outcomes and any partial failures. - Error messages guide users to resolve balance or safety issues.
Metadata
Slug batch-swap
Version 0.1.0
License
All-time Installs 2
Active Installs 2
Total Versions 1
Frequently Asked Questions

What is Uniswap Batch Swap?

Execute multiple token swaps in sequence. Use when user wants to rebalance, swap into multiple tokens, or execute a multi-step trading plan. Each swap goes through full safety validation independently. It is an AI Agent Skill for Claude Code / OpenClaw, with 838 downloads so far.

How do I install Uniswap Batch Swap?

Run "/install batch-swap" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Uniswap Batch Swap free?

Yes, Uniswap Batch Swap is completely free (open-source). You can download, install and use it at no cost.

Which platforms does Uniswap Batch Swap support?

Uniswap Batch Swap is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Uniswap Batch Swap?

It is built and maintained by wpank (@wpank); the current version is v0.1.0.

💬 Comments