Skip to main content
POST
/
image
/
{image_id}
/
generate_url
Generate image URL
curl --request POST \
  --url https://api.videodb.io/image/{image_id}/generate_url \
  --header 'Content-Type: application/json' \
  --header 'x-access-token: <api-key>' \
  --data '
{
  "format": "jpg",
  "quality": 90,
  "width": 1024,
  "height": 768
}
'
{
  "success": true,
  "data": {
    "image_url": "https://assets.videodb.io/img/12345.jpg"
  }
}
Generates a signed, shareable URL for an image. The URL can be used to access the image without authentication.
import videodb

conn = videodb.connect(api_key="your_api_key")
coll = conn.get_collection()

image = coll.get_image("i-xyz789")
signed_url = image.generate_url()
print(f"Signed URL: {signed_url}")
  • Returns a signed URL string that can be shared publicly
  • Signed URLs provide temporary access without requiring authentication
  • URLs expire after a certain period (check API documentation for expiration time)
  • Collection ID must be passed as a parameter with the request

Authorizations

x-access-token
string
header
required

API key for authentication (sk-xxx format)

Path Parameters

image_id
string
required
Example:

"img-12345"

Body

application/json
format
enum<string>
Available options:
jpg,
png,
webp
Example:

"jpg"

quality
integer
Required range: 1 <= x <= 100
Example:

90

width
integer
Example:

1024

height
integer
Example:

768

Response

200 - application/json

Image URL generated

success
boolean
Example:

true

data
object