playwright_upload_file
Upload files to web pages by specifying the CSS selector of the input element and the file’s absolute path using browser automation with Playwright.
Instructions
Upload a file to an input[type='file'] element on the page
Input Schema
Name | Required | Description | Default |
---|---|---|---|
filePath | Yes | Absolute path to the file to upload | |
selector | Yes | CSS selector for the file input element |
Input Schema (JSON Schema)
{
"properties": {
"filePath": {
"description": "Absolute path to the file to upload",
"type": "string"
},
"selector": {
"description": "CSS selector for the file input element",
"type": "string"
}
},
"required": [
"selector",
"filePath"
],
"type": "object"
}