diff --git a/docs/API.md b/docs/API.md index f652fed..e6cbb29 100644 --- a/docs/API.md +++ b/docs/API.md @@ -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 | diff --git a/unshackle/core/api/download_manager.py b/unshackle/core/api/download_manager.py index 87e445c..3c4b29b 100644 --- a/unshackle/core/api/download_manager.py +++ b/unshackle/core/api/download_manager.py @@ -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 diff --git a/unshackle/core/api/handlers.py b/unshackle/core/api/handlers.py index b32768d..f987e7b 100644 --- a/unshackle/core/api/handlers.py +++ b/unshackle/core/api/handlers.py @@ -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, diff --git a/unshackle/core/api/routes.py b/unshackle/core/api/routes.py index 16b422d..d466b40 100644 --- a/unshackle/core/api/routes.py +++ b/unshackle/core/api/routes.py @@ -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) diff --git a/unshackle/unshackle-example.yaml b/unshackle/unshackle-example.yaml index f2d5465..63b4352 100644 --- a/unshackle/unshackle-example.yaml +++ b/unshackle/unshackle-example.yaml @@ -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: