Pixverse Transition Serverless API
PixVerse V4 transforms static images and text into dynamic, visually stunning videos for creators across various industries.
1import requests
2import json
3
4url = "https://api.segmind.com/v1/pixverse-transition"
5headers = {
6 "x-api-key": "YOUR_API_KEY",
7 "Content-Type": "application/json"
8}
9
10data = {
11 "first_frame_url": "https://segmind-inference-inputs.s3.amazonaws.com/e900af97-db46-406d-8403-71210db253c4-pixverse-4.5-transition-first-frame-input.webp",
12 "last_frame_url": "https://segmind-inference-inputs.s3.amazonaws.com/a5e271e3-e37b-4426-a572-06b514319a4c-pixverse-4.5-transition-last-frame-input.webp",
13 "duration": 8,
14 "prompt": "Butterflies fluttering in a sunny meadow.",
15 "quality": "720p",
16 "seed": 12345,
17 "motion_mode": "normal"
18}
19
20response = requests.post(url, headers=headers, json=data)
21
22if response.status_code == 200:
23 result = response.json()
24 print(json.dumps(result, indent=2))
25else:
26 print(f"Error: {response.status_code}")
27 print(response.text) 1import requests
2import json
3
4url = "https://api.segmind.com/v1/pixverse-transition"
5headers = {
6 "x-api-key": "YOUR_API_KEY",
7 "Content-Type": "application/json"
8}
9
10data = {
11 "first_frame_url": "https://segmind-inference-inputs.s3.amazonaws.com/e900af97-db46-406d-8403-71210db253c4-pixverse-4.5-transition-first-frame-input.webp",
12 "last_frame_url": "https://segmind-inference-inputs.s3.amazonaws.com/a5e271e3-e37b-4426-a572-06b514319a4c-pixverse-4.5-transition-last-frame-input.webp",
13 "duration": 8,
14 "prompt": "Butterflies fluttering in a sunny meadow.",
15 "quality": "720p",
16 "seed": 12345,
17 "motion_mode": "normal"
18}
19
20response = requests.post(url, headers=headers, json=data)
21
22if response.status_code == 200:
23 result = response.json()
24 print(json.dumps(result, indent=2))
25else:
26 print(f"Error: {response.status_code}")
27 print(response.text)API Endpoint
https://api.segmind.com/v1/pixverse-transitionParameters
durationrequiredintegerVideo length in seconds. Choose 5 for quick previews, 8 for detailed animations.
858first_frame_urlrequiredstring (uri)URL for the starting image. Use high-quality images for better transitions.
"https://segmind-inference-inputs.s3.amazonaws.com/e900af97-db46-406d-8403-71210db253c4-pixverse-4.5-transition-first-frame-input.webp"last_frame_urlrequiredstring (uri)URL for the ending image. High-quality images enhance visual transitions.
"https://segmind-inference-inputs.s3.amazonaws.com/a5e271e3-e37b-4426-a572-06b514319a4c-pixverse-4.5-transition-last-frame-input.webp"motion_moderequiredstringAnimation motion style. 'Normal' is smooth, 'fast' is rapid.
"normal""normal""fast"promptrequiredstringAnimation theme description. Try thematic prompts for creative animations.
"Butterflies fluttering in a sunny meadow."qualityrequiredstringVideo resolution. Use 1080p for high quality, 360p for fast previews.
"720p""360p""540p""720p""1080p"seedoptionalintegerSeed for repeat results. Change for unique animations.
12345Range: 1 - 999999Response Type
Returns: Video
Common Error Codes
The API returns standard HTTP status codes. Detailed error messages are provided in the response body.
Bad Request
Invalid parameters or request format
Unauthorized
Missing or invalid API key
Forbidden
Insufficient permissions
Not Found
Model or endpoint not found
Insufficient Credits
Not enough credits to process request
Rate Limited
Too many requests
Server Error
Internal server error
Bad Gateway
Service temporarily unavailable
Timeout
Request timed out