ftp_upload
Ftp Upload
Upload a local file to an FTP server. Supports authenticated FTP, FTPS (FTP over SSL/TLS), proxy configuration, and Tor anonymization. Specify the FTP destination URL and local file path.
Usage Example
123456789101112
import asyncio
from owl_browser import OwlBrowser, RemoteConfig
# Async usage
async with OwlBrowser(config) as browser:
context = await browser.create_context()
context_id = context["context_id"]
await browser.ftp_upload(
url="https://example.com",
file_path="value"
)
Parameters
Required
urlstringrequiredFTP URL where the file should be uploaded (e.g., 'ftp://ftp.example.com/uploads/file.txt').
file_pathstringrequiredLocal path of the file to upload.
Optional
usernamestringFTP username. Default: anonymous
passwordstringFTP password. Default: empty
proxy_typeenumhttphttpssocks4socks5+1 moreType of proxy server.
proxy_hoststringProxy server hostname or IP address.
proxy_portstringProxy server port number.
proxy_usernamestringUsername for proxy authentication.
proxy_passwordstringPassword for proxy authentication.
use_torbooleanUse built-in Tor proxy. Default: false
timeoutstringTimeout in milliseconds. Default: 30000
use_sslbooleanUse FTPS (FTP over SSL/TLS). Default: false
Response
Returns a JSON object with the operation result.
{
"success": true,
"result": <value>
}