@@ -15,7 +15,7 @@ servers:
1515security :
1616 - bearerAuth : []
1717paths :
18- /videos/status :
18+ /videos/{id} :
1919 get :
2020 tags : ['Video']
2121 summary : Fetch video metadata
@@ -41,28 +41,28 @@ paths:
4141 label : Together AI SDK (TypeScript)
4242 source : |
4343 import Together from "together-ai";
44-
44+
4545 const client = new Together({
4646 apiKey: process.env.TOGETHER_API_KEY,
4747 });
48-
48+
4949 const response = await client.videos.retrieve(videoId);
50-
50+
5151 console.log(response.status);
5252 - lang : JavaScript
5353 label : Together AI SDK (JavaScript)
5454 source : |
5555 import Together from "together-ai";
56-
56+
5757 const client = new Together({
5858 apiKey: process.env.TOGETHER_API_KEY,
5959 });
60-
60+
6161 const response = await client.videos.retrieve(videoId);
62-
62+
6363 console.log(response.status);
6464 parameters :
65- - in : query
65+ - in : path
6666 name : id
6767 schema :
6868 type : string
7474 content :
7575 application/json :
7676 schema :
77- $ref : ' #/components/schemas/VideoResource '
77+ $ref : ' #/components/schemas/VideoJob '
7878 ' 400 ' :
7979 description : Invalid request parameters.
8080 ' 404 ' :
9393 source : |
9494 from together import Together
9595 import os
96-
96+
9797 client = Together(
9898 api_key=os.environ.get("TOGETHER_API_KEY"),
9999 )
@@ -108,7 +108,7 @@ paths:
108108 label : Together AI SDK (TypeScript)
109109 source : |
110110 import Together from "together-ai";
111-
111+
112112 const client = new Together({
113113 apiKey: process.env.TOGETHER_API_KEY,
114114 });
@@ -117,22 +117,22 @@ paths:
117117 model: "together/video-model",
118118 prompt: "A cartoon of an astronaut riding a horse on the moon",
119119 });
120-
120+
121121 console.log(response.id);
122122 - lang : JavaScript
123123 label : Together AI SDK (JavaScript)
124124 source : |
125125 import Together from "together-ai";
126-
126+
127127 const client = new Together({
128128 apiKey: process.env.TOGETHER_API_KEY,
129129 });
130-
130+
131131 const response = await client.videos.create({
132132 model: "together/video-model",
133133 prompt: "A cartoon of an astronaut riding a horse on the moon",
134134 });
135-
135+
136136 console.log(response.id);
137137 requestBody :
138138 content :
@@ -7355,48 +7355,46 @@ components:
73557355 type : string
73567356 description : Unique identifier for the video job.
73577357
7358- VideoResource :
7358+ VideoJob :
73597359 properties :
73607360 id :
73617361 type : string
73627362 description : Unique identifier for the video job.
7363+ object :
7364+ description : The object type, which is always video.
7365+ type : string
7366+ enum :
7367+ - video
73637368 model :
73647369 type : string
73657370 description : The video generation model that produced the job.
73667371 status :
73677372 $ref : ' #/components/schemas/VideoStatus'
7368- description : Current lifecycle status of the video job.
7369- info :
7370- description : Metadata about the video resource
7371- properties :
7372- user_id :
7373- type : string
7374- description : ID of user who created the video
7375- errors :
7376- description : Errors that caused the creation to fail.
7377- type : array
7378- items :
7379- type : object
7380- properties :
7381- code :
7382- type : string
7383- message :
7384- type : string
7385- required :
7386- - code
7387- - message
7388- required :
7389- - user_id
7373+ description : Current lifecycle status of the video job.
73907374 created_at :
7391- type : string
7375+ type : number
73927376 description : Unix timestamp (seconds) for when the job was created.
7393- done_at :
7394- type : string
7377+ completed_at :
7378+ type : number
73957379 description : Unix timestamp (seconds) for when the job completed, if finished.
7396- inputs :
7380+ size :
7381+ type : string
7382+ description : The resolution of the generated video.
7383+ seconds :
7384+ type : string
7385+ description : Duration of the generated clip in seconds.
7386+ error :
7387+ description : Error payload that explains why generation failed, if applicable.
73977388 type : object
7398- description : The parameters used for the creation of this video.
7389+ properties :
7390+ code :
7391+ type : string
7392+ message :
7393+ type : string
7394+ required :
7395+ - message
73997396 outputs :
7397+ description : Available upon completion, the outputs provides the cost charged and the hosted url to access the video
74007398 type : object
74017399 properties :
74027400 cost :
@@ -7413,9 +7411,8 @@ components:
74137411 - id
74147412 - model
74157413 - status
7416- - info
7417- - inputs
7414+ - size
7415+ - seconds
74187416 - created_at
7419- - done_at
74207417 title : Video job
74217418 description : Structured information describing a generated video job.
0 commit comments