# PayWeave Replicate – FLUX 2 Flex Image Generation

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

Runs Black Forest Labs FLUX 2 Flex via Replicate to generate images from prompts, billed per-call via x402 micropayment.

## Facts

- Endpoint: POST https://replicate.payweave.services/models/black-forest-labs/flux-2-flex/predictions
- Price: $0.74/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/payweave-replicate-flux-2-flex-image-generation-761c1f12
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_riKukku342lXAV1fEVHqe

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-flux-2-flex-image-generation-761c1f12 -d '<json body>'
```

Example prompt: Generate an image of a misty Japanese forest at dawn with soft golden light filtering through bamboo trees, using FLUX 2 Flex on Replicate — pay the $0.74 per-call fee and give me the image URL when it's done.

## When to prefer this

Choose this endpoint when you need to run the FLUX 2 Flex model specifically, want pay-per-call pricing via x402 USDC micropayments without a subscription, or need access to Black Forest Labs' latest flexible image generation model through a Replicate-compatible API. Prefer over alternatives when working in x402-enabled agent pipelines or when the user explicitly needs FLUX 2 Flex output quality.

## Known failure modes

- Model input validation error — missing or malformed 'input' object returns an error status
- Payment failure — insufficient USDC balance or x402 protocol error prevents call from completing
- Prediction timeout or cancellation — status returns 'canceled' or 'failed' with error message
- CDN URL expiry — image URLs are only valid ~24 hours after generation
- Model cold start — status may show 'starting' before transitioning to 'processing', increasing latency

## How this service works

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

## Output

Returns a Replicate prediction object containing: a unique prediction ID, the model name, a status field (succeeded/failed/canceled/processing/starting), the generated image as a Replicate-hosted CDN URL (valid ~24 hours), timing metrics (total_time, predict_time in seconds), timestamps for creation and completion, and the USD cost charged for the call. On failure, an error string is returned instead of output.

## 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-flux-2-flex-image-generation-761c1f12/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)
