6491 lines
349 KiB
Plaintext
6491 lines
349 KiB
Plaintext
[
|
|
ApiGroup {
|
|
name: "authentication",
|
|
methods: [
|
|
ApiMethod {
|
|
name: "login",
|
|
description: Some(
|
|
"Upon success, the response will contain a cookie with your SID. You must supply the cookie whenever you want to perform an operation that requires authentication.\n\nExample showing how to login and execute a command that requires authentication using `curl`:\n\n```sh\n$ curl -i --header 'Referer: http://localhost:8080' --data 'username=admin&password=adminadmin' http://localhost:8080/api/v2/auth/login\nHTTP/1.1 200 OK\nContent-Encoding:\nContent-Length: 3\nContent-Type: text/plain; charset=UTF-8\nSet-Cookie: SID=hBc7TxF76ERhvIw0jQQ4LZ7Z1jQUV0tQ; path=/\n$ curl http://localhost:8080/api/v2/torrents/info --cookie \"SID=hBc7TxF76ERhvIw0jQQ4LZ7Z1jQUV0tQ\"\n```\n\nNote: Set `Referer` or `Origin` header to the exact same domain and port as used in the HTTP query `Host` header.",
|
|
),
|
|
url: "login",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "username",
|
|
description: Some(
|
|
"Username used to access the WebUI",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "password",
|
|
description: Some(
|
|
"Password used to access the WebUI",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "logout",
|
|
description: None,
|
|
url: "logout",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
],
|
|
description: Some(
|
|
"All Authentication API methods are under \"auth\", e.g.: `/api/v2/auth/methodName`.\n\nqBittorrent uses cookie-based authentication.",
|
|
),
|
|
url: "auth",
|
|
},
|
|
ApiGroup {
|
|
name: "application",
|
|
methods: [
|
|
ApiMethod {
|
|
name: "version",
|
|
description: Some(
|
|
"The response is a string with the application version, e.g. `v4.1.3`",
|
|
),
|
|
url: "version",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "webapiVersion",
|
|
description: Some(
|
|
"The response is a string with the WebAPI version, e.g. `2.0`",
|
|
),
|
|
url: "webapiVersion",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "buildInfo",
|
|
description: Some(
|
|
"The response is a JSON object containing the following fields",
|
|
),
|
|
url: "buildInfo",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "qt",
|
|
description: Some(
|
|
"QT version",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "libtorrent",
|
|
description: Some(
|
|
"libtorrent version",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "boost",
|
|
description: Some(
|
|
"Boost version",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "openssl",
|
|
description: Some(
|
|
"OpenSSL version",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "bitness",
|
|
description: Some(
|
|
"Application bitness (e.g. 64-bit)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "shutdown",
|
|
description: None,
|
|
url: "shutdown",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "preferences",
|
|
description: Some(
|
|
"The response is a JSON object with several fields (key-value) pairs representing the application's settings. The contents may vary depending on which settings are present in qBittorrent.ini.\n\n\nPossible values of `scan_dirs`:\n\n\nPossible values of `scheduler_days`:\n\n\nPossible values of `encryption`:\n\n\nNB: the first options allows you to use both encrypted and unencrypted connections (this is the default); other options are mutually exclusive: e.g. by forcing encryption on you won't be able to use unencrypted connections and vice versa.\n\nPossible values of `proxy_type`:\n\n\nPossible values of `dyndns_service`:\n\n\nPossible values of `max_ratio_act`:\n\n\nPossible values of `bittorrent_protocol`:\n\n\nPossible values of `upload_choking_algorithm`:\n\n\nPossible values of `upload_slots_behavior`:\n\n\nPossible values of `utp_tcp_mixed_mode`:\n\n\nExample:\n\n```JSON\n{\n \"add_trackers\": \"\",\n \"add_trackers_enabled\": false,\n \"alt_dl_limit\": 10240,\n \"alt_up_limit\": 10240,\n \"alternative_webui_enabled\": false,\n \"alternative_webui_path\": \"/home/user/Documents/qbit-webui\",\n \"announce_ip\": \"\",\n \"announce_to_all_tiers\": true,\n \"announce_to_all_trackers\": false,\n \"anonymous_mode\": false,\n \"async_io_threads\": 4,\n \"auto_delete_mode\": 0,\n \"auto_tmm_enabled\": false,\n \"autorun_enabled\": false,\n \"autorun_program\": \"\",\n \"banned_IPs\": \"\",\n \"bittorrent_protocol\": 0,\n \"bypass_auth_subnet_whitelist\": \"\",\n \"bypass_auth_subnet_whitelist_enabled\": false,\n \"bypass_local_auth\": false,\n \"category_changed_tmm_enabled\": false,\n \"checking_memory_use\": 32,\n \"create_subfolder_enabled\": true,\n \"current_interface_address\": \"\",\n \"current_network_interface\": \"\",\n \"dht\": true,\n \"disk_cache\": -1,\n \"disk_cache_ttl\": 60,\n \"dl_limit\": 0,\n \"dont_count_slow_torrents\": false,\n \"dyndns_domain\": \"changeme.dyndns.org\",\n \"dyndns_enabled\": false,\n \"dyndns_password\": \"\",\n \"dyndns_service\": 0,\n \"dyndns_username\": \"\",\n \"embedded_tracker_port\": 9000,\n \"enable_coalesce_read_write\": false,\n \"enable_embedded_tracker\": false,\n \"enable_multi_connections_from_same_ip\": false,\n \"enable_os_cache\": true,\n \"enable_piece_extent_affinity\": false,\n \"enable_upload_suggestions\": false,\n \"encryption\": 0,\n \"export_dir\": \"/home/user/Downloads/all\",\n \"export_dir_fin\": \"/home/user/Downloads/completed\",\n \"file_pool_size\": 40,\n \"incomplete_files_ext\": false,\n \"ip_filter_enabled\": false,\n \"ip_filter_path\": \"\",\n \"ip_filter_trackers\": false,\n \"limit_lan_peers\": true,\n \"limit_tcp_overhead\": false,\n \"limit_utp_rate\": true,\n \"listen_port\": 58925,\n \"locale\": \"en\",\n \"lsd\": true,\n \"mail_notification_auth_enabled\": false,\n \"mail_notification_email\": \"\",\n \"mail_notification_enabled\": false,\n \"mail_notification_password\": \"\",\n \"mail_notification_sender\": \"qBittorrent_notification@example.com\",\n \"mail_notification_smtp\": \"smtp.changeme.com\",\n \"mail_notification_ssl_enabled\": false,\n \"mail_notification_username\": \"\",\n \"max_active_downloads\": 3,\n \"max_active_torrents\": 5,\n \"max_active_uploads\": 3,\n \"max_connec\": 500,\n \"max_connec_per_torrent\": 100,\n \"max_ratio\": -1,\n \"max_ratio_act\": 0,\n \"max_ratio_enabled\": false,\n \"max_seeding_time\": -1,\n \"max_seeding_time_enabled\": false,\n \"max_uploads\": -1,\n \"max_uploads_per_torrent\": -1,\n \"outgoing_ports_max\": 0,\n \"outgoing_ports_min\": 0,\n \"pex\": true,\n \"preallocate_all\": false,\n \"proxy_auth_enabled\": false,\n \"proxy_ip\": \"0.0.0.0\",\n \"proxy_password\": \"\",\n \"proxy_peer_connections\": false,\n \"proxy_port\": 8080,\n \"proxy_torrents_only\": false,\n \"proxy_type\": 0,\n \"proxy_username\": \"\",\n \"queueing_enabled\": false,\n \"random_port\": false,\n \"recheck_completed_torrents\": false,\n \"resolve_peer_countries\": true,\n \"rss_auto_downloading_enabled\":true,\n \"rss_download_repack_proper_episodes\":true,\n \"rss_max_articles_per_feed\":50,\n \"rss_processing_enabled\":true,\n \"rss_refresh_interval\":30,\n \"rss_smart_episode_filters\":\"s(\\\\d+)e(\\\\d+)\\n(\\\\d+)x(\\\\d+)\\n(\\\\d{4}[.\\\\-]\\\\d{1,2}[.\\\\-]\\\\d{1,2})\",\n \"save_path\": \"/home/user/Downloads/\",\n \"save_path_changed_tmm_enabled\": false,\n \"save_resume_data_interval\": 60,\n \"scan_dirs\":\n {\n \"/home/user/Downloads/incoming/games\": 0,\n \"/home/user/Downloads/incoming/movies\": 1,\n },\n \"schedule_from_hour\": 8,\n \"schedule_from_min\": 0,\n \"schedule_to_hour\": 20,\n \"schedule_to_min\": 0,\n \"scheduler_days\": 0,\n \"scheduler_enabled\": false,\n \"send_buffer_low_watermark\": 10,\n \"send_buffer_watermark\": 500,\n \"send_buffer_watermark_factor\": 50,\n \"slow_torrent_dl_rate_threshold\": 2,\n \"slow_torrent_inactive_timer\": 60,\n \"slow_torrent_ul_rate_threshold\": 2,\n \"socket_backlog_size\": 30,\n \"start_paused_enabled\": false,\n \"stop_tracker_timeout\": 1,\n \"temp_path\": \"/home/user/Downloads/temp\",\n \"temp_path_enabled\": false,\n \"torrent_changed_tmm_enabled\": true,\n \"up_limit\": 0,\n \"upload_choking_algorithm\": 1,\n \"upload_slots_behavior\": 0,\n \"upnp\": true,\n \"use_https\": false,\n \"utp_tcp_mixed_mode\": 0,\n \"web_ui_address\": \"*\",\n \"web_ui_ban_duration\": 3600,\n \"web_ui_clickjacking_protection_enabled\": true,\n \"web_ui_csrf_protection_enabled\": true,\n \"web_ui_custom_http_headers\": \"\",\n \"web_ui_domain_list\": \"*\",\n \"web_ui_host_header_validation_enabled\": true,\n \"web_ui_https_cert_path\": \"\",\n \"web_ui_https_key_path\": \"\",\n \"web_ui_max_auth_fail_count\": 5,\n \"web_ui_port\": 8080,\n \"web_ui_secure_cookie_enabled\": true,\n \"web_ui_session_timeout\": 3600,\n \"web_ui_upnp\": false,\n \"web_ui_use_custom_http_headers_enabled\": false,\n \"web_ui_username\": \"admin\"\n}\n```",
|
|
),
|
|
url: "preferences",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Enum(
|
|
Enum {
|
|
name: "BittorrentProtocol",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"TCP and μTP",
|
|
),
|
|
value: "TCPAndμTP",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"TCP",
|
|
),
|
|
value: "TCP",
|
|
original_value: "1",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"μTP",
|
|
),
|
|
value: "μTP",
|
|
original_value: "2",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "DyndnsService",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Use DyDNS",
|
|
),
|
|
value: "UseDyDNS",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Use NOIP",
|
|
),
|
|
value: "UseNOIP",
|
|
original_value: "1",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "Encryption",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Prefer encryption",
|
|
),
|
|
value: "PreferEncryption",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Force encryption on",
|
|
),
|
|
value: "ForceEncryptionOn",
|
|
original_value: "1",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Force encryption off",
|
|
),
|
|
value: "ForceEncryptionOff",
|
|
original_value: "2",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "MaxRatioAct",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Pause torrent",
|
|
),
|
|
value: "PauseTorrent",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Remove torrent",
|
|
),
|
|
value: "RemoveTorrent",
|
|
original_value: "1",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "ProxyType",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Proxy is disabled",
|
|
),
|
|
value: "ProxyIsDisabled",
|
|
original_value: "-1",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"HTTP proxy without authentication",
|
|
),
|
|
value: "HTTPProxyWithoutAuthentication",
|
|
original_value: "1",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"SOCKS5 proxy without authentication",
|
|
),
|
|
value: "SOCKS5ProxyWithoutAuthentication",
|
|
original_value: "2",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"HTTP proxy with authentication",
|
|
),
|
|
value: "HTTPProxyWithAuthentication",
|
|
original_value: "3",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"SOCKS5 proxy with authentication",
|
|
),
|
|
value: "SOCKS5ProxyWithAuthentication",
|
|
original_value: "4",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"SOCKS4 proxy without authentication",
|
|
),
|
|
value: "SOCKS4ProxyWithoutAuthentication",
|
|
original_value: "5",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "ScanDirs",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Download to the monitored folder",
|
|
),
|
|
value: "DownloadToTheMonitoredFolder",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Download to the default save path",
|
|
),
|
|
value: "DownloadToTheDefaultSavePath",
|
|
original_value: "1",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Download to this path",
|
|
),
|
|
value: "\"/path/to/download/to\"",
|
|
original_value: "\"/path/to/download/to\"",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "SchedulerDays",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Every day",
|
|
),
|
|
value: "EveryDay",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Every weekday",
|
|
),
|
|
value: "EveryWeekday",
|
|
original_value: "1",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Every weekend",
|
|
),
|
|
value: "EveryWeekend",
|
|
original_value: "2",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Every Monday",
|
|
),
|
|
value: "EveryMonday",
|
|
original_value: "3",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Every Tuesday",
|
|
),
|
|
value: "EveryTuesday",
|
|
original_value: "4",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Every Wednesday",
|
|
),
|
|
value: "EveryWednesday",
|
|
original_value: "5",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Every Thursday",
|
|
),
|
|
value: "EveryThursday",
|
|
original_value: "6",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Every Friday",
|
|
),
|
|
value: "EveryFriday",
|
|
original_value: "7",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Every Saturday",
|
|
),
|
|
value: "EverySaturday",
|
|
original_value: "8",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Every Sunday",
|
|
),
|
|
value: "EverySunday",
|
|
original_value: "9",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "UploadChokingAlgorithm",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Round-robin",
|
|
),
|
|
value: "RoundRobin",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Fastest upload",
|
|
),
|
|
value: "FastestUpload",
|
|
original_value: "1",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Anti-leech",
|
|
),
|
|
value: "AntiLeech",
|
|
original_value: "2",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "UploadSlotsBehavior",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Fixed slots",
|
|
),
|
|
value: "FixedSlots",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Upload rate based",
|
|
),
|
|
value: "UploadRateBased",
|
|
original_value: "1",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "UtpTcpMixedMode",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Prefer TCP",
|
|
),
|
|
value: "PreferTCP",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Peer proportional",
|
|
),
|
|
value: "PeerProportional",
|
|
original_value: "1",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "locale",
|
|
description: Some(
|
|
"Currently selected language (e.g. en_GB for English)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "create_subfolder_enabled",
|
|
description: Some(
|
|
"True if a subfolder should be created when adding a torrent",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "start_paused_enabled",
|
|
description: Some(
|
|
"True if torrents should be added in a Paused state",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "auto_delete_mode",
|
|
description: Some(
|
|
"TODO",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "preallocate_all",
|
|
description: Some(
|
|
"True if disk space should be pre-allocated for all files",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "incomplete_files_ext",
|
|
description: Some(
|
|
"True if \".!qB\" should be appended to incomplete files",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "auto_tmm_enabled",
|
|
description: Some(
|
|
"True if Automatic Torrent Management is enabled by default",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "torrent_changed_tmm_enabled",
|
|
description: Some(
|
|
"True if torrent should be relocated when its Category changes",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "save_path_changed_tmm_enabled",
|
|
description: Some(
|
|
"True if torrent should be relocated when the default save path changes",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "category_changed_tmm_enabled",
|
|
description: Some(
|
|
"True if torrent should be relocated when its Category's save path changes",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "save_path",
|
|
description: Some(
|
|
"Default save path for torrents, separated by slashes",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "temp_path_enabled",
|
|
description: Some(
|
|
"True if folder for incomplete torrents is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "temp_path",
|
|
description: Some(
|
|
"Path for incomplete torrents, separated by slashes",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "scan_dirs",
|
|
description: Some(
|
|
"scan_dirs object see table below. Property: directory to watch for torrent files, value: where torrents loaded from this directory should be downloaded to (see list of possible values below). Slashes are used as path separators; multiple key/value pairs can be specified",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
ref_type: String(
|
|
"ScanDirs",
|
|
),
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "export_dir",
|
|
description: Some(
|
|
"Path to directory to copy .torrent files to. Slashes are used as path separators",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "export_dir_fin",
|
|
description: Some(
|
|
"Path to directory to copy .torrent files of completed downloads to. Slashes are used as path separators",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "mail_notification_enabled",
|
|
description: Some(
|
|
"True if e-mail notification should be enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "mail_notification_sender",
|
|
description: Some(
|
|
"e-mail where notifications should originate from",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "mail_notification_email",
|
|
description: Some(
|
|
"e-mail to send notifications to",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "mail_notification_smtp",
|
|
description: Some(
|
|
"smtp server for e-mail notifications",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "mail_notification_ssl_enabled",
|
|
description: Some(
|
|
"True if smtp server requires SSL connection",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "mail_notification_auth_enabled",
|
|
description: Some(
|
|
"True if smtp server requires authentication",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "mail_notification_username",
|
|
description: Some(
|
|
"Username for smtp authentication",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "mail_notification_password",
|
|
description: Some(
|
|
"Password for smtp authentication",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "autorun_enabled",
|
|
description: Some(
|
|
"True if external program should be run after torrent has finished downloading",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "autorun_program",
|
|
description: Some(
|
|
"Program path/name/arguments to run if autorun_enabled is enabled; path is separated by slashes; you can use %f and %n arguments, which will be expanded by qBittorent as path_to_torrent_file and torrent_name (from the GUI; not the .torrent file name) respectively",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "queueing_enabled",
|
|
description: Some(
|
|
"True if torrent queuing is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "max_active_downloads",
|
|
description: Some(
|
|
"Maximum number of active simultaneous downloads",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "max_active_torrents",
|
|
description: Some(
|
|
"Maximum number of active simultaneous downloads and uploads",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "max_active_uploads",
|
|
description: Some(
|
|
"Maximum number of active simultaneous uploads",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "dont_count_slow_torrents",
|
|
description: Some(
|
|
"If true torrents w/o any activity (stalled ones) will not be counted towards max_active_* limits; see [dont_count_slow_torrents](https://www.libtorrent.org/reference-Settings.html#dont_count_slow_torrents) for more information",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "slow_torrent_dl_rate_threshold",
|
|
description: Some(
|
|
"Download rate in KiB/s for a torrent to be considered \"slow\"",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "slow_torrent_ul_rate_threshold",
|
|
description: Some(
|
|
"Upload rate in KiB/s for a torrent to be considered \"slow\"",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "slow_torrent_inactive_timer",
|
|
description: Some(
|
|
"Seconds a torrent should be inactive before considered \"slow\"",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "max_ratio_enabled",
|
|
description: Some(
|
|
"True if share ratio limit is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "max_ratio",
|
|
description: Some(
|
|
"Get the global share ratio limit",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "max_ratio_act",
|
|
description: Some(
|
|
"max_ratio_act object see table below. Action performed when a torrent reaches the maximum share ratio. See list of possible values here below.",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
ref_type: String(
|
|
"MaxRatioAct",
|
|
),
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "listen_port",
|
|
description: Some(
|
|
"Port for incoming connections",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "upnp",
|
|
description: Some(
|
|
"True if UPnP/NAT-PMP is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "random_port",
|
|
description: Some(
|
|
"True if the port is randomly selected",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dl_limit",
|
|
description: Some(
|
|
"Global download speed limit in KiB/s; -1 means no limit is applied",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "up_limit",
|
|
description: Some(
|
|
"Global upload speed limit in KiB/s; -1 means no limit is applied",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "max_connec",
|
|
description: Some(
|
|
"Maximum global number of simultaneous connections",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "max_connec_per_torrent",
|
|
description: Some(
|
|
"Maximum number of simultaneous connections per torrent",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "max_uploads",
|
|
description: Some(
|
|
"Maximum number of upload slots",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "max_uploads_per_torrent",
|
|
description: Some(
|
|
"Maximum number of upload slots per torrent",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "stop_tracker_timeout",
|
|
description: Some(
|
|
"Timeout in seconds for a stopped announce request to trackers",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "enable_piece_extent_affinity",
|
|
description: Some(
|
|
"True if the advanced libtorrent option piece_extent_affinity is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "bittorrent_protocol",
|
|
description: Some(
|
|
"bittorrent_protocol object see table below Bittorrent Protocol to use (see list of possible values below)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
ref_type: String(
|
|
"BittorrentProtocol",
|
|
),
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "limit_utp_rate",
|
|
description: Some(
|
|
"True if [du]l_limit should be applied to uTP connections; this option is only available in qBittorent built against libtorrent version 0.16.X and higher",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "limit_tcp_overhead",
|
|
description: Some(
|
|
"True if [du]l_limit should be applied to estimated TCP overhead (service data: e.g. packet headers)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "limit_lan_peers",
|
|
description: Some(
|
|
"True if [du]l_limit should be applied to peers on the LAN",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "alt_dl_limit",
|
|
description: Some(
|
|
"Alternative global download speed limit in KiB/s",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "alt_up_limit",
|
|
description: Some(
|
|
"Alternative global upload speed limit in KiB/s",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "scheduler_enabled",
|
|
description: Some(
|
|
"True if alternative limits should be applied according to schedule",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "schedule_from_hour",
|
|
description: Some(
|
|
"Scheduler starting hour",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "schedule_from_min",
|
|
description: Some(
|
|
"Scheduler starting minute",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "schedule_to_hour",
|
|
description: Some(
|
|
"Scheduler ending hour",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "schedule_to_min",
|
|
description: Some(
|
|
"Scheduler ending minute",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "scheduler_days",
|
|
description: Some(
|
|
"scheduler_days object see table below. See possible values here below",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
ref_type: String(
|
|
"SchedulerDays",
|
|
),
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "dht",
|
|
description: Some(
|
|
"True if DHT is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "pex",
|
|
description: Some(
|
|
"True if PeX is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "lsd",
|
|
description: Some(
|
|
"True if LSD is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "encryption",
|
|
description: Some(
|
|
"encryption object see table below. See list of possible values here below",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
ref_type: String(
|
|
"Encryption",
|
|
),
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "anonymous_mode",
|
|
description: Some(
|
|
"If true anonymous mode will be enabled; read more [here](Anonymous-Mode); this option is only available in qBittorent built against libtorrent version 0.16.X and higher",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "proxy_type",
|
|
description: Some(
|
|
"proxy_type object see table below. See list of possible values here below",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "proxy_ip",
|
|
description: Some(
|
|
"Proxy IP address or domain name",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "proxy_port",
|
|
description: Some(
|
|
"Proxy port",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "proxy_peer_connections",
|
|
description: Some(
|
|
"True if peer and web seed connections should be proxified; this option will have any effect only in qBittorent built against libtorrent version 0.16.X and higher",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "proxy_auth_enabled",
|
|
description: Some(
|
|
"True proxy requires authentication; doesn't apply to SOCKS4 proxies",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "proxy_username",
|
|
description: Some(
|
|
"Username for proxy authentication",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "proxy_password",
|
|
description: Some(
|
|
"Password for proxy authentication",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "proxy_torrents_only",
|
|
description: Some(
|
|
"True if proxy is only used for torrents",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "ip_filter_enabled",
|
|
description: Some(
|
|
"True if external IP filter should be enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "ip_filter_path",
|
|
description: Some(
|
|
"Path to IP filter file (.dat, .p2p, .p2b files are supported); path is separated by slashes",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "ip_filter_trackers",
|
|
description: Some(
|
|
"True if IP filters are applied to trackers",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "web_ui_domain_list",
|
|
description: Some(
|
|
"Comma-separated list of domains to accept when performing Host header validation",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "web_ui_address",
|
|
description: Some(
|
|
"IP address to use for the WebUI",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "web_ui_port",
|
|
description: Some(
|
|
"WebUI port",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "web_ui_upnp",
|
|
description: Some(
|
|
"True if UPnP is used for the WebUI port",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "web_ui_username",
|
|
description: Some(
|
|
"WebUI username",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "web_ui_password",
|
|
description: Some(
|
|
"For API ≥ v2.3.0: Plaintext WebUI password, not readable, write-only. For API < v2.3.0: MD5 hash of WebUI password, hash is generated from the following string: username:Web UI Access:plain_text_web_ui_password",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "web_ui_csrf_protection_enabled",
|
|
description: Some(
|
|
"True if WebUI CSRF protection is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "web_ui_clickjacking_protection_enabled",
|
|
description: Some(
|
|
"True if WebUI clickjacking protection is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "web_ui_secure_cookie_enabled",
|
|
description: Some(
|
|
"True if WebUI cookie Secure flag is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "web_ui_max_auth_fail_count",
|
|
description: Some(
|
|
"Maximum number of authentication failures before WebUI access ban",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "web_ui_ban_duration",
|
|
description: Some(
|
|
"WebUI access ban duration in seconds",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "web_ui_session_timeout",
|
|
description: Some(
|
|
"Seconds until WebUI is automatically signed off",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "web_ui_host_header_validation_enabled",
|
|
description: Some(
|
|
"True if WebUI host header validation is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "bypass_local_auth",
|
|
description: Some(
|
|
"True if authentication challenge for loopback address (127.0.0.1) should be disabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "bypass_auth_subnet_whitelist_enabled",
|
|
description: Some(
|
|
"True if webui authentication should be bypassed for clients whose ip resides within (at least) one of the subnets on the whitelist",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "bypass_auth_subnet_whitelist",
|
|
description: Some(
|
|
"(White)list of ipv4/ipv6 subnets for which webui authentication should be bypassed; list entries are separated by commas",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "alternative_webui_enabled",
|
|
description: Some(
|
|
"True if an alternative WebUI should be used",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "alternative_webui_path",
|
|
description: Some(
|
|
"File path to the alternative WebUI",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "use_https",
|
|
description: Some(
|
|
"True if WebUI HTTPS access is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "ssl_key",
|
|
description: Some(
|
|
"For API < v2.0.1: SSL keyfile contents (this is a not a path)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "ssl_cert",
|
|
description: Some(
|
|
"For API < v2.0.1: SSL certificate contents (this is a not a path)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "web_ui_https_key_path",
|
|
description: Some(
|
|
"For API ≥ v2.0.1: Path to SSL keyfile",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "web_ui_https_cert_path",
|
|
description: Some(
|
|
"For API ≥ v2.0.1: Path to SSL certificate",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "dyndns_enabled",
|
|
description: Some(
|
|
"True if server DNS should be updated dynamically",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dyndns_service",
|
|
description: Some(
|
|
"dyndns_service object see table below. See list of possible values here below",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "dyndns_username",
|
|
description: Some(
|
|
"Username for DDNS service",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "dyndns_password",
|
|
description: Some(
|
|
"Password for DDNS service",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "dyndns_domain",
|
|
description: Some(
|
|
"Your DDNS domain name",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "rss_refresh_interval",
|
|
description: Some(
|
|
"RSS refresh interval",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "rss_max_articles_per_feed",
|
|
description: Some(
|
|
"Max stored articles per RSS feed",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "rss_processing_enabled",
|
|
description: Some(
|
|
"Enable processing of RSS feeds",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "rss_auto_downloading_enabled",
|
|
description: Some(
|
|
"Enable auto-downloading of torrents from the RSS feeds",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "rss_download_repack_proper_episodes",
|
|
description: Some(
|
|
"For API ≥ v2.5.1: Enable downloading of repack/proper Episodes",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "rss_smart_episode_filters",
|
|
description: Some(
|
|
"For API ≥ v2.5.1: List of RSS Smart Episode Filters",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "add_trackers_enabled",
|
|
description: Some(
|
|
"Enable automatic adding of trackers to new torrents",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "add_trackers",
|
|
description: Some(
|
|
"List of trackers to add to new torrent",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "web_ui_use_custom_http_headers_enabled",
|
|
description: Some(
|
|
"For API ≥ v2.5.1: Enable custom http headers",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "web_ui_custom_http_headers",
|
|
description: Some(
|
|
"For API ≥ v2.5.1: List of custom http headers",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "max_seeding_time_enabled",
|
|
description: Some(
|
|
"True enables max seeding time",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "max_seeding_time",
|
|
description: Some(
|
|
"Number of minutes to seed a torrent",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "announce_ip",
|
|
description: Some(
|
|
"TODO",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "announce_to_all_tiers",
|
|
description: Some(
|
|
"True always announce to all tiers",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "announce_to_all_trackers",
|
|
description: Some(
|
|
"True always announce to all trackers in a tier",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "async_io_threads",
|
|
description: Some(
|
|
"Number of asynchronous I/O threads",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "banned_IPs",
|
|
description: Some(
|
|
"List of banned IPs",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "checking_memory_use",
|
|
description: Some(
|
|
"Outstanding memory when checking torrents in MiB",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "current_interface_address",
|
|
description: Some(
|
|
"IP Address to bind to. Empty String means All addresses",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "current_network_interface",
|
|
description: Some(
|
|
"Network Interface used",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "disk_cache",
|
|
description: Some(
|
|
"Disk cache used in MiB",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "disk_cache_ttl",
|
|
description: Some(
|
|
"Disk cache expiry interval in seconds",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "embedded_tracker_port",
|
|
description: Some(
|
|
"Port used for embedded tracker",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "enable_coalesce_read_write",
|
|
description: Some(
|
|
"True enables coalesce reads & writes",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "enable_embedded_tracker",
|
|
description: Some(
|
|
"True enables embedded tracker",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "enable_multi_connections_from_same_ip",
|
|
description: Some(
|
|
"True allows multiple connections from the same IP address",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "enable_os_cache",
|
|
description: Some(
|
|
"True enables os cache",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "enable_upload_suggestions",
|
|
description: Some(
|
|
"True enables sending of upload piece suggestions",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "file_pool_size",
|
|
description: Some(
|
|
"File pool size",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "outgoing_ports_max",
|
|
description: Some(
|
|
"Maximal outgoing port (0: Disabled)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "outgoing_ports_min",
|
|
description: Some(
|
|
"Minimal outgoing port (0: Disabled)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "recheck_completed_torrents",
|
|
description: Some(
|
|
"True rechecks torrents on completion",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "resolve_peer_countries",
|
|
description: Some(
|
|
"True resolves peer countries",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "save_resume_data_interval",
|
|
description: Some(
|
|
"Save resume data interval in min",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "send_buffer_low_watermark",
|
|
description: Some(
|
|
"Send buffer low watermark in KiB",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "send_buffer_watermark",
|
|
description: Some(
|
|
"Send buffer watermark in KiB",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "send_buffer_watermark_factor",
|
|
description: Some(
|
|
"Send buffer watermark factor in percent",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "socket_backlog_size",
|
|
description: Some(
|
|
"Socket backlog size",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "upload_choking_algorithm",
|
|
description: Some(
|
|
"upload_choking_algorithm object see table below. Upload choking algorithm used (see list of possible values below)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
ref_type: String(
|
|
"UploadChokingAlgorithm",
|
|
),
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "upload_slots_behavior",
|
|
description: Some(
|
|
"upload_slots_behavior object see table below. Upload slots behavior used (see list of possible values below)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
ref_type: String(
|
|
"UploadSlotsBehavior",
|
|
),
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "upnp_lease_duration",
|
|
description: Some(
|
|
"UPnP lease duration (0: Permanent lease)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "utp_tcp_mixed_mode",
|
|
description: Some(
|
|
"utp_tcp_mixed_mode object see table below. μTP-TCP mixed mode algorithm (see list of possible values below)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
ref_type: String(
|
|
"UtpTcpMixedMode",
|
|
),
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "setPreferences",
|
|
description: Some(
|
|
"1. There is no need to pass all possible preferences' `token:value` pairs if you only want to change one option\n 1. Paths in `scan_dirs` must exist, otherwise this option will have no effect\n 1. String values must be quoted; integer and boolean values must never be quoted\n\nFor a list of possible preference options see [Get application preferences](#get-application-preferences)",
|
|
),
|
|
url: "setPreferences",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "defaultSavePath",
|
|
description: Some(
|
|
"The response is a string with the default save path, e.g. `C:/Users/Dayman/Downloads`.",
|
|
),
|
|
url: "defaultSavePath",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
],
|
|
description: Some(
|
|
"All Application API methods are under \"app\", e.g.: `/api/v2/app/methodName`.",
|
|
),
|
|
url: "app",
|
|
},
|
|
ApiGroup {
|
|
name: "log",
|
|
methods: [
|
|
ApiMethod {
|
|
name: "main",
|
|
description: Some(
|
|
"The response is a JSON array in which each element is an entry of the log.\n\nEach element of the array has the following properties:\n\n\nExample:\n\n```JSON\n[\n {\n \"id\":0,\n \"message\":\"qBittorrent v3.4.0 started\",\n \"timestamp\":1507969127860,\n \"type\":1\n },\n {\n \"id\":1,\n \"message\":\"qBittorrent is trying to listen on any interface port: 19036\",\n \"timestamp\":1507969127869,\n \"type\":2\n },\n {\n \"id\":2,\n \"message\":\"Peer ID: -qB3400-\",\n \"timestamp\":1507969127870,\n \"type\":1\n },\n {\n \"id\":3,\n \"message\":\"HTTP User-Agent is 'qBittorrent/3.4.0'\",\n \"timestamp\":1507969127870,\n \"type\":1\n },\n {\n \"id\":4,\n \"message\":\"DHT support [ON]\",\n \"timestamp\":1507969127871,\n \"type\":2\n },\n {\n \"id\":5,\n \"message\":\"Local Peer Discovery support [ON]\",\n \"timestamp\":1507969127871,\n \"type\":2\n },\n {\n \"id\":6,\n \"message\":\"PeX support [ON]\",\n \"timestamp\":1507969127871,\n \"type\":2\n },\n {\n \"id\":7,\n \"message\":\"Anonymous mode [OFF]\",\n \"timestamp\":1507969127871,\n \"type\":2\n },\n {\n \"id\":8,\n \"message\":\"Encryption support [ON]\",\n \"timestamp\":1507969127871,\n \"type\":2\n },\n {\n \"id\":9,\n \"message\":\"Embedded Tracker [OFF]\",\n \"timestamp\":1507969127871,\n \"type\":2\n },\n {\n \"id\":10,\n \"message\":\"UPnP / NAT-PMP support [ON]\",\n \"timestamp\":1507969127873,\n \"type\":2\n },\n {\n \"id\":11,\n \"message\":\"Web UI: Now listening on port 8080\",\n \"timestamp\":1507969127883,\n \"type\":1\n },\n {\n \"id\":12,\n \"message\":\"Options were saved successfully.\",\n \"timestamp\":1507969128055,\n \"type\":1\n },\n {\n \"id\":13,\n \"message\":\"qBittorrent is successfully listening on interface :: port: TCP/19036\",\n \"timestamp\":1507969128270,\n \"type\":2\n },\n {\n \"id\":14,\n \"message\":\"qBittorrent is successfully listening on interface 0.0.0.0 port: TCP/19036\",\n \"timestamp\":1507969128271,\n \"type\":2\n },\n {\n \"id\":15,\n \"message\":\"qBittorrent is successfully listening on interface 0.0.0.0 port: UDP/19036\",\n \"timestamp\":1507969128272,\n \"type\":2\n }\n]\n```",
|
|
),
|
|
url: "main",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
Bool(
|
|
TypeInfo {
|
|
name: "normal",
|
|
description: Some(
|
|
"Include normal messages (default: true)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "info",
|
|
description: Some(
|
|
"Include info messages (default: true)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "warning",
|
|
description: Some(
|
|
"Include warning messages (default: true)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "critical",
|
|
description: Some(
|
|
"Include critical messages (default: true)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "last_known_id",
|
|
description: Some(
|
|
"Exclude messages with \"message id\" <= last_known_id (default: -1)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "peers",
|
|
description: Some(
|
|
"The response a JSON array. Each element of the array of objects (each object is the information relative to a peer) containing the following fields",
|
|
),
|
|
url: "peers",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "last_known_id",
|
|
description: Some(
|
|
"Exclude messages with \"message id\" <= last_known_id (default: -1)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
],
|
|
description: Some(
|
|
"All Log API methods are under \"log\", e.g.: `/api/v2/log/methodName`.",
|
|
),
|
|
url: "log",
|
|
},
|
|
ApiGroup {
|
|
name: "sync",
|
|
methods: [
|
|
ApiMethod {
|
|
name: "maindata",
|
|
description: Some(
|
|
"The response is a JSON object with the following possible fields\n\n\nExample:\n\n```JSON\n{\n \"rid\":15,\n \"torrents\":\n {\n \"8c212779b4abde7c6bc608063a0d008b7e40ce32\":\n {\n \"state\":\"pausedUP\"\n }\n }\n}\n```",
|
|
),
|
|
url: "maindata",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Object(
|
|
TypeWithName {
|
|
name: "Categories",
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "name",
|
|
description: Some(
|
|
"Category name",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "savePath",
|
|
description: Some(
|
|
"Save path",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
),
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "rid",
|
|
description: Some(
|
|
"Response ID. If not provided, rid=0 will be assumed. If the given rid is different from the one of last server reply, full_update will be true (see the server reply details for more info)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
TypeWithName {
|
|
name: "ServerState",
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "average_time_queue",
|
|
description: Some(
|
|
"Average time queue",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dl_info_data",
|
|
description: Some(
|
|
"Download info data",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dl_info_speed",
|
|
description: Some(
|
|
"Download info speed",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "queued_io_jobs",
|
|
description: Some(
|
|
"Queued io jobs",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "total_buffers_size",
|
|
description: Some(
|
|
"Total buffers size",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "total_peer_connections",
|
|
description: Some(
|
|
"Total peer connections",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
),
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "rid",
|
|
description: Some(
|
|
"Response ID",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "full_update",
|
|
description: Some(
|
|
"Whether the response contains all the data or partial data",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "torrents",
|
|
description: Some(
|
|
"Property: torrent hash, value: same as [torrent list](#get-torrent-list), map from string to torrents object",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
ref_type: Map(
|
|
"String",
|
|
"Torrents",
|
|
),
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "torrents_removed",
|
|
description: Some(
|
|
"List of hashes of torrents removed since last request",
|
|
),
|
|
is_optional: true,
|
|
is_list: true,
|
|
},
|
|
ref_type: String(
|
|
"String",
|
|
),
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "categories",
|
|
description: Some(
|
|
"Info for categories added since last request, map from string to categories object",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
ref_type: Map(
|
|
"String",
|
|
"Categories",
|
|
),
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "categories_removed",
|
|
description: Some(
|
|
"List of categories removed since last request",
|
|
),
|
|
is_optional: true,
|
|
is_list: true,
|
|
},
|
|
ref_type: String(
|
|
"String",
|
|
),
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "tags",
|
|
description: Some(
|
|
"List of tags added since last request",
|
|
),
|
|
is_optional: true,
|
|
is_list: true,
|
|
},
|
|
ref_type: String(
|
|
"String",
|
|
),
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "tags_removed",
|
|
description: Some(
|
|
"List of tags removed since last request",
|
|
),
|
|
is_optional: true,
|
|
is_list: true,
|
|
},
|
|
ref_type: String(
|
|
"String",
|
|
),
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "server_state",
|
|
description: Some(
|
|
"server_state object see table below",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
ref_type: String(
|
|
"ServerState",
|
|
),
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
TypeWithName {
|
|
name: "Torrents",
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "added_on",
|
|
description: Some(
|
|
"Time (Unix Epoch) when the torrent was added to the client",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "amount_left",
|
|
description: Some(
|
|
"Amount of data left to download (bytes)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "auto_tmm",
|
|
description: Some(
|
|
"Whether this torrent is managed by Automatic Torrent Management",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "availability",
|
|
description: Some(
|
|
"Percentage of file pieces currently available",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "category",
|
|
description: Some(
|
|
"Category of the torrent",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "completed",
|
|
description: Some(
|
|
"Amount of transfer data completed (bytes)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "completion_on",
|
|
description: Some(
|
|
"Time (Unix Epoch) when the torrent completed",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "content_path",
|
|
description: Some(
|
|
"Absolute path of torrent content (root path for multifile torrents, absolute file path for singlefile torrents)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dl_limit",
|
|
description: Some(
|
|
"Torrent download speed limit (bytes/s). -1 if ulimited.",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dlspeed",
|
|
description: Some(
|
|
"Torrent download speed (bytes/s)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "downloaded",
|
|
description: Some(
|
|
"Amount of data downloaded",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "downloaded_session",
|
|
description: Some(
|
|
"Amount of data downloaded this session",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "eta",
|
|
description: Some(
|
|
"Torrent ETA (seconds)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "f_l_piece_prio",
|
|
description: Some(
|
|
"True if first last piece are prioritized",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "force_start",
|
|
description: Some(
|
|
"True if force start is enabled for this torrent",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"Torrent hash",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "last_activity",
|
|
description: Some(
|
|
"Last time (Unix Epoch) when a chunk was downloaded/uploaded",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "magnet_uri",
|
|
description: Some(
|
|
"Magnet URI corresponding to this torrent",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "max_ratio",
|
|
description: Some(
|
|
"Maximum share ratio until torrent is stopped from seeding/uploading",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "max_seeding_time",
|
|
description: Some(
|
|
"Maximum seeding time (seconds) until torrent is stopped from seeding",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "name",
|
|
description: Some(
|
|
"Torrent name",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "num_complete",
|
|
description: Some(
|
|
"Number of seeds in the swarm",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "num_incomplete",
|
|
description: Some(
|
|
"Number of leechers in the swarm",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "num_leechs",
|
|
description: Some(
|
|
"Number of leechers connected to",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "num_seeds",
|
|
description: Some(
|
|
"Number of seeds connected to",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "priority",
|
|
description: Some(
|
|
"Torrent priority. Returns -1 if queuing is disabled or torrent is in seed mode",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "progress",
|
|
description: Some(
|
|
"Torrent progress (percentage/100)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "ratio",
|
|
description: Some(
|
|
"Torrent share ratio. Max ratio value: 9999.",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "ratio_limit",
|
|
description: Some(
|
|
"TODO (what is different from max_ratio?)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "save_path",
|
|
description: Some(
|
|
"Path where this torrent's data is stored",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "seeding_time",
|
|
description: Some(
|
|
"Torrent elapsed time while complete (seconds)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "seeding_time_limit",
|
|
description: Some(
|
|
"TODO (what is different from max_seeding_time?) seeding_time_limit is a per torrent setting, when Automatic Torrent Management is disabled, furthermore then max_seeding_time is set to seeding_time_limit for this torrent. If Automatic Torrent Management is enabled, the value is -2. And if max_seeding_time is unset it have a default value -1.",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "seen_complete",
|
|
description: Some(
|
|
"Time (Unix Epoch) when this torrent was last seen complete",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "seq_dl",
|
|
description: Some(
|
|
"True if sequential download is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "size",
|
|
description: Some(
|
|
"Total size (bytes) of files selected for download",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "state",
|
|
description: Some(
|
|
"Torrent state. See table here below for the possible values",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "super_seeding",
|
|
description: Some(
|
|
"True if super seeding is enabled",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "tags",
|
|
description: Some(
|
|
"Comma-concatenated tag list of the torrent",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "time_active",
|
|
description: Some(
|
|
"Total active time (seconds)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "total_size",
|
|
description: Some(
|
|
"Total size (bytes) of all file in this torrent (including unselected ones)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "tracker",
|
|
description: Some(
|
|
"The first tracker with working status. Returns empty string if no tracker is working.",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "up_limit",
|
|
description: Some(
|
|
"Torrent upload speed limit (bytes/s). -1 if ulimited.",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "uploaded",
|
|
description: Some(
|
|
"Amount of data uploaded",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "uploaded_session",
|
|
description: Some(
|
|
"Amount of data uploaded this session",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "upspeed",
|
|
description: Some(
|
|
"Torrent upload speed (bytes/s)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "torrentPeers",
|
|
description: Some(
|
|
"The response is TODO",
|
|
),
|
|
url: "torrentPeers",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"Torrent hash",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "rid",
|
|
description: Some(
|
|
"Response ID. If not provided, rid=0 will be assumed. If the given rid is different from the one of last server reply, full_update will be true (see the server reply details for more info)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
],
|
|
description: Some(
|
|
"Sync API implements requests for obtaining changes since the last request.\nAll Sync API methods are under \"sync\", e.g.: `/api/v2/sync/methodName`.",
|
|
),
|
|
url: "sync",
|
|
},
|
|
ApiGroup {
|
|
name: "transfer_info",
|
|
methods: [
|
|
ApiMethod {
|
|
name: "info",
|
|
description: Some(
|
|
"The response is a JSON object with the following fields\n\n\nIn addition to the above in partial data requests (see [Get partial data](#get-partial-data) for more info):\n\n\nPossible values of `connection_status`:\n\nValue |\n\nExample:\n\n```JSON\n{\n \"connection_status\":\"connected\",\n \"dht_nodes\":386,\n \"dl_info_data\":681521119,\n \"dl_info_speed\":0,\n \"dl_rate_limit\":0,\n \"up_info_data\":10747904,\n \"up_info_speed\":0,\n \"up_rate_limit\":1048576\n}\n```",
|
|
),
|
|
url: "info",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "dl_info_speed",
|
|
description: Some(
|
|
"Global download rate (bytes/s)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dl_info_data",
|
|
description: Some(
|
|
"Data downloaded this session (bytes)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "up_info_speed",
|
|
description: Some(
|
|
"Global upload rate (bytes/s)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "up_info_data",
|
|
description: Some(
|
|
"Data uploaded this session (bytes)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dl_rate_limit",
|
|
description: Some(
|
|
"Download rate limit (bytes/s)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "up_rate_limit",
|
|
description: Some(
|
|
"Upload rate limit (bytes/s)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dht_nodes",
|
|
description: Some(
|
|
"DHT nodes connected to",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "connection_status",
|
|
description: Some(
|
|
"Connection status. See possible values here below",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "speedLimitsMode",
|
|
description: Some(
|
|
"The response is `1` if alternative speed limits are enabled, `0` otherwise.",
|
|
),
|
|
url: "speedLimitsMode",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "toggleSpeedLimitsMode",
|
|
description: None,
|
|
url: "toggleSpeedLimitsMode",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "downloadLimit",
|
|
description: Some(
|
|
"The response is the value of current global download speed limit in bytes/second; this value will be zero if no limit is applied.",
|
|
),
|
|
url: "downloadLimit",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "setDownloadLimit",
|
|
description: None,
|
|
url: "setDownloadLimit",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "limit",
|
|
description: Some(
|
|
"The global download speed limit to set in bytes/second",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "uploadLimit",
|
|
description: Some(
|
|
"The response is the value of current global upload speed limit in bytes/second; this value will be zero if no limit is applied.",
|
|
),
|
|
url: "uploadLimit",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "setUploadLimit",
|
|
description: None,
|
|
url: "setUploadLimit",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "limit",
|
|
description: Some(
|
|
"The global upload speed limit to set in bytes/second",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "banPeers",
|
|
description: None,
|
|
url: "banPeers",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "peers",
|
|
description: Some(
|
|
"The peer to ban, or multiple peers separated by a pipe. Each peer is a colon-separated host:port",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
],
|
|
description: Some(
|
|
"All Transfer info API methods are under \"transfer\", e.g.: `/api/v2/transfer/methodName`.",
|
|
),
|
|
url: "transfer",
|
|
},
|
|
ApiGroup {
|
|
name: "torrent_management",
|
|
methods: [
|
|
ApiMethod {
|
|
name: "info",
|
|
description: Some(
|
|
"The response is a JSON array with the following fields\n\n\nPossible values of `state`:\n\n\nExample:\n\n```JSON\n[\n {\n \"dlspeed\":9681262,\n \"eta\":87,\n \"f_l_piece_prio\":false,\n \"force_start\":false,\n \"hash\":\"8c212779b4abde7c6bc608063a0d008b7e40ce32\",\n \"category\":\"\",\n \"tags\": \"\",\n \"name\":\"debian-8.1.0-amd64-CD-1.iso\",\n \"num_complete\":-1,\n \"num_incomplete\":-1,\n \"num_leechs\":2,\n \"num_seeds\":54,\n \"priority\":1,\n \"progress\":0.16108787059783936,\n \"ratio\":0,\n \"seq_dl\":false,\n \"size\":657457152,\n \"state\":\"downloading\",\n \"super_seeding\":false,\n \"upspeed\":0\n },\n {\n another_torrent_info\n }\n]\n```",
|
|
),
|
|
url: "info",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "filter",
|
|
description: Some(
|
|
"Filter torrent list by state. Allowed state filters: all, downloading, seeding, completed, paused, active, inactive, resumed, stalled, stalled_uploading, stalled_downloading, errored",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "category",
|
|
description: Some(
|
|
"Get torrents with the given category (empty string means \"without category\"; no \"category\" parameter means \"any category\" <- broken until [#11748](https://github.com/qbittorrent/qBittorrent/issues/11748) is resolved). Remember to URL-encode the category name. For example, My category becomes My%20category",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "tag",
|
|
description: Some(
|
|
"Get torrents with the given tag (empty string means \"without tag\"; no \"tag\" parameter means \"any tag\". Remember to URL-encode the category name. For example, My tag becomes My%20tag",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "sort",
|
|
description: Some(
|
|
"Sort torrents by given key. They can be sorted using any field of the response (which are documented below) as the sort key.",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "reverse",
|
|
description: Some(
|
|
"Enable reverse sorting. Defaults to false",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "limit",
|
|
description: Some(
|
|
"Limit the number of torrents returned",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "offset",
|
|
description: Some(
|
|
"Set offset (if less than 0, offset from end)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"Filter by hashes. Can contain multiple hashes separated by a pipe",
|
|
),
|
|
is_optional: true,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "State",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Some error occurred, applies to paused torrents",
|
|
),
|
|
value: "Error",
|
|
original_value: "error",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent data files is missing",
|
|
),
|
|
value: "MissingFiles",
|
|
original_value: "missingFiles",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent is being seeded and data is being transferred",
|
|
),
|
|
value: "Uploading",
|
|
original_value: "uploading",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent is paused and has finished downloading",
|
|
),
|
|
value: "PausedUP",
|
|
original_value: "pausedUP",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Queuing is enabled and torrent is queued for upload",
|
|
),
|
|
value: "QueuedUP",
|
|
original_value: "queuedUP",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent is being seeded, but no connection were made",
|
|
),
|
|
value: "StalledUP",
|
|
original_value: "stalledUP",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent has finished downloading and is being checked",
|
|
),
|
|
value: "CheckingUP",
|
|
original_value: "checkingUP",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent is forced to uploading and ignore queue limit",
|
|
),
|
|
value: "ForcedUP",
|
|
original_value: "forcedUP",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent is allocating disk space for download",
|
|
),
|
|
value: "Allocating",
|
|
original_value: "allocating",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent is being downloaded and data is being transferred",
|
|
),
|
|
value: "Downloading",
|
|
original_value: "downloading",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent has just started downloading and is fetching metadata",
|
|
),
|
|
value: "MetaDL",
|
|
original_value: "metaDL",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent is paused and has NOT finished downloading",
|
|
),
|
|
value: "PausedDL",
|
|
original_value: "pausedDL",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Queuing is enabled and torrent is queued for download",
|
|
),
|
|
value: "QueuedDL",
|
|
original_value: "queuedDL",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent is being downloaded, but no connection were made",
|
|
),
|
|
value: "StalledDL",
|
|
original_value: "stalledDL",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Same as checkingUP, but torrent has NOT finished downloading",
|
|
),
|
|
value: "CheckingDL",
|
|
original_value: "checkingDL",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent is forced to downloading to ignore queue limit",
|
|
),
|
|
value: "ForcedDL",
|
|
original_value: "forcedDL",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Checking resume data on qBt startup",
|
|
),
|
|
value: "CheckingResumeData",
|
|
original_value: "checkingResumeData",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Torrent is moving to another location",
|
|
),
|
|
value: "Moving",
|
|
original_value: "moving",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Unknown status",
|
|
),
|
|
value: "Unknown",
|
|
original_value: "unknown",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "added_on",
|
|
description: Some(
|
|
"Time (Unix Epoch) when the torrent was added to the client",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "amount_left",
|
|
description: Some(
|
|
"Amount of data left to download (bytes)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "auto_tmm",
|
|
description: Some(
|
|
"Whether this torrent is managed by Automatic Torrent Management",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "availability",
|
|
description: Some(
|
|
"Percentage of file pieces currently available",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "category",
|
|
description: Some(
|
|
"Category of the torrent",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "completed",
|
|
description: Some(
|
|
"Amount of transfer data completed (bytes)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "completion_on",
|
|
description: Some(
|
|
"Time (Unix Epoch) when the torrent completed",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "content_path",
|
|
description: Some(
|
|
"Absolute path of torrent content (root path for multifile torrents, absolute file path for singlefile torrents)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dl_limit",
|
|
description: Some(
|
|
"Torrent download speed limit (bytes/s). -1 if ulimited.",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dlspeed",
|
|
description: Some(
|
|
"Torrent download speed (bytes/s)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "downloaded",
|
|
description: Some(
|
|
"Amount of data downloaded",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "downloaded_session",
|
|
description: Some(
|
|
"Amount of data downloaded this session",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "eta",
|
|
description: Some(
|
|
"Torrent ETA (seconds)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "f_l_piece_prio",
|
|
description: Some(
|
|
"True if first last piece are prioritized",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "force_start",
|
|
description: Some(
|
|
"True if force start is enabled for this torrent",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"Torrent hash",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "last_activity",
|
|
description: Some(
|
|
"Last time (Unix Epoch) when a chunk was downloaded/uploaded",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "magnet_uri",
|
|
description: Some(
|
|
"Magnet URI corresponding to this torrent",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "max_ratio",
|
|
description: Some(
|
|
"Maximum share ratio until torrent is stopped from seeding/uploading",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "max_seeding_time",
|
|
description: Some(
|
|
"Maximum seeding time (seconds) until torrent is stopped from seeding",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "name",
|
|
description: Some(
|
|
"Torrent name",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "num_complete",
|
|
description: Some(
|
|
"Number of seeds in the swarm",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "num_incomplete",
|
|
description: Some(
|
|
"Number of leechers in the swarm",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "num_leechs",
|
|
description: Some(
|
|
"Number of leechers connected to",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "num_seeds",
|
|
description: Some(
|
|
"Number of seeds connected to",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "priority",
|
|
description: Some(
|
|
"Torrent priority. Returns -1 if queuing is disabled or torrent is in seed mode",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "progress",
|
|
description: Some(
|
|
"Torrent progress (percentage/100)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "ratio",
|
|
description: Some(
|
|
"Torrent share ratio. Max ratio value: 9999.",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "ratio_limit",
|
|
description: Some(
|
|
"TODO (what is different from max_ratio?)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "save_path",
|
|
description: Some(
|
|
"Path where this torrent's data is stored",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "seeding_time",
|
|
description: Some(
|
|
"Torrent elapsed time while complete (seconds)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "seeding_time_limit",
|
|
description: Some(
|
|
"TODO (what is different from max_seeding_time?) seeding_time_limit is a per torrent setting, when Automatic Torrent Management is disabled, furthermore then max_seeding_time is set to seeding_time_limit for this torrent. If Automatic Torrent Management is enabled, the value is -2. And if max_seeding_time is unset it have a default value -1.",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "seen_complete",
|
|
description: Some(
|
|
"Time (Unix Epoch) when this torrent was last seen complete",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "seq_dl",
|
|
description: Some(
|
|
"True if sequential download is enabled",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "size",
|
|
description: Some(
|
|
"Total size (bytes) of files selected for download",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "state",
|
|
description: Some(
|
|
"state object see table below.",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
ref_type: String(
|
|
"State",
|
|
),
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "super_seeding",
|
|
description: Some(
|
|
"True if super seeding is enabled",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "tags",
|
|
description: Some(
|
|
"Comma-concatenated tag list of the torrent",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "time_active",
|
|
description: Some(
|
|
"Total active time (seconds)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "total_size",
|
|
description: Some(
|
|
"Total size (bytes) of all file in this torrent (including unselected ones)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "tracker",
|
|
description: Some(
|
|
"The first tracker with working status. Returns empty string if no tracker is working.",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "up_limit",
|
|
description: Some(
|
|
"Torrent upload speed limit (bytes/s). -1 if ulimited.",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "uploaded",
|
|
description: Some(
|
|
"Amount of data uploaded",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "uploaded_session",
|
|
description: Some(
|
|
"Amount of data uploaded this session",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "upspeed",
|
|
description: Some(
|
|
"Torrent upload speed (bytes/s)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: true,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "properties",
|
|
description: Some(
|
|
"The response is a JSON of objects containing the following fields:\n\n\nNB: `-1` is returned if the type of the property is integer but its value is not known.\n\nExample:\n\n```JSON\n{\n \"addition_date\":1438429165,\n \"comment\":\"\\\"Debian CD from cdimage.debian.org\\\"\",\n \"completion_date\":1438429234,\n \"created_by\":\"\",\n \"creation_date\":1433605214,\n \"dl_limit\":-1,\n \"dl_speed\":0,\n \"dl_speed_avg\":9736015,\n \"eta\":8640000,\n \"last_seen\":1438430354,\n \"nb_connections\":3,\n \"nb_connections_limit\":250,\n \"peers\":1,\n \"peers_total\":89,\n \"piece_size\":524288,\n \"pieces_have\":1254,\n \"pieces_num\":1254,\n \"reannounce\":672,\n \"save_path\":\"/Downloads/debian-8.1.0-amd64-CD-1.iso\",\n \"seeding_time\":1128,\n \"seeds\":1,\n \"seeds_total\":254,\n \"share_ratio\":0.00072121022562178299,\n \"time_elapsed\":1197,\n \"total_downloaded\":681521119,\n \"total_downloaded_session\":681521119,\n \"total_size\":657457152,\n \"total_uploaded\":491520,\n \"total_uploaded_session\":491520,\n \"total_wasted\":23481724,\n \"up_limit\":-1,\n \"up_speed\":0,\n \"up_speed_avg\":410\n}\n```",
|
|
),
|
|
url: "properties",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"The hash of the torrent you want to get the generic properties of",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "save_path",
|
|
description: Some(
|
|
"Torrent save path",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "creation_date",
|
|
description: Some(
|
|
"Torrent creation date (Unix timestamp)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "piece_size",
|
|
description: Some(
|
|
"Torrent piece size (bytes)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "comment",
|
|
description: Some(
|
|
"Torrent comment",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "total_wasted",
|
|
description: Some(
|
|
"Total data wasted for torrent (bytes)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "total_uploaded",
|
|
description: Some(
|
|
"Total data uploaded for torrent (bytes)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "total_uploaded_session",
|
|
description: Some(
|
|
"Total data uploaded this session (bytes)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "total_downloaded",
|
|
description: Some(
|
|
"Total data downloaded for torrent (bytes)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "total_downloaded_session",
|
|
description: Some(
|
|
"Total data downloaded this session (bytes)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "up_limit",
|
|
description: Some(
|
|
"Torrent upload limit (bytes/s)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dl_limit",
|
|
description: Some(
|
|
"Torrent download limit (bytes/s)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "time_elapsed",
|
|
description: Some(
|
|
"Torrent elapsed time (seconds)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "seeding_time",
|
|
description: Some(
|
|
"Torrent elapsed time while complete (seconds)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "nb_connections",
|
|
description: Some(
|
|
"Torrent connection count",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "nb_connections_limit",
|
|
description: Some(
|
|
"Torrent connection count limit",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "share_ratio",
|
|
description: Some(
|
|
"Torrent share ratio",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "addition_date",
|
|
description: Some(
|
|
"When this torrent was added (unix timestamp)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "completion_date",
|
|
description: Some(
|
|
"Torrent completion date (unix timestamp)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "created_by",
|
|
description: Some(
|
|
"Torrent creator",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dl_speed_avg",
|
|
description: Some(
|
|
"Torrent average download speed (bytes/second)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dl_speed",
|
|
description: Some(
|
|
"Torrent download speed (bytes/second)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "eta",
|
|
description: Some(
|
|
"Torrent ETA (seconds)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "last_seen",
|
|
description: Some(
|
|
"Last seen complete date (unix timestamp)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "peers",
|
|
description: Some(
|
|
"Number of peers connected to",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "peers_total",
|
|
description: Some(
|
|
"Number of peers in the swarm",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "pieces_have",
|
|
description: Some(
|
|
"Number of pieces owned",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "pieces_num",
|
|
description: Some(
|
|
"Number of pieces of the torrent",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "reannounce",
|
|
description: Some(
|
|
"Number of seconds until the next announce",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "seeds",
|
|
description: Some(
|
|
"Number of seeds connected to",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "seeds_total",
|
|
description: Some(
|
|
"Number of seeds in the swarm",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "total_size",
|
|
description: Some(
|
|
"Torrent total size (bytes)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "up_speed_avg",
|
|
description: Some(
|
|
"Torrent average upload speed (bytes/second)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "up_speed",
|
|
description: Some(
|
|
"Torrent upload speed (bytes/second)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "trackers",
|
|
description: Some(
|
|
"The response is a JSON array, where each element contains info about one tracker, with the following fields\n\n\nPossible values of `status`:\n\n\nExample:\n\n```JSON\n[\n {\n \"msg\":\"\",\n \"num_peers\":100,\n \"status\":2,\n \"url\":\"http://bttracker.debian.org:6969/announce\"\n },\n {\n another_tracker_info\n }\n]\n```",
|
|
),
|
|
url: "trackers",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"The hash of the torrent you want to get the trackers of",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "Status",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Tracker is disabled (used for DHT, PeX, and LSD)",
|
|
),
|
|
value: "TrackerIsDisabled",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Tracker has not been contacted yet",
|
|
),
|
|
value: "TrackerHasNotBeenContactedYet",
|
|
original_value: "1",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Tracker has been contacted and is working",
|
|
),
|
|
value: "TrackerHasBeenContactedAndIsWorking",
|
|
original_value: "2",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Tracker is updating",
|
|
),
|
|
value: "TrackerIsUpdating",
|
|
original_value: "3",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Tracker has been contacted, but it is not working (or doesn't send proper replies)",
|
|
),
|
|
value: "TrackerHasBeenContactedButItIsNotWorking",
|
|
original_value: "4",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "url",
|
|
description: Some(
|
|
"Tracker url",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "status",
|
|
description: Some(
|
|
"Tracker status. See the table below for possible values",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "tier",
|
|
description: Some(
|
|
"Tracker priority tier. Lower tier trackers are tried before higher tiers. Tier numbers are valid when >= 0, < 0 is used as placeholder when tier does not exist for special entries (such as DHT).",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "num_peers",
|
|
description: Some(
|
|
"Number of peers for current torrent, as reported by the tracker",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "num_seeds",
|
|
description: Some(
|
|
"Number of seeds for current torrent, asreported by the tracker",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "num_leeches",
|
|
description: Some(
|
|
"Number of leeches for current torrent, as reported by the tracker",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "num_downloaded",
|
|
description: Some(
|
|
"Number of completed downlods for current torrent, as reported by the tracker",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "msg",
|
|
description: Some(
|
|
"Tracker message (there is no way of knowing what this message is - it's up to tracker admins)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: true,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "webseeds",
|
|
description: Some(
|
|
"The response is a JSON array, where each element is information about one webseed, with the following fields\n\n\nExample:\n\n```JSON\n[\n {\n \"url\":\"http://some_url/\"\n },\n {\n \"url\":\"http://some_other_url/\"\n }\n]\n```",
|
|
),
|
|
url: "webseeds",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"The hash of the torrent you want to get the webseeds of",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "url",
|
|
description: Some(
|
|
"URL of the web seed",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: true,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "files",
|
|
description: Some(
|
|
"The response is a JSON array of objects containing the following fields:\n\n\nPossible values of `priority`:\n\n\nExample:\n\n```JSON\n\n[\n {\n \"index\":0,\n \"is_seed\":false,\n \"name\":\"debian-8.1.0-amd64-CD-1.iso\",\n \"piece_range\":[0,1253],\n \"priority\":1,\n \"progress\":0,\n \"size\":657457152,\n \"availability\":0.5,\n }\n]\n```",
|
|
),
|
|
url: "files",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"The hash of the torrent you want to get the contents of",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "indexes",
|
|
description: Some(
|
|
"The indexes of the files you want to retrieve. indexes can contain multiple values separated by a pipe.",
|
|
),
|
|
is_optional: true,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "Priority",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Do not download",
|
|
),
|
|
value: "DoNotDownload",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Normal priority",
|
|
),
|
|
value: "NormalPriority",
|
|
original_value: "1",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Default Normal priority",
|
|
),
|
|
value: "DefaultNormalPriority",
|
|
original_value: "4",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"High priority",
|
|
),
|
|
value: "HighPriority",
|
|
original_value: "6",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Maximal priority",
|
|
),
|
|
value: "MaximalPriority",
|
|
original_value: "7",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "index",
|
|
description: Some(
|
|
"File index",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "name",
|
|
description: Some(
|
|
"File name (including relative path)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "size",
|
|
description: Some(
|
|
"File size (bytes)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "progress",
|
|
description: Some(
|
|
"File progress (percentage/100)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "priority",
|
|
description: Some(
|
|
"priority object see table below. File priority. See possible values here below",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
ref_type: String(
|
|
"Priority",
|
|
),
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "is_seed",
|
|
description: Some(
|
|
"True if file is seeding/complete",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "piece_range",
|
|
description: Some(
|
|
"The first number is the starting piece index and the second number is the ending piece index (inclusive)",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "availability",
|
|
description: Some(
|
|
"Percentage of file pieces currently available (percentage/100)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: true,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "pieceStates",
|
|
description: Some(
|
|
"The response is a JSON array of `return_objects`;\n\nPossible values of `return_objects`:\n\n\nExample:\n\n```JSON\n[0,0,2,1,0,0,2,1]\n```",
|
|
),
|
|
url: "pieceStates",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"The hash of the torrent you want to get the pieces' states of",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "ReturnObjects",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Not downloaded yet",
|
|
),
|
|
value: "NotDownloadedYet",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Now downloading",
|
|
),
|
|
value: "NowDownloading",
|
|
original_value: "1",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Already downloaded",
|
|
),
|
|
value: "AlreadyDownloaded",
|
|
original_value: "2",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "pieceHashes",
|
|
description: Some(
|
|
"The response is a JSON array of hashes (strings).\n\nExample:\n\n```JSON\n[\"54eddd830a5b58480a6143d616a97e3a6c23c439\",\"f8a99d225aa4241db100f88407fc3bdaead583ab\",\"928fb615b9bd4dd8f9e9022552c8f8f37ef76f58\"]\n```",
|
|
),
|
|
url: "pieceHashes",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"The hash of the torrent you want to get the pieces' hashes of",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "pause",
|
|
description: None,
|
|
url: "pause",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"The hashes of the torrents you want to pause. hashes can contain multiple hashes separated by a pipe, to pause multiple torrents, or set to all, to pause all torrents.",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "resume",
|
|
description: None,
|
|
url: "resume",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"The hashes of the torrents you want to resume. hashes can contain multiple hashes separated by a pipe, to resume multiple torrents, or set to all, to resume all torrents.",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "delete",
|
|
description: None,
|
|
url: "delete",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"The hashes of the torrents you want to delete. hashes can contain multiple hashes separated by a pipe, to delete multiple torrents, or set to all, to delete all torrents.",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "deleteFiles",
|
|
description: Some(
|
|
"If set to true, the downloaded data will also be deleted, otherwise has no effect.",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "recheck",
|
|
description: None,
|
|
url: "recheck",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"The hashes of the torrents you want to recheck. hashes can contain multiple hashes separated by a pipe, to recheck multiple torrents, or set to all, to recheck all torrents.",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "reannounce",
|
|
description: None,
|
|
url: "reannounce",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"The hashes of the torrents you want to reannounce. hashes can contain multiple hashes separated by a pipe, to reannounce multiple torrents, or set to all, to reannounce all torrents.",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "add",
|
|
description: None,
|
|
url: "add",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "urls",
|
|
description: Some(
|
|
"URLs separated with newlines",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "savepath",
|
|
description: Some(
|
|
"Download folder",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "cookie",
|
|
description: Some(
|
|
"Cookie sent to download the .torrent file",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "category",
|
|
description: Some(
|
|
"Category for the torrent",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "tags",
|
|
description: Some(
|
|
"Tags for the torrent, split by ','",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "skip_checking",
|
|
description: Some(
|
|
"Skip hash checking. Possible values are true, false (default)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "paused",
|
|
description: Some(
|
|
"Add torrents in the paused state. Possible values are true, false (default)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "root_folder",
|
|
description: Some(
|
|
"Create the root folder. Possible values are true, false, unset (default)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "rename",
|
|
description: Some(
|
|
"Rename torrent",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "upLimit",
|
|
description: Some(
|
|
"Set torrent upload speed limit. Unit in bytes/second",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "dlLimit",
|
|
description: Some(
|
|
"Set torrent download speed limit. Unit in bytes/second",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Float(
|
|
TypeInfo {
|
|
name: "ratioLimit",
|
|
description: Some(
|
|
"Set torrent share ratio limit",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "seedingTimeLimit",
|
|
description: Some(
|
|
"Set torrent seeding time limit. Unit in seconds",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "autoTMM",
|
|
description: Some(
|
|
"Whether Automatic Torrent Management should be used",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "sequentialDownload",
|
|
description: Some(
|
|
"Enable sequential download. Possible values are true, false (default)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "firstLastPiecePrio",
|
|
description: Some(
|
|
"Prioritize download first last piece. Possible values are true, false (default)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "addTrackers",
|
|
description: None,
|
|
url: "addTrackers",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "editTracker",
|
|
description: None,
|
|
url: "editTracker",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"The hash of the torrent",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "origUrl",
|
|
description: Some(
|
|
"The tracker URL you want to edit",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "newUrl",
|
|
description: Some(
|
|
"The new URL to replace the origUrl",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "removeTrackers",
|
|
description: None,
|
|
url: "removeTrackers",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"The hash of the torrent",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "urls",
|
|
description: Some(
|
|
"URLs to remove, separated by a pipe",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "addPeers",
|
|
description: None,
|
|
url: "addPeers",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"The hash of the torrent, or multiple hashes separated by a pipe",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "peers",
|
|
description: Some(
|
|
"The peer to add, or multiple peers separated by a pipe. Each peer is a colon-separated host:port",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "increasePrio",
|
|
description: None,
|
|
url: "increasePrio",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"The hashes of the torrents you want to increase the priority of. hashes can contain multiple hashes separated by a pipe, to increase the priority of multiple torrents, or set to all, to increase the priority of all torrents.",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "decreasePrio",
|
|
description: None,
|
|
url: "decreasePrio",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"The hashes of the torrents you want to decrease the priority of. hashes can contain multiple hashes separated by a pipe, to decrease the priority of multiple torrents, or set to all, to decrease the priority of all torrents.",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "topPrio",
|
|
description: None,
|
|
url: "topPrio",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"The hashes of the torrents you want to set to the maximum priority. hashes can contain multiple hashes separated by a pipe, to set multiple torrents to the maximum priority, or set to all, to set all torrents to the maximum priority.",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "bottomPrio",
|
|
description: None,
|
|
url: "bottomPrio",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"The hashes of the torrents you want to set to the minimum priority. hashes can contain multiple hashes separated by a pipe, to set multiple torrents to the minimum priority, or set to all, to set all torrents to the minimum priority.",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "filePrio",
|
|
description: None,
|
|
url: "filePrio",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"The hash of the torrent",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "id",
|
|
description: Some(
|
|
"File ids, separated by a pipe",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "priority",
|
|
description: Some(
|
|
"priority object see table below. File priority to set (consult [torrent contents API](#get-torrent-contents) for possible values)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
ref_type: String(
|
|
"Priority",
|
|
),
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
Enum(
|
|
Enum {
|
|
name: "Priority",
|
|
values: [
|
|
EnumValue {
|
|
description: Some(
|
|
"Do not download",
|
|
),
|
|
value: "DoNotDownload",
|
|
original_value: "0",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Normal priority",
|
|
),
|
|
value: "NormalPriority",
|
|
original_value: "4",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"High priority",
|
|
),
|
|
value: "HighPriority",
|
|
original_value: "6",
|
|
},
|
|
EnumValue {
|
|
description: Some(
|
|
"Maximal priority",
|
|
),
|
|
value: "MaximalPriority",
|
|
original_value: "7",
|
|
},
|
|
],
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "downloadLimit",
|
|
description: None,
|
|
url: "downloadLimit",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "setShareLimits",
|
|
description: None,
|
|
url: "setShareLimits",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "uploadLimit",
|
|
description: None,
|
|
url: "uploadLimit",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "setUploadLimit",
|
|
description: None,
|
|
url: "setUploadLimit",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "setLocation",
|
|
description: None,
|
|
url: "setLocation",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "rename",
|
|
description: None,
|
|
url: "rename",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "setCategory",
|
|
description: None,
|
|
url: "setCategory",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "categories",
|
|
description: None,
|
|
url: "categories",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "createCategory",
|
|
description: None,
|
|
url: "createCategory",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "editCategory",
|
|
description: None,
|
|
url: "editCategory",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "removeCategories",
|
|
description: None,
|
|
url: "removeCategories",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "addTags",
|
|
description: None,
|
|
url: "addTags",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "removeTags",
|
|
description: None,
|
|
url: "removeTags",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "tags",
|
|
description: None,
|
|
url: "tags",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "createTags",
|
|
description: None,
|
|
url: "createTags",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "deleteTags",
|
|
description: None,
|
|
url: "deleteTags",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "setAutoManagement",
|
|
description: None,
|
|
url: "setAutoManagement",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "toggleSequentialDownload",
|
|
description: None,
|
|
url: "toggleSequentialDownload",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"The hashes of the torrents you want to toggle sequential download for. hashes can contain multiple hashes separated by a pipe, to toggle sequential download for multiple torrents, or set to all, to toggle sequential download for all torrents.",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "toggleFirstLastPiecePrio",
|
|
description: None,
|
|
url: "toggleFirstLastPiecePrio",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "hashes",
|
|
description: Some(
|
|
"The hashes of the torrents you want to toggle the first/last piece priority for. hashes can contain multiple hashes separated by a pipe, to toggle the first/last piece priority for multiple torrents, or set to all, to toggle the first/last piece priority for all torrents.",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "setForceStart",
|
|
description: None,
|
|
url: "setForceStart",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "setSuperSeeding",
|
|
description: None,
|
|
url: "setSuperSeeding",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "renameFile",
|
|
description: None,
|
|
url: "renameFile",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"The hash of the torrent",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "oldPath",
|
|
description: Some(
|
|
"The old path of the torrent",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "newPath",
|
|
description: Some(
|
|
"The new path to use for the file",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "renameFolder",
|
|
description: None,
|
|
url: "renameFolder",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "hash",
|
|
description: Some(
|
|
"The hash of the torrent",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "oldPath",
|
|
description: Some(
|
|
"The old path of the torrent",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "newPath",
|
|
description: Some(
|
|
"The new path to use for the file",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
],
|
|
description: Some(
|
|
"All Torrent management API methods are under \"torrents\", e.g.: `/api/v2/torrents/methodName`.",
|
|
),
|
|
url: "torrents",
|
|
},
|
|
ApiGroup {
|
|
name: "rss",
|
|
methods: [
|
|
ApiMethod {
|
|
name: "addFolder",
|
|
description: None,
|
|
url: "addFolder",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "path",
|
|
description: Some(
|
|
"Full path of added folder (e.g. \"The Pirate Bay\\Top100\")",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "addFeed",
|
|
description: None,
|
|
url: "addFeed",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "url",
|
|
description: Some(
|
|
"URL of RSS feed (e.g. \"[http://thepiratebay.org/rss//top100/200](http://thepiratebay.org/rss//top100/200)\")",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "path",
|
|
description: Some(
|
|
"Full path of added folder (e.g. \"The Pirate Bay\\Top100\\Video\")",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "removeItem",
|
|
description: None,
|
|
url: "removeItem",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "path",
|
|
description: Some(
|
|
"Full path of removed item (e.g. \"The Pirate Bay\\Top100\")",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "moveItem",
|
|
description: None,
|
|
url: "moveItem",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "itemPath",
|
|
description: Some(
|
|
"Current full path of item (e.g. \"The Pirate Bay\\Top100\")",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "destPath",
|
|
description: Some(
|
|
"New full path of item (e.g. \"The Pirate Bay\")",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "items",
|
|
description: None,
|
|
url: "items",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
Bool(
|
|
TypeInfo {
|
|
name: "withData",
|
|
description: Some(
|
|
"True if you need current feed articles",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "markAsRead",
|
|
description: None,
|
|
url: "markAsRead",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "itemPath",
|
|
description: Some(
|
|
"Current full path of item (e.g. \"The Pirate Bay\\Top100\")",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "articleId",
|
|
description: Some(
|
|
"ID of article",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "refreshItem",
|
|
description: None,
|
|
url: "refreshItem",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "itemPath",
|
|
description: Some(
|
|
"Current full path of item (e.g. \"The Pirate Bay\\Top100\")",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "setRule",
|
|
description: None,
|
|
url: "setRule",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "ruleName",
|
|
description: Some(
|
|
"Rule name (e.g. \"Punisher\")",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "ruleDef",
|
|
description: Some(
|
|
"JSON encoded rule definition",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "renameRule",
|
|
description: None,
|
|
url: "renameRule",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "ruleName",
|
|
description: Some(
|
|
"Rule name (e.g. \"Punisher\")",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "newRuleName",
|
|
description: Some(
|
|
"New rule name (e.g. \"The Punisher\")",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "removeRule",
|
|
description: None,
|
|
url: "removeRule",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "ruleName",
|
|
description: Some(
|
|
"Rule name (e.g. \"Punisher\")",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "rules",
|
|
description: None,
|
|
url: "rules",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "matchingArticles",
|
|
description: None,
|
|
url: "matchingArticles",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
],
|
|
description: Some(
|
|
"All RSS API methods are under \"rss\", e.g.: `/api/v2/rss/methodName`.",
|
|
),
|
|
url: "rss",
|
|
},
|
|
ApiGroup {
|
|
name: "search",
|
|
methods: [
|
|
ApiMethod {
|
|
name: "start",
|
|
description: Some(
|
|
"The response is a JSON object with the following fields\n\n\nExample:\n\n```JSON\n{\n \"id\": 12345\n}\n```",
|
|
),
|
|
url: "start",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "pattern",
|
|
description: Some(
|
|
"Pattern to search for (e.g. \"Ubuntu 18.04\")",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "plugins",
|
|
description: Some(
|
|
"Plugins to use for searching (e.g. \"legittorrents\"). Supports multiple plugins separated by a pipe. Also supports all and enabled",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "category",
|
|
description: Some(
|
|
"Categories to limit your search to (e.g. \"legittorrents\"). Available categories depend on the specified plugins. Also supports all",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "id",
|
|
description: Some(
|
|
"ID of the search job",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "stop",
|
|
description: None,
|
|
url: "stop",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "id",
|
|
description: Some(
|
|
"ID of the search job",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "status",
|
|
description: Some(
|
|
"The response is a JSON array of objects containing the following fields\n\n\nExample:\n\n```JSON\n[\n {\n \"id\": 12345,\n \"status\": \"Running\",\n \"total\": 170\n }\n]\n```",
|
|
),
|
|
url: "status",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "id",
|
|
description: Some(
|
|
"ID of the search job. If not specified, all search jobs are returned",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "id",
|
|
description: Some(
|
|
"ID of the search job",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "status",
|
|
description: Some(
|
|
"Current status of the search job (either Running or Stopped)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "total",
|
|
description: Some(
|
|
"Total number of results. If the status is Running this number may contineu to increase",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: true,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "results",
|
|
description: Some(
|
|
"The response is a JSON object with the following fields\n\n\n\n\nExample:\n\n```JSON\n{\n \"results\": [\n {\n \"descrLink\": \"http://www.legittorrents.info/index.php?page=torrent-details&id=8d5f512e1acb687029b8d7cc6c5a84dce51d7a41\",\n \"fileName\": \"Ubuntu-10.04-32bit-NeTV.ova\",\n \"fileSize\": -1,\n \"fileUrl\": \"http://www.legittorrents.info/download.php?id=8d5f512e1acb687029b8d7cc6c5a84dce51d7a41&f=Ubuntu-10.04-32bit-NeTV.ova.torrent\",\n \"nbLeechers\": 1,\n \"nbSeeders\": 0,\n \"siteUrl\": \"http://www.legittorrents.info\"\n },\n {\n \"descrLink\": \"http://www.legittorrents.info/index.php?page=torrent-details&id=d5179f53e105dc2c2401bcfaa0c2c4936a6aa475\",\n \"fileName\": \"mangOH-Legato-17_06-Ubuntu-16_04.ova\",\n \"fileSize\": -1,\n \"fileUrl\": \"http://www.legittorrents.info/download.php?id=d5179f53e105dc2c2401bcfaa0c2c4936a6aa475&f=mangOH-Legato-17_06-Ubuntu-16_04.ova.torrent\",\n \"nbLeechers\": 0,\n \"nbSeeders\": 59,\n \"siteUrl\": \"http://www.legittorrents.info\"\n }\n ],\n \"status\": \"Running\",\n \"total\": 2\n}\n```",
|
|
),
|
|
url: "results",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "id",
|
|
description: Some(
|
|
"ID of the search job",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "limit",
|
|
description: Some(
|
|
"max number of results to return. 0 or negative means no limit",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "offset",
|
|
description: Some(
|
|
"result to start at. A negative number means count backwards (e.g. -2 returns the 2 most recent results)",
|
|
),
|
|
is_optional: true,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
TypeWithName {
|
|
name: "Result",
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "descrLink",
|
|
description: Some(
|
|
"URL of the torrent's description page",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "fileName",
|
|
description: Some(
|
|
"Name of the file",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "fileSize",
|
|
description: Some(
|
|
"Size of the file in Bytes",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "fileUrl",
|
|
description: Some(
|
|
"Torrent download link (usually either .torrent file or magnet link)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "nbLeechers",
|
|
description: Some(
|
|
"Number of leechers",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "nbSeeders",
|
|
description: Some(
|
|
"Number of seeders",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "siteUrl",
|
|
description: Some(
|
|
"URL of the torrent site",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
),
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "results",
|
|
description: Some(
|
|
"Array of result objects- see table below",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
ref_type: String(
|
|
"Result",
|
|
),
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "status",
|
|
description: Some(
|
|
"Current status of the search job (either Running or Stopped)",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Number(
|
|
TypeInfo {
|
|
name: "total",
|
|
description: Some(
|
|
"Total number of results. If the status is Running this number may continue to increase",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "delete",
|
|
description: None,
|
|
url: "delete",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
Number(
|
|
TypeInfo {
|
|
name: "id",
|
|
description: Some(
|
|
"ID of the search job",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "plugins",
|
|
description: Some(
|
|
"The response is a JSON array of objects containing the following fields\n\n\n```JSON\n[\n {\n \"enabled\": true,\n \"fullName\": \"Legit Torrents\",\n \"name\": \"legittorrents\",\n \"supportedCategories\": [{\n \"id\": \"all\",\n \"name\": \"All categories\"\n }, {\n \"id\": \"anime\",\n \"name\": \"Anime\"\n }, {\n \"id\": \"books\",\n \"name\": \"Books\"\n }, {\n \"id\": \"games\",\n \"name\": \"Games\"\n }, {\n \"id\": \"movies\",\n \"name\": \"Movies\"\n }, {\n \"id\": \"music\",\n \"name\": \"Music\"\n }, {\n \"id\": \"tv\",\n \"name\": \"TV shows\"\n }],\n \"url\": \"http://www.legittorrents.info\",\n \"version\": \"2.3\"\n }\n]\n```",
|
|
),
|
|
url: "plugins",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Object(
|
|
TypeWithName {
|
|
name: "Category",
|
|
types: [
|
|
String(
|
|
TypeInfo {
|
|
name: "id",
|
|
description: Some(
|
|
"Id",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "name",
|
|
description: Some(
|
|
"Name",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
),
|
|
Response(
|
|
TypeWithoutName {
|
|
types: [
|
|
Bool(
|
|
TypeInfo {
|
|
name: "enabled",
|
|
description: Some(
|
|
"Whether the plugin is enabled",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "fullName",
|
|
description: Some(
|
|
"Full name of the plugin",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "name",
|
|
description: Some(
|
|
"Short name of the plugin",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
Object(
|
|
Object {
|
|
type_info: TypeInfo {
|
|
name: "supportedCategories",
|
|
description: Some(
|
|
"List of category objects",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
ref_type: String(
|
|
"Category",
|
|
),
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "url",
|
|
description: Some(
|
|
"URL of the torrent site",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
String(
|
|
TypeInfo {
|
|
name: "version",
|
|
description: Some(
|
|
"Installed version of the plugin",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: true,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "installPlugin",
|
|
description: None,
|
|
url: "installPlugin",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "sources",
|
|
description: Some(
|
|
"Url or file path of the plugin to install (e.g. \"[https://raw.githubusercontent.com/qbittorrent/search-plugins/master/nova3/engines/legittorrents.py](https://raw.githubusercontent.com/qbittorrent/search-plugins/master/nova3/engines/legittorrents.py)\"). Supports multiple sources separated by a pipe",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "uninstallPlugin",
|
|
description: None,
|
|
url: "uninstallPlugin",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "names",
|
|
description: Some(
|
|
"Name of the plugin to uninstall (e.g. \"legittorrents\"). Supports multiple names separated by a pipe",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "enablePlugin",
|
|
description: None,
|
|
url: "enablePlugin",
|
|
types: CompositeTypes {
|
|
composite_types: [
|
|
Parameters(
|
|
TypeWithoutName {
|
|
types: [
|
|
JoinedStringArray(
|
|
TypeInfo {
|
|
name: "names",
|
|
description: Some(
|
|
"Name of the plugin to enable/disable (e.g. \"legittorrents\"). Supports multiple names separated by a pipe",
|
|
),
|
|
is_optional: false,
|
|
is_list: true,
|
|
},
|
|
"|",
|
|
),
|
|
Bool(
|
|
TypeInfo {
|
|
name: "enable",
|
|
description: Some(
|
|
"Whether the plugins should be enabled",
|
|
),
|
|
is_optional: false,
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
is_list: false,
|
|
},
|
|
),
|
|
],
|
|
},
|
|
},
|
|
ApiMethod {
|
|
name: "updatePlugins",
|
|
description: None,
|
|
url: "updatePlugins",
|
|
types: CompositeTypes {
|
|
composite_types: [],
|
|
},
|
|
},
|
|
],
|
|
description: Some(
|
|
"All Search API methods are under \"search\", e.g.: `/api/v2/search/methodName`.",
|
|
),
|
|
url: "search",
|
|
},
|
|
] |