VIUCraft supports two URL formats for image transformations.
Standard Format
The standard format uses explicit parameter names:
Code
/operation_param1_value1_param2_value2/image-id.format
Examples
Code
# Resize with explicit width and height
/resize_width_300_height_200/image.jpg
# Crop with position and dimensions
/crop_x_10_y_10_width_400_height_300/image.jpg
# Rotate with angle
/rotate_angle_90/image.jpg
Short Format
The short format is more concise:
Code
/operation-value1-value2/image-id.format
Examples
Code
# Resize (width-height)
/resize-300-200/image.jpg
# Crop (x-y-width-height)
/crop-10-10-400-300/image.jpg
# Rotate (angle)
/rotate-90/image.jpg
Chaining Operations
Apply multiple operations by chaining them:
Code
# Standard format
/resize_width_800_height_600/grayscale/image.jpg
# Short format
/resize-800-600/grayscale/image.jpg
Operations are applied left to right.
URL Structure
Complete URL structure:
Code
https://{subdomain}.viucraft.com/{operations}/{image-id}.{format}
Components
| Component | Description | Example |
|---|---|---|
| subdomain | Your account subdomain | mycompany |
| operations | Transformation chain | resize-300-200/grayscale |
| image-id | Unique image identifier | abc123 |
| format | Output format | jpg, png, webp |
Free Tier URL Format
Free tier users use a shared endpoint:
Code
https://viucraft.com/free/acc_{customer_id}/{operations}/{image-id}.{format}