letz-ai/letzai-skillMIT8 files

Letzai API

Generate AI images and videos via the LetzAI API. Images with Nano Banana Pro, Seedream 5, Flux 2, GPT Image 2; videos with Veo 3.1, Kling V3, Seedance 2.0. Includes context editing, upscaling, asset uploads, and custom @model training. Use for content creation apps and automation.

Specification
Skill ID
letz-ai/letzai-skill/letzai-api
Publisher
letz-ai
Repository
letzai-skill
Installs
0
Files
8
License
MIT
Synced
Sep 23, 2026
How to use it

Open any RiverX project, open the Skills panel in the chat, and search for this identifier. The files are fetched from the source repository at install time.

letz-ai/letzai-skill/letzai-apiInstalls these files
  • LICENSE.txt
  • README.md
  • SKILL.md
  • api_reference.md
  • examples/image_generation.js
  • examples/polling_pattern.md
  • examples/uploads_and_training.md
  • examples/video_generation.py

What this skill tells the agent

LetzAI API Integration Skill

Overview

Helps you integrate the LetzAI public API for AI image and video generation, editing, upscaling, asset uploads, and custom model (LoRA) training. Custom-trained models for persons, objects and styles are referenced inside prompts with @modelname.

Authentication

  • Base URL: https://api.letz.ai
  • Auth: Authorization: Bearer YOUR_API_KEY
  • Get an API key: letz.ai/subscription
  • Swagger (source of truth): api.letz.ai/doc — machine-readable at /doc-json and /doc-yaml
const headers = {
  'Content-Type': 'application/json',
  Authorization: `Bearer ${process.env.LETZAI_API_KEY}`,
};
headers = {
    "Content-Type": "application/json",
    "Authorization": f"Bearer {os.environ['LETZAI_API_KEY']}",
}
Do not confuse the public API with the private one. https://api.letz.ai is the public developer API described here. https://private-api.letz.ai powers the LetzAI web app and has different route names (/upscales, /image_completions, /video-edits). Those routes 404 on the public API.

Unknown-field rejection

The API validates request bodies strictly. Sending a field that is not in the schema returns 400. In particular there is no negativePrompt, seed or aspectRatio on POST /images — aspect ratio is expressed via width/height.

Core Workflows

1. Image Generation — POST /images

ParameterTypeDefaultNotes
promptstring—Required. May contain @modelname tags.
baseModelstringaccount defaultSee model table below.
modestringmodel defaultResolution tier — allowed values differ per model.
widthint1600480–2160
heightint1600480–2160
qualityint21–6
creativityint21–6
hasWatermarkbooltrue
systemVersionintaccount default2 or 3
hideFromUserProfileboolfalse
webhookUrlstring—POSTed when the job finishes.
organizationIdUUID—Bill credits to an org you belong to.
Image models

mode is the resolution tier, and the accepted values are model-specific.

ModelbaseModelmode valuesCredits (generate)Credits (edit)
Nano Banana Pro (Google)gemini-3-pro-imagedefault (1K) · 2k (HD) · 4k80 / 160 / 24080 / 160 / 240
Nano Banana 2 (Google)nbf-inferenceshdefault (1K) · 2k (HD) · 4k40 / 80 / 16050 / 100 / 150
Nano Banana 2 Lite (Google)nano-banana-2-litedefault (1K)2025
Seedream 5 Pro (ByteDance)seedream-5-0-pro2k (HD) · 4k80 / 16080 / 160
Seedream 4.5 (ByteDance)seedream-4-5-2511282k (HD) · 4k80 / 16080 / 160
Flux 2 (Black Forest Labs)flux21k · hd60 / 12060 / 120
GPT Image 2 (OpenAI)gpt-image-21k · hd · 4k160 / 240 / 480160 / 240 / 480
WAN 2.7 Image Pro (Alibaba)wan-2-7-image-pro1k · 2k1010

Aliases are accepted, e.g. gemini-3-pro-image-preview still resolves to Nano Banana Pro. The live catalogue with pricing lives at letz.ai/docs/models.json.

Workflow

  1. POST /images
  2. Read id from the response
  3. Poll GET /images/{id} every 3 s
  4. On status === "ready", read imageVersions.original

