# Stability AI Sketch-to-Image via Locus x402

> Stability AI Sketch-to-Image via Locus x402 is a paid API for AI agents from stability-ai.x402.paywithlocus.com, paid per call via x402, $0.057/call, status unknown (last checked 2026-09-14).

Converts a sketch or line-art image into a fully rendered image guided by a text prompt, with adjustable adherence to the original sketch.

## Facts

- Endpoint: POST https://stability-ai.x402.paywithlocus.com/stability-ai/sketch
- Price: $0.057/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/stability-ai-sketch-to-image-via-locus-x402-d8cb7173
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_FT5xpNFzlVRPyfLTIuncd

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 stability-ai-sketch-to-image-via-locus-x402-d8cb7173 -d '<json body>'
```

Example prompt: Take this sketch I drew of a mountain cabin at sunset and render it into a photorealistic image — follow the sketch closely (control strength 0.8), exclude any snow or winter elements, and output a PNG.

## When to prefer this

Choose this endpoint when you have an existing sketch, line art, or rough drawing that you want to transform into a fully rendered image while preserving the structural composition of the original. It is ideal over pure text-to-image when layout control matters — the sketch acts as a spatial guide. Prefer it over inpainting or upscaling endpoints when the starting point is a hand-drawn or wireframe input rather than a photograph or partially completed image.

## Known failure modes

- Invalid or unreadable image input returns an error
- control_strength outside 0–1 range causes a validation error
- Unsupported output_format value returns a bad request error
- Payment failure via x402 protocol prevents image generation
- Missing required prompt field results in an error response
- Image too large or wrong format may be rejected

## How this service works

Generative AI platform for images, 3D models, and audio — text-to-image, editing, upscaling, and more.

## Output

A JSON response containing the generated image data (in the requested format: jpeg, png, or webp), a success flag, payment settlement details in USDC, and a request ID with a status URL for tracking the async result.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "seed": {
   "type": "number"
  },
  "image": {
   "type": "string"
  },
  "prompt": {
   "type": "string"
  },
  "output_format": {
   "type": "string"
  },
  "negative_prompt": {
   "type": "string"
  },
  "control_strength": {
   "type": "number"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "data": {},
  "payment": {
   "scheme": "exact",
   "settledUsdc": "0.001000",
   "authorizedMaxUsdc": "0.001000"
  },
  "request": {
   "id": "00000000-0000-4000-8000-000000000000",
   "statusUrl": "/requests/00000000-0000-4000-8000-000000000000"
  },
  "success": true
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/stability-ai-sketch-to-image-via-locus-x402-d8cb7173/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from stability-ai.x402.paywithlocus.com](https://www.zero.xyz/host/stability-ai.x402.paywithlocus.com/llms.txt)
