← Back to Skills Marketplace
🔌

Gen Video

by skills-video · GitHub ↗ · v1.0.1 · MIT-0
linuxdarwin ✓ Security Clean
141
Downloads
0
Stars
0
Active Installs
2
Versions
Install in OpenClaw
/install gen-video
Description
Build and execute skills.video video generation REST requests from OpenAPI specs. Use when user needs to create, debug, or document video generation calls on...
README (SKILL.md)

ai-video

Overview

Use this skill to turn OpenAPI definitions into working video-generation API calls for skills.video. Prefer deterministic extraction from openapi.json instead of guessing fields.

Prerequisites

  1. Obtain an API key at: https://skills.video/dashboard/developer
  2. Configure SKILLS_VIDEO_API_KEY before using the skill.

Preferred OpenClaw setup:

  • Open the skill settings for ai-video
  • Add an environment variable named SKILLS_VIDEO_API_KEY
  • Paste the API key as its value

Equivalent config shape:

{
  "skills": {
    "entries": {
      "ai-video": {
        "enabled": true,
        "env": {
          "SKILLS_VIDEO_API_KEY": "your_api_key_here"
        }
      }
    }
  }
}

Other valid ways to provide the key:

  • Shell: export SKILLS_VIDEO_API_KEY="your_api_key_here"
  • Tool-specific env config: any runtime that injects SKILLS_VIDEO_API_KEY

Workflow

  1. Check API key and bootstrap environment on first use.
  2. Identify the active spec.
  3. Select the SSE endpoint pair for a video model.
  4. Extract request schema and generate a payload template.
  5. Execute POST /generation/sse/... as default and keep the stream open.
  6. If SSE does not reach terminal completion, poll GET /generation/{id} to terminal status.
  7. Return only terminal result (COMPLETED/SUCCEEDED/FAILED/CANCELED), never IN_PROGRESS.
  8. Apply retry and failure handling.

0) Check API key (first run)

Run this check before any API call.

python scripts/ensure_api_key.py

If ok is false, tell the user to:

  • Follow the setup in Prerequisites

Example:

export SKILLS_VIDEO_API_KEY="\x3CYOUR_API_KEY>"

1) Identify the spec

Load the most specific OpenAPI first.

  • Prefer model-specific OpenAPI when available (for example /v1/openapi.json under a model namespace).
  • Fall back to platform-level openapi.json.
  • Use references/open-platform-api.md for base URL, auth, and async lifecycle.

2) Select a video endpoint

If docs.json exists, derive video endpoints from the Videos navigation group. Use default_endpoints from the script output as the primary list (SSE first).

python scripts/inspect_openapi.py \
  --openapi /abs/path/to/openapi.json \
  --docs /abs/path/to/docs.json \
  --list-endpoints

When docs.json is unavailable, pass a known endpoint directly (for example /generation/sse/kling-ai/kling-v2.6). Use references/video-model-endpoints.md as a snapshot list.

3) Extract schema and build payload

Inspect endpoint details and generate a request template from required/default fields.

python scripts/inspect_openapi.py \
  --openapi /abs/path/to/openapi.json \
  --endpoint /generation/sse/kling-ai/kling-v2.6 \
  --include-template

Use the returned request_template as the starting point. Do not add fields not defined by the endpoint schema. Use default_create_endpoint from output unless an explicit override is required.

4) Execute SSE request (default) with automatic fallback

Prefer the helper script. It creates via SSE and keeps streaming; if stream ends before terminal completion, it automatically switches to polling fallback.

python scripts/create_and_wait.py \
  --sse-endpoint /generation/sse/kling-ai/kling-v2.6 \
  --payload '{"prompt":"A cinematic dolly shot of neon city rain at night"}' \
  --poll-timeout 900 \
  --poll-interval 3

Treat SSE as the default result channel. Do not finish the task on IN_QUEUE or IN_PROGRESS. Return only after terminal result.

5) Fall back to polling

Use polling only if SSE cannot be established, disconnects early, or does not reach a terminal state. Use GET /generation/{id} (or model-spec equivalent path if the OpenAPI uses /v1/...).

curl -X GET "https://open.skills.video/api/v1/generation/\x3CGENERATION_ID>" \
  -H "Authorization: Bearer $SKILLS_VIDEO_API_KEY"

Stop polling on terminal states:

  • COMPLETED
  • FAILED
  • CANCELED

Recommended helper:

python scripts/wait_generation.py \
  --generation-id \x3CGENERATION_ID> \
  --timeout 900 \
  --interval 3

Return to user only after helper emits event=terminal.

6) Handle errors and retries

Handle these response codes for create, SSE, and fallback poll operations:

  • 400: request format issue
  • 401: missing/invalid API key
  • 402: possible payment/credits issue in runtime
  • 404: endpoint or generation id not found
  • 422: schema validation failed

Classify non-2xx runtime errors with:

python scripts/handle_runtime_error.py \
  --status \x3CHTTP_STATUS> \
  --body '\x3CRAW_ERROR_BODY_JSON_OR_TEXT>'

