safari_upload_file
Upload a file to a file input element using JavaScript DataTransfer, bypassing the file dialog. Provide a CSS selector and file path; the tool handles the rest.
Instructions
Upload a file to a element via JavaScript DataTransfer — NO file dialog, NO UI interaction. IMPORTANT: Do NOT click the file input before calling this tool — just provide the selector and file path. If a file dialog is already open, this tool will close it first. NOTE: 'verified 0 files' may appear even on success if the site uses a custom upload handler — check visually with safari_snapshot.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| filePath | Yes | Absolute path to the file to upload | |
| selector | Yes | CSS selector of the file input |