# Haven Image Upscale

> Haven Image Upscale is a paid API for AI agents from api.havenagent.ai, paid per call via x402, $0.06/call, status unknown (last checked 2026-10-21).

Upscales an image by 2x or 4x using AI, with an optional face-enhancement mode, returning a job ID and result URL for async polling.

## Facts

- Endpoint: POST https://api.havenagent.ai/x402/api/v1/image/upscale?utm_source=zero.xyz
- Price: $0.06/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-21
- Success rate: 0% of calls made through Zero
- Rating: 1.3 / 5 from 1 review
- Activations on Zero: 2
- Tags: x402
- Canonical page: https://www.zero.xyz/c/haven-image-upscale-2a2ed0bb
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_U6MC5HzpMVYSh46Rgj9Tf

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 haven-image-upscale-2a2ed0bb -d '<json body>'
```

Example prompt: Can you upscale this photo by 4x using face enhancement mode? It's a JPEG portrait and I want the highest quality result.

## When to prefer this

Choose this endpoint when you need AI-powered image upscaling with either general (auto) or face-optimized enhancement, supporting 2x or 4x enlargement of PNG or JPEG images, and can tolerate async processing (up to ~5 minutes). Prefer face mode for portrait or headshot images. Best suited for agents that can handle polling workflows and x402 USDC micropayments.

## Known failure modes

- Invalid or corrupt base64 image data — returns error on submission
- Unsupported media type (not image/png or image/jpeg) — rejected at input validation
- Upscale factor not 2 or 4 — enum validation failure
- Job timeout if processing exceeds pollBudgetSeconds (1200s) — result may not be available
- Payment failure via x402 protocol — request blocked without $0.06 USDC
- Image too large or too small for upscaling — possible server-side rejection
- Network timeout while polling statusUrl

## How this service works

Haven is a private AI agent for your home. Join the waitlist for h1 speaker updates and early app access.

## Output

Returns a JSON object with a job ID, initial status ('queued'), a result URL to fetch the upscaled image once complete, a status polling URL, an estimated completion time in seconds (etaSeconds), and a maximum polling budget in seconds. The agent must poll the statusUrl until complete, then retrieve the upscaled image from resultUrl.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "mode": {
   "enum": [
    "auto",
    "face"
   ],
   "type": "string",
   "default": "auto"
  },
  "factor": {
   "enum": [
    2,
    4
   ],
   "type": "number",
   "default": 2
  },
  "mediaType": {
   "enum": [
    "image/png",
    "image/jpeg"
   ],
   "type": "string"
  },
  "imageBase64": {
   "type": "string",
   "description": "base64 image bytes, no data-URI prefix"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "kind": "image_upscale",
  "jobId": "00000000-0000-0000-0000-000000000000",
  "status": "queued",
  "resultUrl": "https://api.havenagent.ai/x402/api/v1/image/upscale/jobs/00000000-0000-0000-0000-000000000000/result",
  "statusUrl": "https://api.havenagent.ai/x402/api/v1/image/upscale/jobs/00000000-0000-0000-0000-000000000000",
  "etaSeconds": 300,
  "pollBudgetSeconds": 1200
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/haven-image-upscale-2a2ed0bb/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.havenagent.ai](https://www.zero.xyz/host/api.havenagent.ai/llms.txt)
