Developer API

Video API

Queue AI video jobs, track generation status, repurpose long videos into clips, and run studio tools for images, audio, lipsync, edits, and ads.

Create jobs

Start long-running video generation and repurpose jobs. Create requests should include Idempotency-Key.

Example
curl -X POST https://api.grik.io/api/v1/generate/video \
  -H "Authorization: Bearer GRIK_API_KEY" \
  -H "Idempotency-Key: video_job_123" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "kling",
    "task_type": "multi-image2video",
    "prompt": "A cinematic product reveal on a black reflective table",
    "aspect_ratio": "16:9",
    "duration": "5s",
    "mode": "standard",
    "sound": "on",
    "image_list": [
      {"image": "BASE64_IMAGE_1"},
      {"image": "BASE64_IMAGE_2"}
    ]
  }'
GET/rico/workflows

List RICO Supercomputer recipes and allowlisted executor workflows for web, MCP, CLI, and API use.

Auth: API keyScope: rico.media or videoAudience: Developers
GET/rico/recipes

List RICO Supercomputer recipes only.

Auth: API keyScope: rico.media or videoAudience: Developers
POST/rico/sessions

Create a RICO Supercomputer session with brief, recipe, inputs, cost estimate, messages, and pending steps.

Auth: API keyScope: rico.media or videoAudience: Developers
POST/rico/sessions/:id/approve

Approve a RICO Supercomputer session, deduct RICO media credits, and queue deterministic execution.

Auth: API keyScope: rico.media or videoAudience: Developers
POST/rico/mcp

Call the RICO MCP endpoint with tools such as rico_estimate_cost, rico_apply_effect, rico_repurpose, and rico_get_job.

Auth: API keyScope: rico.media or videoAudience: Developers
POST/generate/video

Start text-to-video or image-to-video generation with model, aspect ratio, duration, mode, image URL, and sound options.Send Idempotency-Key for user-triggered create/retry requests.

Auth: API keyScope: videoAudience: Developers
POST/kling/videos/effects

Queue a Kling Video Effects Center task by effect_scene with single-image or dual-image input.

Auth: API keyScope: videoAudience: Developers
POST/kling/lipsync

Queue Kling advanced lip-sync and track it through the provider task registry.

Auth: API keyScope: videoAudience: Developers
POST/kling/multi-elements

Queue a Kling multi-elements video editing task.

Auth: API keyScope: videoAudience: Developers
POST/repurpose

Start a repurposing pipeline from a YouTube or file URL with optional language.Send Idempotency-Key for user-triggered create/retry requests.

Auth: API keyScope: videoAudience: Developers

Check status

Poll generation and repurpose records until the job reaches a terminal status.

GET/rico/sessions

List recent RICO Supercomputer sessions for the authenticated account.

Auth: API keyScope: rico.media or videoAudience: Developers
GET/rico/sessions/:id

Fetch a RICO Supercomputer session with messages, workflow steps, status, and current assets.

Auth: API keyScope: rico.media or videoAudience: Developers
GET/rico/sessions/:id/events

Fetch a polling-friendly RICO session timeline with messages, steps, and assets.

Auth: API keyScope: rico.media or videoAudience: Developers
POST/rico/sessions/:id/messages

Add a user or assistant message to an existing RICO session.

Auth: API keyScope: rico.media or videoAudience: Developers
GET/rico/sessions/:id/assets

List media assets produced by a RICO Supercomputer session.

Auth: API keyScope: rico.media or videoAudience: Developers
GET/rico/assets

List recent RICO media assets.

Auth: API keyScope: rico.media or videoAudience: Developers
POST/rico/assets

Upload or register a RICO media asset by multipart file, URL, or data URL.

Auth: API keyScope: rico.media or videoAudience: Developers
GET/rico/assets/:id

Fetch one RICO media asset by id.

Auth: API keyScope: rico.media or videoAudience: Developers
GET/generation/:id

Fetch a generation record, status, output video URL, metadata, file size, and any error message.

Auth: API keyScope: videoAudience: Developers
GET/kling/tasks/:id

Fetch any Kling provider task by local task ID, provider task ID, or external task ID.

Auth: API keyScope: videoAudience: Developers
GET/repurpose

List recent repurpose jobs.

Auth: API keyScope: videoAudience: Developers
GET/repurpose/:id

Fetch a repurposing task with rendered clips, transcripts, segments, viral scores, and output URLs.

Auth: API keyScope: videoAudience: Developers
POST/repurpose/:id/retry

Retry a failed repurpose job.

Auth: API keyScope: videoAudience: Developers
DELETE/repurpose/:id

Delete a repurpose job by id.

Auth: API keyScope: videoAudience: Developers
PUT/repurpose/:task_id/clip/:clip_id

Update a clip edit state for a repurpose task.

Auth: API keyScope: videoAudience: Developers
POST/repurpose/:task_id/clip/:clip_id/render-captions

Render a repurpose clip with timeline edits and optional burned captions.

