Managing Media Library
These endpoints manage a project's media library - uploads, listing, captions, and deletion. Every route is relative to /public/v2/projects/:uuid/media and requires a bearer token.
List Media
GET
/mediaList uploaded media
Supports page (defaults to 1) and a text search parameter matched against captions and filenames. Requires the read ability.
Upload Media
POST
/media/uploadUpload a file
Multipart form upload - the file in a file field, an optional caption field. Rejected if the file exceeds the project's size limit (20 MB by default). Requires the create ability.
curl
curl -X POST \
-H "Authorization: Bearer <token>" \
-F "file=@photo.jpg" \
-F "caption=Team offsite" \
https://<host>/public/v2/projects/<uuid>/media/uploadUpdate Caption
PATCH
/media/:idUpdate a media item's caption
Body: { "caption": "..." }. Requires the update ability.
Delete Media
DELETE
/media/:idDelete a media item
Requires the delete ability.
Response
{ "success": true }