# Send payrail402 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. Then review README.md for any prerequisites, environment setup, or post-install checks. 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. Then review README.md for any prerequisites, environment setup, or post-install checks. Summarize what changed and any follow-up checks I should run.
```
## Machine-readable fields
```json
{
  "schemaVersion": "1.0",
  "item": {
    "slug": "payrail402",
    "name": "payrail402",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/rsquaredsolutions2026/payrail402",
    "canonicalUrl": "https://clawhub.ai/rsquaredsolutions2026/payrail402",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadUrl": "/downloads/payrail402",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=payrail402",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "packageFormat": "ZIP package",
    "primaryDoc": "SKILL.md",
    "includedAssets": [
      "openclaw-skill.js",
      "README.md",
      "SKILL.md"
    ],
    "downloadMode": "redirect",
    "sourceHealth": {
      "source": "tencent",
      "slug": "payrail402",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-05-12T13:01:18.984Z",
      "expiresAt": "2026-05-19T13:01:18.984Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=payrail402",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=payrail402",
        "contentDisposition": "attachment; filename=\"payrail402-1.0.2.zip\"",
        "redirectLocation": null,
        "bodySnippet": null,
        "slug": "payrail402"
      },
      "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/payrail402"
    },
    "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/payrail402",
    "downloadUrl": "https://openagent3.xyz/downloads/payrail402",
    "agentUrl": "https://openagent3.xyz/skills/payrail402/agent",
    "manifestUrl": "https://openagent3.xyz/skills/payrail402/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/payrail402/agent.md"
  }
}
```
## Documentation

### PayRail402

Track every financial transaction your AI agent makes — across any payment rail — in one place.

PayRail402 is the control plane for AI agent transactions. When your agent makes a purchase, payment, or financial operation on Visa Intelligent Commerce, Mastercard Agent Pay, Stripe ACP, x402 (USDC on-chain), or ACH, this skill reports it to your PayRail402 dashboard for budget enforcement, anomaly detection, and cross-rail reconciliation.

### Setup

Go to payrail402.com and create a free account
Add an agent in the dashboard — you'll receive a webhook token
Configure your environment:

Option A — Webhook auth (simplest, one agent):

PAYRAIL402_WEBHOOK_TOKEN=your-webhook-token

Option B — API key auth (multi-agent setups):

PAYRAIL402_API_KEY=pr4_your-key
PAYRAIL402_AGENT_ID=your-agent-id

You only need one auth method. Webhook auth is recommended for single-agent use.

### payrail402_track

Track a financial transaction after any purchase, payment, or financial operation.

Required inputs:

amount — Transaction amount (positive number, USD)
description — What the agent did (max 500 chars)

Optional inputs:

merchant — Merchant or service name (e.g., "OpenAI", "AWS")
category — One of: shopping, finance, devops, research, travel, api, other
rail — Payment rail: visa_ic, mc_agent, stripe_acp, x402, ach, manual
mandate — Authorization or mandate reference
proofHash — On-chain transaction hash (for x402 payments)

When to use: Call this immediately after your agent completes any financial transaction. This feeds the PayRail402 dashboard with real-time spend data and triggers budget rule evaluation.

### payrail402_register

Self-register this agent with PayRail402 to get tracking credentials.

Required inputs:

name — Agent name (max 100 chars)
contactEmail — Developer/owner email for notifications and dashboard claiming

Optional inputs:

description — What this agent does
type — Agent type: shopping, finance, devops, research, travel, api, general
callbackUrl — Webhook URL for receiving alerts and budget violation events

When to use: Call this once when the agent first starts and has no existing credentials. The response includes an API key (shown once — save it) and a webhook token.

### payrail402_status

Check this agent's current status, claim state, and configuration on PayRail402.

Required inputs:

agentAccountId — Agent account ID from registration

When to use: Call this to verify the agent is still active, check its registration tier, or confirm it has been claimed by a dashboard user.

### Supported Payment Rails

Rail IDNameDescriptionvisa_icVisa Intelligent CommerceVisa's AI agent payment protocolmc_agentMastercard Agent PayMastercard's autonomous agent payment railstripe_acpStripe Agent Credit PlatformStripe's agent-to-agent payment systemx402x402 ProtocolUSDC on-chain payments via HTTP 402achACHTraditional ACH bank transfersmanualManualManual or unclassified transactions

### What Happens After Tracking

When you call payrail402_track, the PayRail402 backend:

Records the transaction with full metadata
Updates agent spend stats (total spent, transaction count)
Evaluates budget rules (per-transaction max, daily/weekly/monthly limits)
Runs anomaly detection (flags transactions 3x above agent average)
Sends alerts to the dashboard (and optionally via email) on violations

### Permission Justification

This skill requires three environment variables. Here is exactly what each one is used for and why it is necessary:

PAYRAIL402_WEBHOOK_TOKEN (primary credential)

Used by: payrail402_track tool
How: Embedded in the API URL path (/api/ingest/webhook/{token}) to authenticate transaction submissions
Why: Each agent has a unique webhook token that links transactions to the correct agent in the dashboard. Without it, the skill cannot submit transactions.
Security: Sent as a URL path segment over HTTPS only. Never included in query strings, headers, or request bodies.

PAYRAIL402_API_KEY

Used by: payrail402_track (alternative auth path) and payrail402_status tool
How: Sent via x-agent-key or x-api-key HTTP header over HTTPS
Why: Required for checking agent status and for multi-agent setups where one API key manages multiple agents. Not needed if you only use webhook auth for tracking.
Security: Transmitted only in HTTP headers over HTTPS. Format: pr4_ prefix + base64url secret. Stored as SHA-256 hash on the server.

PAYRAIL402_AGENT_ID

Used by: payrail402_track (with API key auth) and payrail402_status tool
How: Included in the API URL path (/api/v1/agents/{agentId}) and request body
Why: Identifies which agent account to operate on when using API key auth. Not needed for webhook auth (the webhook token already identifies the agent).
Security: Not a secret — it is a public CUID identifier. Included in URL paths only.

### Security

This skill is designed to be transparent and minimal:

Single endpoint: All network requests go to https://payrail402-production-2a69.up.railway.app over HTTPS only
No filesystem access: The skill does not read, write, or modify any files
No shell commands: The skill does not execute any system commands
No other network calls: The skill makes no requests to any other domain or service
Zero dependencies: The entire implementation is a single JavaScript file with no external packages
Credential handling: API keys and webhook tokens are sent via HTTP headers or URL path segments — never in query strings, never logged, never stored locally

You can inspect the full implementation in openclaw-skill.js — it is 184 lines of plain JavaScript.

### Troubleshooting

ErrorCauseFixNo credentials configured. Set webhookToken or apiKey in skill config.Neither PAYRAIL402_WEBHOOK_TOKEN nor PAYRAIL402_API_KEY is setSet at least one credential — see Setup aboveamount must be a positive numberThe amount input is missing, zero, or negativePass a positive number for the transaction amountapiKey is required in skill config to check statusCalled payrail402_status without PAYRAIL402_API_KEYSet PAYRAIL402_API_KEY — status checks require API key authHTTP 429 (Too Many Requests)Rate limit exceededWebhook: max 60 requests/minute. Register: max 10/hour. Wait and retry.HTTP 403 (Forbidden)Agent is paused or stopped in the dashboardResume the agent in your PayRail402 dashboardHTTP 400 (Bad Request)Invalid input (missing required field or bad format)Check that amount and description are provided and validNetwork error / timeoutCannot reach PayRail402 APICheck internet connectivity. The API is at payrail402-production-2a69.up.railway.app

### Links

Dashboard: payrail402.com
SDK: npm install @payrail402/sdk
Agent Card: payrail402.com/.well-known/agent-card.json
Full API Docs: payrail402.com/llms-full.txt
## Trust
- Source: tencent
- Verification: Indexed source record
- Publisher: rsquaredsolutions2026
- Version: 1.0.2
## 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-12T13:01:18.984Z
- Expires at: 2026-05-19T13:01:18.984Z
- Recommended action: Download for OpenClaw
## Links
- [Detail page](https://openagent3.xyz/skills/payrail402)
- [Send to Agent page](https://openagent3.xyz/skills/payrail402/agent)
- [JSON manifest](https://openagent3.xyz/skills/payrail402/agent.json)
- [Markdown brief](https://openagent3.xyz/skills/payrail402/agent.md)
- [Download page](https://openagent3.xyz/downloads/payrail402)