# ForgeMesh x402 Service Spec

> ForgeMesh x402 Service Spec is a paid API for AI agents from x402.forgemesh.io, paid per call via x402, $0.05/call, status unknown (last checked 2026-09-15).

Returns the complete call specification for a single ForgeMesh x402 service: routes, HTTP methods, pricing, JSON input schemas, and worked examples, fetched live from that service's own API discovery surface.

## Facts

- Endpoint: POST https://x402.forgemesh.io/x402-service-spec
- Price: $0.05/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/forgemesh-x402-service-spec-b0a7691d
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Ux-7Tgu5yx3fNlcclAZeq

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability forgemesh-x402-service-spec-b0a7691d -d '<json body>'
```

Example prompt: Pull up the full call spec for the ForgeMesh 'imagegen' service — I need the routes, what JSON it expects, how much each call costs, and a worked example so I can integrate it without guessing.

## When to prefer this

Use this endpoint when an agent needs to integrate a specific ForgeMesh x402 service and wants the authoritative, live-fetched call spec rather than cached or hand-written documentation. Prefer it over the fleet catalog endpoint when you already know which product you want and need deep per-route detail including schemas and examples, not just a high-level listing.

## Known failure modes

- Unknown product id or name returns an error indicating the product was not found in the ForgeMesh fleet
- Missing required 'product' parameter returns a validation error
- Service discovery surface for the requested product is temporarily unavailable, returning a 5xx error
- Payment of $0.05 USDC not completed or rejected, returning a 402 Payment Required response

## How this service works

The exact call spec for one x402 service in the ForgeMesh fleet: routes, methods, prices, JSON input schemas, and worked examples, pulled from that service's own live API discovery surface. Pass `product` (id or name from fleet-products). Built for agents integrating a new paid tool without trial-and-error against its API.

## Output

A structured document containing the target ForgeMesh service's live API routes, accepted HTTP methods, per-route pricing in USDC, JSON input schemas for each route, and worked request/response examples — everything needed to call that service correctly on the first try.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "product": {
   "type": "string",
   "description": "Required: product id or name from fleet-products, e.g. \"imagegen\" or \"voice\""
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "product": {
   "id": "imagegen",
   "host": "imagegen.coinopai.com",
   "name": "AI Image Generation",
   "summary": "Paid AI image generation via x402. Text-to-image, background removal, 4x HD upscaling.",
   "category": "media",
   "endpoints": [
    {
     "price": "$0.250000",
     "route": "/generate",
     "method": "GET",
     "example": null,
     "description": "Standard AI image generation. Requires x402 payment of 0.25 USDC on Base.",
     "input_schema": [
      {
       "in": "query",
       "name": "prompt",
       "schema": {
        "type": "string"
       },
       "required": true,
       "description": "Natural language image description"
      },
      {
       "in": "query",
       "name": "aspect",
       "schema": {
        "enum": [
         "1:1",
         "16:9",
         "9:16",
         "4:3"
        ],
        "type": "string",
        "default": "1:1"
       },
       "required": false,
       "description": "Aspect ratio"
      }
     ]
    }
   ],
   "price_range": {
    "max": 0.75,
    "min": 0.25
   },
   "route_count": 4
  },
  "generated_at": "2026-07-17T11:53:32.075Z"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/forgemesh-x402-service-spec-b0a7691d/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402.forgemesh.io](https://www.zero.xyz/host/x402.forgemesh.io/llms.txt)
