mirror of
https://github.com/unshackle-dl/unshackle.git
synced 2026-05-16 21:59:26 +00:00
docs(api): update --export from string path to boolean flag
Update API docs, Swagger schema, handlers, and example config to reflect --export as a boolean flag that auto-generates export files in the configurable exports directory.
This commit is contained in:
@@ -247,10 +247,10 @@ Start a download job. Returns immediately with a job ID (HTTP 202).
|
||||
| `no_proxy` | boolean | `false` | Disable all proxy use |
|
||||
| `workers` | int | `null` | Max threads per track download |
|
||||
| `downloads` | int | `1` | Concurrent track downloads |
|
||||
| `slow` | boolean | `false` | Add 60-120s delay between titles |
|
||||
| `slow` | string | `null` | Add delay between titles. `true` for 60-120s, or `MIN-MAX` (e.g. `20-40`) |
|
||||
| `best_available` | boolean | `false` | Continue if requested quality unavailable |
|
||||
| `skip_dl` | boolean | `false` | Skip download, only get decryption keys |
|
||||
| `export` | string | `null` | Export keys to JSON file path |
|
||||
| `export` | boolean | `false` | Export manifest, track URLs, keys, and subtitles to JSON in the exports directory |
|
||||
| `cdm_only` | boolean | `null` | Only use CDM (`true`) or only vaults (`false`) |
|
||||
| `no_cache` | boolean | `false` | Bypass title cache |
|
||||
| `reset_cache` | boolean | `false` | Clear title cache before fetching |
|
||||
|
||||
@@ -141,8 +141,8 @@ def _perform_download(
|
||||
sub_map.update({c.value.upper(): c for c in Subtitle.Codec})
|
||||
params["sub_format"] = sub_map.get(sub_format_raw.upper())
|
||||
|
||||
if params.get("export") and isinstance(params["export"], str):
|
||||
params["export"] = Path(params["export"])
|
||||
if params.get("export"):
|
||||
params["export"] = bool(params["export"])
|
||||
|
||||
# Load service configuration
|
||||
service_config_path = Services.get_path(service) / config.filenames.config
|
||||
|
||||
@@ -48,7 +48,7 @@ DEFAULT_DOWNLOAD_PARAMS = {
|
||||
"slow": None,
|
||||
"split_audio": None,
|
||||
"skip_dl": False,
|
||||
"export": None,
|
||||
"export": False,
|
||||
"cdm_only": None,
|
||||
"no_proxy": False,
|
||||
"no_folder": False,
|
||||
|
||||
@@ -639,8 +639,8 @@ async def download(request: web.Request) -> web.Response:
|
||||
type: boolean
|
||||
description: Skip downloading, only retrieve decryption keys (default - false)
|
||||
export:
|
||||
type: string
|
||||
description: Path to export decryption keys as JSON (default - None)
|
||||
type: boolean
|
||||
description: Export manifest, track URLs, keys, and subtitles to JSON in the exports directory (default - false)
|
||||
cdm_only:
|
||||
type: boolean
|
||||
description: Only use CDM for key retrieval (true) or only vaults (false) (default - None)
|
||||
|
||||
@@ -163,6 +163,7 @@ directories:
|
||||
temp: Temp
|
||||
wvds: WVDs
|
||||
prds: PRDs
|
||||
exports: Exports # JSON export output from --export flag
|
||||
# Additional directories that can be configured:
|
||||
# commands: Commands
|
||||
services:
|
||||
|
||||
Reference in New Issue
Block a user