Integrate Multimodal AI
Into Your Code

Unified API for LLM, image, video, audio, and 3D models. Returns structured data you can process. TypeScript and Python support.

npm install @seacloudai/sdk

Code Examples

See the SDK in code

import { SeaCloud } from '@seacloudai/sdk';

const client = new SeaCloud({
  apiKey: process.env.SEACLOUD_API_KEY
});

// Wait for the result
const result = await client.runSync('wan25_t2i_preview', {
  prompt: 'a photorealistic orange tabby cat by a sunny window',
  size: '1024*1024',
  n: 1
});

console.log(result.output?.urls[0]);
console.log(result.status); // "completed"

Core Features

Built for multimodal generation

Multimodal runs

Use the same client for image, video, audio, 3D, and language models.

const result = await client.runSync(modelId, params);
const task = await client.run(modelId, params);

Model discovery

Browse available models and query parameter specs before making calls.

const models = await client.models.list({ type: 'video' });
const spec = await client.models.getSpec('wan25_t2i_preview');

SkillHub access

Search and install creative skills from the marketplace.

const skills = await client.skills.find('video generation');
const list = await client.skills.list();

Offline docs

Bundled method references work without network access. Built for agent environments.

import { getSeaCloudDocs } from '@seacloudai/sdk';

const docs = getSeaCloudDocs();
console.log(docs.methods);
console.log(docs.operationManual.content);

How It Works

Three steps to generation

01

Initialize

Create a client with your API key and optional timeout.

const client = new SeaCloud({
  apiKey: 'sk-...',
  timeout: 600_000
});
02

Execute

Choose sync for immediate results or async for long-running tasks.

const result = await client.runSync(modelId, params);
const task = await client.run(modelId, params);
03

Get results

Read structured output with URLs, raw responses, and task status.

if (status.status === 'completed') {
  const result = await client.tasks.getResponse(task.id, {
    responseUrl: status.responseUrl
  });
}
task-lifecycle.tsSDK
// 1. Create a job
const task = await client.run('kling_v2_6_i2v', {
  prompt: 'a cat running on the beach',
  duration: 5
});

console.log(task.id, task.statusUrl);

// 2. Check status
const status = await client.tasks.get(task.id, {
  statusUrl: task.statusUrl
});

// 3. Read the response
if (status.status === 'completed') {
  const result = await client.tasks.getResponse(task.id, {
    responseUrl: status.responseUrl
  });

  console.log(result.output?.urls);
}

Method Reference

Key methods at a glance

Method

chat.send()

Send messages to a language model and receive text responses.

const text = await client.chat.send('gpt-4.1', [
  { role: 'user', content: 'Explain quantum computing in three sentences' }
]);

console.log(text);

Use Cases

Integration examples

Integrate multimodal generation into web apps, batch workflows, and agent pipelines.

Web applications

Add AI generation to your API routes and return results to the frontend.

// Express route
app.post('/api/generate', async (req, res) => {
  const result = await client.runSync('wan25_t2i_preview', {
    prompt: req.body.prompt,
    size: '1024*1024'
  });
  res.json({ imageUrl: result.output?.urls[0] });
});

Batch generation

Process multiple prompts in sequence and save outputs to your system.

const prompts = await loadPrompts('prompts.csv');

for (const prompt of prompts) {
  const result = await client.runSync('model_id', { prompt });
  await saveToDatabase(result.output?.urls[0]);
}

Multi-model pipelines

Chain multiple models together to build complex generation workflows.

const description = await client.chat.send('gpt-4.1', messages);

const image = await client.runSync('wan25_t2i_preview', {
  prompt: description
});

const video = await client.run('kling_v2_6_i2v', {
  image: image.output?.urls[0],
  prompt: 'add motion'
});

Get started with SeaCloud SDK

Install the SDK and start calling multimodal models from your code.