Get device paths
GET /api/gallery/:device/paths
Get the file system paths for uploading media to a device
Path parameters
Device identifier
Response
Indicates if the request was successful
File system paths for the device
Path where new files should be uploaded
Path where thumbnail files should be uploaded
Example request
List media events
GET /api/gallery/:device/events
List all media events for a device with optional type filtering
Path parameters
Device identifier
Query parameters
Filter by media type:
image, video, audio, document, otherMaximum number of events to return
Number of events to skip for pagination
Response
Returns an array of event objects.Unique event identifier
Event filename
Media type classification
File size in bytes
Whether a thumbnail is available
ISO 8601 timestamp of event creation
Example request
Upload media event
POST /api/gallery/:device/upload
Upload a media event with optional thumbnail
Path parameters
Device identifier
Request body (multipart/form-data)
Event filename
Media file to upload
Optional thumbnail image
Media type:
image, video, audio, document, otherIndicates if a thumbnail is included
JSON string of additional metadata
Response
Indicates if upload was successful
ID of the created event
Example request
Get upload URL
GET /api/gallery/:device/upload-url
Get pre-signed URLs for uploading media files
Path parameters
Device identifier
Query parameters
Name of the file to upload
Whether to also get a thumbnail upload URL
Response
Indicates if the request was successful
Pre-signed URL for uploading the media file
Pre-signed URL for uploading the thumbnail (if requested)
Example request
Get media statistics
GET /api/gallery/:device/stats
Get media statistics with type breakdown
Path parameters
Device identifier
Response
Total number of media events
Total size of all media in bytes
Breakdown of events and size by media type
Example request
Delete media event
DELETE /api/gallery/:device/events/:eventId
Delete a specific media event
Path parameters
Device identifier
Event identifier to delete
Response
Indicates if deletion was successful
Example request
Pull specific event
POST /api/gallery/:device/pull/:eventId
Pull a specific event from the device
Path parameters
Device identifier
Event identifier to pull from device
Response
Indicates if the pull was successful
ID of the pulled event