From 7fd528f36678e3073c5c5a8298d26a45cffd35d8 Mon Sep 17 00:00:00 2001 From: "promptless[bot]" Date: Tue, 1 Dec 2026 09:30:27 +0000 Subject: [PATCH] SK-3326: Document blocked file types, default multi-file size cap, and upload success entries in skyvault README --- skyvault/README.md | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/skyvault/README.md b/skyvault/README.md index 481c82c3..32c0c0db 100644 --- a/skyvault/README.md +++ b/skyvault/README.md @@ -2275,7 +2275,7 @@ Skyflow.CollectElementInput( | Value | Meaning | | --- | --- | | `FILE_INPUT` | A single file. The per-file size cap is fixed at 32 MB by the server. | -| `MULTI_FILE_INPUT` | Multiple files, up to `maxFileCount` (default 4), each up to `maxFileSize`. | +| `MULTI_FILE_INPUT` | Multiple files, up to `maxFileCount` (default 4), each up to `maxFileSize` (default 32 MB). | **Layout.** There is one native layout — a trigger button that opens the picker, the selected files listed below with a per-file remove (✕), and an error line. A single element replaces its one file; a multi element appends up to its max. Style the trigger with `inputStyles`, the label with `labelStyles` and the error line with `errorTextStyles`, as on a text field. Apps that want their own trigger call `openPicker()` (see Step 3). @@ -2306,7 +2306,7 @@ Skyflow.CollectElementOptions( blockEmptyFiles: Boolean, // reject a 0-byte file (default false) preserveFileName: Boolean, // true (default) keeps the original name (rejected if it has characters outside A-Za-z0-9 ! - _ . * ( )); false sends a generated UUID name (keeps PII in the name out of the vault) returnFileMetadata: Boolean, // ask the server to return fileName / fileSize / fileType on success (default false) - maxFileSize: Long, // per-file byte cap — MULTI_FILE_INPUT only (single is fixed at 32 MB) + maxFileSize: Long, // per-file byte cap — MULTI_FILE_INPUT only (default 32 MB; single is fixed at 32 MB) maxFileCount: Int, // max files for one MULTI_FILE_INPUT upload (default 4) stripImageMetadata: Boolean, // remove GPS/EXIF metadata from JPEG photos before upload (default false) sources: Array // which pickers to offer (default [FILES, PHOTOS]) @@ -2317,6 +2317,8 @@ With `preserveFileName = true` (the default) the original name is uploaded, so i `allowedFileType` accepts file extensions (`".pdf"`), exact MIME types (`"application/pdf"`) and MIME wildcards (`"image/*"`), matched case-insensitively. Extension entries match the file's extension; MIME and wildcard entries match its resolved content type. +The SDK always rejects `.zip`, `.exe`, `.rar`, `.deb`, and `.apk` files, even when `allowedFileType` lists them or is `null`. + With `stripImageMetadata = true`, JPEGs (matched by extension **or** `image/jpeg` MIME type) have their GPS, destination-coordinate, timestamp and camera make/model EXIF removed before upload. This is **fail-closed**: if a JPEG is selected but its metadata can't be removed, that file fails rather than uploading with its location intact. Non-JPEG files are unaffected and upload normally. **`sources` — `Skyflow.FileSource`** @@ -2414,6 +2416,16 @@ The response keeps the **input order** of the files. Outcomes: | Every file failed | `onFailure` | `{ "errorResponse": [ ... ] }` | | Some succeeded, some failed | `onFailure` | `{ "fileUploadResponse": [ ... ], "errorResponse": [ ... ] }` | +Each success entry carries the `skyflow_id` of the record the file was uploaded to. With `returnFileMetadata = true`, it also carries the `fileMetadata` object the server returns: + +```json +{ + "fileUploadResponse": [ + { "skyflow_id": "", "fileMetadata": { ... } } + ] +} +``` + Each error entry carries its `fileName`, `code` and `description`. ### End to end example of collecting files with Skyflow Elements