Auth: API keyScope: videoAudience: Developers

Image tools

Generate, edit, enhance, faceswap, and create character or 3D-angle assets for video workflows.

POST/images/generate

Generate images from a prompt, reference image, palette, model, and resolution. Kling models are queued through the provider task registry.

Auth: API keyScope: videoAudience: Developers
POST/kling/images/generations

Queue Kling image generation directly with model_name, n, aspect ratio, references, and provider task status.

Auth: API keyScope: videoAudience: Developers
POST/kling/general/ai-multi-shot

Queue Kling AI Multi-Shot from one frontal image and store all returned shots in the media library.

Auth: API keyScope: videoAudience: Developers
POST/kling/images/kolors-virtual-try-on

Queue Kling Kolors virtual try-on with human and cloth images.

Auth: API keyScope: videoAudience: Developers
POST/images/edit

Edit an image with a prompt and source image URL.

Auth: API keyScope: videoAudience: Developers
POST/images/enhance

Enhance or upscale an image asset.

Auth: API keyScope: videoAudience: Developers
POST/images/faceswap

Swap a face between target and source images.

Auth: API keyScope: videoAudience: Developers
POST/images/3d-angles

Generate a 3D/360-style video from an image.

Auth: API keyScope: videoAudience: Developers
POST/images/character-gen

Generate a consistent character from a prompt and optional reference image.

Auth: API keyScope: videoAudience: Developers

Studio tools

Run speech, audio enhancement, lipsync, recast, transition, edit, and ad generation operations.

POST/kling/image-recognize

Run Kling image recognition and segmentation utilities for object, head, face, and clothing masks.

Auth: API keyScope: videoAudience: Developers
POST/kling/audio/text-to-audio

Queue Kling text-to-audio generation and persist the generated audio in the media library.

Auth: API keyScope: videoAudience: Developers
POST/kling/audio/video-to-audio

Queue Kling video-to-audio generation for a supplied video source.

Auth: API keyScope: videoAudience: Developers
POST/kling/lipsync/identify-face

Identify faces for Kling lip-sync workflows before creating the final lip-sync task.

Auth: API keyScope: videoAudience: Developers
POST/kling/voices

Create a Kling custom voice task.

Auth: API keyScope: videoAudience: Developers
GET/kling/voices

List Kling custom voices.

Auth: API keyScope: videoAudience: Developers
GET/kling/voices/:id

Fetch one Kling custom voice task by id.

Auth: API keyScope: videoAudience: Developers
POST/kling/voices/delete

Queue deletion of a Kling custom voice.

Auth: API keyScope: videoAudience: Developers
GET/kling/voices/presets

List Kling preset voices available for audio and avatar tools.

Auth: API keyScope: videoAudience: Developers
POST/kling/elements

Create Kling advanced custom elements for multi-element video editing.

Auth: API keyScope: videoAudience: Developers
GET/kling/elements

List Kling advanced custom elements.

Auth: API keyScope: videoAudience: Developers
GET/kling/elements/:id

Fetch one Kling advanced custom element by id.

Auth: API keyScope: videoAudience: Developers
POST/kling/multi-elements/init-selection

Initialize Kling multi-elements selections for editing workflows.

Auth: API keyScope: videoAudience: Developers
POST/kling/multi-elements/add-selection

Add a Kling multi-elements selection.

Auth: API keyScope: videoAudience: Developers
POST/kling/multi-elements/delete-selection

Delete a Kling multi-elements selection.

Auth: API keyScope: videoAudience: Developers
POST/kling/multi-elements/clear-selection

Clear all Kling multi-elements selections.

Auth: API keyScope: videoAudience: Developers
POST/kling/multi-elements/preview-selection

Preview a Kling multi-elements selection.

Auth: API keyScope: videoAudience: Developers
GET/kling/multi-elements

List Kling multi-elements tasks.

Auth: API keyScope: videoAudience: Developers
GET/kling/multi-elements/:id

Fetch one Kling multi-elements task by id.

Auth: API keyScope: videoAudience: Developers
POST/repurpose/tts

Generate speech audio from text and a voice selection.

Auth: API keyScope: videoAudience: Developers
POST/repurpose/enhance-audio

Queue audio enhancement for a source video.

Auth: API keyScope: videoAudience: Developers
POST/repurpose/lipsync

Synchronize a video with a supplied audio track.

Auth: API keyScope: videoAudience: Developers
POST/repurpose/recast

Replace or recast a character in a source video with a target image.

Auth: API keyScope: videoAudience: Developers
POST/video/transitions

Create transitions across two or more input video URLs.

Auth: API keyScope: videoAudience: Developers
POST/video/edit

Edit an existing video with a natural-language prompt.

Auth: API keyScope: videoAudience: Developers
POST/ads/generate

Generate an ad creative from a product URL.

Auth: API keyScope: videoAudience: Developers
GET/broll/search

Search for B-roll media for repurpose and editing workflows.

Auth: API keyScope: videoAudience: Developers