Skip to content

Commit 2275421

Browse files
feat: re-gen pixverse/v5.5 t2v i2v
1 parent 79146ba commit 2275421

3 files changed

Lines changed: 42 additions & 4 deletions

File tree

docs/api-references/video-models/PixVerse/v5.5-image-to-video.json

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,25 @@
189189
}
190190
}
191191
},
192-
"x-hideTryItPanel": true
192+
"x-hideTryItPanel": true,
193+
"x-codeSamples": [
194+
{
195+
"lang": "JavaScript",
196+
"source": "async function main() {\n const response = await fetch('https://api.aimlapi.com/v2/video/generations', {\n method: 'POST',\n headers: {\n 'Authorization': 'Bearer <YOUR_AIMLAPI_KEY>',\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify({\n \"model\": \"pixverse/v5.5/image-to-video\",\n \"prompt\": \"Mona Lisa puts on glasses with her hands.\",\n \"image_url\": \"https://s2-111386.kwimgs.com/bs2/mmu-aiplatform-temp/kling/20240620/1.jpeg\"\n }),\n });\n\n const data = await response.json();\n console.log(JSON.stringify(data, null, 2));\n}\n\nmain();"
197+
},
198+
{
199+
"lang": "Python",
200+
"source": "import requests\n\nresponse = requests.post(\n \"https://api.aimlapi.com/v2/video/generations\",\n headers={\n \"Content-Type\": \"application/json\",\n \"Authorization\": \"Bearer <YOUR_AIMLAPI_KEY>\",\n },\n json={\n \"model\": \"pixverse/v5.5/image-to-video\",\n \"prompt\": \"Mona Lisa puts on glasses with her hands.\",\n \"image_url\": \"https://s2-111386.kwimgs.com/bs2/mmu-aiplatform-temp/kling/20240620/1.jpeg\"\n }\n)\n\ndata = response.json()\nprint(data)"
201+
},
202+
{
203+
"lang": "cURL",
204+
"source": "curl -L \\\n --request POST \\\n --url 'https://api.aimlapi.com/v2/video/generations' \\\n --header 'Authorization: Bearer <YOUR_AIMLAPI_KEY>' \\\n --header 'Content-Type: application/json' \\\n --data '{\n \"model\": \"pixverse/v5.5/image-to-video\",\n \"prompt\": \"Mona Lisa puts on glasses with her hands.\",\n \"image_url\": \"https://s2-111386.kwimgs.com/bs2/mmu-aiplatform-temp/kling/20240620/1.jpeg\"\n }'"
205+
},
206+
{
207+
"lang": "HTTP",
208+
"source": "POST / HTTP/1.1\nHost: test.com\nAuthorization: Bearer <YOUR_AIMLAPI_KEY>\nContent-Type: application/json\nAccept: */*\n\n{\n \"model\": \"pixverse/v5.5/image-to-video\",\n \"prompt\": \"Mona Lisa puts on glasses with her hands.\",\n \"image_url\": \"https://s2-111386.kwimgs.com/bs2/mmu-aiplatform-temp/kling/20240620/1.jpeg\"\n}"
209+
}
210+
]
193211
}
194212
}
195213
},

docs/api-references/video-models/PixVerse/v5.5-text-to-video.json

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,25 @@
195195
}
196196
}
197197
},
198-
"x-hideTryItPanel": true
198+
"x-hideTryItPanel": true,
199+
"x-codeSamples": [
200+
{
201+
"lang": "JavaScript",
202+
"source": "async function main() {\n const response = await fetch('https://api.aimlapi.com/v2/video/generations', {\n method: 'POST',\n headers: {\n 'Authorization': 'Bearer <YOUR_AIMLAPI_KEY>',\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify({\n \"model\": \"pixverse/v5.5/text-to-video\",\n \"prompt\": \"A menacing evil dragon appears in a distance above the tallest mountain, then rushes toward the camera with its jaws open, revealing massive fangs. We see it's coming.\"\n }),\n });\n\n const data = await response.json();\n console.log(JSON.stringify(data, null, 2));\n}\n\nmain();"
203+
},
204+
{
205+
"lang": "Python",
206+
"source": "import requests\n\nresponse = requests.post(\n \"https://api.aimlapi.com/v2/video/generations\",\n headers={\n \"Content-Type\": \"application/json\",\n \"Authorization\": \"Bearer <YOUR_AIMLAPI_KEY>\",\n },\n json={\n \"model\": \"pixverse/v5.5/text-to-video\",\n \"prompt\": \"A menacing evil dragon appears in a distance above the tallest mountain, then rushes toward the camera with its jaws open, revealing massive fangs. We see it's coming.\"\n }\n)\n\ndata = response.json()\nprint(data)"
207+
},
208+
{
209+
"lang": "cURL",
210+
"source": "curl -L \\\n --request POST \\\n --url 'https://api.aimlapi.com/v2/video/generations' \\\n --header 'Authorization: Bearer <YOUR_AIMLAPI_KEY>' \\\n --header 'Content-Type: application/json' \\\n --data '{\n \"model\": \"pixverse/v5.5/text-to-video\",\n \"prompt\": \"A menacing evil dragon appears in a distance above the tallest mountain, then rushes toward the camera with its jaws open, revealing massive fangs. We see it\\'s coming.\"\n }'"
211+
},
212+
{
213+
"lang": "HTTP",
214+
"source": "POST / HTTP/1.1\nHost: test.com\nAuthorization: Bearer <YOUR_AIMLAPI_KEY>\nContent-Type: application/json\nAccept: */*\n\n{\n \"model\": \"pixverse/v5.5/text-to-video\",\n \"prompt\": \"A menacing evil dragon appears in a distance above the tallest mountain, then rushes toward the camera with its jaws open, revealing massive fangs. We see it's coming.\"\n}"
215+
}
216+
]
199217
}
200218
}
201219
},

packages/generators-v2/src/json_for-docs_generation.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,15 @@
44
"url": "https://ai.aimlapi.com/docs-json?endpoint=internal/video-generations/submit&model=pixverse/v5.5/text-to-video",
55
"alias": "v5.5/text-to-video",
66
"category": "video-models",
7-
"vendor": "PixVerse"
7+
"vendor": "PixVerse",
8+
"codeSamples": "video:video"
89
},
910
{
1011
"name": "pixverse/v5.5/image-to-video",
1112
"url": "https://ai.aimlapi.com/docs-json?endpoint=internal/video-generations/submit&model=pixverse/v5.5/image-to-video",
1213
"alias": "v5.5/image-to-video",
1314
"category": "video-models",
14-
"vendor": "PixVerse"
15+
"vendor": "PixVerse",
16+
"codeSamples": "video:video"
1517
}
1618
]

0 commit comments

Comments
 (0)