This commit is contained in:
Luxferre
2025-12-25 15:59:31 +02:00
parent 4fdd29cb55
commit c57cdc4fdb
+1 -1
View File
@@ -158,7 +158,7 @@ Exports the following functions:
- `http_set_ua(ua_str='Mozilla/5.0')`: set a default HTTP user agent string
- `http_fetch(url, useragent=None, hdrs={})`: fetch text content from a URL into a string (returns `(status_code, content)` tuple)
- `auth_header(username, password)`: get an dictionary fragment with the corresponding HTTP Basic Auth header according to the username and password
- `auth_header(username, password)`: get a dictionary fragment with the corresponding HTTP Basic Auth header according to the username and password
- `wget(url, filename='', useragent=None, hdrs={})`: download a file into a local path (returns `(status_code, filename)` tuple)
- `wput(url, file_path, field_name="file", method="POST", format="x-www-form-urlencoded", headers={}, useragent=None)`: upload a file from a local path in the `x-www-form-urlencoded` or JSON format (returns `(status_code, content)` tuple)