HiAPI Seedance Python SDK
Python SDK for Seedance 2.5 API, Seedance text-to-video, Seedance image-to-video, and Seedance video editing through the HiAPI unified task API.
Use this SDK when you want a small Python client focused on AI video generation:
- Seedance 2.5 API access through HiAPI's
/v1/tasksendpoint. - Text-to-video with
client.text_to_video(...). - Image-to-video with
client.image_to_video(...). - Video editing with
client.video_edit(...). - Async task polling built in: submit, poll, and read the output URL.
- Zero runtime dependencies: standard library only.
Install
pip install hiapi-seedance
Requires Python 3.8+.
Quick Start
from hiapi_seedance import Seedance
client = Seedance() # uses HIAPI_API_KEY
task = client.text_to_video(
prompt="A 30-second cinematic one-take product film, golden hour, slow dolly in",
duration=30,
aspect_ratio="16:9",
resolution="1080p",
)
print(task.output[0].url)
Set your API key:
export HIAPI_API_KEY="sk-your-hiapi-key"
Get a key at HiAPI.
Text-to-Video
from hiapi_seedance import Seedance
client = Seedance(api_key="sk-...")
task = client.text_to_video(
prompt=(
"A one-take AI video prompt: a glass perfume bottle rotates on wet black "
"stone while sunrise light moves across the surface, macro texture, no text."
),
duration=15,
aspect_ratio="16:9",
resolution="1080p",
)
print(task.status, task.output[0].url)
Image-to-Video
task = client.image_to_video(
prompt="Animate the reference image with a slow push-in, drifting fabric, and warm rim light.",
image_urls=["https://example.com/first-frame.png"],
duration=8,
aspect_ratio="9:16",
)
Video Editing
task = client.video_edit(
prompt="Keep the original camera movement and timing. Add a blue-white energy bow in the actor's hands.",
video_urls=["https://example.com/source.mp4"],
image_urls=["https://example.com/prop-reference.png"],
)
Return Immediately Instead of Waiting
created = client.text_to_video(
prompt="A fashion film in a desert gallery",
duration=30,
wait=False,
)
task = client.wait(created.task_id, poll_interval=3, timeout=900)
print(task.output[0].url)
Raw HiAPI Task Shape
The SDK sends requests to:
POST https://api.hiapi.ai/v1/tasks
Authorization: Bearer $HIAPI_API_KEY
Content-Type: application/json
{
"model": "seedance-2-5",
"input": {
"prompt": "A cinematic Seedance 2.5 prompt",
"duration": 30,
"aspect_ratio": "16:9",
"resolution": "1080p"
}
}
You can pass additional model fields as keyword arguments:
task = client.text_to_video(
prompt="A multilingual typography loop",
duration=15,
web_search=False,
generate_audio=True,
)
Prompt Library
Need production prompts and preview examples? Use the companion prompt library:
Model Slug
The default model is seedance-2-5. You can override it per client or per call:
client = Seedance(model="seedance-2-5")
task = client.text_to_video(prompt="...", model="seedance-2-0")
Use the fallback model while waiting for Seedance 2.5 availability on your account.
SEO Keywords
Seedance 2.5 API, Seedance Python SDK, Seedance API Python, Seedance text to video API, Seedance image to video API, AI video generation API, text-to-video Python, image-to-video Python, HiAPI Seedance API.
License
MIT
Metadata
Release files for hiapi-seedance 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| hiapi_seedance-0.1.0.tar.gz | 6.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| hiapi_seedance-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 15.5 kB
Release files / hiapi_seedance-0.1.0.tar.gz
| Download URL | hiapi_seedance-0.1.0.tar.gz |
|---|---|
| Size | 6.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
51a7c801fd93047799c09e69e626bcfd803e54a537bd580c1821528462cb66aa
|
|
BLAKE2b-256 checksum How to use checksums |
281466cbbcbe28c48fb2f29b00b17d15256e057879d80cc5627dfe4ab28f95da
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.5
|
Release files / hiapi_seedance-0.1.0-py3-none-any.whl
| Download URL | hiapi_seedance-0.1.0-py3-none-any.whl |
|---|---|
| Size | 8.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f05a037129844872bee8ddffea7c58823e3fcbab29fbffd6349fe7ba852e8637
|
|
BLAKE2b-256 checksum How to use checksums |
8d113a8f687ff7edcca153d16949a093fb91a0e51fefa56ce1d67dbc6d536f59
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.5
|