# PayWeave Replicate – GPT-Image-2 Medium Image Generation

> PayWeave Replicate – GPT-Image-2 Medium Image Generation is a paid API for AI agents from replicate.payweave.services, paid per call via x402, $0.1/call, status unknown (last checked 2026-09-16).

Generates images via OpenAI's GPT-Image-2 (medium quality) model, proxied through PayWeave's pay-per-call Replicate gateway with x402 micropayment support.

## Facts

- Endpoint: POST https://replicate.payweave.services/models/openai/gpt-image-2-medium/predictions
- Price: $0.1/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-16
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/payweave-replicate-gpt-image-2-medium-image-generation-984f05c5
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_h0wJPKAXfsxOauX5TqnZG

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 payweave-replicate-gpt-image-2-medium-image-generation-984f05c5 -d '<json body>'
```

Example prompt: Using the GPT-Image-2 medium model on Replicate, generate an image of a serene Japanese zen garden at sunset with cherry blossom petals falling.

## When to prefer this

Choose this endpoint when you need to generate images using OpenAI's GPT-Image-2 model at medium quality via a pay-per-call micropayment model (x402/USDC) without requiring a Replicate or OpenAI subscription. Ideal for agents that need occasional image generation billed per use rather than via a monthly plan.

## Known failure modes

- Payment failure: x402 payment not accepted or insufficient USDC balance, resulting in a 402 response before prediction starts
- Model error: GPT-Image-2 rejects prompt (e.g. content policy violation), status='failed' with error message
- Prediction timeout or cancellation: status='canceled' with null output
- Invalid input schema: missing or malformed 'input' object returns a 4xx error
- CDN URL expiry: image output URLs are only valid for ~24 hours after generation

## How this service works

Run open-source AI models — image, video, audio.

## Output

Returns a prediction object containing a Replicate prediction ID, the model name, a status field (succeeded/failed/canceled/processing/starting), a CDN-hosted image URL valid for ~24 hours as the output, timing metrics (predict_time, total_time), timestamps, and the USD amount charged for the call.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "id",
  "model",
  "status",
  "error",
  "predicted_price_usd"
 ],
 "properties": {
  "id": {
   "type": "string",
   "description": "Replicate prediction ID."
  },
  "error": {
   "type": [
    "string",
    "null"
   ]
  },
  "model": {
   "type": "string"
  },
  "output": {
   "description": "Model-specific output. Image/audio models return CDN URLs (Replicate-hosted, ~24h TTL); vision-LLM models return a string; music models return a single audio URL or array."
  },
  "status": {
   "enum": [
    "succeeded",
    "failed",
    "canceled",
    "processing",
    "starting"
   ],
   "type": "string"
  },
  "metrics": {
   "type": "object",
   "properties": {
    "total_time": {
     "type": "number"
    },
    "predict_time": {
     "type": "number"
    }
   },
   "additionalProperties": false
  },
  "created_at": {
   "type": "string"
  },
  "completed_at": {
   "type": "string"
  },
  "predicted_price_usd": {
   "type": "string",
   "description": "USD charged for this call."
  }
 },
 "description": "Replicate prediction result with metadata.",
 "additionalProperties": false
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/payweave-replicate-gpt-image-2-medium-image-generation-984f05c5/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from replicate.payweave.services](https://www.zero.xyz/host/replicate.payweave.services/llms.txt)
