9Router Video Generation (xAI Grok Imagine)
Generate, edit, and extend videos via 9Router's unified API using xAI Grok Imagine, with an async submit-poll-download job flow for text-to-video and image-to-video.
SKILL.md transparently discloses the data flow: requests pass through to api.x.ai, keys come from NINEROUTER_KEY env var, and it explicitly notes that subscription video quota is controlled by xAI and not verified by 9Router. No covert exfiltration, no overreach, and POSTs that could bill are deliberately never auto-retried, showing cost care. Deducted for: no user-confirmation mechanism described, incomplete rollback/cancellation coverage, unverified publisher, and setup delegated to an external document.
Docs are self-consistent: async flow (submit→poll→download), connection-header binding, atomic .part rename in the CLI, clean Ctrl+C, non-zero exit codes, and a structured failure state (failed + error code/message) show good failure feedback. Deducted for: static review only — no committed tests or third-party execution evidence covering the skill's key paths, fabricated example responses, and unaddressed edge cases like poll timeouts or network interruption.
Trigger conditions are clear in the description (create/generate/render video, txt2vid, image-to-video), field tables distinguish required vs optional, and non-fit is partially disclosed (403 means no video access). Deducted for: complete dependence on overseas services (xAI, console.x.ai, 9Router endpoints) with no mainland-China reachability assessment; the implicit assumption that the user holds a paid Grok subscription or xAI API key is not stated as an explicit boundary; no declared Chinese-language support.
MIT license is explicit, the repo has versioning (0.5.69), release workflows and maintenance signals; docs are well layered (field tables, examples, Notes & limits) with known-limitation disclosure. Deducted for: setup depends on a raw external link to a different SKILL.md rather than a local path, no per-skill changelog/version mapping, and maintenance responsibility is only implied at the repository level.
The core task path (text/image-to-video, polling, MP4 download) is fully described and the CLI one-shot yields a directly usable output file with clear marginal value (encapsulating async polling). Deducted for: unexecuted, success contingent on the user's existing paid xAI subscription/API key and 9Router configuration; cost/benefit evidence is thin and output correctness cannot be confirmed statically.
Field definitions link to the official xAI API reference, allowing cross-checking of request structure; the repo contains CI workflows and version-release evidence. Deducted for: no tests targeting this skill, no committed real execution outputs, all sample responses authored by the maintainer, and most key claims not independently reproducible from the static evidence.
- Video generation incurs real billing: a Grok Build OAuth (SuperGrok / X Premium+) subscription or an xAI API key is required, and whether a subscription tier includes video quota is not verified by 9Router — a 403 means no video access. Confirm pricing before use.
- Core function depends entirely on overseas services (api.x.ai, 9Router endpoints, console.x.ai); mainland-China reachability is unverified and a proxy may be needed.
- This is a static review with no executed requests; edge behavior such as poll timeouts and network interruption is untested.
- Setup instructions live in a separate external SKILL.md; if that content changes, this skill's documentation may break.
What does this skill do, and when should you use it?
9router-video is one of nine skills bundled in the decolua/9router repository (MIT-licensed), located at skills/9router-video/SKILL.md. It wraps 9Router's /v1/videos/* endpoints, backed by xAI's grok-imagine-video model. Generation is asynchronous: the POST returns a request_id immediately, you poll until the job is done or failed, then download the MP4. It requires a running 9Router instance and a connected xAI account in the dashboard — either Grok Build OAuth (SuperGrok / X Premium+) or a direct xAI API key, which are separate auth types with separate billing. Creation requests are never auto-retried to avoid double billing, and jobs are bound to the connection that created them.
Submits text-to-video or image-to-video jobs to POST /v1/videos/generations with fields prompt, duration, aspect_ratio (16:9, 9:16, 1:1, 4:3, 3:4, 3:2, 2:3), resolution (480p/720p/1080p), and image (URL or base64 data URI); submits video edits to /v1/videos/edits and extensions to /v1/videos/extensions; polls GET /v1/videos/{request_id} until done or failed; downloads the MP4 from the done response's video.url; or runs the whole flow in one shot via 9router xai video, which polls with progress, downloads to video.mp4.part, and atomically renames on success. Polls must echo back the x-connection-id header from the create response.
- A developer producing short promo clips who types a text description and gets back a 720p/1080p MP4
- A creator with a still image who wants to animate it via the image-to-video path using the image field
- A user who needs to trim-edit or lengthen an existing video through the edits/extensions endpoints
- A team wiring programmatic video generation into a pipeline using request_id polling as a background job
- CLI-first users who prefer `9router xai video --prompt ... --output video.mp4` over raw API calls
What are this skill's strengths and limitations?
- Single unified gateway API with fields passed through unchanged to xAI — full coverage of generate, edit, and extend
- Clean async design; the CLI handles submit, polling with progress, and atomic download in one command
- Creation POSTs are never auto-retried, preventing duplicate billed videos
- Video models are tagged kind: video and excluded from chat fallback combos, avoiding misuse
- Requires a connected xAI account; whether Grok subscription OAuth tiers include video quota is controlled by xAI and unverified by 9Router — a 403 means no video access
- Polling must echo the same x-connection-id used at creation; querying across connections fails
- No evidence of a dedicated test suite for this skill in the source; repository testing coverage is unknown
- Only works while a 9Router instance is running; it cannot be used standalone
How do you install this skill?
The skill ships inside the 9router repository: install the service with npm install -g 9router, then run 9router (dashboard at http://localhost:20128); or from source, run npm install then npm run dev in the repo. The skill file lives at skills/9router-video/SKILL.md — place it in your Agent Skills directory so compatible clients can discover it; the repo does not document per-client skill installation paths. Also connect an xAI account (Grok Build OAuth or an API key from console.x.ai) under Providers in the dashboard.
How do you use this skill?
Set NINEROUTER_URL (and NINEROUTER_KEY if auth is enabled). Example trigger prompt: "Generate a video: a cinematic tracking shot through a neon city at night, 8 seconds, 16:9, 720p." Manual call: curl -X POST "$NINEROUTER_URL/v1/videos/generations" -H "Authorization: Bearer $NINEROUTER_KEY" -H "Content-Type: application/" -d '{"model":"xai/grok-imagine-video","prompt":"...","duration":8,"aspect_ratio":"16:9","resolution":"720p"}', then poll GET /v1/videos/{request_id} with the x-connection-id header until done, and download video.url. Or one-shot: 9router xai video --prompt "..." --output video.mp4.
How does this skill compare with similar options?
Calling xAI's official API (api.x.ai/v1/videos) directly is the obvious alternative; 9Router's value is the unified gateway, dashboard account management, and CLI wrapper. If you already hold an xAI API key and don't need a gateway, direct access works equally well.