API Reference
Pixelflare API - Version 1.0.0
The Pixelflare API provides full programmatic access to all features, so you can integrate image hosting, CDN delivery, and management into your own applications and workflows.
Quick Start
To upload an image via the API:
- Authenticate: All API endpoints require authentication (see below)
- Create an Image: POST to
/imagesto get a signed upload URL - Upload File: PUT your image to the signed URL
Then, you'll be able to access your image via the CDN, with either:
/{owner}/{album}/{filename}/{owner}/{album}/{filename}/{variant}/i/{image-id}
Try a test request, by running:
curl 'https://pixelflare.cc/api/v1/images?limit=1' --header 'Authorization: Bearer YOUR_SECRET_TOKEN'Authentication
NOTE
Note that authentication options depend on your deployment configuration.
This API uses:
- Cloudflare Access: JWT-based authentication (if enabled)
- API Keys: Bearer token authentication for programmatic access (if enabled)
You can generate a key in the Pixelflare app at Settings > API Keys, or use the POST /keys endpoint.
CAUTION
Keep your API keys secure. They grant access to your account
Rate Limiting
Unless otherwise specified, the following rate limits apply:
- API endpoints: 100 requests/minute per user
- CDN endpoints: 1000 requests/minute per IP (does not apply to cached content)
You will receive HTTP 429 responses, along with a message when exceeding these limits.
NOTE
Rate limits are configurable by the server administrator, and may differ from the defaults listed here.
WARNING
Repeatedly exceeding rate limits by a significant margin may result in temporary or permanent bans.
Using the API docs
- In the web app, create an API token with your desired scopes and expiry.
- Then, under the "Authentication" section to the right, paste your token into the "Bearer" field
- Choose your desired programming language, in the Client Library section (this will give you code snippets for making requests)
- You will then be able to send test requests directly from the documentation interface, or copy the code snippets
Alternatively, you can download the OpenAPI Schema and import it into an Swagger-compatible API client of your choice (such as Postman, Insomnia, or Hoppscotch).
TIP
If you use Scalar, click here for a pre-configured instance!
Getting help
Support is offered to paying customers and GitHub Sponsors, who reach our via support@as93.net.
For all other users, please reference the docs, github repo and community forum.
Legal
Pixelflare is licensed under MIT © Alicia Sykes 2025
For terms, privacy policy, and security information, please see Legal Documents
IMPORTANT
The public instance does not allow for NSFW or adult content
API Overview
55 endpoints · 15 resource groups · 40 GET · 21 POST · 7 PATCH · 9 DELETE
Auto-generated Documentation
This documentation is automatically generated from the OpenAPI specification. For interactive testing, visit the API Playground.
Base URLs
- Production API:
https://pixelflare.cc/api/v1 - Production API (alternate):
https://api.pixelflare.cc/v1 - Local Development:
http://localhost:8787/v1
Table of Contents
Media Management
Configuration
Stats & Logs
Public
CDN
Misc
Images
The /images endpoint covers everything from uploading, retrieving, updating, deleting, and managing image variants.
GET /images
Authentication Required
This endpoint requires authentication: Bearer
Returns a paginated list of images with optional filtering by album, tags, search terms, date range, and more. Returns 401 if unauthorized.
Parameters:
limit(query) optional- Type:
integer - Description: Number of images to return (max 200)
- Example:
10 - Default:
10
- Type:
cursor(query) optional- Type:
string - Description: Pagination cursor from previous response
- Example:
img_xyz789
- Type:
album(query) optional- Type:
string - Description: Filter by album slug
- Example:
vacation-2024
- Type:
tag(query) optional- Type:
string - Description: Filter by tag(s) - comma-separated for AND logic
- Example:
nature,sunset
- Type:
search(query) optional- Type:
string - Description: Search by filename, alt text, or tags
- Example:
sunset beach
- Type:
sort(query) optional- Type:
"relevance" | "recent" | "bytes" - Description: Sort order: relevance (if searching), recent (newest first), or bytes (largest first)
- Example:
recent - Default:
recent
- Type:
include_deleted(query) optional- Type:
boolean - Description: Include soft-deleted images
- Default:
false
- Type:
is_favourited(query) optional- Type:
boolean - Description: Filter by favourite status
- Example:
true
- Type:
from(query) optional- Type:
string - Description: Filter by creation date (start, YYYY-MM-DD)
- Example:
2024-01-01
- Type:
to(query) optional- Type:
string - Description: Filter by creation date (end, YYYY-MM-DD)
- Example:
2024-12-31
- Type:
Responses:
200: Paginated list of images
Response 200:
datarequired- Type:
any[] - Description: Array of items in this page
- Type:
next_cursorrequired- Type:
string - Description: Cursor for next page (null if no more pages)
- Example:
"img_xyz789"
- Type:
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /images
Authentication Required
This endpoint requires authentication: Bearer
Creates a new image resource and returns a signed upload URL. The image file should be uploaded to the returned upload URL within 1 hour. Returns 401 if unauthorized.
Request Body:
filenamerequired- Type:
string - Description: Your image filename with extension
- Example:
"sunset.jpg"
- Type:
content_typeoptional- Type:
string - Description: MIME type - we'll detect it if you don't provide it
- Example:
"image/jpeg"
- Type:
size_bytesoptional- Type:
integer - Description: File size in bytes - max 100MB
- Example:
1048576
- Type:
widthoptional- Type:
integer - Description: Width in pixels - we'll extract this from your file
- Example:
1920
- Type:
heightoptional- Type:
integer - Description: Height in pixels - we'll extract this too
- Example:
1080
- Type:
albumoptional- Type:
string - Description: Album to file the image in - defaults to "images"
- Example:
"vacation-2024"
- Type:
tagsoptional- Type:
string[] - Description: Tags for organising your images
- Example:
["nature","sunset","beach"]
- Type:
strip_metadataoptional- Type:
boolean - Description: Remove EXIF data from the image
- Example:
true
- Type:
altoptional- Type:
string - Description: Alt text for accessibility
- Example:
"A stunning sunset over the Pacific Ocean"
- Type:
nsfwoptional- Type:
boolean - Description: Is this image NSFW?
- Type:
licenseoptional- Type:
"all-rights-reserved" | "cc0" | "pd" | "cc-by" | "cc-by-sa" | "cc-by-nc" | "cc-by-nc-sa" | "cc-by-nd" | "cc-by-nc-nd" | "mit" | "apache-2.0" | "gpl-3.0" - Description: License for your image
- Example:
"cc-by"
- Type:
visibilityoptional- Type:
"public" | "private" | "unlisted" - Description: Who can see this? public (show in "all images" + accessible to anyone), unlisted (in album if album is public + accessible with link), or private (never on profile + owner only). Defaults to public
- Example:
"public"
- Type:
expirationoptional- Type:
string - Description: When should this expire? Try "7d", "30d", or "never"
- Example:
"30d"
- Type:
encryptoptional- Type:
boolean - Description: Encrypt image at rest with AES-256-GCM
- Type:
turnstile_tokenoptional- Type:
string - Description: Cloudflare Turnstile token for bot protection
- Example:
"eyJ..."
- Type:
Responses:
201: Image resource created with upload URL
Response 201:
idrequired- Type:
string - Description: Unique image identifier
- Example:
"img_abc123"
- Type:
ownerrequired- Type:
string - Description: Owner email address
- Example:
"user@example.com"
- Type:
filenamerequired- Type:
string - Description: Image filename with extension
- Example:
"sunset.jpg"
- Type:
albumrequired- Type:
string - Description: Album slug this image belongs to
- Example:
"vacation-2024"
- Type:
tagsrequired- Type:
string[] - Description: Tags associated with this image
- Example:
["nature","sunset","beach"]
- Type:
urlsrequired- Type:
object - Description: Image URLs for different variants
- Type:
uploadrequired- Type:
object - Description: Upload details (only present immediately after image creation)
- Type:
inforequired- Type:
object - Description: Image file information
- Type:
statusrequired- Type:
object - Description: Image status information
- Type:
altrequired- Type:
string - Description: Alt text for accessibility
- Example:
"A beautiful sunset over the ocean"
- Type:
nsfwrequired- Type:
boolean - Description: Whether image contains NSFW content
- Type:
licenserequired- Type:
string - Description: Image license type
- Example:
"cc-by"
- Type:
visibilityrequired- Type:
string - Description: Image visibility setting
- Example:
"public"
- Type:
expiration_daterequired- Type:
string - Description: Auto-delete expiration date (null for permanent)
- Type:
is_privaterequired- Type:
boolean - Description: Whether image requires authentication to view
- Type:
is_favouritedrequired- Type:
boolean - Description: Whether the current user has favourited this image
- Type:
created_atrequired- Type:
string - Description: Image creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atrequired- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
409: Conflict - Resource already exists
Response 409:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /images/{id}
Authentication Required
This endpoint requires authentication: Bearer
Returns a single image by ID. Returns 401 if unauthorized or 404 if not found.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Responses:
200: Image resource or array of resources (for batch requests)
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
PATCH /images/{id}
Authentication Required
This endpoint requires authentication: Bearer
Updates image metadata (filename, album, tags, alt text, etc.). Returns 401 if unauthorized or 404 if not found.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Request Body:
filenameoptional- Type:
string - Description: Rename the file - old URLs will redirect
- Example:
"renamed-sunset.jpg"
- Type:
albumoptional- Type:
string - Description: Move to a different album
- Example:
"nature-photos"
- Type:
tagsoptional- Type:
string[] - Description: Replace all tags with these ones
- Example:
["nature","ocean"]
- Type:
altoptional- Type:
string - Description: Update the alt text
- Example:
"An even more stunning sunset over the Pacific"
- Type:
nsfwoptional- Type:
boolean - Description: Change NSFW status
- Type:
licenseoptional- Type:
"all-rights-reserved" | "cc0" | "pd" | "cc-by" | "cc-by-sa" | "cc-by-nc" | "cc-by-nc-sa" | "cc-by-nd" | "cc-by-nc-nd" | "mit" | "apache-2.0" | "gpl-3.0" - Description: Change the license
- Example:
"cc-by-sa"
- Type:
visibilityoptional- Type:
"public" | "private" | "unlisted" - Description: Change visibility - public (show in "all images" + accessible to anyone), unlisted (in album if album is public + accessible with link), or private (never on profile + owner only)
- Example:
"private"
- Type:
expirationoptional- Type:
string - Description: Change when it expires
- Example:
"never"
- Type:
is_privateoptional- Type:
boolean - Description: Alternative way to set privacy
- Type:
Responses:
200: Updated image resource
Response 200:
idrequired- Type:
string - Description: Unique image identifier
- Example:
"img_abc123"
- Type:
ownerrequired- Type:
string - Description: Owner email address
- Example:
"user@example.com"
- Type:
filenamerequired- Type:
string - Description: Image filename with extension
- Example:
"sunset.jpg"
- Type:
albumrequired- Type:
string - Description: Album slug this image belongs to
- Example:
"vacation-2024"
- Type:
tagsrequired- Type:
string[] - Description: Tags associated with this image
- Example:
["nature","sunset","beach"]
- Type:
urlsrequired- Type:
object - Description: Image URLs for different variants
- Type:
uploadrequired- Type:
object - Description: Upload details (only present immediately after image creation)
- Type:
inforequired- Type:
object - Description: Image file information
- Type:
statusrequired- Type:
object - Description: Image status information
- Type:
altrequired- Type:
string - Description: Alt text for accessibility
- Example:
"A beautiful sunset over the ocean"
- Type:
nsfwrequired- Type:
boolean - Description: Whether image contains NSFW content
- Type:
licenserequired- Type:
string - Description: Image license type
- Example:
"cc-by"
- Type:
visibilityrequired- Type:
string - Description: Image visibility setting
- Example:
"public"
- Type:
expiration_daterequired- Type:
string - Description: Auto-delete expiration date (null for permanent)
- Type:
is_privaterequired- Type:
boolean - Description: Whether image requires authentication to view
- Type:
is_favouritedrequired- Type:
boolean - Description: Whether the current user has favourited this image
- Type:
created_atrequired- Type:
string - Description: Image creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atrequired- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
409: Conflict - Resource already exists
Response 409:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
DELETE /images/{id}
Authentication Required
This endpoint requires authentication: Bearer
Soft-deletes an image (marks as deleted but keeps data for recovery). Returns 401 if unauthorized or 404 if not found.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Responses:
200: Image deleted successfully
Response 200:
idrequired- Type:
string - Description: Unique image identifier
- Example:
"img_abc123"
- Type:
ownerrequired- Type:
string - Description: Owner email address
- Example:
"user@example.com"
- Type:
filenamerequired- Type:
string - Description: Image filename with extension
- Example:
"sunset.jpg"
- Type:
albumrequired- Type:
string - Description: Album slug this image belongs to
- Example:
"vacation-2024"
- Type:
tagsrequired- Type:
string[] - Description: Tags associated with this image
- Example:
["nature","sunset","beach"]
- Type:
urlsrequired- Type:
object - Description: Image URLs for different variants
- Type:
uploadrequired- Type:
object - Description: Upload details (only present immediately after image creation)
- Type:
inforequired- Type:
object - Description: Image file information
- Type:
statusrequired- Type:
object - Description: Image status information
- Type:
altrequired- Type:
string - Description: Alt text for accessibility
- Example:
"A beautiful sunset over the ocean"
- Type:
nsfwrequired- Type:
boolean - Description: Whether image contains NSFW content
- Type:
licenserequired- Type:
string - Description: Image license type
- Example:
"cc-by"
- Type:
visibilityrequired- Type:
string - Description: Image visibility setting
- Example:
"public"
- Type:
expiration_daterequired- Type:
string - Description: Auto-delete expiration date (null for permanent)
- Type:
is_privaterequired- Type:
boolean - Description: Whether image requires authentication to view
- Type:
is_favouritedrequired- Type:
boolean - Description: Whether the current user has favourited this image
- Type:
created_atrequired- Type:
string - Description: Image creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atrequired- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /images/{id}/restore
Authentication Required
This endpoint requires authentication: Bearer
Restores a soft-deleted image. Returns 401 if unauthorized or 404 if not found.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Responses:
200: Restored image resource
Response 200:
idrequired- Type:
string - Description: Unique image identifier
- Example:
"img_abc123"
- Type:
ownerrequired- Type:
string - Description: Owner email address
- Example:
"user@example.com"
- Type:
filenamerequired- Type:
string - Description: Image filename with extension
- Example:
"sunset.jpg"
- Type:
albumrequired- Type:
string - Description: Album slug this image belongs to
- Example:
"vacation-2024"
- Type:
tagsrequired- Type:
string[] - Description: Tags associated with this image
- Example:
["nature","sunset","beach"]
- Type:
urlsrequired- Type:
object - Description: Image URLs for different variants
- Type:
uploadrequired- Type:
object - Description: Upload details (only present immediately after image creation)
- Type:
inforequired- Type:
object - Description: Image file information
- Type:
statusrequired- Type:
object - Description: Image status information
- Type:
altrequired- Type:
string - Description: Alt text for accessibility
- Example:
"A beautiful sunset over the ocean"
- Type:
nsfwrequired- Type:
boolean - Description: Whether image contains NSFW content
- Type:
licenserequired- Type:
string - Description: Image license type
- Example:
"cc-by"
- Type:
visibilityrequired- Type:
string - Description: Image visibility setting
- Example:
"public"
- Type:
expiration_daterequired- Type:
string - Description: Auto-delete expiration date (null for permanent)
- Type:
is_privaterequired- Type:
boolean - Description: Whether image requires authentication to view
- Type:
is_favouritedrequired- Type:
boolean - Description: Whether the current user has favourited this image
- Type:
created_atrequired- Type:
string - Description: Image creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atrequired- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
DELETE /images/{id}/permanent
Authentication Required
This endpoint requires authentication: Bearer
Permanently deletes an image from R2 storage and database. ONLY works on images that have already been soft-deleted. Returns 401 if unauthorized, 404 if not found, or 400 if image is not deleted.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Responses:
200: Image permanently deleted
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /images/{id}/variants
Authentication Required
This endpoint requires authentication: Bearer
Returns a list of all existing variants (preset and custom) for an image. Returns 401 if unauthorized or 404 if not found.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Responses:
200: List of existing variants
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /images/{id}/variants
Authentication Required
This endpoint requires authentication: Bearer
Triggers generation of image variants (thumbnails, optimized versions) in the background. Returns 401 if unauthorized or 404 if not found.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Request Body:
variantsrequired- Type:
"original" | "w128" | "w256" | "w512" | "w1024" | "w1536" | "w2048" | "thumb" | "og-image"[] - Description: List of variant presets to generate
- Example:
["thumbnail","preview"]
- Type:
Responses:
202: Variant generation queued
Response 202:
idrequired- Type:
string - Description: Unique image identifier
- Example:
"img_abc123"
- Type:
ownerrequired- Type:
string - Description: Owner email address
- Example:
"user@example.com"
- Type:
filenamerequired- Type:
string - Description: Image filename with extension
- Example:
"sunset.jpg"
- Type:
albumrequired- Type:
string - Description: Album slug this image belongs to
- Example:
"vacation-2024"
- Type:
tagsrequired- Type:
string[] - Description: Tags associated with this image
- Example:
["nature","sunset","beach"]
- Type:
urlsrequired- Type:
object - Description: Image URLs for different variants
- Type:
uploadrequired- Type:
object - Description: Upload details (only present immediately after image creation)
- Type:
inforequired- Type:
object - Description: Image file information
- Type:
statusrequired- Type:
object - Description: Image status information
- Type:
altrequired- Type:
string - Description: Alt text for accessibility
- Example:
"A beautiful sunset over the ocean"
- Type:
nsfwrequired- Type:
boolean - Description: Whether image contains NSFW content
- Type:
licenserequired- Type:
string - Description: Image license type
- Example:
"cc-by"
- Type:
visibilityrequired- Type:
string - Description: Image visibility setting
- Example:
"public"
- Type:
expiration_daterequired- Type:
string - Description: Auto-delete expiration date (null for permanent)
- Type:
is_privaterequired- Type:
boolean - Description: Whether image requires authentication to view
- Type:
is_favouritedrequired- Type:
boolean - Description: Whether the current user has favourited this image
- Type:
created_atrequired- Type:
string - Description: Image creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atrequired- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /images/{id}/complete
Authentication Required
This endpoint requires authentication: Bearer
Marks an image upload as complete after the file has been uploaded to R2. Returns 401 if unauthorized or 404 if not found.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Responses:
200: Upload completed successfully
Response 200:
idrequired- Type:
string - Description: Unique image identifier
- Example:
"img_abc123"
- Type:
ownerrequired- Type:
string - Description: Owner email address
- Example:
"user@example.com"
- Type:
filenamerequired- Type:
string - Description: Image filename with extension
- Example:
"sunset.jpg"
- Type:
albumrequired- Type:
string - Description: Album slug this image belongs to
- Example:
"vacation-2024"
- Type:
tagsrequired- Type:
string[] - Description: Tags associated with this image
- Example:
["nature","sunset","beach"]
- Type:
urlsrequired- Type:
object - Description: Image URLs for different variants
- Type:
uploadrequired- Type:
object - Description: Upload details (only present immediately after image creation)
- Type:
inforequired- Type:
object - Description: Image file information
- Type:
statusrequired- Type:
object - Description: Image status information
- Type:
altrequired- Type:
string - Description: Alt text for accessibility
- Example:
"A beautiful sunset over the ocean"
- Type:
nsfwrequired- Type:
boolean - Description: Whether image contains NSFW content
- Type:
licenserequired- Type:
string - Description: Image license type
- Example:
"cc-by"
- Type:
visibilityrequired- Type:
string - Description: Image visibility setting
- Example:
"public"
- Type:
expiration_daterequired- Type:
string - Description: Auto-delete expiration date (null for permanent)
- Type:
is_privaterequired- Type:
boolean - Description: Whether image requires authentication to view
- Type:
is_favouritedrequired- Type:
boolean - Description: Whether the current user has favourited this image
- Type:
created_atrequired- Type:
string - Description: Image creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atrequired- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /images/{id}/ai
Retrieve AI-generated classification, caption, and metadata for a specific image
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Responses:
200: AI analysis data
Response 200:
image_idrequired- Type:
string - Description: Image ID
- Example:
"abc123def456"
- Type:
labelsrequired- Type:
string[] - Description: Classification labels
- Example:
["cat","animal","pet"]
- Type:
label_scoresrequired- Type:
number[] - Description: Confidence scores for each label (0-1)
- Example:
[0.95,0.87,0.82]
- Type:
captionrequired- Type:
string - Description: AI-generated caption describing the image
- Example:
"A fluffy orange cat sitting on a windowsill"
- Type:
colorsrequired- Type:
object[] - Description: Dominant colors extracted from the image
- Type:
nsfw_scorerequired- Type:
number - Description: NSFW content score (0-1, higher = more likely NSFW)
- Example:
0.02
- Type:
nsfw_flaggedrequired- Type:
boolean - Description: Whether the image was flagged as NSFW
- Type:
model_versionrequired- Type:
string - Description: AI model version used for analysis
- Example:
"resnet-50"
- Type:
processing_time_msrequired- Type:
number - Description: Time taken to process the image (milliseconds)
- Example:
1250
- Type:
created_atrequired- Type:
string - Description: When the analysis was created
- Example:
"2025-11-22T10:30:00Z"
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /images/{id}/ai/analyze
Manually trigger AI classification, caption generation, and analysis for an image. Useful for testing or reprocessing.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Responses:
200: AI analysis completed
Response 200:
image_idrequired- Type:
string - Description: Image ID
- Example:
"abc123def456"
- Type:
labelsrequired- Type:
string[] - Description: Classification labels
- Example:
["cat","animal","pet"]
- Type:
label_scoresrequired- Type:
number[] - Description: Confidence scores for each label (0-1)
- Example:
[0.95,0.87,0.82]
- Type:
captionrequired- Type:
string - Description: AI-generated caption describing the image
- Example:
"A fluffy orange cat sitting on a windowsill"
- Type:
colorsrequired- Type:
object[] - Description: Dominant colors extracted from the image
- Type:
nsfw_scorerequired- Type:
number - Description: NSFW content score (0-1, higher = more likely NSFW)
- Example:
0.02
- Type:
nsfw_flaggedrequired- Type:
boolean - Description: Whether the image was flagged as NSFW
- Type:
model_versionrequired- Type:
string - Description: AI model version used for analysis
- Example:
"resnet-50"
- Type:
processing_time_msrequired- Type:
number - Description: Time taken to process the image (milliseconds)
- Example:
1250
- Type:
created_atrequired- Type:
string - Description: When the analysis was created
- Example:
"2025-11-22T10:30:00Z"
- Type:
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /images/{id}/replace
Authentication Required
This endpoint requires authentication: Bearer
Replace an existing image file with a new one while preserving the image ID, filename, and album. Optionally update metadata (tags, alt text, visibility). Existing variants will be deleted and regenerated. Returns a signed upload URL for the new file. Returns 401 if unauthorized or 404 if not found.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Request Body:
content_typeoptional- Type:
string - Description: MIME type of the new file - we'll detect it if you don't provide it
- Example:
"image/jpeg"
- Type:
size_bytesoptional- Type:
integer - Description: New file size in bytes - max 100MB
- Example:
1048576
- Type:
widthoptional- Type:
integer - Description: Width in pixels of the new file
- Example:
1920
- Type:
heightoptional- Type:
integer - Description: Height in pixels of the new file
- Example:
1080
- Type:
tagsoptional- Type:
string[] - Description: Update tags when replacing
- Example:
["nature","sunset","beach"]
- Type:
altoptional- Type:
string - Description: Update alt text when replacing
- Example:
"A stunning sunset over the Pacific Ocean"
- Type:
nsfwoptional- Type:
boolean - Description: Update NSFW flag when replacing
- Type:
licenseoptional- Type:
"all-rights-reserved" | "cc0" | "pd" | "cc-by" | "cc-by-sa" | "cc-by-nc" | "cc-by-nc-sa" | "cc-by-nd" | "cc-by-nc-nd" | "mit" | "apache-2.0" | "gpl-3.0" - Description: Update license when replacing
- Example:
"cc-by"
- Type:
visibilityoptional- Type:
"public" | "private" | "unlisted" - Description: Update visibility when replacing
- Example:
"public"
- Type:
expirationoptional- Type:
string - Description: Update expiration when replacing
- Example:
"30d"
- Type:
Responses:
200: Image ready for replacement with upload URL
Response 200:
idrequired- Type:
string - Description: Unique image identifier
- Example:
"img_abc123"
- Type:
ownerrequired- Type:
string - Description: Owner email address
- Example:
"user@example.com"
- Type:
filenamerequired- Type:
string - Description: Image filename with extension
- Example:
"sunset.jpg"
- Type:
albumrequired- Type:
string - Description: Album slug this image belongs to
- Example:
"vacation-2024"
- Type:
tagsrequired- Type:
string[] - Description: Tags associated with this image
- Example:
["nature","sunset","beach"]
- Type:
urlsrequired- Type:
object - Description: Image URLs for different variants
- Type:
uploadrequired- Type:
object - Description: Upload details (only present immediately after image creation)
- Type:
inforequired- Type:
object - Description: Image file information
- Type:
statusrequired- Type:
object - Description: Image status information
- Type:
altrequired- Type:
string - Description: Alt text for accessibility
- Example:
"A beautiful sunset over the ocean"
- Type:
nsfwrequired- Type:
boolean - Description: Whether image contains NSFW content
- Type:
licenserequired- Type:
string - Description: Image license type
- Example:
"cc-by"
- Type:
visibilityrequired- Type:
string - Description: Image visibility setting
- Example:
"public"
- Type:
expiration_daterequired- Type:
string - Description: Auto-delete expiration date (null for permanent)
- Type:
is_privaterequired- Type:
boolean - Description: Whether image requires authentication to view
- Type:
is_favouritedrequired- Type:
boolean - Description: Whether the current user has favourited this image
- Type:
created_atrequired- Type:
string - Description: Image creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atrequired- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /images/{id}/token
Authentication Required
This endpoint requires authentication: Bearer
Generate a time-limited access token for an encrypted image. Returns 400 if image is not encrypted.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
abc123
- Type:
Request Body:
variantoptional- Type:
string - Description: Variant to generate token for (default: original)
- Example:
"thumbnail" - Default:
"original"
- Type:
expires_inoptional- Type:
integer - Description: Token lifetime in seconds (min: 5min, max: 7 days, default: 1 hour)
- Example:
3600 - Default:
3600
- Type:
Responses:
200: Access token generated successfully
400: Image not encrypted or invalid parameters
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
Albums
Albums let you organise your images into folders. They relate to physical directories on-disk in the bucket, but can also have custom metadata and settings.
GET /albums
Authentication Required
This endpoint requires authentication: Bearer
Returns a list of all albums for the authenticated user. Returns 401 if unauthorized.
Responses:
200: List of albums retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /albums
Authentication Required
This endpoint requires authentication: Bearer
Creates a new album for organizing images. Album slugs must be unique and contain only lowercase letters, numbers, and hyphens. Returns 400 for validation errors, 401 if unauthorized, or 409 if album already exists.
Request Body:
albumrequired- Type:
string - Description: Slug for the album - lowercase letters, numbers, hyphens
- Example:
"vacation-2024"
- Type:
titlerequired- Type:
string - Description: Display name for the album
- Example:
"Summer Vacation 2024"
- Type:
descriptionoptional- Type:
string - Description: What this album is about
- Example:
"Photos from our summer vacation to Hawaii"
- Type:
permissionoptional- Type:
"public" | "private" - Description: Public profile permission - public or private. Defaults to private
- Example:
"private"
- Type:
Responses:
201: Album created successfully
Response 201:
albumrequired- Type:
string - Description: Album slug (unique identifier)
- Example:
"vacation-2024"
- Type:
titlerequired- Type:
string - Description: Human-readable album title
- Example:
"Summer Vacation 2024"
- Type:
descriptionrequired- Type:
string - Description: Album description
- Example:
"Photos from our summer vacation"
- Type:
countrequired- Type:
integer - Description: Number of images in this album
- Example:
42
- Type:
created_atrequired- Type:
string - Description: Album creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atrequired- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
cover_urloptional- Type:
string - Description: URL of album cover image (if set)
- Example:
"https://cdn.pixelflare.cc/user/vacation/cover.jpg/thumb"
- Type:
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
409: Conflict - Resource already exists
Response 409:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /albums/{album}
Authentication Required
This endpoint requires authentication: Bearer
Returns details about a specific album, including image count. Returns 401 if unauthorized or 404 if album not found.
Parameters:
album(path) required- Type:
string - Description: Album slug
- Example:
vacation-2024
- Type:
Responses:
200: Album details retrieved successfully
Response 200:
albumrequired- Type:
string - Description: Album slug (unique identifier)
- Example:
"vacation-2024"
- Type:
titlerequired- Type:
string - Description: Human-readable album title
- Example:
"Summer Vacation 2024"
- Type:
descriptionrequired- Type:
string - Description: Album description
- Example:
"Photos from our summer vacation"
- Type:
countrequired- Type:
integer - Description: Number of images in this album
- Example:
42
- Type:
created_atrequired- Type:
string - Description: Album creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atrequired- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
cover_urloptional- Type:
string - Description: URL of album cover image (if set)
- Example:
"https://cdn.pixelflare.cc/user/vacation/cover.jpg/thumb"
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
PATCH /albums/{album}
Authentication Required
This endpoint requires authentication: Bearer
Updates an album's title or description. The album slug cannot be changed. Returns 400 for validation errors, 401 if unauthorized, or 404 if album not found.
Parameters:
album(path) required- Type:
string - Description: Album slug
- Example:
vacation-2024
- Type:
Request Body:
titleoptional- Type:
string - Description: New name for the album
- Example:
"Updated Vacation Photos"
- Type:
descriptionoptional- Type:
string - Description: New description
- Example:
"Updated description"
- Type:
permissionoptional- Type:
"public" | "private" - Description: Change public profile permission
- Example:
"public"
- Type:
Responses:
200: Album updated successfully
Response 200:
albumrequired- Type:
string - Description: Album slug (unique identifier)
- Example:
"vacation-2024"
- Type:
titlerequired- Type:
string - Description: Human-readable album title
- Example:
"Summer Vacation 2024"
- Type:
descriptionrequired- Type:
string - Description: Album description
- Example:
"Photos from our summer vacation"
- Type:
countrequired- Type:
integer - Description: Number of images in this album
- Example:
42
- Type:
created_atrequired- Type:
string - Description: Album creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atrequired- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
cover_urloptional- Type:
string - Description: URL of album cover image (if set)
- Example:
"https://cdn.pixelflare.cc/user/vacation/cover.jpg/thumb"
- Type:
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
DELETE /albums/{album}
Authentication Required
This endpoint requires authentication: Bearer
Permanently deletes an album. This does not delete the images in the album, they will be moved to the default "images" album. Returns 401 if unauthorized or 404 if album not found.
Parameters:
album(path) required- Type:
string - Description: Album slug
- Example:
vacation-2024
- Type:
Responses:
204: Album deleted successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
Tags
Images can have zero or more tags, to make searching and organisation easier. The tags endpoint let you fetch, create, edit and delete tags, but won't affect the images themselves.
GET /tags
Authentication Required
This endpoint requires authentication: Bearer
Returns a list of all tags for the authenticated user, sorted by usage count (descending). Returns 401 if unauthorized.
Responses:
200: List of tags retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /tags
Authentication Required
This endpoint requires authentication: Bearer
Creates a new tag for organizing images. Tag names are automatically normalized to lowercase slugs. Returns 400 for validation errors, 401 if unauthorized, or 409 if tag already exists.
Request Body:
tagrequired- Type:
string - Description: Tag name - I'll convert it to lowercase
- Example:
"nature"
- Type:
descriptionoptional- Type:
string - Description: What this tag means
- Example:
"Photos of natural landscapes and wildlife"
- Type:
coloroptional- Type:
string - Description: Colour for this tag - uses Tailwind colour names
- Example:
"red"
- Type:
Responses:
201: Tag created successfully
Response 201:
tagrequired- Type:
string - Description: Tag slug (unique identifier)
- Example:
"nature"
- Type:
descriptionoptional- Type:
string - Description: Tag description
- Example:
"Photos of natural landscapes and wildlife"
- Type:
coloroptional- Type:
string - Description: Tag color in hex format
- Example:
"#22c55e"
- Type:
countrequired- Type:
integer - Description: Number of images with this tag
- Example:
156
- Type:
created_atoptional- Type:
string - Description: Tag creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atoptional- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
409: Conflict - Resource already exists
Response 409:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /tags/{tag}
Authentication Required
This endpoint requires authentication: Bearer
Returns details about a specific tag, including usage count. Returns 401 if unauthorized or 404 if tag not found.
Parameters:
tag(path) required- Type:
string - Description: Tag slug
- Example:
nature
- Type:
Responses:
200: Tag details retrieved successfully
Response 200:
tagrequired- Type:
string - Description: Tag slug (unique identifier)
- Example:
"nature"
- Type:
descriptionoptional- Type:
string - Description: Tag description
- Example:
"Photos of natural landscapes and wildlife"
- Type:
coloroptional- Type:
string - Description: Tag color in hex format
- Example:
"#22c55e"
- Type:
countrequired- Type:
integer - Description: Number of images with this tag
- Example:
156
- Type:
created_atoptional- Type:
string - Description: Tag creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atoptional- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
PATCH /tags/{tag}
Authentication Required
This endpoint requires authentication: Bearer
Updates a tag's description or other metadata. The tag slug cannot be changed. Returns 400 for validation errors, 401 if unauthorized, or 404 if tag not found.
Parameters:
tag(path) required- Type:
string - Description: Tag slug
- Example:
nature
- Type:
Request Body:
descriptionoptional- Type:
string - Description: New description for this tag
- Example:
"Updated tag description"
- Type:
coloroptional- Type:
string - Description: New colour - use Tailwind colour names
- Example:
"pink"
- Type:
Responses:
200: Tag updated successfully
Response 200:
tagrequired- Type:
string - Description: Tag slug (unique identifier)
- Example:
"nature"
- Type:
descriptionoptional- Type:
string - Description: Tag description
- Example:
"Photos of natural landscapes and wildlife"
- Type:
coloroptional- Type:
string - Description: Tag color in hex format
- Example:
"#22c55e"
- Type:
countrequired- Type:
integer - Description: Number of images with this tag
- Example:
156
- Type:
created_atoptional- Type:
string - Description: Tag creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
updated_atoptional- Type:
string - Description: Last update timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
DELETE /tags/{tag}
Authentication Required
This endpoint requires authentication: Bearer
Permanently deletes a tag. This does not delete the images associated with this tag, only the tag association. Returns 401 if unauthorized or 404 if tag not found.
Parameters:
tag(path) required- Type:
string - Description: Tag slug
- Example:
nature
- Type:
Responses:
200: Tag deleted successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
Favourites
Mark and retrieve your favorite images for quick access and (where supported) offline viewing.
POST /images/{id}/favourite
Authentication Required
This endpoint requires authentication: Bearer
Marks an image as favourited. Returns 401 if unauthorized or 404 if image not found.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Responses:
200: Image added to favourites successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
DELETE /images/{id}/favourite
Authentication Required
This endpoint requires authentication: Bearer
Removes the favourite mark from an image. Returns 401 if unauthorized.
Parameters:
id(path) required- Type:
string - Description: Image ID
- Example:
img_abc123
- Type:
Responses:
200: Image removed from favourites successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /favourites
Authentication Required
This endpoint requires authentication: Bearer
Returns a paginated list of all favourited images for the authenticated user. Returns 401 if unauthorized.
Parameters:
limit(query) optional- Type:
integer - Description: Number of items per page
- Example:
10 - Default:
10
- Type:
cursor(query) optional- Type:
string - Description: Pagination cursor from previous response
- Example:
img_xyz789
- Type:
Responses:
200: Favourited images retrieved successfully
Response 200:
datarequired- Type:
any[] - Description: Array of items in this page
- Type:
next_cursorrequired- Type:
string - Description: Cursor for next page (null if no more pages)
- Example:
"img_xyz789"
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
Analytics
Track CDN usage, bandwidth consumption, and image performance metrics with detailed breakdowns.
GET /analytics/usage
Authentication Required
This endpoint requires authentication: Bearer
Returns overall usage statistics for the authenticated user including storage, bandwidth, and request counts. Returns 401 if unauthorized.
Parameters:
days(query) optional- Type:
string - Description: Number of days to include in statistics (default: 30, max: 90)
- Example:
30
- Type:
offset(query) optional- Type:
string - Description: Number of days to offset the period (default: 0). Use offset=30 for previous 30-day period.
- Example:
0
- Type:
Responses:
200: Usage statistics retrieved successfully
Response 200:
enabledrequired- Type:
boolean - Description: Whether analytics is enabled for this account
- Example:
true
- Type:
periodrequired- Type:
object - Description: Time period for the statistics
- Type:
storagerequired- Type:
object - Description: Storage usage statistics
- Type:
bandwidthrequired- Type:
object - Description: Bandwidth usage statistics
- Type:
requestsrequired- Type:
object - Description: Request count statistics
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /analytics/images/{id}
Authentication Required
This endpoint requires authentication: Bearer
Returns detailed consumption statistics for one or more images. Supports comma-separated IDs for batch requests (e.g., /analytics/images/:id1,:id2,:id3). Returns single object for one ID, array for multiple IDs. Returns 401 if unauthorized, 403 if not owned by user, or 404 if image not found (single ID only).
Parameters:
id(path) required- Type:
string - Description: Image ID or comma-separated IDs (e.g., id1,id2,id3)
- Example:
img_abc123
- Type:
days(query) optional- Type:
string - Description: Number of days to include in statistics (default: 30, max: 90)
- Example:
30
- Type:
offset(query) optional- Type:
string - Description: Number of days to offset the period (default: 0)
- Example:
0
- Type:
Responses:
200: Image statistics retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
403: Forbidden - Insufficient permissions
Response 403:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /analytics/flows
Authentication Required
This endpoint requires authentication: Bearer
Returns image request flows data for Sankey diagram visualization, showing top images by request count with album and variant breakdown. Returns 401 if unauthorized.
Parameters:
days(query) optional- Type:
string - Description: Number of days to include in statistics (default: 30, max: 90)
- Example:
30
- Type:
offset(query) optional- Type:
string - Description: Number of days to offset the period (default: 0)
- Example:
0
- Type:
limit(query) optional- Type:
string - Description: Maximum number of flow records to return (default: 10, max: 200)
- Example:
10
- Type:
Responses:
200: Image flows retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /analytics/referrers/timeline
Authentication Required
This endpoint requires authentication: Bearer
Returns daily request counts for the top N referrer domains over the specified period. Referrers are grouped by domain for cleaner visualization. Useful for tracking referrer trends. Returns 401 if unauthorized.
Parameters:
days(query) optional- Type:
string - Description: Number of days to include in statistics (default: 30, max: 90)
- Example:
30
- Type:
offset(query) optional- Type:
string - Description: Number of days to offset the period (default: 0)
- Example:
0
- Type:
top(query) optional- Type:
string - Description: Number of top referrer domains to include (default: 10, max: 20)
- Example:
10
- Type:
Responses:
200: Referrer timeline retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /analytics/countries/timeline
Authentication Required
This endpoint requires authentication: Bearer
Returns daily request and bandwidth counts for the top N countries over the specified period. Useful for tracking geographic traffic trends. Returns 401 if unauthorized.
Parameters:
days(query) optional- Type:
string - Description: Number of days to include in statistics (default: 30, max: 90)
- Example:
30
- Type:
offset(query) optional- Type:
string - Description: Number of days to offset the period (default: 0)
- Example:
0
- Type:
top(query) optional- Type:
string - Description: Number of top countries to include (default: 10, max: 20)
- Example:
10
- Type:
Responses:
200: Country timeline retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /analytics/usage-limits
Authentication Required
This endpoint requires authentication: Bearer
Returns current usage and limit information for the authenticated user. Shows quota status and plan tier. Returns 401 if unauthorized.
Responses:
200: Usage limit information retrieved successfully
Response 200:
enabledrequired- Type:
boolean - Description: Whether usage limits are enabled
- Example:
true
- Type:
currentrequired- Type:
integer - Description: Current number of images uploaded
- Example:
245
- Type:
limitrequired- Type:
integer - Description: Maximum images allowed for user plan (null = unlimited)
- Example:
1000
- Type:
percentagerequired- Type:
number - Description: Usage percentage (0-100+)
- Example:
24.5
- Type:
planrequired- Type:
string - Description: User plan tier (free, starter, pro, unlimited)
- Example:
"free"
- Type:
grace_percentagerequired- Type:
number - Description: Grace buffer percentage over limit
- Example:
1
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
Audit Logs
View audit logs of all API actions and mutations. Track who did what, when, and from where.
GET /audit-logs
Authentication Required
This endpoint requires authentication: Bearer
Returns a paginated list of audit log entries with optional filtering by action, resource type, status, and date range. Returns 503 if audit logging is disabled.
Parameters:
limit(query) optional- Type:
integer - Description: Number of logs to return (max 200)
- Example:
10 - Default:
10
- Type:
cursor(query) optional- Type:
string - Description: Pagination cursor from previous response
- Example:
log_xyz789
- Type:
action(query) optional- Type:
string - Description: Filter by action type
- Example:
image.create
- Type:
resource_type(query) optional- Type:
string - Description: Filter by resource type
- Example:
image
- Type:
status(query) optional- Type:
"success" | "failure" - Description: Filter by status
- Example:
success
- Type:
date_from(query) optional- Type:
string - Description: Filter logs from this date (YYYY-MM-DD)
- Example:
2025-01-01
- Type:
date_to(query) optional- Type:
string - Description: Filter logs up to this date (YYYY-MM-DD)
- Example:
2025-12-31
- Type:
Responses:
200: List of audit logs retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
503: Service Unavailable - Service temporarily unavailable
Response 503:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /audit-logs/stats
Authentication Required
This endpoint requires authentication: Bearer
Returns aggregated statistics about audit logs for the authenticated user. Returns 503 if audit logging is disabled.
Parameters:
days(query) optional- Type:
integer - Description: Number of days to include in statistics (1-365)
- Example:
30 - Default:
30
- Type:
Responses:
200: Audit log statistics retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
503: Service Unavailable - Service temporarily unavailable
Response 503:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /audit-logs/export
Authentication Required
This endpoint requires authentication: Bearer
Exports audit logs matching the specified filters as a CSV file. Returns 503 if audit logging is disabled.
Parameters:
action(query) optional- Type:
string - Description: Filter by action type
- Example:
image.create
- Type:
resource_type(query) optional- Type:
string - Description: Filter by resource type
- Example:
image
- Type:
status(query) optional- Type:
"success" | "failure" - Description: Filter by status
- Example:
success
- Type:
date_from(query) optional- Type:
string - Description: Filter logs from this date (YYYY-MM-DD)
- Example:
2025-01-01
- Type:
date_to(query) optional- Type:
string - Description: Filter logs up to this date (YYYY-MM-DD)
- Example:
2025-12-31
- Type:
Responses:
200: CSV file generated successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
503: Service Unavailable - Service temporarily unavailable
Response 503:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /audit-logs/status
Returns whether audit logging is enabled on this instance. No authentication required.
Responses:
200: Audit logging status retrieved successfully
API Keys
Manage API keys for programmatic access. Supports scoped permissions and expiration.
GET /keys
Authentication Required
This endpoint requires authentication: Bearer
Returns a list of all API keys for the authenticated user. The key values are not returned (only shown on creation). Returns 401 if unauthorized.
Responses:
200: List of API keys retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /keys
Authentication Required
This endpoint requires authentication: Bearer
Creates a new API key with specified scopes and optional expiration. The key value is only returned once on creation - store it securely! Returns 400 for validation errors or 401 if unauthorized.
Request Body:
nameoptional- Type:
string - Description: Name to help you remember what this key is for
- Example:
"CI/CD Pipeline Key"
- Type:
scopesrequired- Type:
"read" | "write" | "delete"[] - Description: What can this key do? Pick at least one
- Example:
["read","write"]
- Type:
expires_in_daysoptional- Type:
integer - Description: Days until expiry - max 365
- Example:
90
- Type:
allowed_ipsoptional- Type:
string[] - Description: Limit to specific IPs or CIDR ranges - leave empty to allow all
- Example:
["192.168.1.1","10.0.0.0/24"]
- Type:
Responses:
201: API key created successfully
Response 201:
key_idrequired- Type:
string - Description: Unique key identifier
- Example:
"key_abc123"
- Type:
keyoptional- Type:
string - Description: API key value (only present on creation, store securely!)
- Example:
"pxf_1234567890abcdef1234567890abcdef"
- Type:
scopesrequired- Type:
string[] - Description: Permissions granted to this API key
- Example:
["read","write"]
- Type:
namerequired- Type:
string - Description: Human-readable key name
- Example:
"CI/CD Pipeline Key"
- Type:
expires_atrequired- Type:
string - Description: Key expiration timestamp (null for no expiration)
- Example:
"2026-11-10T22:00:00.000Z"
- Type:
last_used_atrequired- Type:
string - Description: Last time this key was used
- Example:
"2025-11-10T21:00:00.000Z"
- Type:
revoked_atrequired- Type:
string - Description: Key revocation timestamp (null if active)
- Type:
created_atrequired- Type:
string - Description: Key creation timestamp
- Example:
"2025-11-10T22:00:00.000Z"
- Type:
allowed_ipsrequired- Type:
string[] - Description: IP addresses or CIDR ranges allowed to use this key (null allows all)
- Example:
["192.168.1.1","10.0.0.0/24"]
- Type:
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
DELETE /keys/{keyId}
Authentication Required
This endpoint requires authentication: Bearer
Permanently revokes an API key. The key will no longer be able to authenticate. Returns 401 if unauthorized or 404 if key not found.
Parameters:
keyId(path) required- Type:
string - Description: API key ID
- Example:
key_abc123
- Type:
Responses:
204: API key revoked successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
Backup
Configure S3 backup for redundancy. Supports automatic sync and encryption.
GET /backup/config
Retrieve the current S3 backup configuration for the authenticated user
Responses:
200: Backup configuration retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /backup/config
Configure S3-compatible storage for automated image backups
Request Body:
enabledrequired- Type:
boolean - Description:
- Type:
s3_endpointrequired- Type:
string - Description:
- Type:
s3_regionrequired- Type:
string - Description:
- Type:
s3_bucketrequired- Type:
string - Description:
- Type:
s3_path_prefixoptional- Type:
string - Description:
- Type:
s3_access_key_idrequired- Type:
string - Description:
- Type:
s3_secret_access_keyrequired- Type:
string - Description:
- Type:
Responses:
200: Backup configuration updated successfully
201: Backup configuration created successfully
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
PATCH /backup/config
Partially update S3 backup configuration fields
Request Body:
enabledoptional- Type:
boolean - Description:
- Type:
s3_endpointoptional- Type:
string - Description:
- Type:
s3_regionoptional- Type:
string - Description:
- Type:
s3_bucketoptional- Type:
string - Description:
- Type:
s3_path_prefixoptional- Type:
string - Description:
- Type:
s3_access_key_idoptional- Type:
string - Description:
- Type:
s3_secret_access_keyoptional- Type:
string - Description:
- Type:
Responses:
200: Backup configuration updated successfully
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
DELETE /backup/config
Remove S3 backup configuration and encrypted credentials
Responses:
204: Backup configuration deleted successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /backup/test
Validate S3 credentials and bucket access
Responses:
200: Connection test completed
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /backup/sync
Manually trigger backup sync for pending images
Responses:
202: Backup sync queued successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /backup/stats
Retrieve backup sync statistics and status counts
Responses:
200: Backup statistics retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
Settings
Manage user preferences including theme, language, accessibility options, and default upload settings.
GET /settings
Authentication Required
This endpoint requires authentication: Bearer
Returns user preferences for appearance, accessibility, and upload defaults. Returns default values for new users.
Responses:
200: Settings retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
PATCH /settings
Authentication Required
This endpoint requires authentication: Bearer
Partially update user settings. Only provided fields will be updated. Returns merged settings with defaults.
Request Body:
themeoptional- Type:
"auto" | "light" | "dark" | "dracula" | "night" | "winter" | "synthwave" | "valentine" | "aqua" | "lofi" | "dim" | "pastel" | "business" | "nord" | "sunset" | "fantasy" | "cupcake" | "emerald" - Description:
- Type:
languageoptional- Type:
"en" | "es" | "fr" | "zh" | "hi" | "ar" | "pt" | "de" | "id" | "ru" | "ko" | "it" - Description:
- Type:
accessibilityoptional- Type:
object - Description:
- Type:
uploadoptional- Type:
object - Description:
- Type:
image_view_modeoptional- Type:
"regular" | "expanded" - Description:
- Type:
embed_url_formatoptional- Type:
"full" | "short" - Description:
- Type:
embed_use_custom_domainoptional- Type:
boolean - Description:
- Type:
embed_enabled_formatsoptional- Type:
string[] - Description:
- Type:
saved_custom_variantoptional- Type:
object - Description:
- Type:
delete_variant_idoptional- Type:
string - Description:
- Type:
update_variantoptional- Type:
object - Description:
- Type:
Responses:
200: Settings updated successfully
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
Custom Domains
Configure custom subdomains for serving images from your own domain (e.g., cdn.yourdomain.com).
GET /custom-domain
Authentication Required
This endpoint requires authentication: Bearer
Returns the custom domain configuration for the authenticated user. Returns 404 if no custom domain is configured.
Responses:
200: Custom domain retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: No custom domain configured
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /custom-domain
Authentication Required
This endpoint requires authentication: Bearer
Configures a custom subdomain for serving images. Only one domain per user is allowed. If a domain already exists, it will be replaced. The domain must be verified via DNS (CNAME or TXT record) before it becomes active.
Request Body:
hostnamerequired- Type:
string - Description: The custom subdomain (e.g., cdn.example.com). Root domains are not supported.
- Type:
Responses:
200: Custom domain updated successfully
201: Custom domain created successfully
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
409: Hostname already in use by another user
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
503: Custom domains feature is not enabled
DELETE /custom-domain
Authentication Required
This endpoint requires authentication: Bearer
Removes the custom domain configuration for the authenticated user. The domain will be immediately removed from Cloudflare and the cache will be invalidated.
Responses:
204: Custom domain deleted successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: No custom domain configured
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /custom-domain/verify
Authentication Required
This endpoint requires authentication: Bearer
Manually triggers a verification check for the custom domain. Queries Cloudflare API to check if DNS records are correctly configured.
Responses:
200: Verification check completed
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: No custom domain configured
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
Webhooks
Configure webhooks to receive real-time HTTP notifications when events occur (e.g., image uploaded, album created). Includes HMAC-SHA256 signatures for security.
POST /webhooks
Authentication Required
This endpoint requires authentication: Bearer
Create a new webhook to receive HTTP POST notifications when events occur. Maximum 10 webhooks per user.
Request Body:
urlrequired- Type:
string - Description: HTTPS URL to receive webhook POST requests
- Example:
"https://example.com/webhooks/pixelflare"
- Type:
eventsrequired- Type:
"image.uploaded" | "image.updated" | "image.deleted" | "image.permanently_deleted" | "image.restored" | "album.created" | "album.updated" | "album.deleted"[] - Description: Array of events to subscribe to
- Example:
["image.uploaded","image.deleted"]
- Type:
descriptionoptional- Type:
string - Description: Optional description for this webhook
- Example:
"Production webhook for image events"
- Type:
Responses:
201: Webhook created successfully (secret only returned once)
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /webhooks
Authentication Required
This endpoint requires authentication: Bearer
Get all webhooks for the authenticated user
Responses:
200: List of webhooks (secrets not included)
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /webhooks/{id}
Authentication Required
This endpoint requires authentication: Bearer
Get details of a specific webhook
Parameters:
id(path) required- Type:
string - Description:
- Example:
wh_abc123
- Type:
Responses:
200: Webhook details (secret not included)
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
PATCH /webhooks/{id}
Authentication Required
This endpoint requires authentication: Bearer
Update webhook URL, events, description, or enabled status
Parameters:
id(path) required- Type:
string - Description:
- Example:
wh_abc123
- Type:
Request Body:
urloptional- Type:
string - Description:
- Example:
"https://example.com/webhooks/pixelflare-v2"
- Type:
eventsoptional- Type:
"image.uploaded" | "image.updated" | "image.deleted" | "image.permanently_deleted" | "image.restored" | "album.created" | "album.updated" | "album.deleted"[] - Description:
- Example:
["image.uploaded"]
- Type:
descriptionoptional- Type:
string - Description:
- Example:
"Updated webhook description"
- Type:
enabledoptional- Type:
boolean - Description:
- Example:
true
- Type:
Responses:
200: Webhook updated successfully
400: Bad Request - Invalid input or validation error
Response 400:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
DELETE /webhooks/{id}
Authentication Required
This endpoint requires authentication: Bearer
Permanently delete a webhook
Parameters:
id(path) required- Type:
string - Description:
- Example:
wh_abc123
- Type:
Responses:
204: Webhook deleted successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
POST /webhooks/{id}/test
Authentication Required
This endpoint requires authentication: Bearer
Send a test event to verify webhook is configured correctly
Parameters:
id(path) required- Type:
string - Description:
- Example:
wh_abc123
- Type:
Responses:
200: Test result
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /webhooks/{id}/deliveries
Authentication Required
This endpoint requires authentication: Bearer
Get recent delivery attempts for a webhook (last 100)
Parameters:
id(path) required- Type:
string - Description:
- Example:
wh_abc123
- Type:
Responses:
200: List of recent deliveries
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
Status
Check API health, service status, and system information.
GET /status
Returns public system status including dependency health, feature availability, and app version. No authentication required. Use this endpoint for monitoring and health checks.
Responses:
200: System status retrieved successfully
Response 200:
statusrequired- Type:
"ok" | "degraded" | "error" - Description: Overall system status: ok (all dependencies healthy), degraded (optional dependencies down), error (critical dependencies down)
- Example:
"ok"
- Type:
timestamprequired- Type:
string - Description: ISO 8601 timestamp of status check
- Example:
"2025-12-01T14:30:00.123Z"
- Type:
apprequired- Type:
object - Description: Application metadata
- Type:
featuresrequired- Type:
object - Description: Available features and capabilities
- Type:
dependenciesrequired- Type:
object - Description: Health status of external dependencies
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /status/detailed
Authentication Required
This endpoint requires authentication: Bearer
Returns detailed system status including migration version, resource counts, scheduled jobs, and binding information. Requires authentication. In production, sensitive details are redacted. In development, full binding IDs are shown.
Responses:
200: Detailed status retrieved successfully
401: Unauthorised - Authentication required
Response 401:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
Public Profiles
Public (unauthenticated) endpoints for viewing user profiles, albums, and images. No authentication required.
GET /public/users/:owner
Returns a user's public profile information and statistics. No authentication required.
Parameters:
owner(path) required- Type:
string - Description: User owner ID / username
- Example:
alice
- Type:
Responses:
200: Public profile retrieved successfully
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /public/users/:owner/albums
Returns a paginated list of public albums for a user. No authentication required.
Parameters:
owner(path) required- Type:
string - Description: User owner ID / username
- Example:
alice
- Type:
limit(query) optional- Type:
integer - Description: Number of items per page
- Example:
10 - Default:
10
- Type:
cursor(query) optional- Type:
string - Description: Pagination cursor from previous response
- Example:
img_xyz789
- Type:
Responses:
200: Public albums list retrieved successfully
Response 200:
datarequired- Type:
any[] - Description: Array of items in this page
- Type:
next_cursorrequired- Type:
string - Description: Cursor for next page (null if no more pages)
- Example:
"img_xyz789"
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /public/users/:owner/albums/:slug
Returns a public album with its images (filtered to public and inherit permissions). No authentication required.
Parameters:
owner(path) required- Type:
string - Description: User owner ID / username
- Example:
alice
- Type:
slug(path) required- Type:
string - Description: Album slug
- Example:
vacation-2024
- Type:
limit(query) optional- Type:
integer - Description: Number of items per page
- Example:
10 - Default:
10
- Type:
cursor(query) optional- Type:
string - Description: Pagination cursor from previous response
- Example:
img_xyz789
- Type:
Responses:
200: Public album with images retrieved successfully
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /public/users/:owner/images
Returns paginated list of public images for a user (includes orphan images and images in private albums that are marked public). No authentication required.
Parameters:
owner(path) required- Type:
string - Description: User owner ID / username
- Example:
alice
- Type:
limit(query) optional- Type:
integer - Description: Number of items per page
- Example:
10 - Default:
10
- Type:
cursor(query) optional- Type:
string - Description: Pagination cursor from previous response
- Example:
img_xyz789
- Type:
Responses:
200: Public images list retrieved successfully
Response 200:
datarequired- Type:
any[] - Description: Array of items in this page
- Type:
next_cursorrequired- Type:
string - Description: Cursor for next page (null if no more pages)
- Example:
"img_xyz789"
- Type:
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
GET /public/users/:owner/albums/:slug/images/:filename
Returns a single public image with album context and navigation (prev/next images). Works regardless of album permission - only checks if the image itself is public. No authentication required.
Parameters:
owner(path) required- Type:
string - Description: User owner ID / username
- Example:
alice
- Type:
slug(path) required- Type:
string - Description: Album slug
- Example:
vacation-2024
- Type:
filename(path) required- Type:
string - Description: Image filename
- Example:
beach-sunset.jpg
- Type:
Responses:
200: Public image retrieved successfully
404: Not Found - Resource does not exist
Response 404:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
429: Too Many Requests - Rate limit exceeded
Response 429:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
500: Internal Server Error - Unexpected server error
Response 500:
coderequired- Type:
string - Description: Machine-readable error code
- Example:
"VALIDATION_ERROR"
- Type:
messagerequired- Type:
string - Description: Human-readable error message
- Example:
"Request validation failed"
- Type:
detailsoptional- Type:
object - Description: Additional error details (field-specific validation errors)
- Example:
{"filename":"Filename is required"}
- Type:
Image Serving
Public CDN routes for accessing and serving images. These endpoints deliver your images globally via Cloudflare's edge network with automatic caching and image transformations.
GET /i/{id}
Serve an image using its short ID, with optional custom transformations.
Path format: /i/{id}
Benefits:
- Shorter URLs (6 characters instead of full path)
- Stable links (unaffected by renames/moves)
- Ideal for sharing and embedding
- Custom transformations via query parameters
Examples:
https://pixelflare.cc/i/ab12xy
https://pixelflare.cc/i/ab12xy?w=400&h=300&fit=coverParameters:
id(path) required- Type:
string - Description: Short image ID (6 characters)
- Type:
w(query) optional- Type:
integer - Description: Width in pixels (1-9999)
- Type:
h(query) optional- Type:
integer - Description: Height in pixels (1-9999)
- Type:
fit(query) optional- Type:
"scale-down" | "contain" | "cover" | "crop" | "pad" | "squeeze" - Description: Resize fit mode
- Type:
q(query) optional- Type:
integer - Description: Quality (1-100)
- Type:
f(query) optional- Type:
"auto" | "avif" | "webp" | "jpeg" | "png" - Description: Output format
- Type:
g(query) optional- Type:
"auto" | "center" | "left" | "right" | "top" | "bottom" | "face" - Description: Gravity/focus point
- Type:
trim(query) optional- Type:
string - Description: Crop margins (e.g., top:10,left:20)
- Type:
blur(query) optional- Type:
integer - Description: Blur radius (1-250)
- Type:
sharpen(query) optional- Type:
integer - Description: Sharpen amount (1-10)
- Type:
br(query) optional- Type:
number - Description: Brightness (0.5-2.0)
- Type:
co(query) optional- Type:
number - Description: Contrast (0.5-2.0)
- Type:
sat(query) optional- Type:
number - Description: Saturation (0-2.0)
- Type:
gam(query) optional- Type:
number - Description: Gamma (0.5-2.0)
- Type:
r(query) optional- Type:
"0" | "90" | "180" | "270" - Description: Rotation angle (0, 90, 180, 270)
- Type:
flip(query) optional- Type:
"h" | "v" | "hv" - Description: Flip direction (h=horizontal, v=vertical, hv=both)
- Type:
bg(query) optional- Type:
string - Description: Background color (hex without #)
- Type:
meta(query) optional- Type:
"keep" | "copyright" | "none" - Description: Metadata handling
- Type:
Responses:
200: Image successfully served
403: Image is private
404: Image not found
410: Image deleted
429: Too many custom transformation requests
GET /i/{id}/{variant}
Serve a specific image variant using the short ID format, with optional custom transformations.
Path format: /i/{id}/{variant}
Examples:
https://pixelflare.cc/i/ab12xy/w512
https://pixelflare.cc/i/ab12xy/w512?sharpen=5&q=90This combines the benefits of short URLs with on-demand image transformation. Query params override variant preset.
Parameters:
id(path) required- Type:
string - Description: Short image ID (6 characters)
- Type:
variant(path) required- Type:
"original" | "w128" | "w256" | "w512" | "w1024" | "w1536" | "w2048" | "thumb" | "og-image" - Description:
- Type:
w(query) optional- Type:
integer - Description: Width in pixels (1-9999)
- Type:
h(query) optional- Type:
integer - Description: Height in pixels (1-9999)
- Type:
fit(query) optional- Type:
"scale-down" | "contain" | "cover" | "crop" | "pad" | "squeeze" - Description: Resize fit mode
- Type:
q(query) optional- Type:
integer - Description: Quality (1-100)
- Type:
f(query) optional- Type:
"auto" | "avif" | "webp" | "jpeg" | "png" - Description: Output format
- Type:
g(query) optional- Type:
"auto" | "center" | "left" | "right" | "top" | "bottom" | "face" - Description: Gravity/focus point
- Type:
trim(query) optional- Type:
string - Description: Crop margins (e.g., top:10,left:20)
- Type:
blur(query) optional- Type:
integer - Description: Blur radius (1-250)
- Type:
sharpen(query) optional- Type:
integer - Description: Sharpen amount (1-10)
- Type:
br(query) optional- Type:
number - Description: Brightness (0.5-2.0)
- Type:
co(query) optional- Type:
number - Description: Contrast (0.5-2.0)
- Type:
sat(query) optional- Type:
number - Description: Saturation (0-2.0)
- Type:
gam(query) optional- Type:
number - Description: Gamma (0.5-2.0)
- Type:
r(query) optional- Type:
"0" | "90" | "180" | "270" - Description: Rotation angle (0, 90, 180, 270)
- Type:
flip(query) optional- Type:
"h" | "v" | "hv" - Description: Flip direction (h=horizontal, v=vertical, hv=both)
- Type:
bg(query) optional- Type:
string - Description: Background color (hex without #)
- Type:
meta(query) optional- Type:
"keep" | "copyright" | "none" - Description: Metadata handling
- Type:
Responses:
200: Image variant served
400: Invalid variant
403: Image is private
404: Image not found
410: Image deleted
429: Rate limited
GET /{owner}/{album}/{filename}
Serve an image at its original size or apply custom transformations via query parameters.
Path format: /{owner}/{album}/{filename}
Features:
- Global edge caching via Cloudflare CDN
- Automatic content-type detection
- Support for private images with authentication
- CORS enabled for cross-origin requests
- ETag support for efficient caching
- Custom transformations via query parameters (w, h, fit, q, f, g, etc.)
Examples:
https://pixelflare.cc/alice/vacation-2024/sunset.jpg
https://pixelflare.cc/alice/vacation-2024/sunset.jpg?w=800&h=600&fit=cover&q=85Parameters:
owner(path) required- Type:
string - Description: Image owner username
- Type:
album(path) required- Type:
string - Description: Album slug
- Type:
filename(path) required- Type:
string - Description: Image filename (with extension)
- Type:
w(query) optional- Type:
integer - Description: Width in pixels (1-9999)
- Type:
h(query) optional- Type:
integer - Description: Height in pixels (1-9999)
- Type:
fit(query) optional- Type:
"scale-down" | "contain" | "cover" | "crop" | "pad" | "squeeze" - Description: Resize fit mode
- Type:
q(query) optional- Type:
integer - Description: Quality (1-100)
- Type:
f(query) optional- Type:
"auto" | "avif" | "webp" | "jpeg" | "png" - Description: Output format
- Type:
g(query) optional- Type:
"auto" | "center" | "left" | "right" | "top" | "bottom" | "face" - Description: Gravity/focus point
- Type:
trim(query) optional- Type:
string - Description: Crop margins (e.g., top:10,left:20)
- Type:
blur(query) optional- Type:
integer - Description: Blur radius (1-250)
- Type:
sharpen(query) optional- Type:
integer - Description: Sharpen amount (1-10)
- Type:
br(query) optional- Type:
number - Description: Brightness (0.5-2.0)
- Type:
co(query) optional- Type:
number - Description: Contrast (0.5-2.0)
- Type:
sat(query) optional- Type:
number - Description: Saturation (0-2.0)
- Type:
gam(query) optional- Type:
number - Description: Gamma (0.5-2.0)
- Type:
r(query) optional- Type:
"0" | "90" | "180" | "270" - Description: Rotation angle (0, 90, 180, 270)
- Type:
flip(query) optional- Type:
"h" | "v" | "hv" - Description: Flip direction (h=horizontal, v=vertical, hv=both)
- Type:
bg(query) optional- Type:
string - Description: Background color (hex without #)
- Type:
meta(query) optional- Type:
"keep" | "copyright" | "none" - Description: Metadata handling
- Type:
Responses:
200: Image successfully served
403: Image is private and requires authentication
404: Image not found
410: Image has been deleted
429: Too many custom transformation requests
GET /{owner}/{album}/{filename}/{variant}
Serve a specific image variant (resized/optimized version) or apply custom transformations via query parameters.
Path format: /{owner}/{album}/{filename}/{variant}
Available variants: original, w128, w256, w512, w1024, w1536, w2048, thumb, og-image
Features:
- On-demand image transformation (if variant doesn't exist)
- Automatic format optimization (WebP when supported)
- Smart caching (variants are cached after first generation)
- Fallback to original for unsupported formats (e.g., SVG)
- Custom transformations via query parameters override variant preset
Examples:
https://pixelflare.cc/alice/vacation-2024/sunset.jpg/w1024
https://pixelflare.cc/alice/vacation-2024/sunset.jpg/w1024?blur=10&sharpen=5When query params are provided, they override the variant preset.
Parameters:
owner(path) required- Type:
string - Description: Image owner username
- Type:
album(path) required- Type:
string - Description: Album slug
- Type:
filename(path) required- Type:
string - Description: Image filename (with extension)
- Type:
variant(path) required- Type:
"original" | "w128" | "w256" | "w512" | "w1024" | "w1536" | "w2048" | "thumb" | "og-image" - Description:
- Type:
w(query) optional- Type:
integer - Description: Width in pixels (1-9999)
- Type:
h(query) optional- Type:
integer - Description: Height in pixels (1-9999)
- Type:
fit(query) optional- Type:
"scale-down" | "contain" | "cover" | "crop" | "pad" | "squeeze" - Description: Resize fit mode
- Type:
q(query) optional- Type:
integer - Description: Quality (1-100)
- Type:
f(query) optional- Type:
"auto" | "avif" | "webp" | "jpeg" | "png" - Description: Output format
- Type:
g(query) optional- Type:
"auto" | "center" | "left" | "right" | "top" | "bottom" | "face" - Description: Gravity/focus point
- Type:
trim(query) optional- Type:
string - Description: Crop margins (e.g., top:10,left:20)
- Type:
blur(query) optional- Type:
integer - Description: Blur radius (1-250)
- Type:
sharpen(query) optional- Type:
integer - Description: Sharpen amount (1-10)
- Type:
br(query) optional- Type:
number - Description: Brightness (0.5-2.0)
- Type:
co(query) optional- Type:
number - Description: Contrast (0.5-2.0)
- Type:
sat(query) optional- Type:
number - Description: Saturation (0-2.0)
- Type:
gam(query) optional- Type:
number - Description: Gamma (0.5-2.0)
- Type:
r(query) optional- Type:
"0" | "90" | "180" | "270" - Description: Rotation angle (0, 90, 180, 270)
- Type:
flip(query) optional- Type:
"h" | "v" | "hv" - Description: Flip direction (h=horizontal, v=vertical, hv=both)
- Type:
bg(query) optional- Type:
string - Description: Background color (hex without #)
- Type:
meta(query) optional- Type:
"keep" | "copyright" | "none" - Description: Metadata handling
- Type:
Responses:
200: Image variant successfully served (or original if variant generation not supported)
400: Invalid variant specified
403: Image is private and requires authentication
404: Image not found
410: Image has been deleted
429: Rate limit exceeded for variant generation
Additional Resources
- Interactive API Docs - Test endpoints with Scalar UI
- OpenAPI Spec - Download the OpenAPI JSON specification
- Authentication Guide - Learn about API authentication
- Rate Limiting - Understand rate limits
Support
For issues or questions, visit: