Get All Videos
Returns a list of all videos sorted by view count (descending).
Request
No parameters required.
curl http://localhost:3001/api/videos
Response
Array of video objects sorted by views (highest first)
Unique video identifier (filename without extension)Example: "EFTA01683563"
Video title (may be null)
Full filename including extensionExample: "EFTA01683563.mp4"
Video duration in seconds
Whether a thumbnail image exists for this videoDefault: false
Total number of viewsDefault: 0
Total number of likes (updated when users like/unlike)Default: 0
Whether this video should appear on the shorts pageDefault: false
Playlist identifier if video belongs to a playlistExample: "elevator-cam", "lobby-cam"
Example Response
[
{
"id": "EFTA01683563",
"title": "Elevator Cam - Floor 5",
"filename": "EFTA01683563.mp4",
"length": 127,
"hasThumbnail": true,
"views": 1523,
"likes": 42,
"is_shorts": false,
"playlist": "elevator-cam"
},
{
"id": "LOBBY20240315",
"title": null,
"filename": "LOBBY20240315.mp4",
"length": 89,
"hasThumbnail": false,
"views": 856,
"likes": 15,
"is_shorts": true,
"playlist": "lobby-cam"
}
]
Notes
Videos are ordered by the views column in descending order. The most-viewed video appears first.
The likes count is denormalized and automatically updated when users like or unlike videos through the Video Likes endpoints.