mirror of
https://github.com/unshackle-dl/unshackle.git
synced 2026-12-05 07:25:08 +00:00
Deployed 87b58190 with MkDocs version: 1.6.1
This commit is contained in:
File diff suppressed because it is too large
Load Diff
+725
-650
File diff suppressed because it is too large
Load Diff
+583
-1183
File diff suppressed because it is too large
Load Diff
+241
-163
@@ -13,10 +13,10 @@
|
||||
<link rel="canonical" href="https://docs.unshackle.dev/dev/rest-api/errors/">
|
||||
|
||||
|
||||
<link rel="prev" href="../remote-sessions/">
|
||||
<link rel="prev" href="../job-lifecycle/">
|
||||
|
||||
|
||||
<link rel="next" href="../../../reference/api/service/">
|
||||
<link rel="next" href="../remote-sessions/">
|
||||
|
||||
|
||||
|
||||
@@ -347,28 +347,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-tabs__item">
|
||||
<a href="../../../reference/api/service/" class="md-tabs__link">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
API Reference
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</nav>
|
||||
@@ -614,6 +592,8 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -886,6 +866,171 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_3_9" >
|
||||
|
||||
|
||||
<div class="md-nav__link md-nav__container">
|
||||
<a href="../" class="md-nav__link ">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Server
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
|
||||
|
||||
<label class="md-nav__link " for="__nav_3_9" id="__nav_3_9_label" tabindex="0">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
</div>
|
||||
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_3_9_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_3_9">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
|
||||
|
||||
Server
|
||||
|
||||
|
||||
</label>
|
||||
<ul class="md-nav__list" data-md-scrollfix>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../authentication/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Authentication
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../dashboard/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Dashboard
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../../../guide/remote-sessions/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Remote Sessions
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
@@ -1078,7 +1223,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Output & Naming
|
||||
Output & Naming Options
|
||||
|
||||
|
||||
|
||||
@@ -1162,7 +1307,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Key Vaults
|
||||
Key Vault Options
|
||||
|
||||
|
||||
|
||||
@@ -1282,6 +1427,8 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1400,14 +1547,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1436,9 +1575,8 @@
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_5_3" checked>
|
||||
|
||||
|
||||
<div class="md-nav__link md-nav__container">
|
||||
<a href="../" class="md-nav__link ">
|
||||
|
||||
<label class="md-nav__link" for="__nav_5_3" id="__nav_5_3_label" tabindex="">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
@@ -1452,14 +1590,8 @@
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
|
||||
|
||||
<label class="md-nav__link " for="__nav_5_3" id="__nav_5_3_label" tabindex="">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
</div>
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_5_3_label" aria-expanded="true">
|
||||
<label class="md-nav__title" for="__nav_5_3">
|
||||
@@ -1473,8 +1605,6 @@
|
||||
<ul class="md-nav__list" data-md-scrollfix>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1488,35 +1618,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Quick Start
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../authentication/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Authentication
|
||||
REST API Quick Start
|
||||
|
||||
|
||||
|
||||
@@ -1590,62 +1692,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../dashboard/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Dashboard
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../remote-sessions/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Remote Sessions
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1872,9 +1918,29 @@
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../remote-sessions/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Remote Session Protocol
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
@@ -1886,9 +1952,10 @@
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1911,25 +1978,28 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_6" >
|
||||
|
||||
|
||||
<label class="md-nav__link" for="__nav_6" id="__nav_6_label" tabindex="0">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--section md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_5_4" >
|
||||
|
||||
|
||||
<label class="md-nav__link" for="__nav_5_4" id="__nav_5_4_label" tabindex="">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
API Reference
|
||||
Python API
|
||||
|
||||
|
||||
|
||||
@@ -1940,12 +2010,12 @@
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
<nav class="md-nav" data-md-level="1" aria-labelledby="__nav_6_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_6">
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_5_4_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_5_4">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
|
||||
|
||||
API Reference
|
||||
Python API
|
||||
|
||||
|
||||
</label>
|
||||
@@ -2097,6 +2167,14 @@
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
@@ -2307,7 +2385,7 @@ that carries a machine-readable <strong>error code</strong>, a human-readable <s
|
||||
matching <strong>HTTP status</strong>. This page documents that format and catalogues every error
|
||||
code the server can send.</p>
|
||||
<p>If you write a client against the API, read this page alongside the endpoint
|
||||
reference. Each endpoint lists the specific codes it raises, and this page gives the
|
||||
reference. The section of each endpoint names the specific codes it raises, and this page gives the
|
||||
meanings of those codes.</p>
|
||||
<div class="admonition note">
|
||||
<p class="admonition-title">Where this comes from</p>
|
||||
@@ -2405,7 +2483,7 @@ stable across releases.</p>
|
||||
<div class="language-text highlight"><pre><span></span><code><span id="__span-1-1"><a id="__codelineno-1-1" name="__codelineno-1-1" href="#__codelineno-1-1"></a>Error ref 7f3a2c: SERVICE_ERROR 422 POST /api/session/<id>/license service=EXAMPLE user=alice: Licence request failed: ...
|
||||
</span></code></pre></div>
|
||||
<p>Search the server log for <code>Error ref <ref></code>. The handler's traceback, when there is one,
|
||||
is directly above that line. The <a href="../dashboard/">developer dashboard</a> log view also shows it.</p>
|
||||
is directly above that line. The <a href="../dashboard/">server dashboard</a> log view also shows it.</p>
|
||||
<h3 id="the-details-object">The <code>details</code> object<a class="headerlink" href="#the-details-object" title="Permanent link">¶</a></h3>
|
||||
<p>When present, <code>details</code> carries extra context specific to the error. It is only
|
||||
included when it is non-empty, so a client must treat a missing <code>details</code> as "no
|
||||
@@ -2511,7 +2589,7 @@ while the server restarts.</p>
|
||||
<tr>
|
||||
<td><code>SESSION_NOT_FOUND</code></td>
|
||||
<td>404</td>
|
||||
<td>The remote-dl session does not exist or has expired.</td>
|
||||
<td>The remote session does not exist or has expired.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>TRACK_NOT_FOUND</code></td>
|
||||
@@ -2536,7 +2614,7 @@ while the server restarts.</p>
|
||||
<tr>
|
||||
<td><code>DRM_ERROR</code></td>
|
||||
<td>422</td>
|
||||
<td>DRM or license acquisition failed.</td>
|
||||
<td>DRM or licence acquisition failed.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>RATE_LIMITED</code></td>
|
||||
@@ -2713,9 +2791,9 @@ body that uses an integer <code>status</code> and no <code>error_code</code> or
|
||||
(integer <code>status</code>, no <code>error_code</code>).</p>
|
||||
</div>
|
||||
<h2 id="late-failures-with-status-200">Late failures with status <code>200</code><a class="headerlink" href="#late-failures-with-status-200" title="Permanent link">¶</a></h2>
|
||||
<p>The remote session <code>titles</code>, <code>tracks</code> and <code>license</code> routes send status <code>200</code> and the headers
|
||||
<p>The remote session <code>titles</code>, <code>tracks</code>, <code>segments</code> and <code>license</code> routes send status <code>200</code> and the headers
|
||||
when the work takes longer than 30 seconds. They then send a newline every 30 seconds to keep
|
||||
the connection open. See <a href="../endpoints/#slow-responses">Slow responses</a>. A failure after that
|
||||
the connection open. See <a href="../remote-sessions/#slow-responses">Slow responses</a>. A failure after that
|
||||
time arrives as the standard error body, but with status <code>200</code>. The body has no field for the
|
||||
HTTP status that the error would otherwise have. <code>error_code</code> and <code>retryable</code> stay in the body.</p>
|
||||
<div class="admonition warning">
|
||||
@@ -2770,7 +2848,7 @@ debugging, never on a server reachable by untrusted clients.</p>
|
||||
</ol>
|
||||
<div class="admonition note">
|
||||
<p class="admonition-title">Reference consumer</p>
|
||||
<p>unshackle's own remote-download client treats any status of <code>400</code> or above as
|
||||
<p>unshackle's own remote session client treats any status of <code>400</code> or above as
|
||||
fatal, and a <code>200</code> body with <code>"status": "error"</code> and an <code>error_code</code> too: it logs
|
||||
<code>Server error [<error_code>]: <message></code> and exits. It retries a request once,
|
||||
after one second, only when a <code>502</code>, <code>503</code> or <code>504</code> arrives with a body that is
|
||||
@@ -2815,7 +2893,7 @@ handling.</p>
|
||||
<nav class="md-footer__inner md-grid" aria-label="Footer" >
|
||||
|
||||
|
||||
<a href="../remote-sessions/" class="md-footer__link md-footer__link--prev" aria-label="Previous: Remote Sessions">
|
||||
<a href="../job-lifecycle/" class="md-footer__link md-footer__link--prev" aria-label="Previous: Job Lifecycle">
|
||||
<div class="md-footer__button md-icon">
|
||||
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M20 11v2H8l5.5 5.5-1.42 1.42L4.16 12l7.92-7.92L13.5 5.5 8 11z"/></svg>
|
||||
@@ -2825,20 +2903,20 @@ handling.</p>
|
||||
Previous
|
||||
</span>
|
||||
<div class="md-ellipsis">
|
||||
Remote Sessions
|
||||
Job Lifecycle
|
||||
</div>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
|
||||
|
||||
<a href="../../../reference/api/service/" class="md-footer__link md-footer__link--next" aria-label="Next: Service">
|
||||
<a href="../remote-sessions/" class="md-footer__link md-footer__link--next" aria-label="Next: Remote Session Protocol">
|
||||
<div class="md-footer__title">
|
||||
<span class="md-footer__direction">
|
||||
Next
|
||||
</span>
|
||||
<div class="md-ellipsis">
|
||||
Service
|
||||
Remote Session Protocol
|
||||
</div>
|
||||
</div>
|
||||
<div class="md-footer__button md-icon">
|
||||
|
||||
+288
-278
@@ -13,10 +13,10 @@
|
||||
<link rel="canonical" href="https://docs.unshackle.dev/dev/rest-api/">
|
||||
|
||||
|
||||
<link rel="prev" href="../service-architecture/">
|
||||
<link rel="prev" href="../../guide/troubleshooting/">
|
||||
|
||||
|
||||
<link rel="next" href="quickstart/">
|
||||
<link rel="next" href="authentication/">
|
||||
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
|
||||
|
||||
|
||||
<title>Overview - unshackle</title>
|
||||
<title>Server Overview - unshackle</title>
|
||||
|
||||
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
<div data-md-component="skip">
|
||||
|
||||
|
||||
<a href="#rest-api-overview" class="md-skip">
|
||||
<a href="#server-overview" class="md-skip">
|
||||
Skip to content
|
||||
</a>
|
||||
|
||||
@@ -116,7 +116,7 @@
|
||||
<div class="md-header__topic" data-md-component="header-topic">
|
||||
<span class="md-ellipsis">
|
||||
|
||||
Overview
|
||||
Server Overview
|
||||
|
||||
</span>
|
||||
</div>
|
||||
@@ -283,10 +283,12 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-tabs__item">
|
||||
<li class="md-tabs__item md-tabs__item--active">
|
||||
<a href="../../guide/downloading/" class="md-tabs__link">
|
||||
|
||||
|
||||
@@ -327,12 +329,10 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-tabs__item md-tabs__item--active">
|
||||
<li class="md-tabs__item">
|
||||
<a href="../creating-a-service/" class="md-tabs__link">
|
||||
|
||||
|
||||
@@ -347,28 +347,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-tabs__item">
|
||||
<a href="../../reference/api/service/" class="md-tabs__link">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
API Reference
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</nav>
|
||||
@@ -596,6 +574,8 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -614,26 +594,31 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--nested">
|
||||
<li class="md-nav__item md-nav__item--active md-nav__item--section md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_3" >
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_3" checked>
|
||||
|
||||
|
||||
<label class="md-nav__link" for="__nav_3" id="__nav_3_label" tabindex="0">
|
||||
<label class="md-nav__link" for="__nav_3" id="__nav_3_label" tabindex="">
|
||||
|
||||
|
||||
|
||||
@@ -651,7 +636,7 @@
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
<nav class="md-nav" data-md-level="1" aria-labelledby="__nav_3_label" aria-expanded="false">
|
||||
<nav class="md-nav" data-md-level="1" aria-labelledby="__nav_3_label" aria-expanded="true">
|
||||
<label class="md-nav__title" for="__nav_3">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
|
||||
@@ -886,6 +871,176 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--active md-nav__item--section md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_3_9" checked>
|
||||
|
||||
|
||||
<div class="md-nav__link md-nav__container">
|
||||
<a href="./" class="md-nav__link md-nav__link--active">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Server
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
|
||||
|
||||
<label class="md-nav__link md-nav__link--active" for="__nav_3_9" id="__nav_3_9_label" tabindex="">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
</div>
|
||||
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_3_9_label" aria-expanded="true">
|
||||
<label class="md-nav__title" for="__nav_3_9">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
|
||||
|
||||
Server
|
||||
|
||||
|
||||
</label>
|
||||
<ul class="md-nav__list" data-md-scrollfix>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="authentication/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Authentication
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="dashboard/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Dashboard
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../../guide/remote-sessions/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Remote Sessions
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
@@ -1078,7 +1233,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Output & Naming
|
||||
Output & Naming Options
|
||||
|
||||
|
||||
|
||||
@@ -1162,7 +1317,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Key Vaults
|
||||
Key Vault Options
|
||||
|
||||
|
||||
|
||||
@@ -1271,8 +1426,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1284,26 +1437,25 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--active md-nav__item--section md-nav__item--nested">
|
||||
<li class="md-nav__item md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_5" checked>
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_5" >
|
||||
|
||||
|
||||
<label class="md-nav__link" for="__nav_5" id="__nav_5_label" tabindex="">
|
||||
<label class="md-nav__link" for="__nav_5" id="__nav_5_label" tabindex="0">
|
||||
|
||||
|
||||
|
||||
@@ -1321,7 +1473,7 @@
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
<nav class="md-nav" data-md-level="1" aria-labelledby="__nav_5_label" aria-expanded="true">
|
||||
<nav class="md-nav" data-md-level="1" aria-labelledby="__nav_5_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_5">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
|
||||
@@ -1392,53 +1544,39 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_5_3" >
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--active md-nav__item--section md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_5_3" checked>
|
||||
|
||||
|
||||
<div class="md-nav__link md-nav__container">
|
||||
<a href="./" class="md-nav__link md-nav__link--active">
|
||||
|
||||
<label class="md-nav__link" for="__nav_5_3" id="__nav_5_3_label" tabindex="0">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
@@ -1452,16 +1590,10 @@
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
|
||||
|
||||
<label class="md-nav__link md-nav__link--active" for="__nav_5_3" id="__nav_5_3_label" tabindex="">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
</div>
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_5_3_label" aria-expanded="true">
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_5_3_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_5_3">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
|
||||
@@ -1473,8 +1605,6 @@
|
||||
<ul class="md-nav__list" data-md-scrollfix>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1488,35 +1618,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Quick Start
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="authentication/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Authentication
|
||||
REST API Quick Start
|
||||
|
||||
|
||||
|
||||
@@ -1593,14 +1695,14 @@
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="dashboard/" class="md-nav__link">
|
||||
<a href="errors/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Dashboard
|
||||
Error Responses
|
||||
|
||||
|
||||
|
||||
@@ -1628,7 +1730,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Remote Sessions
|
||||
Remote Session Protocol
|
||||
|
||||
|
||||
|
||||
@@ -1642,55 +1744,20 @@
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="errors/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Error Responses
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1717,17 +1784,17 @@
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_6" >
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_5_4" >
|
||||
|
||||
|
||||
<label class="md-nav__link" for="__nav_6" id="__nav_6_label" tabindex="0">
|
||||
<label class="md-nav__link" for="__nav_5_4" id="__nav_5_4_label" tabindex="0">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
API Reference
|
||||
Python API
|
||||
|
||||
|
||||
|
||||
@@ -1738,12 +1805,12 @@
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
<nav class="md-nav" data-md-level="1" aria-labelledby="__nav_6_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_6">
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_5_4_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_5_4">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
|
||||
|
||||
API Reference
|
||||
Python API
|
||||
|
||||
|
||||
</label>
|
||||
@@ -1895,6 +1962,14 @@
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
@@ -2040,10 +2115,10 @@
|
||||
</li>
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="#remote-download-sessions" class="md-nav__link">
|
||||
<a href="#remote-sessions" class="md-nav__link">
|
||||
<span class="md-ellipsis">
|
||||
|
||||
Remote-download sessions
|
||||
Remote sessions
|
||||
|
||||
</span>
|
||||
</a>
|
||||
@@ -2097,20 +2172,19 @@
|
||||
|
||||
|
||||
|
||||
<h1 id="rest-api-overview">REST API Overview<a class="headerlink" href="#rest-api-overview" title="Permanent link">¶</a></h1>
|
||||
<p>unshackle ships with a built-in HTTP server. Alongside the command-line tool, you
|
||||
can operate <code>unshackle serve</code> and drive the same download engine over a REST API:
|
||||
searching services, listing titles and tracks, queueing downloads, watching live
|
||||
progress, and browsing history, all as JSON over HTTP.</p>
|
||||
<p>This page explains what the API is for, how to start the server, where it listens,
|
||||
and how the endpoints are organised. Later pages cover each area in depth.</p>
|
||||
<h1 id="server-overview">Server Overview<a class="headerlink" href="#server-overview" title="Permanent link">¶</a></h1>
|
||||
<p><code>unshackle serve</code> starts an HTTP server. The server can give the download engine of the
|
||||
command-line tool as a REST API, and your CDM devices to other machines. The
|
||||
<a href="#server-modes">server modes</a> select which of the two it gives.</p>
|
||||
<p>This page is for the operator of the server. The other pages of this section tell you how
|
||||
to set the <a href="authentication/">API keys</a>, how to watch the server from the
|
||||
<a href="dashboard/">dashboard</a>, and how a <a href="../../guide/remote-sessions/"><code>dl --remote</code> client</a>
|
||||
connects to it.</p>
|
||||
<div class="admonition info">
|
||||
<p class="admonition-title">Who this section is for</p>
|
||||
<p>The REST API is for people who make automation, dashboards, or remote
|
||||
clients on top of unshackle. If you only download the occasional title, the
|
||||
<a href="../../guide/cli-reference/">command-line tool</a> does everything the API does
|
||||
and is simpler to use. Reach for the API when you want a long-running service, a
|
||||
job queue, or a web front-end.</p>
|
||||
<p class="admonition-title">Pages for client developers</p>
|
||||
<p>To write a client for the REST API, start with the <a href="quickstart/">REST API Quick Start</a>.
|
||||
<a href="#where-to-go-next">Where to go next</a> lists the other client pages. To download a title,
|
||||
you do not need the server: the <a href="../../guide/cli-reference/">command-line tool</a> is simpler.</p>
|
||||
</div>
|
||||
<h2 id="what-the-api-is-for">What the API is for<a class="headerlink" href="#what-the-api-is-for" title="Permanent link">¶</a></h2>
|
||||
<p>The server exposes the same capabilities as the <code>dl</code> command, but as discrete HTTP
|
||||
@@ -2124,10 +2198,10 @@ calls you can script against:</p>
|
||||
<li><strong>History and housekeeping</strong>: read the log of finished jobs, inspect the server's
|
||||
effective (redacted) configuration, examine external tool versions, and clear caches
|
||||
or temp files.</li>
|
||||
<li><strong>Remote-download sessions</strong>: a thin local client can authenticate against a
|
||||
service <em>on the server</em>, then pull titles, tracks, and segment info back, and proxy
|
||||
<li><strong>Remote sessions</strong>: a thin local client can authenticate against a
|
||||
service <em>on the server</em>, then pull titles, tracks, and segment info back, and relay
|
||||
DRM licensing. This is how one machine with the credentials and CDMs can serve
|
||||
downloads to another. See <a href="remote-sessions/">Remote Sessions</a>.</li>
|
||||
downloads to another. See the <a href="remote-sessions/">remote session protocol</a>.</li>
|
||||
</ul>
|
||||
<p>Because every download runs as a queued job in a separate job worker process, the API is
|
||||
well suited to running unattended: submit work, come back later, and read the result.</p>
|
||||
@@ -2194,7 +2268,7 @@ how the <code>X-Secret-Key</code> header works.</p>
|
||||
<tr>
|
||||
<td><code>--remote-only</code></td>
|
||||
<td>off</td>
|
||||
<td>Expose only the remote-session subset of routes. Implies <code>--api-only</code>.</td>
|
||||
<td>Expose only the <a href="remote-sessions/#routes">remote session routes</a>. Implies <code>--api-only</code>.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>--debug-api</code></td>
|
||||
@@ -2235,8 +2309,7 @@ This is the mode you get when you operate <code>unshackle serve</code> with no m
|
||||
Authentication uses the single configured API key (or none, with <code>--no-key</code>).</p>
|
||||
</div>
|
||||
<div class="tabbed-block">
|
||||
<p>The server mounts only the remote-session subset of routes (health, services, search,
|
||||
and everything under <code>/api/session/*</code>). This mode implies <code>--api-only</code>, and the
|
||||
<p>The server mounts only the <a href="remote-sessions/#routes">remote session routes</a>. This mode implies <code>--api-only</code>, and the
|
||||
interactive Swagger UI is <strong>not</strong> mounted.</p>
|
||||
</div>
|
||||
<div class="tabbed-block">
|
||||
@@ -2437,7 +2510,9 @@ request and response in full.</p>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<h3 id="remote-download-sessions">Remote-download sessions<a class="headerlink" href="#remote-download-sessions" title="Permanent link">¶</a></h3>
|
||||
<h3 id="remote-sessions">Remote sessions<a class="headerlink" href="#remote-sessions" title="Permanent link">¶</a></h3>
|
||||
<p>The <code>/api/session/*</code>, <code>/api/tunnel</code> and <code>/api/tunnel/check</code> routes carry the remote sessions of
|
||||
<code>dl --remote</code>. The <a href="remote-sessions/#routes">remote session protocol</a> lists each route.</p>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
@@ -2448,86 +2523,21 @@ request and response in full.</p>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><code>POST</code></td>
|
||||
<td><code>/api/session/create</code></td>
|
||||
<td>Start a server-side, authenticated service session.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>GET</code></td>
|
||||
<td><code>/api/session/{session_id}</code></td>
|
||||
<td>Remote session info and time-to-live.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>DELETE</code></td>
|
||||
<td><code>/api/session/{session_id}</code></td>
|
||||
<td>Tear down a session.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>GET</code></td>
|
||||
<td><code>/api/session/{session_id}/titles</code></td>
|
||||
<td>Titles for the session's title ID.</td>
|
||||
<td><code>/api/remote/logins</code></td>
|
||||
<td>The logins of a <a href="endpoints/#remote-services-relay">relayed</a> list call that wait on you.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>POST</code></td>
|
||||
<td><code>/api/session/{session_id}/tracks</code></td>
|
||||
<td>Tracks (with URLs) for a chosen title.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>POST</code></td>
|
||||
<td><code>/api/session/{session_id}/segments</code></td>
|
||||
<td>Per-track segment/download details.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>POST</code></td>
|
||||
<td><code>/api/session/{session_id}/segment_filter</code></td>
|
||||
<td>Server-side HLS segment filter results for one track.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>POST</code></td>
|
||||
<td><code>/api/session/{session_id}/samples</code></td>
|
||||
<td>Server-side cbcs sample decryption for one track.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>POST</code></td>
|
||||
<td><code>/api/session/{session_id}/license</code></td>
|
||||
<td>Proxy or server-side DRM licensing.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>POST</code></td>
|
||||
<td><code>/api/session/{session_id}/keys</code></td>
|
||||
<td>Store the content keys the client proved on a track.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>POST</code></td>
|
||||
<td><code>/api/session/{session_id}/keys/bad</code></td>
|
||||
<td>Report a server-vault content key that did not decrypt.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>GET</code></td>
|
||||
<td><code>/api/session/{session_id}/channel</code></td>
|
||||
<td>WebSocket of the remote session channel: prompts, CDM calls, logs, login state.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>GET</code></td>
|
||||
<td><code>/api/session/{session_id}/logs</code></td>
|
||||
<td>Drain the service's server-side log output.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>GET</code></td>
|
||||
<td><code>/api/session/{session_id}/prompt</code></td>
|
||||
<td>Poll for interactive auth status/prompt.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>POST</code></td>
|
||||
<td><code>/api/session/{session_id}/prompt</code></td>
|
||||
<td>Submit an answer to an auth prompt.</td>
|
||||
<td><code>/api/remote/logins/{login_id}/input</code></td>
|
||||
<td>Answer the prompt of such a login.</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="admonition note">
|
||||
<p class="admonition-title">Remote-only routes</p>
|
||||
<p>The health, services, search, and <code>/api/session/*</code> routes are the ones exposed
|
||||
when the server runs with <code>--remote-only</code>. Everything else (downloads, jobs,
|
||||
<p>A server that runs with <code>--remote-only</code> exposes only the
|
||||
<a href="remote-sessions/#routes">remote session routes</a> and the dashboard routes. Everything else (downloads, jobs,
|
||||
history, config, maintenance) is only available in the full or <code>--api-only</code> modes.</p>
|
||||
</div>
|
||||
<h2 id="authentication-in-one-line">Authentication in one line<a class="headerlink" href="#authentication-in-one-line" title="Permanent link">¶</a></h2>
|
||||
@@ -2543,7 +2553,7 @@ the full model, including per-key service allowlists.</p>
|
||||
<h2 id="where-to-go-next">Where to go next<a class="headerlink" href="#where-to-go-next" title="Permanent link">¶</a></h2>
|
||||
<div class="grid cards">
|
||||
<ul>
|
||||
<li><strong><a href="quickstart/">Quick Start</a></strong>: start the server, set an API key, and operate your
|
||||
<li><strong><a href="quickstart/">REST API Quick Start</a></strong>: start the server, set an API key, and operate your
|
||||
first end-to-end download over the API.</li>
|
||||
<li><strong><a href="authentication/">Authentication</a></strong>: the <code>X-Secret-Key</code> header, <code>--no-key</code>,
|
||||
per-key service allowlists, and CORS.</li>
|
||||
@@ -2551,8 +2561,8 @@ the full model, including per-key service allowlists.</p>
|
||||
shape, endpoint by endpoint.</li>
|
||||
<li><strong><a href="job-lifecycle/">Job Lifecycle</a></strong>: how a download moves from <code>queued</code> to a
|
||||
terminal state, live progress, cancellation, and retries.</li>
|
||||
<li><strong><a href="remote-sessions/">Remote Sessions</a></strong>: the <code>/api/session/*</code> flow for driving a
|
||||
service from a thin remote client.</li>
|
||||
<li><strong><a href="remote-sessions/">Remote Session Protocol</a></strong>: the routes, login states,
|
||||
licensing modes and message shapes of a remote session.</li>
|
||||
<li><strong><a href="errors/">Error Responses</a></strong>: the standard error envelope, error codes, and
|
||||
their HTTP statuses.</li>
|
||||
</ul>
|
||||
@@ -2594,7 +2604,7 @@ the full model, including per-key service allowlists.</p>
|
||||
<nav class="md-footer__inner md-grid" aria-label="Footer" >
|
||||
|
||||
|
||||
<a href="../service-architecture/" class="md-footer__link md-footer__link--prev" aria-label="Previous: Service Architecture">
|
||||
<a href="../../guide/troubleshooting/" class="md-footer__link md-footer__link--prev" aria-label="Previous: Troubleshooting">
|
||||
<div class="md-footer__button md-icon">
|
||||
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M20 11v2H8l5.5 5.5-1.42 1.42L4.16 12l7.92-7.92L13.5 5.5 8 11z"/></svg>
|
||||
@@ -2604,20 +2614,20 @@ the full model, including per-key service allowlists.</p>
|
||||
Previous
|
||||
</span>
|
||||
<div class="md-ellipsis">
|
||||
Service Architecture
|
||||
Troubleshooting
|
||||
</div>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
|
||||
|
||||
<a href="quickstart/" class="md-footer__link md-footer__link--next" aria-label="Next: Quick Start">
|
||||
<a href="authentication/" class="md-footer__link md-footer__link--next" aria-label="Next: Authentication">
|
||||
<div class="md-footer__title">
|
||||
<span class="md-footer__direction">
|
||||
Next
|
||||
</span>
|
||||
<div class="md-ellipsis">
|
||||
Quick Start
|
||||
Authentication
|
||||
</div>
|
||||
</div>
|
||||
<div class="md-footer__button md-icon">
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<link rel="prev" href="../endpoints/">
|
||||
|
||||
|
||||
<link rel="next" href="../dashboard/">
|
||||
<link rel="next" href="../errors/">
|
||||
|
||||
|
||||
|
||||
@@ -347,28 +347,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-tabs__item">
|
||||
<a href="../../../reference/api/service/" class="md-tabs__link">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
API Reference
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</nav>
|
||||
@@ -614,6 +592,8 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -886,6 +866,171 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_3_9" >
|
||||
|
||||
|
||||
<div class="md-nav__link md-nav__container">
|
||||
<a href="../" class="md-nav__link ">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Server
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
|
||||
|
||||
<label class="md-nav__link " for="__nav_3_9" id="__nav_3_9_label" tabindex="0">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
</div>
|
||||
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_3_9_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_3_9">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
|
||||
|
||||
Server
|
||||
|
||||
|
||||
</label>
|
||||
<ul class="md-nav__list" data-md-scrollfix>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../authentication/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Authentication
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../dashboard/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Dashboard
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../../../guide/remote-sessions/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Remote Sessions
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
@@ -1078,7 +1223,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Output & Naming
|
||||
Output & Naming Options
|
||||
|
||||
|
||||
|
||||
@@ -1162,7 +1307,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Key Vaults
|
||||
Key Vault Options
|
||||
|
||||
|
||||
|
||||
@@ -1282,6 +1427,8 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1400,14 +1547,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1436,9 +1575,8 @@
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_5_3" checked>
|
||||
|
||||
|
||||
<div class="md-nav__link md-nav__container">
|
||||
<a href="../" class="md-nav__link ">
|
||||
|
||||
<label class="md-nav__link" for="__nav_5_3" id="__nav_5_3_label" tabindex="">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
@@ -1452,14 +1590,8 @@
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
|
||||
|
||||
<label class="md-nav__link " for="__nav_5_3" id="__nav_5_3_label" tabindex="">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
</div>
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_5_3_label" aria-expanded="true">
|
||||
<label class="md-nav__title" for="__nav_5_3">
|
||||
@@ -1473,8 +1605,6 @@
|
||||
<ul class="md-nav__list" data-md-scrollfix>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1488,35 +1618,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Quick Start
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../authentication/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Authentication
|
||||
REST API Quick Start
|
||||
|
||||
|
||||
|
||||
@@ -1836,10 +1938,10 @@
|
||||
</li>
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="#secret-handling-in-serialized-jobs" class="md-nav__link">
|
||||
<a href="#secret-handling-in-serialised-jobs" class="md-nav__link">
|
||||
<span class="md-ellipsis">
|
||||
|
||||
Secret handling in serialized jobs
|
||||
Secret handling in serialised jobs
|
||||
|
||||
</span>
|
||||
</a>
|
||||
@@ -1878,14 +1980,14 @@
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../dashboard/" class="md-nav__link">
|
||||
<a href="../errors/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Dashboard
|
||||
Error Responses
|
||||
|
||||
|
||||
|
||||
@@ -1913,7 +2015,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Remote Sessions
|
||||
Remote Session Protocol
|
||||
|
||||
|
||||
|
||||
@@ -1927,55 +2029,20 @@
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../errors/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Error Responses
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1994,25 +2061,28 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_6" >
|
||||
|
||||
|
||||
<label class="md-nav__link" for="__nav_6" id="__nav_6_label" tabindex="0">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--section md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_5_4" >
|
||||
|
||||
|
||||
<label class="md-nav__link" for="__nav_5_4" id="__nav_5_4_label" tabindex="">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
API Reference
|
||||
Python API
|
||||
|
||||
|
||||
|
||||
@@ -2023,12 +2093,12 @@
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
<nav class="md-nav" data-md-level="1" aria-labelledby="__nav_6_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_6">
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_5_4_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_5_4">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
|
||||
|
||||
API Reference
|
||||
Python API
|
||||
|
||||
|
||||
</label>
|
||||
@@ -2180,6 +2250,14 @@
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
@@ -2419,10 +2497,10 @@
|
||||
</li>
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="#secret-handling-in-serialized-jobs" class="md-nav__link">
|
||||
<a href="#secret-handling-in-serialised-jobs" class="md-nav__link">
|
||||
<span class="md-ellipsis">
|
||||
|
||||
Secret handling in serialized jobs
|
||||
Secret handling in serialised jobs
|
||||
|
||||
</span>
|
||||
</a>
|
||||
@@ -2949,12 +3027,12 @@ it repackages and muxes. A track counts as done when it reaches a terminal state
|
||||
subprocess (escalating to <code>kill()</code> if it does not exit within 5 seconds), and raises
|
||||
a cancellation so the task unwinds. The subprocess model is what makes this a clean,
|
||||
immediate stop rather than a cooperative one. A job with the <code>remote</code> parameter first ends its
|
||||
<a href="../remote-sessions/#when-the-client-ends-a-remote-session">remote session</a>, in at most 4
|
||||
<a href="../../../guide/remote-sessions/#when-the-client-ends-a-remote-session">remote session</a>, in at most 4
|
||||
seconds, and runs no post-script after the cancel.</li>
|
||||
</ul>
|
||||
<h3 id="secret-handling-in-serialized-jobs">Secret handling in serialized jobs<a class="headerlink" href="#secret-handling-in-serialized-jobs" title="Permanent link">¶</a></h3>
|
||||
<h3 id="secret-handling-in-serialised-jobs">Secret handling in serialised jobs<a class="headerlink" href="#secret-handling-in-serialised-jobs" title="Permanent link">¶</a></h3>
|
||||
<p>Job parameters may carry secrets: a raw <code>user:pass</code> credential, or a proxy URL with
|
||||
embedded userinfo. Whenever the manager serializes a job (for an API response or the
|
||||
embedded userinfo. Whenever the manager serialises a job (for an API response or the
|
||||
history file), it masks the sensitive keys (<code>credential</code>, <code>credentials</code>, <code>password</code>,
|
||||
<code>token</code>, <code>api_key</code>) and strips userinfo from proxy URLs. The manager also scrubs
|
||||
free-text fields that a service might have leaked a secret into (<code>error_message</code>,
|
||||
@@ -2966,7 +3044,7 @@ or logs them.</p>
|
||||
<li><a href="../endpoints/">Endpoints</a>: the full request/response reference for every job endpoint.</li>
|
||||
<li><a href="../errors/">Error Responses</a>: the error envelope, codes, and HTTP statuses a failed job reports.</li>
|
||||
<li><a href="../authentication/">Authentication</a>: the <code>X-Secret-Key</code> header and per-key service allowlists that gate job creation and retry.</li>
|
||||
<li><a href="../../../guide/downloading/">Downloading</a>: the equivalent options on the <code>dl</code> command line.</li>
|
||||
<li><a href="../../../guide/cli-reference/#dl">CLI reference: <code>dl</code></a>: the equivalent options on the <code>dl</code> command line.</li>
|
||||
</ul>
|
||||
|
||||
|
||||
@@ -3022,13 +3100,13 @@ or logs them.</p>
|
||||
|
||||
|
||||
|
||||
<a href="../dashboard/" class="md-footer__link md-footer__link--next" aria-label="Next: Dashboard">
|
||||
<a href="../errors/" class="md-footer__link md-footer__link--next" aria-label="Next: Error Responses">
|
||||
<div class="md-footer__title">
|
||||
<span class="md-footer__direction">
|
||||
Next
|
||||
</span>
|
||||
<div class="md-ellipsis">
|
||||
Dashboard
|
||||
Error Responses
|
||||
</div>
|
||||
</div>
|
||||
<div class="md-footer__button md-icon">
|
||||
|
||||
+232
-225
@@ -13,10 +13,10 @@
|
||||
<link rel="canonical" href="https://docs.unshackle.dev/dev/rest-api/quickstart/">
|
||||
|
||||
|
||||
<link rel="prev" href="../">
|
||||
<link rel="prev" href="../../service-architecture/">
|
||||
|
||||
|
||||
<link rel="next" href="../authentication/">
|
||||
<link rel="next" href="../endpoints/">
|
||||
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
|
||||
|
||||
|
||||
<title>Quick Start - unshackle</title>
|
||||
<title>REST API Quick Start - unshackle</title>
|
||||
|
||||
|
||||
|
||||
@@ -116,7 +116,7 @@
|
||||
<div class="md-header__topic" data-md-component="header-topic">
|
||||
<span class="md-ellipsis">
|
||||
|
||||
Quick Start
|
||||
REST API Quick Start
|
||||
|
||||
</span>
|
||||
</div>
|
||||
@@ -347,28 +347,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-tabs__item">
|
||||
<a href="../../../reference/api/service/" class="md-tabs__link">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
API Reference
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</nav>
|
||||
@@ -614,6 +592,8 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -886,6 +866,171 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_3_9" >
|
||||
|
||||
|
||||
<div class="md-nav__link md-nav__container">
|
||||
<a href="../" class="md-nav__link ">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Server
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
|
||||
|
||||
<label class="md-nav__link " for="__nav_3_9" id="__nav_3_9_label" tabindex="0">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
</div>
|
||||
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_3_9_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_3_9">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
|
||||
|
||||
Server
|
||||
|
||||
|
||||
</label>
|
||||
<ul class="md-nav__list" data-md-scrollfix>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../authentication/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Authentication
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../dashboard/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Dashboard
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../../../guide/remote-sessions/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Remote Sessions
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
@@ -1078,7 +1223,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Output & Naming
|
||||
Output & Naming Options
|
||||
|
||||
|
||||
|
||||
@@ -1162,7 +1307,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Key Vaults
|
||||
Key Vault Options
|
||||
|
||||
|
||||
|
||||
@@ -1282,6 +1427,8 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1400,14 +1547,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1436,9 +1575,8 @@
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_5_3" checked>
|
||||
|
||||
|
||||
<div class="md-nav__link md-nav__container">
|
||||
<a href="../" class="md-nav__link ">
|
||||
|
||||
<label class="md-nav__link" for="__nav_5_3" id="__nav_5_3_label" tabindex="">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
@@ -1452,14 +1590,8 @@
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
|
||||
|
||||
<label class="md-nav__link " for="__nav_5_3" id="__nav_5_3_label" tabindex="">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
</div>
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_5_3_label" aria-expanded="true">
|
||||
<label class="md-nav__title" for="__nav_5_3">
|
||||
@@ -1473,8 +1605,6 @@
|
||||
<ul class="md-nav__list" data-md-scrollfix>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1497,7 +1627,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Quick Start
|
||||
REST API Quick Start
|
||||
|
||||
|
||||
|
||||
@@ -1515,7 +1645,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Quick Start
|
||||
REST API Quick Start
|
||||
|
||||
|
||||
|
||||
@@ -1608,10 +1738,10 @@
|
||||
<ul class="md-nav__list">
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="#frequently-used-download-fields" class="md-nav__link">
|
||||
<a href="#download-fields" class="md-nav__link">
|
||||
<span class="md-ellipsis">
|
||||
|
||||
Frequently used download fields
|
||||
Download fields
|
||||
|
||||
</span>
|
||||
</a>
|
||||
@@ -1693,34 +1823,6 @@
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../authentication/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Authentication
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../endpoints/" class="md-nav__link">
|
||||
|
||||
@@ -1778,14 +1880,14 @@
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../dashboard/" class="md-nav__link">
|
||||
<a href="../errors/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Dashboard
|
||||
Error Responses
|
||||
|
||||
|
||||
|
||||
@@ -1813,7 +1915,7 @@
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Remote Sessions
|
||||
Remote Session Protocol
|
||||
|
||||
|
||||
|
||||
@@ -1827,55 +1929,20 @@
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="../errors/" class="md-nav__link">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
Error Responses
|
||||
|
||||
|
||||
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1894,25 +1961,28 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_6" >
|
||||
|
||||
|
||||
<label class="md-nav__link" for="__nav_6" id="__nav_6_label" tabindex="0">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<li class="md-nav__item md-nav__item--section md-nav__item--nested">
|
||||
|
||||
|
||||
|
||||
<input class="md-nav__toggle md-toggle " type="checkbox" id="__nav_5_4" >
|
||||
|
||||
|
||||
<label class="md-nav__link" for="__nav_5_4" id="__nav_5_4_label" tabindex="">
|
||||
|
||||
|
||||
|
||||
<span class="md-ellipsis">
|
||||
|
||||
|
||||
API Reference
|
||||
Python API
|
||||
|
||||
|
||||
|
||||
@@ -1923,12 +1993,12 @@
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
</label>
|
||||
|
||||
<nav class="md-nav" data-md-level="1" aria-labelledby="__nav_6_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_6">
|
||||
<nav class="md-nav" data-md-level="2" aria-labelledby="__nav_5_4_label" aria-expanded="false">
|
||||
<label class="md-nav__title" for="__nav_5_4">
|
||||
<span class="md-nav__icon md-icon"></span>
|
||||
|
||||
|
||||
API Reference
|
||||
Python API
|
||||
|
||||
|
||||
</label>
|
||||
@@ -2080,6 +2150,14 @@
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
@@ -2175,10 +2253,10 @@
|
||||
<ul class="md-nav__list">
|
||||
|
||||
<li class="md-nav__item">
|
||||
<a href="#frequently-used-download-fields" class="md-nav__link">
|
||||
<a href="#download-fields" class="md-nav__link">
|
||||
<span class="md-ellipsis">
|
||||
|
||||
Frequently used download fields
|
||||
Download fields
|
||||
|
||||
</span>
|
||||
</a>
|
||||
@@ -2268,7 +2346,7 @@
|
||||
<h1 id="rest-api-quick-start">REST API Quick Start<a class="headerlink" href="#rest-api-quick-start" title="Permanent link">¶</a></h1>
|
||||
<p>Unshackle ships with a built-in REST API that exposes the same download engine you drive from the command line. The <code>unshackle serve</code> command serves it and lets you queue downloads, poll their progress, browse services, and manage history over HTTP instead of the terminal.</p>
|
||||
<p>The full loop runs end to end: start the server, authenticate, submit a download job, and poll it to completion. The <code>curl</code> commands here come directly from the API routes.</p>
|
||||
<div class="admonition note">
|
||||
<div class="admonition info">
|
||||
<p class="admonition-title">Who this page is for</p>
|
||||
<p>This is a <strong>developer</strong> guide. It assumes you are comfortable with HTTP, JSON, and a tool like <code>curl</code>. If you only want to download something, the <a href="../../../">command line</a> is simpler. The REST API is meant for building tools, UIs, and automation on top of unshackle.</p>
|
||||
</div>
|
||||
@@ -2362,7 +2440,7 @@
|
||||
<tr>
|
||||
<td><code>--remote-only</code></td>
|
||||
<td>off</td>
|
||||
<td>Expose only the remote-session subset of routes</td>
|
||||
<td>Expose only the remote session routes: <code>/api/health</code>, <code>/api/services</code>, <code>/api/search</code>, <code>/api/session/*</code>, <code>/api/tunnel</code> and <code>/api/tunnel/check</code>, and the dashboard routes when <code>serve.dashboard.key</code> is set</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>--caddy</code></td>
|
||||
@@ -2472,80 +2550,9 @@
|
||||
</span><span id="__span-15-4"><a id="__codelineno-15-4" name="__codelineno-15-4" href="#__codelineno-15-4"></a><span class="w"> </span>-d<span class="w"> </span><span class="s1">'{"service":"EXAMPLE","title_id":"12345","quality":[1080]}'</span><span class="w"> </span><span class="se">\</span>
|
||||
</span><span id="__span-15-5"><a id="__codelineno-15-5" name="__codelineno-15-5" href="#__codelineno-15-5"></a><span class="w"> </span><span class="p">|</span><span class="w"> </span>python<span class="w"> </span>-c<span class="w"> </span><span class="s2">"import sys, json; print(json.load(sys.stdin)['job_id'])"</span><span class="k">)</span>
|
||||
</span></code></pre></div>
|
||||
<h3 id="frequently-used-download-fields">Frequently used download fields<a class="headerlink" href="#frequently-used-download-fields" title="Permanent link">¶</a></h3>
|
||||
<p>The request body accepts the full download parameter set. A few of the most useful:</p>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Field</th>
|
||||
<th>Default</th>
|
||||
<th>Meaning</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><code>service</code></td>
|
||||
<td>-</td>
|
||||
<td>Service tag (required)</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>title_id</code></td>
|
||||
<td>-</td>
|
||||
<td>Title identifier (required)</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>profile</code></td>
|
||||
<td><code>null</code></td>
|
||||
<td>Named credential/cookie profile to use</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>quality</code></td>
|
||||
<td><code>[]</code></td>
|
||||
<td>Resolution(s), e.g. <code>[1080]</code>; empty means best available</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>vcodec</code></td>
|
||||
<td><code>[]</code></td>
|
||||
<td>Video codec, e.g. <code>"H265"</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>acodec</code></td>
|
||||
<td><code>[]</code></td>
|
||||
<td>Audio codec, e.g. <code>"EC3"</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>range</code></td>
|
||||
<td><code>["SDR"]</code></td>
|
||||
<td>Dynamic range: <code>SDR</code>, <code>HDR10</code>, <code>HDR10+</code>, <code>VIVID</code>, <code>DV</code>, <code>HLG</code>, <code>HYBRID</code></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>wanted</code></td>
|
||||
<td><code>[]</code></td>
|
||||
<td>Episodes to fetch, e.g. <code>["S01E01"]</code>, or music tracks, e.g. <code>["1-5"]</code>. Empty means all</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>lang</code></td>
|
||||
<td><code>["orig"]</code></td>
|
||||
<td>Video/audio language(s)</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>s_lang</code></td>
|
||||
<td><code>["all"]</code></td>
|
||||
<td>Subtitle language(s)</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>downloads</code></td>
|
||||
<td><code>1</code></td>
|
||||
<td>Number of tracks to download concurrently</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><code>proxy</code></td>
|
||||
<td><code>null</code></td>
|
||||
<td>Proxy URI or country code</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>Validation is strict: invalid codecs, subtitle formats, dynamic-range names, non-positive counts, or flags that conflict (for example both <code>no_subs</code> and <code>subs_only</code>) come back as <code>400</code> with error code <code>INVALID_PARAMETERS</code>. See the full reference on the <a href="../endpoints/">download reference page</a> for every accepted field.</p>
|
||||
<h3 id="download-fields">Download fields<a class="headerlink" href="#download-fields" title="Permanent link">¶</a></h3>
|
||||
<p>The request body takes every <code>dl</code> option. The <a href="../endpoints/#post-apidownload">request body table</a> gives the type, default and meaning of each field.</p>
|
||||
<p>Validation is strict: invalid codecs, subtitle formats, dynamic-range names, non-positive counts, or flags that conflict (for example both <code>no_subs</code> and <code>subs_only</code>) come back as <code>400</code> with error code <code>INVALID_PARAMETERS</code>.</p>
|
||||
<div class="admonition note">
|
||||
<p class="admonition-title">Gated fields</p>
|
||||
<p>The server refuses a per-request CDM (<code>cdm</code>) or inline credentials (<code>credential</code> / <code>credentials</code>) with <code>403 FORBIDDEN</code>, unless the server operator has explicitly opted in with <code>serve.cdm_overrides</code> and <code>serve.allow_job_credentials</code>. Both are off by default.</p>
|
||||
@@ -2698,13 +2705,13 @@
|
||||
<p>A retry reuses the original job's service, title, and parameters to enqueue a brand new job, and returns <code>202</code> with a fresh <code>job_id</code>. A retry works only on terminal jobs, and returns <code>409 CONFLICT</code> otherwise. A priority change works only on jobs still in the <code>queued</code> state.</p>
|
||||
<hr />
|
||||
<h2 id="beyond-a-single-download">Beyond a single download<a class="headerlink" href="#beyond-a-single-download" title="Permanent link">¶</a></h2>
|
||||
<p>The download loop above is the core of the API, but the same server exposes more:</p>
|
||||
<p>The download flow above is the core of the API, but the same server exposes more:</p>
|
||||
<ul>
|
||||
<li><strong>Discovery</strong>: <code>POST /api/search</code> finds titles by query, and <code>POST /api/list-titles</code> / <code>POST /api/list-tracks</code> inspect what a title offers before you commit to downloading it. See <a href="../endpoints/">titles and tracks</a>.</li>
|
||||
<li><strong>History</strong>: <code>GET /api/history</code> reads a persisted log of jobs that reached a terminal state (newest first), and <code>DELETE /api/history/{job_id}</code> removes a single entry. See <a href="../endpoints/">history</a>.</li>
|
||||
<li><strong>Introspection</strong>: <code>GET /api/profiles</code> lists configured credential profiles per service, <code>GET /api/config</code> returns a redacted view of the effective server config, and <code>GET /api/env/check</code> reports which external binaries the machine has.</li>
|
||||
<li><strong>Maintenance</strong>: <code>POST /api/maintenance/clear-cache</code>, <code>.../clear-temp</code>, and <code>.../refresh-services</code> do housekeeping (the server blocks the cache and temp clears with <code>409</code> while a download is active).</li>
|
||||
<li><strong>Remote sessions</strong>: the <code>/api/session/*</code> endpoints drive the thin-client "remote download" flow, where the server authenticates and licenses on behalf of a local client. See <a href="../remote-sessions/">remote sessions</a>.</li>
|
||||
<li><strong>Remote sessions</strong>: the routes that carry the remote sessions of <code>dl --remote</code>, where the server authenticates and licenses on behalf of a local client. See <a href="../remote-sessions/">remote sessions</a>.</li>
|
||||
</ul>
|
||||
<p>The interactive <strong>Swagger UI at <code>/api/docs/</code></strong> documents every route and lets you try them in the browser (send your <code>X-Secret-Key</code> there too).</p>
|
||||
<hr />
|
||||
@@ -2833,7 +2840,7 @@
|
||||
<nav class="md-footer__inner md-grid" aria-label="Footer" >
|
||||
|
||||
|
||||
<a href="../" class="md-footer__link md-footer__link--prev" aria-label="Previous: Overview">
|
||||
<a href="../../service-architecture/" class="md-footer__link md-footer__link--prev" aria-label="Previous: Service Architecture">
|
||||
<div class="md-footer__button md-icon">
|
||||
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M20 11v2H8l5.5 5.5-1.42 1.42L4.16 12l7.92-7.92L13.5 5.5 8 11z"/></svg>
|
||||
@@ -2843,20 +2850,20 @@
|
||||
Previous
|
||||
</span>
|
||||
<div class="md-ellipsis">
|
||||
Overview
|
||||
Service Architecture
|
||||
</div>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
|
||||
|
||||
<a href="../authentication/" class="md-footer__link md-footer__link--next" aria-label="Next: Authentication">
|
||||
<a href="../endpoints/" class="md-footer__link md-footer__link--next" aria-label="Next: Endpoints">
|
||||
<div class="md-footer__title">
|
||||
<span class="md-footer__direction">
|
||||
Next
|
||||
</span>
|
||||
<div class="md-ellipsis">
|
||||
Authentication
|
||||
Endpoints
|
||||
</div>
|
||||
</div>
|
||||
<div class="md-footer__button md-icon">
|
||||
|
||||
+2073
-1393
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user