# Send x402-cli to your agent
Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.
## Fast path
- Download the package from Yavira.
- Extract it into a folder your agent can access.
- Paste one of the prompts below and point your agent at the extracted folder.
## Suggested prompts
### New install

```text
I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete.
```
### Upgrade existing

```text
I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run.
```
## Machine-readable fields
```json
{
  "schemaVersion": "1.0",
  "item": {
    "slug": "x402-cli",
    "name": "x402-cli",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/razvanmacovei/x402-cli",
    "canonicalUrl": "https://clawhub.ai/razvanmacovei/x402-cli",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadUrl": "/downloads/x402-cli",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=x402-cli",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "packageFormat": "ZIP package",
    "primaryDoc": "SKILL.md",
    "includedAssets": [
      "SKILL.md",
      "clawhub.json"
    ],
    "downloadMode": "redirect",
    "sourceHealth": {
      "source": "tencent",
      "slug": "x402-cli",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-05-12T22:48:10.801Z",
      "expiresAt": "2026-05-19T22:48:10.801Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=x402-cli",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=x402-cli",
        "contentDisposition": "attachment; filename=\"x402-cli-1.0.3.zip\"",
        "redirectLocation": null,
        "bodySnippet": null,
        "slug": "x402-cli"
      },
      "scope": "item",
      "summary": "Item download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this item.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/x402-cli"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    }
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/x402-cli",
    "downloadUrl": "https://openagent3.xyz/downloads/x402-cli",
    "agentUrl": "https://openagent3.xyz/skills/x402-cli/agent",
    "manifestUrl": "https://openagent3.xyz/skills/x402-cli/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/x402-cli/agent.md"
  }
}
```
## Documentation

### x402-cli

Pay for x402 payment-gated HTTP endpoints using USDC stablecoins.

### When to use

Use this tool when you need to access an API that returns HTTP 402 Payment Required with x402 payment requirements. The tool handles the full payment flow: probe → sign → pay → return response.

### Prerequisites

Set EVM_PRIVATE_KEY environment variable with a wallet private key that holds USDC on the target network (e.g., Base Sepolia for testnet).

### Probe an endpoint (check price without paying)

x402-cli --json --skip-verify <url>

Returns JSON with probe.paymentRequirements containing the price, network, and asset.

### Pay and access an endpoint

x402-cli --json -y <url>

Returns JSON with payment.body containing the backend response and payment.paymentResponse containing the transaction hash.

### POST with body

x402-cli --json -y -X POST -d '{"query": "hello"}' -H 'Content-Type: application/json' <url>

### Self-signed TLS (local development)

x402-cli --json -y -k <url>

### Exit codes

0 — Success (payment accepted or probe completed)
1 — Error (network, config, or unexpected failure)
2 — Payment rejected by facilitator
3 — Route is free (no payment needed)

### JSON output structure

{
  "status": "accepted",
  "probe": {
    "statusCode": 402,
    "paymentRequired": true,
    "paymentRequirements": { "...x402 requirements..." }
  },
  "payment": {
    "statusCode": 200,
    "accepted": true,
    "signer": "0x...",
    "paymentResponse": { "success": true, "transaction": "0x...", "network": "eip155:84532" },
    "body": "...backend response..."
  }
}

### Key fields to parse

.status — "free", "payment_required", "accepted", "rejected", "error"
.probe.paymentRequirements.accepts[0].amount — price in atomic units
.probe.paymentRequirements.accepts[0].network — chain ID (e.g., eip155:84532)
.payment.body — the actual backend response after payment
.payment.paymentResponse.transaction — on-chain transaction hash
## Trust
- Source: tencent
- Verification: Indexed source record
- Publisher: razvanmacovei
- Version: 1.0.3
## Source health
- Status: healthy
- Item download looks usable.
- Yavira can redirect you to the upstream package for this item.
- Health scope: item
- Reason: direct_download_ok
- Checked at: 2026-05-12T22:48:10.801Z
- Expires at: 2026-05-19T22:48:10.801Z
- Recommended action: Download for OpenClaw
## Links
- [Detail page](https://openagent3.xyz/skills/x402-cli)
- [Send to Agent page](https://openagent3.xyz/skills/x402-cli/agent)
- [JSON manifest](https://openagent3.xyz/skills/x402-cli/agent.json)
- [Markdown brief](https://openagent3.xyz/skills/x402-cli/agent.md)
- [Download page](https://openagent3.xyz/downloads/x402-cli)