See examples/image_generation.js.

2. Video Generation — POST /videos

ParameterTypeNotes
promptstringRequired.
originalImageCompletionIdUUIDAnimate a previously generated LetzAI image.
imageUrlstringAnimate a public image URL.
imageUrlsstring[]Multi-frame: [0] = first frame, [1] = last frame.
promptsobject[]Multi-shot storyboards (video-kling3): [{ prompt, duration }].
baseModelstringOptional; settings.mode is the usual selector.
width / height / resolutionnumberOptional output sizing.
settingsobjectModel + duration + audio (below).
webhookUrlstring
hidePromptbool
organizationIdUUID

Image input is optional — omit all of originalImageCompletionId / imageUrl / imageUrls for pure text-to-video.

settings
FieldNotes
modeVideo model key — see table.
durationSeconds, clamped to the model's allowed values.
withSoundEnable native audio where supported.
highQualityHigher-resolution tier; usually doubles the price.
resolution"720p", "1080p", "4k" for per-second-priced models.
Video models

Use the `video-` prefixed key as settings.mode.

Modelsettings.modeDurationCredits
Google Veo 3.1video-veo318 s (fixed)1500 · ×2 with audio · ×2 at 1080p
Kling V3video-kling33–15 s150 · 300 with audio
Kling V2.6video-kling265 or 10 s150 · ×2 with audio · ×2 at 1080p
WAN 2.5video-wan255 or 10 s110 · ×2 at 1080p (image-to-video only)
Seedance 2.0video-seedance24–15 sper second: 105 @480p · 210 @720p · 500 @1080p · 1000 @4K (audio always on)
Seedance 2.0 Enterprisevideo-seedance2-enterprise4–15 ssame as Seedance 2.0; requires organizationIdonly available to Enterprise Customers with an active organization
Gemini Omni Flashvideo-gemini-omni3–10 s100 per second (audio always on)

Workflow

  1. POST /videos
  2. Poll GET /videos/{id} every 2–3 s
  3. On status === "ready", read videoVersions.original

See examples/video_generation.py.

3. Image Editing — POST /image-edits

ParameterTypeNotes
modestringRequired. context (AI editing) or skin (skin fix).
promptstringEdit instruction. May contain @modelname tags.
imageUrlstringSingle source image URL.
inputImageUrlsstring[]Multi-reference source images (up to 9 in practice).
originalImageCompletionIdUUIDEdit a previously generated LetzAI image.
originalImageCompletionIdsUUID[]Several LetzAI images as sources.
baseModelstringSame identifiers as image generation.
settingsobject{ resolution, aspect_ratio, model }
imageCompletionsCountintVariations to generate (1–5, default 1). Not used by skin.
maskstringBase64 mask, legacy inpainting only.
width / heightnumberTarget dimensions.
webhookUrl, organizationId, hidePrompt

settings:

  • resolution: "2k" (HD) or "4k" (Ultra HD)
  • aspect_ratio: "1:1", "16:9", "9:16", "4:3", "3:4", "21:9", "9:21"
  • model: same identifiers as baseModel

Provide at least one source: imageUrl, inputImageUrls, originalImageCompletionId or originalImageCompletionIds.

Prefer the top-level `baseModel`. Server-side queue routing reads baseModel; settings.model is forwarded to the worker. Setting both to the same value is safest.

Workflow

  1. POST /image-edits
  2. Poll GET /image-edits/{id} every 3 s
  3. On status === "ready", read generatedImageCompletion.imageVersions.original

mode: "in" (inpainting) and mode: "out" (outpainting) are deprecated — use context.

4. Upscaling — POST /upscale

The public route is `/upscale` (singular). /upscales is the private web-app route and returns 404 here.
ParameterTypeDefaultNotes
imageIdUUID—A LetzAI image completion ID.
imageUrlstring—Public image URL. Use instead of imageId. To upscale your own file, upload it via /user-assets and pass the returned imageUrl.

Use this skill in a project

Open any RiverX project, search the Skills panel for letz-ai/letzai-skill/letzai-api, and install it in one click.

Use this skill