Skip to main content
GMI Cloud is Zap’s primary live video provider. When a step declares provider: gmi (or defaults.provider: gmi is set) and the run is dispatched with --live, the GMI adapter routes the request to the GMI Cloud request queue API and settles on the flagship BytePlus Seedance 2.0 model (seedance-2-0-260128). This page documents how to obtain a GMI key, wire it into a CLI or web run, and shape recipe steps to match Seedance’s parameters.
GMI keys are bring-your-own-key (BYOK). Zap does not proxy or resell GMI capacity. You must have a funded GMI Cloud account and export the key locally or store it in Supabase before any live run is accepted.

1. Obtain a GMI API Key

1

Sign in to GMI Cloud

Visit console.gmicloud.ai and sign in or create an account.
2

Generate an API key

Open Settings → API Keys and click Create key. Copy the key immediately — it will not be shown again.
3

(Optional) Note your org ID

If your account belongs to a shared workspace, copy the organisation ID from Settings → Organisation. Zap sends it as gmi_org_id when present.

2. Wire the Key Into Zap

Zap accepts the GMI key in two places, depending on where the run originates.

CLI runs — environment variable

Export the key in the shell where zap run --live will be invoked:
export GMI_API_KEY="sk-gmi-..."
export GMI_ORG_ID="org-..."   # optional
Or add to .env.local at your project root (already git-ignored by the zap init scaffold):
GMI_API_KEY=sk-gmi-...
GMI_ORG_ID=org-...
Run the doctor command to confirm the CLI can see the key:
npx @wzrdtech/zap@0.1.0 doctor

Web runs — Supabase vault

For runs initiated from zap.wzrd.tech, the key is stored server-side per creator wallet. See Auth & Secrets for the full flow. Summary:
PUT /api/secrets
Authorization: Bearer <supabase-session-token>
Content-Type: application/json

{ "provider": "gmi", "key": "gmi_api_key", "value": "sk-gmi-..." }
Keys are encrypted at rest and only decrypted server-side immediately before dispatching the run to GMI.

3. The Seedance 2.0 Model

Seedance 2.0 (seedance-2-0-260128) is the flagship BytePlus video model exposed through GMI. It supports three generation modes:
ModeTriggerDescription
T2V — Text-to-Videoprompt onlyGenerate a clip from a text description.
I2V — Image-to-Videofirst_frame (and optional last_frame)Animate a still image; optionally interpolate to a last frame.
R2V — Reference-to-Videoreference_images / reference_videos / reference_audiosCondition on up to 9 images, 3 videos, or 3 audios.
At least one of prompt, first_frame, reference_images, or reference_videos must be present.

Seedance parameters

ParameterTypeRequiredDefaultDescription
promptstringconditional""Text description. Required only if no image/video reference is supplied.
first_frameimage URLconditionalFirst-frame anchor for I2V.
last_frameimage URLnoOptional last-frame target for I2V interpolation.
reference_imagesimage URL[]conditionalUp to 9 reference images (R2V).
reference_videosvideo URL[]conditionalUp to 3 reference videos (R2V).
reference_audiosaudio URL[]noUp to 3 reference audios (R2V).
durationintegerno5Clip length in seconds. Valid range 4–15.
resolutionenumno"720p""480p", "720p", or "1080p".
ratioenumno"adaptive"Aspect ratio, e.g. "16:9", "9:16", "1:1".
generate_audiobooleannotrueGenerate a matching audio track.
watermarkbooleannofalseAdd a GMI watermark to the output.
seedintegernoReproducibility seed. -1 requests a random seed.
web_searchbooleannofalseEnrich the prompt with a web search before generation.

Pricing (per second of output video)

ResolutionPrice / second
480p$0.07
720p$0.152
1080p$0.374
Zap’s cost planner uses the 720p rate ($0.07/s in the built-in rate table) as the default — override with a step-level model or custom rate if you’re targeting a different resolution.

