> ## Documentation Index
> Fetch the complete documentation index at: https://developers.fd.xyz/llms.txt
> Use this file to discover all available pages before exploring further.

# Finance District CLI Skills

> Give any AI agent crypto wallet and merchant payment capabilities — one skill install, zero code.

The Finance District skill follows the [Agent Skills specification](https://agentskills.io/specification) and works with OpenClaw, Claude Code, GitHub Copilot, and 40+ other agentic platforms. Once installed, the skill teaches your agent how to use the [Finance District CLI](/agent-wallet/ai-integration/cli) — giving it wallet management, token transfers, DEX swaps, DeFi yield, x402 payments, and Prism merchant operations through natural language.

## Why a Skill?

The skill bridges the gap between the CLI and your agent. Without it, the agent would need to figure out which `fdx` commands exist, what parameters they take, and how to chain them together. The skill provides:

* **Tool discovery** — the agent knows which `fdx` commands are available and uses `--help` to learn parameters on demand
* **Workflow guidance** — authentication flows, pre-operation checklists, safety confirmations before irreversible operations
* **Protocol knowledge** — the full [x402 payment flow](/agent-wallet/concepts/x402-payments), including when to use `authorizePayment` vs `getX402Content`
* **Two service areas** — both **Wallet** (`fdx wallet`) and **Prism** (`fdx prism`) operations in a single skill

<Info>
  The skill is a single `SKILL.md` file with reference documents. It doesn't add runtime dependencies — it teaches the agent how to use the CLI you've already installed.
</Info>

## Installation

**Step 1:** Install the CLI:

```bash theme={"theme":{"light":"github-light","dark":"one-dark-pro"}}
npm install -g @financedistrict/fdx
```

**Step 2:** Install the skill:

```bash theme={"theme":{"light":"github-light","dark":"one-dark-pro"}}
npx skills add financedistrict-platform/fd-cli-skills
```

That's it. The skill is automatically detected when your agent encounters a relevant task.

## What the Agent Can Do

Once the skill is installed, your agent handles all of this through natural language:

**Wallet operations:**

> "Set up my wallet" — authentication via email OTP

> "Show my balance on Base" — balances across all chains

> "Send 10 USDC to 0x1234...abcd on Arbitrum" — token transfers with safety confirmations

> "Swap 5 USDC for ETH" — DEX swaps with quote-first flow

> "Find yield strategies for my USDC" — DeFi discovery, deposit, and withdrawal

> "Access the premium API at [https://api.example.com/data](https://api.example.com/data)" — x402 payments

**Prism merchant operations:**

> "Set up my merchant account" — onboarding and configuration

> "Create a new Project" — payment acceptance setup

> "Show my payment history" — earnings and settlement details

The skill guides the agent to confirm with you before any irreversible operation (transfers, swaps, deposits) and to check balances before executing.

## How It Works

The skill is not a wrapper or abstraction layer. It's a set of instructions that teach the agent:

1. **Check prerequisites** — is `fdx` installed? Is the user authenticated?
2. **Use `--help` liberally** — discover tool parameters dynamically rather than hardcoding them
3. **Follow safety patterns** — check balances, confirm with the human, verify chain matches recipient
4. **Handle authentication** — autonomous path (with email inbox access) or human-assisted path
5. **Consult reference docs** — deeper guidance on specific topics (x402 flow, chain capabilities, troubleshooting) loaded only when needed

The agent runs `fdx` commands via bash and parses structured JSON output. All wallet operations use `fdx wallet <method>`, all Prism operations use `fdx prism <method>`.

## Skill vs MCP

The skill and the [MCP server](/agent-wallet/ai-integration/mcp-server) provide access to the same underlying capabilities. Choose based on your agent's environment:

| Approach  | How it works                                                   | Best for                                                            |
| --------- | -------------------------------------------------------------- | ------------------------------------------------------------------- |
| **Skill** | Agent runs `fdx` CLI commands via bash                         | Agents with shell access — Claude Code, OpenClaw, autonomous agents |
| **MCP**   | Agent connects to `https://wallet-mcp.fd.xyz` via MCP protocol | MCP-native clients — Claude Code, Cursor, Windsurf                  |

Both can be used together. An agent with both the skill and MCP access has maximum flexibility.

<CardGroup cols={2}>
  <Card title="CLI Reference" icon="terminal" href="/agent-wallet/ai-integration/cli">
    Full CLI documentation and configuration
  </Card>

  <Card title="Skills Repository" icon="github" href="https://github.com/financedistrict-platform/fd-cli-skills">
    Source code and contributing guidelines
  </Card>
</CardGroup>
