The Server API Key only permits CDN uploads and Logs reads/writes. Use a Developer API Key with
cdn:read, cdn:delete or cdn:purge for listing, deletion or purge. Configure it as the default or pass a named keyProfile.FIVEMESH_API_KEY, so these exports should be called from server-side Lua or JavaScript.
Lua callers can read the returned value directly. Failed exports return success = false with an error payload. JavaScript callers can use the returned Promise with await.
Upload a file
UseuploadFile when you already have bytes, a data URL or a Blob-compatible value.
publicUrl.
canvas.toDataURL() values and raw binary strings produced by atob() can be
passed directly. When the value is bare base64 without a data: prefix, declare
the representation explicitly:
Upload an image data URL
UseuploadImage when a script gives you an image as a data URL.
Use an API key profile
PasskeyProfile when an export should use a named key such as FIVEMESH_API_KEY_MUGSHOTS instead of the default FIVEMESH_API_KEY.
FIVEMESH_API_KEY_.
Upload multiple files
UsebulkUpload when a resource needs to upload a small batch and handle per-file results.
List CDN objects
UselistObjects with a path and optional pagination limit.
continuationToken is returned, pass it to the next call.
Delete objects
UsedeleteObject for one path or bulkDelete for a batch.
Purge CDN files
UsepurgeObjects when a resource needs FiveMesh to refresh public CDN files after an overwrite or external change. The paths are relative to your CDN workspace and must be allowed by the API key.
cdn:purge for this export.
Inspect the key
Usewhoami to check the configured key’s permissions and server binding without exposing its secret.