← Back to Skills Marketplace
agnicpay-prog

Agnic Pay for Service

by Agnic.AI · GitHub ↗ · v2.0.2 · MIT-0
cross-platform ⚠ suspicious
104
Downloads
0
Stars
0
Active Installs
2
Versions
Install in OpenClaw
/install agnicpay-pay-for-service
Description
Make paid requests to x402-enabled APIs using USDC on Base. Use when the user explicitly asks to call a paid API, make an x402 payment, pay for a request, or...
README (SKILL.md)

Paying for x402 Services

Use npx agnic@latest x402 pay to call x402-enabled API endpoints with automatic USDC payment on Base.

Authentication

Run npx agnic@latest status --json to verify. If not authenticated:

  • Headless (CI/server/agent): Set AGNIC_TOKEN env var or pass --token \x3Ctoken>
  • Interactive (has browser): Run npx agnic@latest auth login

See the authenticate-wallet skill for details.

Command Syntax

npx agnic@latest x402 pay \x3Curl> [-X \x3Cmethod>] [-d \x3Cjson>] [-q \x3Cparams>] [-h \x3Cjson>] [--max-amount \x3Cn>] [--json]

See reference/x402-protocol.md for full options, USDC amounts, and input validation rules.

Workflow

  1. Check requirements (optional but recommended):

    npx agnic@latest x402 details \x3Curl>
    

    Shows price, method, and schema without making a payment.

  2. Verify balance:

    npx agnic@latest balance --network base
    
  3. Make the paid request:

    npx agnic@latest x402 pay \x3Curl> --json
    

Examples

# GET request (auto-pays)
npx agnic@latest x402 pay https://example.com/api/weather --json

# POST request with body
npx agnic@latest x402 pay https://example.com/api/sentiment -X POST -d '{"text": "I love this product"}' --json

# Limit max payment to $0.10
npx agnic@latest x402 pay https://example.com/api/data --max-amount 100000 --json

Prerequisites

  • Must be authenticated (npx agnic@latest status to check)
  • Wallet must have sufficient USDC balance on Base

Error Handling

Common errors:

  • "Not authenticated" -- Run npx agnic@latest auth login or set AGNIC_TOKEN
  • "Insufficient balance" -- Fund wallet with USDC (npx agnic@latest balance to check)
  • "No X402 payment requirements found" -- URL may not be an x402 endpoint
  • Invalid JSON in --data -- Ensure the body is valid JSON before passing
  • HTTP 4xx/5xx from the API -- Show the status code and response body to the user
Usage Guidance
This skill appears to do what it says (make paid x402 calls), but exercise caution: it runs `npx agnic@latest`, which will fetch and execute code from npm each time — consider pinning to a specific, reviewed package/version instead of `@latest`. The SKILL.md mentions AGNIC_TOKEN for headless auth but the metadata doesn't declare it; confirm how you will provide a token and avoid exposing secrets on the command line (they can end up in shell history). Before using: (1) review the agnic npm package source or its npm page, (2) prefer a pinned version you can audit, (3) ensure the wallet and USDC balances are controlled and minimal for testing, (4) avoid passing other sensitive data through CLI args, and (5) if you need stronger assurance, ask the publisher for an install spec or code you can audit locally.
Capability Analysis
Type: OpenClaw Skill Name: agnicpay-pay-for-service Version: 2.0.2 The skill bundle facilitates paid API requests using the x402 protocol via the 'agnic' CLI tool on the Base network. It demonstrates good security practices by providing explicit instructions in SKILL.md and reference/x402-protocol.md for the AI agent to validate user-provided URLs and JSON data to prevent shell injection, and its functionality is consistent with its stated purpose.
Capability Tags
cryptorequires-walletcan-make-purchasesrequires-sensitive-credentials
Capability Assessment
Purpose & Capability
Name, description, and SKILL.md consistently describe making x402 payments on Base using USDC and the documented commands (npx agnic x402 ...) are aligned with that purpose. Minor incoherence: the instructions reference an AGNIC_TOKEN environment variable for headless auth, but the skill metadata lists no required env vars.
Instruction Scope
Runtime instructions are narrowly focused: they call `npx agnic@latest` subcommands to check status, view details, check balance, and pay. The documentation includes input validation suggestions (URL regex, JSON parsing) and does not instruct the agent to read unrelated files or exfiltrate data. It does, however, allow passing authentication tokens via CLI or env — a normal but sensitive operation.
Install Mechanism
This is an instruction-only skill that runs `npx agnic@latest` at runtime. `npx` will download and execute code from the npm registry (the `latest` tag), which is effectively executing remote code each time — a non-trivial risk. The skill provides no install spec or pinned package version to allow static review of code prior to execution.
Credentials
The only credential-like item referenced is AGNIC_TOKEN (for authentication) and the user's wallet balance (USDC on Base), both reasonable for the stated purpose. But the metadata does not declare AGNIC_TOKEN in required env vars, creating a mismatch between declared requirements and instructions.
Persistence & Privilege
The skill does not request persistent presence (always:false) and model invocation is disabled (disable-model-invocation:true), so it cannot be autonomously invoked by the model. No install scripts, no system-wide config changes are specified.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install agnicpay-pay-for-service
  3. After installation, invoke the skill by name or use /agnicpay-pay-for-service
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v2.0.2
v2.0.2 — Synced with upstream agnic-wallet-skills: - Security fix: now requires explicit user invocation (disable-model-invocation: true) — prevents auto-spend of USDC - Added context: fork for execution isolation - Added reference/x402-protocol.md for progressive disclosure - Standardized authentication (browser OAuth + headless AGNIC_TOKEN) - Rebranded references from "AgnicPay" to "Agnic"
v1.0.0
Initial publish of Pay for Service for Agnic wallet agent.
Metadata
Slug agnicpay-pay-for-service
Version 2.0.2
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 2
Frequently Asked Questions

What is Agnic Pay for Service?

Make paid requests to x402-enabled APIs using USDC on Base. Use when the user explicitly asks to call a paid API, make an x402 payment, pay for a request, or... It is an AI Agent Skill for Claude Code / OpenClaw, with 104 downloads so far.

How do I install Agnic Pay for Service?

Run "/install agnicpay-pay-for-service" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Agnic Pay for Service free?

Yes, Agnic Pay for Service is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Agnic Pay for Service support?

Agnic Pay for Service is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Agnic Pay for Service?

It is built and maintained by Agnic.AI (@agnicpay-prog); the current version is v2.0.2.

💬 Comments