contento
API Reference

Sign Read URL

Generate a signed URL to read or transform a file.

Returns a URL appropriate for the file type:

  • Image → signed imgproxy URL with optional transformation params
  • Video / Audio/f/ delivery URL with ?format= query param (FFmpeg on demand)
  • Other → MinIO presigned GET URL

Endpoint

POST /api/v1/projects/:id/sign/read
Authorization: Bearer <read-key>
Content-Type: application/json

{
  "path": "/images/photo.jpg",
  "expiresIn": 3600,
  "transform": {
    "format": "webp",
    "width": 800,
    "height": 600,
    "quality": 85,
    "fit": "fill",
    "blur": 0
  }
}
FieldTypeRequiredDefaultDescription
pathstringObject key in the bucket.
expiresInnumber3600Seconds until the signed URL expires (for images and raw files).
transformobjectTransformation options. See below.

Transform options

FieldApplies toDescription
formatimage, video, audioOutput format. Images: webp, avif, jpg, png. Video: mp4, webm, mkv. Audio: mp3, aac, ogg, flac, wav.
widthimageOutput width in pixels.
heightimageOutput height in pixels.
qualityimageQuality 1–100.
fitimageResize mode: fit, fill, auto.
blurimageBlur sigma.

Response

{
  "data": {
    "url": "https://imgproxy.yourdomain.com/abc123/rs:fill:800:600/q:85/...",
    "expiresAt": "2025-06-01T13:00:00.000Z"
  }
}

For video/audio transforms, the returned URL is your own delivery endpoint:

{
  "data": {
    "url": "https://contento.yourdomain.com/f/my-project/audio/track.wav?format=mp3",
    "expiresAt": "2025-06-01T13:00:00.000Z"
  }
}

Drop this URL directly into an <audio src="..."> or <video src="..."> tag.