[Integrations](https://spiral.ai/integrations) › [opencode](https://spiral.ai/integrations/opencode) › [Wan 2.5 Text to Image](https://spiral.ai/integrations/opencode/wan-2-5-text-to-image)

# How to Use Wan 2.5 Text to Image in opencode

Wan 2.5 Text to Image creates images from written briefs, including layouts with English or Chinese text, charts, and diagrams. Unlike Wan 2.5 Image to Image, it starts without a reference image.

|  |  |
| --- | --- |
| Model | Wan 2.5 Text to Image |
| Available through | fal |
| Category | Image |
| Price | $0.065 per image. Billed on `num_images`, default 1. |
| Returns | image |
| Runs | In the background |
| Setup | About 2 minutes, no API key |

## Prompts to try with Wan 2.5 Text to Image in opencode

- Read the homepage copy and use Wan 2.5 Text to Image to create a 1280 × 720 editorial image of a bicycle workshop at dawn. Put the mechanic on the right and leave the left third empty for our headline.
- Read the onboarding explanation and use Wan 2.5 Text to Image to draft a 1280 × 720 diagram with three labeled stages: Import, Review, Export. Compare the image's labels and arrows against the explanation.
- Read the event brief and use Wan 2.5 Text to Image to draft a 1024 × 1024 poster with the exact heading 'Repair day'. Use a red bicycle, an off-white wall, and generous spacing; check the heading afterward.
- Generate a product photo with Wan 2.5 Text to Image: a matte black water bottle on wet slate, soft morning light, 1:1. Tell me the price first. Save the result in ./assets.
- Make four logo concepts for a coffee brand called "Northline" with Wan 2.5 Text to Image.

## How to set up Wan 2.5 Text to Image in opencode

Pick the way that suits you. Each takes about two minutes.

### Use Spiral's MCP server

1. **Add the server**: Leave out `--global` to add Spiral to the current project only. No header and no client ID or secret: opencode registers itself with Spiral.

```bash
opencode mcp add spiral --global --url https://api.spiral.ai/mcp
```

2. **Sign in**: Your browser opens. Sign in to Spiral, pick the organization and click Authorize, then return to the terminal. No API key. Inside opencode, `/mcps` starts the same sign-in.

```bash
opencode mcp auth spiral
```

3. **Check it**: Spiral shows as connected.

```bash
opencode mcp list
```

### Use the Spiral skill

1. **Send opencode this message**: Your agent reads Spiral's skill and sets itself up.

```
set up https://spiral.ai/SKILL.md
```

2. **Sign in or paste a key**: Approve Spiral in the browser, or give the agent a key from the console.

### Use the Spiral CLI

1. **Install and sign in**: Installs the Spiral CLI, signs you in and adds its skill to your coding agents.

```bash
npx -y spiral-cli@latest init
```

### Call the Spiral API

1. **Create an API key**: In the console, under API keys.

2. **Run Wan 2.5 Text to Image**: One request; the result comes back by polling or a webhook.

```bash
curl https://api.spiral.ai/v1/runs \
  -H "Authorization: Bearer $SPIRAL_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{
    "provider": "fal",
    "model": "fal-ai/wan-25-preview/text-to-image",
    "input": {
      "prompt": "A lone samurai standing on the edge of a cliff at twilight, overlooking a vast valley shrouded in mist. The sky burns with deep orange and purple hues from the…"
    }
  }'
```

Then paste one of the prompts above: opencode finds Wan 2.5 Text to Image on Spiral, shows the price and runs it.

Setup guide in the docs: https://spiral.ai/docs/quickstarts/opencode

## Wan 2.5 Text to Image tools and prices

- [Wan 2.5 · Text to Image](https://spiral.ai/tools/fal/fal-ai/wan-25-preview/text-to-image) (fal): $0.065 per image. Billed on `num_images`, default 1.

## Settings you can ask for

| Setting | Allowed values | Default | Description |
| --- | --- | --- | --- |
| negative_prompt |  | — | Negative prompt to describe content to avoid. Max 500 characters. |
| num_images | 1 to 4 | 1 | Number of images to generate. Values from 1 to 4. |
| image_size |  | square | The size of the generated image. Can use preset names like 'square', 'landscape_16_9', etc., or specific dimensions. Total pixels must be between 768×768 and 1440×1440, with aspect ratio between [1:4, 4:1]. |
| enable_prompt_expansion |  | true | Whether to enable prompt rewriting using LLM. Improves results for short prompts but increases processing time. |
| seed |  | — | Random seed for reproducibility. If None, a random seed is chosen. |

## What can you do with Wan 2.5 Text to Image in opencode?

Turn project briefs into artwork you can inspect in the actual page layout with Wan 2.5. Let the coding agent prepare focused image instructions and place reviewed results beside the relevant content.

### Product campaign concepts

Create a product scene from a written brief with Wan 2.5 Text to Image, or restage a supplied product photo with Wan 2.5 Image to Image. Specify the surface, lighting, and room for copy.

### Article cover artwork

Illustrate an article's central idea from text or revise supplied artwork. Use a wide composition with a clear focal point and deliberate space for the title.

### Social campaign artwork

Draft square campaign images from a brief or adapt an existing campaign image. Specify one message, a defined palette, and a simple composition for review.

### Illustration style exploration

Explore watercolor, photographic, or painterly treatments of a scene. Start from a description with Wan 2.5 Text to Image or a supplied image with Wan 2.5 Image to Image.

### Bilingual poster drafts

Use Wan 2.5 Text to Image to draft posters containing English and Chinese copy. Supply the exact wording and review the rendered text before publication.

### Diagram layout drafts

Turn a written explanation into a chart or architectural diagram with Wan 2.5 Text to Image. Treat the result as a visual draft and check labels, values, and connections.

## Overview

- [fal](https://spiral.ai/providers/fal)
- [All opencode guides](https://spiral.ai/integrations/opencode)

## Wan 2.5 Text to Image in other agents

- [Amp](https://spiral.ai/integrations/amp/wan-2-5-text-to-image)
- [ChatGPT](https://spiral.ai/integrations/chatgpt/wan-2-5-text-to-image)
- [Claude](https://spiral.ai/integrations/claude-desktop/wan-2-5-text-to-image)
- [Claude Code](https://spiral.ai/integrations/claude-code/wan-2-5-text-to-image)
- [Cline](https://spiral.ai/integrations/cline/wan-2-5-text-to-image)
- [Codex](https://spiral.ai/integrations/codex/wan-2-5-text-to-image)
- [Cursor](https://spiral.ai/integrations/cursor/wan-2-5-text-to-image)
- [Devin](https://spiral.ai/integrations/devin/wan-2-5-text-to-image)
- [dots](https://spiral.ai/integrations/dots/wan-2-5-text-to-image)
- [Factory Droid](https://spiral.ai/integrations/factory-droid/wan-2-5-text-to-image)
- [Gemini](https://spiral.ai/integrations/gemini/wan-2-5-text-to-image)
- [Gemini CLI](https://spiral.ai/integrations/gemini-cli/wan-2-5-text-to-image)
- [Google Antigravity](https://spiral.ai/integrations/antigravity/wan-2-5-text-to-image)
- [goose](https://spiral.ai/integrations/goose/wan-2-5-text-to-image)
- [Grok](https://spiral.ai/integrations/grok/wan-2-5-text-to-image)
- [Grok Build](https://spiral.ai/integrations/grok-build/wan-2-5-text-to-image)
- [Hermes](https://spiral.ai/integrations/hermes/wan-2-5-text-to-image)
- [Instinct](https://spiral.ai/integrations/instinct/wan-2-5-text-to-image)
- [Manus](https://spiral.ai/integrations/manus/wan-2-5-text-to-image)
- [Muse](https://spiral.ai/integrations/muse/wan-2-5-text-to-image)
- [Muse Code](https://spiral.ai/integrations/muse-code/wan-2-5-text-to-image)
- [n8n](https://spiral.ai/integrations/n8n/wan-2-5-text-to-image)
- [Notion](https://spiral.ai/integrations/notion/wan-2-5-text-to-image)
- [OpenClaw](https://spiral.ai/integrations/openclaw/wan-2-5-text-to-image)
- [Perplexity](https://spiral.ai/integrations/perplexity/wan-2-5-text-to-image)
- [Raycast](https://spiral.ai/integrations/raycast/wan-2-5-text-to-image)
- [VS Code](https://spiral.ai/integrations/vscode/wan-2-5-text-to-image)
- [Windsurf](https://spiral.ai/integrations/windsurf/wan-2-5-text-to-image)
- [Zapier](https://spiral.ai/integrations/zapier/wan-2-5-text-to-image)

## More opencode guides

- [Wan 2.5 Image to Image](https://spiral.ai/integrations/opencode/wan-2-5-image-to-image)
- [Wan 2.6 Image to Image](https://spiral.ai/integrations/opencode/wan-2-6-image-to-image)
- [Wan 2.2 A14B Text to Image LoRA](https://spiral.ai/integrations/opencode/wan-2-2-a14b-text-to-image-lora)
- [Wan 2.6 Text to Image](https://spiral.ai/integrations/opencode/wan-2-6-text-to-image)
- [Wan 2.2 A14B Text to Image](https://spiral.ai/integrations/opencode/wan-2-2-a14b-text-to-image)
- [Wan 2.7 Image to Image](https://spiral.ai/integrations/opencode/wan-2-7-image-to-image)

## Questions about Wan 2.5 Text to Image in opencode

**Can opencode use Wan 2.5 Text to Image?**

Yes. Add Spiral to opencode as an MCP server, and opencode can find and run Wan 2.5 Text to Image like any built-in tool.

**How much does Wan 2.5 Text to Image cost in opencode?**

$0.065 per image. Billed on `num_images`, default 1. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your opencode plan is separate.

**Do I need a fal account to use Wan 2.5 Text to Image in opencode?**

No. Spiral runs Wan 2.5 Text to Image on its own fal account. You sign in to Spiral once and never paste a key.

**How long does it take to set up Wan 2.5 Text to Image in opencode?**

About two minutes: add the server, then sign in, then check it.

**Does opencode wait while Wan 2.5 Text to Image runs?**

Wan 2.5 Text to Image runs in the background. opencode starts the run, checks on it and gives you the image when it's ready.

**How should I write a Wan 2.5 prompt?**

Describe the subject, setting, visual style, camera angle, lighting, and composition. As a practical starting point, give each instruction a clear purpose, such as leaving empty space above the subject for a headline.

**Can I prompt Wan 2.5 in English or Chinese?**

Yes, Wan 2.5 accepts instructions in English and Chinese. Use concrete descriptions of what should appear in the image.

**What image dimensions should I start with?**

A practical starting point is 1024 × 1024 for square artwork or 1280 × 720 for a wide composition. Both sizes fit the documented limits for Wan 2.5 image generation and editing.

**Can Wan 2.5 produce native 4K square images?**

No. A 4096 × 4096 output exceeds the documented limits for Wan 2.5 image generation and editing; plan a separate enlargement step if you need that size.

**Will using the same seed reproduce an image exactly?**

A fixed seed helps compare results, but it does not guarantee an identical image. Save an approved output instead of relying on regenerating it later.

