List videos
Parameters
after: Optional[str]
Identifier for the last item from the previous pagination request
limit: Optional[int]
Number of items to retrieve
minimum0
maximum100
Returns
List videos
import os
from openai import OpenAI
client = OpenAI(
api_key=os.environ.get("OPENAI_API_KEY"), # This is the default and can be omitted
)
page = client.videos.list()
page = page.data[0]
print(page.id){
"data": [
{
"id": "id",
"completed_at": 0,
"created_at": 0,
"error": {
"code": "code",
"message": "message"
},
"expires_at": 0,
"model": "string",
"object": "video",
"progress": 0,
"prompt": "prompt",
"remixed_from_video_id": "remixed_from_video_id",
"seconds": "4",
"size": "720x1280",
"status": "queued"
}
],
"first_id": "first_id",
"has_more": true,
"last_id": "last_id",
"object": "list"
}Returns Examples
{
"data": [
{
"id": "id",
"completed_at": 0,
"created_at": 0,
"error": {
"code": "code",
"message": "message"
},
"expires_at": 0,
"model": "string",
"object": "video",
"progress": 0,
"prompt": "prompt",
"remixed_from_video_id": "remixed_from_video_id",
"seconds": "4",
"size": "720x1280",
"status": "queued"
}
],
"first_id": "first_id",
"has_more": true,
"last_id": "last_id",
"object": "list"
}