Spiral gives your agent every tool with one account. Browse the tools →

opencode · Image

How to Use Fibo 2.0 Edit in opencode

Use Fibo 2.0 Edit to restage products, change materials, or combine up to four source images. Unlike Generate, it starts with existing images and supports masked changes to one image.

Prompts to try with Fibo 2.0 Edit in opencode

Copy an example into opencode, or ask in your own words.

Use Fibo 2.0 Edit on the project's chair photograph. Replace only the masked upholstery with forest-green velvet, keeping the original pixels outside the mask. Save the result at the source dimensions.

Fibo 2.0 Editopencode
Try asking
  • Use Fibo 2.0 Edit to combine three project images: take the bottle from image 1, the tabletop setting from image 2, and the wordmark from image 3. Place the bottle centrally with the wordmark above it in a square composition.

  • Remove the background from the photo I attach with Fibo 2.0 Edit and give me a transparent PNG. Save the result in ./assets.

  • Use Fibo 2.0 Edit to clean up these product shots so they sit on pure white.

  • Edit this image with Fibo 2.0 Edit: keep the subject, swap the background for a sunlit studio.

How to set up Fibo 2.0 Edit 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.

    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.

    opencode mcp auth spiral
  3. Check it

    Spiral shows as connected.

    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.

    npx -y spiral-cli@latest init

Call the Spiral API

  1. Create an API key

    In the console, under API keys.

  2. Run Fibo 2.0 Edit

    One request; the result comes back by polling or a webhook.

    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": "bria/fibo-2/edit",
        "input": {
          "image_urls": [
            "<image_urls>"
          ]
        }
      }'

Then paste one of the prompts above: opencode finds Fibo 2.0 Edit on Spiral, shows the price and runs it.

Fibo 2.0 Edit providers and prices

Spiral runs Fibo 2.0 Edit through fal. Open a card for today's price, with every fee included.

falImage
Fibo 2.0 Edit
bria/fibo-2/edit

Settings you can ask for

Fibo 2.0 Edit works from your image URLs and mask URL. Ask opencode for any of these in your prompt.

SettingAllowed valuesDefaultDescription
Aspect ratio1:1, 1:2, 1:3, 1:4, 1:5, 2:1, 2:3, 3:1 and 13 more

Output aspect ratio, at about one megapixel. Left unset, the output keeps the ratio of the first image. A single image always keeps its own ratio.

Seed0 to 21474836475555

Random seed for reproducibility, 0 to 2147483647.

Every API field of Fibo 2.0 Edit is on its tool page: open its card above.

What can you do with Fibo 2.0 Edit in opencode?

Create project illustrations and revise existing image assets from concrete visual briefs. Keep returned VGL descriptions and seeds beside the assets so later revisions have a reproducible starting point.

Product restaging

Use Edit to place a product from one reference into a setting from another. Describe the product's placement and the details to retain.

Controlled campaign variations

Save a generated image's VGL and seed, then change a selected scene detail to explore variations from the same brief.

Localized asset revisions

Use a masked single-image edit to replace a selected region while retaining the source dimensions and original pixels elsewhere.

Illustrations from visual briefs

Use Generate for scenes with specific subjects, materials, lighting, and composition. Inspect the returned scene description before deciding what to revise.

Reference-led compositions

Combine a product, a setting, and lettering from three images with Edit. Assign each reference a distinct role in the instruction.

Repeatable image production

Keep the VGL and seed alongside approved generated images so an agent can reproduce them and prepare controlled revisions.

Questions about Fibo 2.0 Edit in opencode

Can opencode use Fibo 2.0 Edit?

Yes. Add Spiral to opencode as an MCP server, and opencode can find and run Fibo 2.0 Edit like any built-in tool.

How much does Fibo 2.0 Edit cost in opencode?

$0.052 per image. 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 Fibo 2.0 Edit in opencode?

No. Spiral runs Fibo 2.0 Edit on its own fal account. You sign in to Spiral once and never paste a key.

How long does it take to set up Fibo 2.0 Edit in opencode?

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

Does opencode wait while Fibo 2.0 Edit runs?

Fibo 2.0 Edit runs in the background. opencode starts the run, checks on it and gives you the image when it's ready.

When should I use Generate instead of Edit?

Choose Generate for a new scene from a written brief or visual reference. Choose Edit when an existing image supplies the product, subject, or composition you want to change.

What resolution should I expect?

Generate and multi-image edits are documented at approximately one megapixel. Masked single-image edits retain the source image's dimensions.

What is VGL useful for?

VGL is an editable JSON description of the scene. Save it with the seed to reproduce a generated result, then change selected details to make controlled variations.

Can it combine several reference images?

Edit accepts up to four images together. Give each image a clear role, such as the product, setting, or lettering to use in the result.

Will a masked edit preserve the original image?

Original pixels outside the mask are preserved, and the output retains the source dimensions. Inside the mask, the model generates new content, so treat the region as a replacement area.

Get started

Start using Fibo 2.0 Edit in opencode

One Spiral account for every tool your agent needs. No subscription; you pay per run.

Paste this into opencode:

Set up opencode

set up https://spiral.ai/SKILL.md
Are you an AI agent? See setup options