AeroModel
Documentation
filetype
Binary format of the returned image.
Values
| Value | Description | Alpha | Compression | Typical 1024 px size |
|---|---|---|---|---|
png (default) | Lossless PNG | ✅ | Lossless | 80-200 KB |
jpg (alias jpeg) | Opaque JPEG | ❌ | Lossy | 30-80 KB |
webp | Modern WebP | ✅ | Lossy | 40-100 KB |
Choosing the format
| Use case | Format |
|---|---|
On-the-fly composition (pitch, scale, background, ...) | png (forced) |
| Standard web display | webp (best ratio) |
| Maximum compatibility (legacy browsers) | jpg |
| Transparent background required (overlay) | png or webp |
| Print / high quality | png |
API examples
GET https://api.aeromodel.dash-systems.fr/v1/images/plane?api-key=YOUR_KEY&plane=A320&airline=AF&filetype=png
GET https://api.aeromodel.dash-systems.fr/v1/images/plane?api-key=YOUR_KEY&plane=A320&airline=AF&filetype=jpg
GET https://api.aeromodel.dash-systems.fr/v1/images/plane?api-key=YOUR_KEY&plane=A320&airline=AF&filetype=webp
The three serve the same image in the requested format. File size varies by format.
On-the-fly composition
As soon as a composition option is used — pitch, scale, align, background, backgroundGradient, width, zoomLevel, marginPercent, zoomType, resolution — the output is forced to PNG, regardless of the requested filetype.
Response headers x-format-requested and x-format-coerced indicate the coercion:
x-format-requested: jpg
x-format-coerced: png
Reason: composition uses a PNG decode → manipulate → encode chain optimized for the Workers runtime. JPG/WebP encoders are not bundled to keep bundle size small.
Coercion example
GET https://api.aeromodel.dash-systems.fr/v1/images/plane?api-key=YOUR_KEY&plane=A320&filetype=jpg&pitch=15
→ returns a PNG (with x-format-coerced: png header).
Errors
GET https://api.aeromodel.dash-systems.fr/v1/images/plane?api-key=YOUR_KEY&plane=A320&filetype=svg&format=json
→ 400 { "error": "invalid filetype" }
See also
width/resolution— sizebackground— color background (PNG only)