# StableStudio Grok Edit Image Generation

> StableStudio Grok Edit Image Generation is a paid API for AI agents from stablestudio.io, paid per call via x402, $10/call, status unknown (last checked 2026-09-16).

Generates an AI image using the Grok model with configurable resolution, aspect ratio, format, and safety settings, returning a job ID for async retrieval.

## Facts

- Endpoint: POST https://stablestudio.io/api/generate/grok/edit
- Price: $10/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-16
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/stablestudio-grok-edit-image-generation-71ac7329
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_TlB7b5gETm7WvGetWdd5p

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 stablestudio-grok-edit-image-generation-71ac7329 -d '<json body>'
```

Example prompt: Generate an image of a futuristic cityscape at night with neon lights reflecting on wet streets — make it 4MP resolution, 16:9 aspect ratio, PNG format at quality 95, with safety tolerance 2.

## When to prefer this

Choose this endpoint when you need pay-per-use Grok-powered AI image generation with no subscription commitment, especially when you want fine-grained control over resolution (up to 4MP), aspect ratio, format (webp/jpg/png), and content safety tolerance. Prefer this over other image generators when the user specifically wants Grok's image model or wants to avoid monthly subscription costs.

## Known failure modes

- Missing required 'prompt' field returns validation error
- Prompt exceeding 10,000 characters rejected
- Invalid resolution enum value (not '0.5 MP', '1 MP', '2 MP', '4 MP') causes error
- Invalid aspect ratio value causes schema validation failure
- Safety tolerance outside 1-5 range rejected
- Payment of $10 USDC not provided or fails — request not processed
- Output quality outside 0-100 range rejected

## How this service works

Pay-per-generation AI image and video creation. No subscriptions ever.

## Output

Returns a JSON object containing a job ID (e.g. 'cmpbmzaee000j04jrzx4f43tw'), the generation type ('grok-edit'), a status field ('pending'), and a success boolean. The agent must use the job ID to poll or retrieve the final generated image once processing completes.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "images": {
   "type": "array",
   "items": {
    "type": "string",
    "format": "uri",
    "description": "Image URL"
   },
   "minItems": 1,
   "description": "Array of image URLs to edit"
  },
  "prompt": {
   "type": "string",
   "maxLength": 8000,
   "minLength": 1,
   "description": "A detailed description of the image you want to generate"
  },
  "aspect_ratio": {
   "enum": [
    "1:1",
    "16:9",
    "9:16",
    "4:3",
    "3:4",
    "3:2",
    "2:3",
    "2:1",
    "1:2",
    "19.5:9",
    "9:19.5",
    "20:9",
    "9:20"
   ],
   "type": "string",
   "default": "16:9",
   "description": "Aspect ratio of the output image"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "type": "grok-edit",
  "jobId": "cmpbmzaee000j04jrzx4f43tw",
  "status": "pending",
  "pollUrl": "https://stablestudio.dev/api/jobs/cmpbmzaee000j04jrzx4f43tw",
  "success": true
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/stablestudio-grok-edit-image-generation-71ac7329/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from stablestudio.io](https://www.zero.xyz/host/stablestudio.io/llms.txt)