4. Recipe Examples

All three Seedance modes are expressible as a single video.gen step in a Zap recipe.

T2V — text-to-video

- id: initial_gen
  kind: video.gen
  provider: gmi
  model: seedance-2-0-260128
  duration_s: 5
  prompt: prompts/initial-gen.md
  # The prompt file body becomes the Seedance `prompt` field.
  audio:
    generate_audio: true
  first_frame:
    resolution: "720p"
    ratio: "16:9"

I2V — first-frame animation

- id: initial_frame
  kind: image.gen
  provider: gmi
  model: fal-ai/flux/dev
  prompt: prompts/initial-frame.md

- id: initial_gen
  kind: video.gen
  provider: gmi
  model: seedance-2-0-260128
  inputs: [initial_frame]              # -> first_frame
  duration_s: 5
  prompt: prompts/pan-up.md
  first_frame:
    resolution: "720p"
    ratio: "9:16"
Zap’s provider adapter maps the resolved inputs[0] URL to Seedance’s first_frame parameter automatically.

R2V — reference conditioning

- id: reference_gen
  kind: video.gen
  provider: gmi
  model: seedance-2-0-260128
  reference_images:
    - inputs/style_ref_1.jpg
    - inputs/style_ref_2.jpg
  duration_s: 7
  prompt: prompts/cinematic.md
  first_frame:
    resolution: "720p"
    ratio: "16:9"

5. Raw API Reference

Zap wraps these calls, but you may need to reproduce them directly for debugging.

Submit a request

POST https://console.gmicloud.ai/api/v1/ie/requestqueue/apikey/requests
Authorization: Bearer <GMI_API_KEY>
Content-Type: application/json
curl -X POST "https://console.gmicloud.ai/api/v1/ie/requestqueue/apikey/requests" \
  -H "Authorization: Bearer $GMI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "seedance-2-0-260128",
    "payload": {
      "prompt": "A majestic eagle soaring over snowy mountains at sunset",
      "duration": 5,
      "resolution": "720p",
      "ratio": "16:9",
      "generate_audio": true
    }
  }'

Response envelope

{
  "request_id": "abc123",
  "model": "seedance-2-0-260128",
  "status": "success",
  "outcome": {
    "media_urls": [
      { "id": "0", "url": "https://storage.googleapis.com/..." }
    ],
    "thumbnail_image_url": "https://storage.googleapis.com/..."
  }
}

Poll a request

GET https://console.gmicloud.ai/api/v1/ie/requestqueue/apikey/requests/{request_id}
Authorization: Bearer <GMI_API_KEY>
Zap’s runtime polls this endpoint via Upstash queue workers; you rarely need to call it manually. When you do, use it to confirm asynchronous completion during debugging.

6. Running Live End-to-End

# 1. Verify your key is loaded
npx @wzrdtech/zap@0.1.0 doctor

# 2. Mock the run to see the quote first
npx @wzrdtech/zap@0.1.0 run agent/skills/zap-my-zap/Zap.md --json

# 3. Approve the quote, then dispatch live
npx @wzrdtech/zap@0.1.0 run agent/skills/zap-my-zap/Zap.md --live --json \
  --input PROMPT="an astronaut riding a cheetah"
The live run returns a runId; check status with:
npx @wzrdtech/zap@0.1.0 status <runId>
Or open https://zap.wzrd.tech/runs/<runId> in the browser for the visual timeline.
Live runs charge your GMI Cloud account immediately when each step is accepted. Always run mock first, confirm the quote, and only pass --live after review. Budget caps in Zap.md are enforced server-side but will not refund a step that has already been dispatched.
  • Providers — how Zap routes each step and the full BYOK secret table.
  • Budget — how the planner quotes and enforces spend before dispatch.
  • Auth & Secrets — storing your GMI key in Supabase for web runs.
  • Step Kinds — all 11 step types and their per-model rates.