If category is insufficient_credits, tell the user to recharge:

  • Open https://skills.video/dashboard and go to Billing/Credits
  • Recharge or purchase additional credits
  • Retry after recharge

Optional balance check:

curl -X GET "https://open.skills.video/api/v1/credits" \
  -H "Authorization: Bearer $SKILLS_VIDEO_API_KEY"

Apply retries only for transient conditions (network failure or temporary 5xx). Use bounded exponential backoff (for example 1s, 2s, 4s, max 16s, then fail). Do not retry unchanged payloads after 4xx validation errors.

Rate limits and timeouts

Treat rate limits and server-side timeout windows as unknown unless documented in the active OpenAPI or product docs. If unknown, explicitly note this in output and choose conservative client defaults.

Resources

  • scripts/ensure_api_key.py: validate SKILLS_VIDEO_API_KEY and show first-run setup guidance
  • scripts/handle_runtime_error.py: classify runtime errors and provide recharge guidance for insufficient credits
  • scripts/inspect_openapi.py: extract SSE/polling endpoint pair, contract, and payload template
  • scripts/create_and_wait.py: create via SSE and auto-fallback to polling when stream does not reach terminal status
  • scripts/wait_generation.py: poll generation status until terminal completion and return final response
  • references/open-platform-api.md: SSE-first lifecycle, fallback polling, retry baseline
  • references/video-model-endpoints.md: current video endpoint snapshot from docs.json
Usage Guidance
This skill appears internally consistent: it needs your skills.video API key and standard tools (python3, curl) and then runs bundled scripts to parse OpenAPI files and call the skills.video endpoints. Before enabling: (1) Only provide a SKILLS_VIDEO_API_KEY you trust and do not hardcode it into files; use the skill env or shell env as instructed. (2) Only point the scripts at OpenAPI/docs and payload files you trust — the tooling will read those files and may run subprocesses. (3) The skill will make network calls to open.skills.video (and to any full URL you pass); ensure that is acceptable for your environment. (4) There appears to be a minor code truncation in one script's source listing (possible runtime bug) — consider running python scripts/ensure_api_key.py to verify the environment and review the bundled scripts if you need stricter assurance. If you need stricter security, review the included Python files locally before use or run them in a sandboxed environment.
Capability Assessment
Purpose & Capability
Name/description match what the package does: the skill builds requests from OpenAPI specs and calls skills.video endpoints. Required items (python3, curl, SKILLS_VIDEO_API_KEY) are expected and directly used by the scripts and examples.
Instruction Scope
SKILL.md and included scripts are narrowly scoped: they parse OpenAPI/docs JSON files, generate payload templates, open SSE streams to skills.video, and poll generation status. The instructions only reference OpenAPI/docs files and the SKILLS_VIDEO_API_KEY; they do not instruct reading unrelated system config or secrets. Note: the scripts execute subprocesses (to run the bundled wait script) and read files you pass (openapi/docs/payload files), so only provide trusted file paths.
Install Mechanism
No remote install/download step is declared — this is an instruction/script-only skill packaged with Python scripts. No URLs or archive extraction are used during install, lowering supply-chain risk.
Credentials
Only one environment variable is required: SKILLS_VIDEO_API_KEY (declared as primary). That is appropriate and proportional for calling the skills.video API. The scripts do not attempt to read other environment variables or unrelated credentials.
Persistence & Privilege
The skill is not marked always:true and uses normal agent invocation. It does not request system-wide configuration changes or other skills' credentials.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install gen-video
  3. After installation, invoke the skill by name or use /gen-video
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.1
- Skill renamed from "video-generation" to "ai-video" - Added explicit license information (MIT) and metadata including author, supported OS, required environment variables, and setup help - Expanded setup and prerequisites instructions for configuring `SKILLS_VIDEO_API_KEY` via OpenClaw or environment variables - Clarified API key setup in the first-run check section and linked to the expanded prerequisites - Provided OpenClaw-specific configuration examples and instructions for adding environment variables
v1.0.0
Initial release of the video-generation skill for orchestrating video API calls via OpenAPI specs. - Automates building and executing video-generation requests, supporting SSE and polling workflows. - Ensures environment setup and API key validation before any requests. - Dynamically discovers model endpoints and generates payload templates from OpenAPI. - Handles full async lifecycle, returning only terminal result states, never `IN_PROGRESS`. - Implements error classification, retry/backoff, and credit-recharge guidance. - Leverages helper scripts for endpoint inspection, payload creation, streaming, polling, and runtime error analysis.
Metadata
Slug gen-video
Version 1.0.1
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 2
Frequently Asked Questions

What is Gen Video?

Build and execute skills.video video generation REST requests from OpenAPI specs. Use when user needs to create, debug, or document video generation calls on... It is an AI Agent Skill for Claude Code / OpenClaw, with 141 downloads so far.

How do I install Gen Video?

Run "/install gen-video" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Gen Video free?

Yes, Gen Video is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Gen Video support?

Gen Video is cross-platform and runs anywhere OpenClaw / Claude Code is available (linux, darwin).

Who created Gen Video?

It is built and maintained by skills-video (@skills-video); the current version is v1.0.1.

💬 Comments