coverImage fields or any other content reference. All media endpoints require a valid Bearer token.
List Media Files
Returns a paginated list of all files in the media library. Requires a valid Bearer token.Query Parameters
Page number to retrieve. Defaults to
1.Number of items to return per page. Defaults to
10.Response
| Field | Type | Description |
|---|---|---|
id | number | Unique media file identifier |
filename | string | Original filename as stored on the server |
path | string | Server-relative path to the file (use this in article coverImage fields) |
size | number | File size in bytes |
mimeType | string | MIME type of the file (e.g. image/jpeg, image/png) |
createdAt | string | ISO 8601 upload timestamp |
total | number | Total number of files in the media library |
Upload a File
Uploads a new file to the media library. Requires a valid Bearer token. The request must be sent asmultipart/form-data with the binary file attached under the file field.
cURL Example
Request Body
The binary file to upload, sent as a
multipart/form-data field named file. The filename and MIME type are inferred from the submitted file.Response
| Field | Type | Description |
|---|---|---|
id | number | Unique ID assigned to the new media record |
filename | string | Stored filename (may be normalised or de-duplicated by the server) |
path | string | Server-relative path — use this value in article coverImage and other content fields |
url | string | Fully-qualified public URL to access the uploaded file directly |
Supported file types: JPEG (
.jpg, .jpeg), PNG (.png), GIF (.gif), and WebP (.webp). Uploads of unsupported MIME types will be rejected with a 400 error. The default maximum file size is 10 MB per upload — contact your system administrator to adjust this limit in the server configuration. Large images are not automatically resized; optimise images before uploading for best front-end performance.Delete a Media File
Permanently removes a file from the media library and deletes it from the server filesystem. Requires a valid Bearer token.Path Parameters
The numeric ID of the media file to delete.