mirror of https://github.com/OpenVidu/openvidu.git
openvidu-node-client TypeDoc refined
parent
20027ab19b
commit
9ef4ed9242
|
@ -41,7 +41,7 @@
|
|||
"indent": [
|
||||
true,
|
||||
"spaces",
|
||||
4
|
||||
2
|
||||
],
|
||||
"interface-name": [
|
||||
true,
|
||||
|
|
|
@ -287,7 +287,7 @@
|
|||
</li>
|
||||
</ul>
|
||||
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="recording.html" class="tsd-signature-type">Recording</a><span class="tsd-signature-symbol">></span></h4>
|
||||
<p>A Promise that is resolved to the <a href="recording.html">Recording</a> if it successfully started and rejected with an Error object if not. This Error object has as <code>message</code> property with the following values:</p>
|
||||
<p>A Promise that is resolved to the <a href="recording.html">Recording</a> if it successfully started (the recording can be stopped with guarantees) and rejected with an Error object if not. This Error object has as <code>message</code> property with the following values:</p>
|
||||
<ul>
|
||||
<li><code>404</code>: no session exists for the passed <code>sessionId</code></li>
|
||||
<li><code>400</code>: the session has no connected participants</li>
|
||||
|
@ -325,7 +325,7 @@
|
|||
</li>
|
||||
</ul>
|
||||
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="recording.html" class="tsd-signature-type">Recording</a><span class="tsd-signature-symbol">></span></h4>
|
||||
<p>A Promise that is resolved to the <a href="recording.html">Recording</a> if it successfully started and rejected with an Error object if not. This Error object has as <code>message</code> property with the following values:</p>
|
||||
<p>A Promise that is resolved to the <a href="recording.html">Recording</a> if it successfully started (the recording can be stopped with guarantees) and rejected with an Error object if not. This Error object has as <code>message</code> property with the following values:</p>
|
||||
<ul>
|
||||
<li><code>404</code>: no session exists for the passed <code>sessionId</code></li>
|
||||
<li><code>400</code>: the session has no connected participants</li>
|
||||
|
@ -358,7 +358,7 @@
|
|||
</li>
|
||||
</ul>
|
||||
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="recording.html" class="tsd-signature-type">Recording</a><span class="tsd-signature-symbol">></span></h4>
|
||||
<p>A Promise that is resolved to the <a href="recording.html">Recording</a> if it successfully started and rejected with an Error object if not. This Error object has as <code>message</code> property with the following values:</p>
|
||||
<p>A Promise that is resolved to the <a href="recording.html">Recording</a> if it successfully started (the recording can be stopped with guarantees) and rejected with an Error object if not. This Error object has as <code>message</code> property with the following values:</p>
|
||||
<ul>
|
||||
<li><code>404</code>: no session exists for the passed <code>sessionId</code></li>
|
||||
<li><code>400</code>: the session has no connected participants</li>
|
||||
|
|
|
@ -119,7 +119,7 @@
|
|||
<li class="tsd-description">
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L75">Recording.ts:75</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L77">Recording.ts:77</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<h4 class="tsd-parameters-title">Parameters</h4>
|
||||
|
@ -216,12 +216,14 @@
|
|||
<div class="tsd-signature tsd-kind-icon">name<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span></div>
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L70">Recording.ts:70</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L72">Recording.ts:72</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
<div class="lead">
|
||||
<p>Name of the Recording. The video file will be named after this property</p>
|
||||
<p>Name of the Recording. The video file will be named after this property.
|
||||
You can access this same value in your clients on recording events
|
||||
(<code>recordingStarted</code>, <code>recordingStopped</code>)</p>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
@ -231,7 +233,7 @@
|
|||
<div class="tsd-signature tsd-kind-icon">recording<wbr>Layout<span class="tsd-signature-symbol">:</span> <a href="../enums/recordinglayout.html" class="tsd-signature-type">RecordingLayout</a></div>
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L75">Recording.ts:75</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L77">Recording.ts:77</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
|
|
|
@ -174,7 +174,7 @@
|
|||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
<div class="lead">
|
||||
<p>Gets a new token associated to Session object. This translates into a new request to OpenVidu Server</p>
|
||||
<p>Gets a new token associated to Session object. This always translates into a new request to OpenVidu Server</p>
|
||||
</div>
|
||||
</div>
|
||||
<h4 class="tsd-parameters-title">Parameters</h4>
|
||||
|
|
|
@ -92,9 +92,16 @@
|
|||
<div class="tsd-signature tsd-kind-icon">available<span class="tsd-signature-symbol">:</span> </div>
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L99">Recording.ts:99</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L119">Recording.ts:119</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
<div class="lead">
|
||||
<p>The recording is available for downloading. This status is reached for all
|
||||
stopped recordings if <a href="http://openvidu.io/docs/reference-docs/openvidu-server-params/">OpenVidu Server configuration</a>
|
||||
property <code>openvidu.recording.free-access</code> is true</p>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
<section class="tsd-panel tsd-member tsd-kind-enum-member tsd-parent-kind-enum">
|
||||
<a name="failed" class="tsd-anchor"></a>
|
||||
|
@ -102,9 +109,14 @@
|
|||
<div class="tsd-signature tsd-kind-icon">failed<span class="tsd-signature-symbol">:</span> </div>
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L101">Recording.ts:101</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L124">Recording.ts:124</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
<div class="lead">
|
||||
<p>The recording has failed</p>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
<section class="tsd-panel tsd-member tsd-kind-enum-member tsd-parent-kind-enum">
|
||||
<a name="started" class="tsd-anchor"></a>
|
||||
|
@ -112,9 +124,14 @@
|
|||
<div class="tsd-signature tsd-kind-icon">started<span class="tsd-signature-symbol">:</span> </div>
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L97">Recording.ts:97</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L107">Recording.ts:107</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
<div class="lead">
|
||||
<p>The recording has started and is going on</p>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
<section class="tsd-panel tsd-member tsd-kind-enum-member tsd-parent-kind-enum">
|
||||
<a name="starting" class="tsd-anchor"></a>
|
||||
|
@ -122,9 +139,14 @@
|
|||
<div class="tsd-signature tsd-kind-icon">starting<span class="tsd-signature-symbol">:</span> </div>
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L96">Recording.ts:96</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L102">Recording.ts:102</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
<div class="lead">
|
||||
<p>The recording is starting (cannot be stopped)</p>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
<section class="tsd-panel tsd-member tsd-kind-enum-member tsd-parent-kind-enum">
|
||||
<a name="stopped" class="tsd-anchor"></a>
|
||||
|
@ -132,9 +154,14 @@
|
|||
<div class="tsd-signature tsd-kind-icon">stopped<span class="tsd-signature-symbol">:</span> </div>
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L98">Recording.ts:98</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/Recording.ts#L112">Recording.ts:112</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
<div class="lead">
|
||||
<p>The recording has finished OK</p>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
</section>
|
||||
</div>
|
||||
|
|
|
@ -96,7 +96,7 @@
|
|||
<div class="tsd-signature tsd-kind-icon">default<wbr>Custom<wbr>Layout<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span></div>
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/SessionProperties.ts#L37">SessionProperties.ts:37</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/SessionProperties.ts#L45">SessionProperties.ts:45</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
|
@ -112,7 +112,7 @@
|
|||
<div class="tsd-signature tsd-kind-icon">default<wbr>Recording<wbr>Layout<span class="tsd-signature-symbol">:</span> <a href="../enums/recordinglayout.html" class="tsd-signature-type">RecordingLayout</a></div>
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/SessionProperties.ts#L31">SessionProperties.ts:31</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/SessionProperties.ts#L39">SessionProperties.ts:39</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
|
@ -128,9 +128,15 @@
|
|||
<div class="tsd-signature tsd-kind-icon">media<wbr>Mode<span class="tsd-signature-symbol">:</span> <a href="../enums/mediamode.html" class="tsd-signature-type">MediaMode</a></div>
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/SessionProperties.ts#L24">SessionProperties.ts:24</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/SessionProperties.ts#L28">SessionProperties.ts:28</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
<div class="lead">
|
||||
<p>How the media streams will be sent and received by your clients: routed through OpenVidu Media Server
|
||||
(<code>MediaMode.ROUTED</code>) or attempting direct p2p connections (<code>MediaMode.RELAYED</code>, <em>not available yet</em>)</p>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-interface">
|
||||
<a name="recordingmode" class="tsd-anchor"></a>
|
||||
|
@ -138,9 +144,14 @@
|
|||
<div class="tsd-signature tsd-kind-icon">recording<wbr>Mode<span class="tsd-signature-symbol">:</span> <a href="../enums/recordingmode.html" class="tsd-signature-type">RecordingMode</a></div>
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/SessionProperties.ts#L25">SessionProperties.ts:25</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/SessionProperties.ts#L33">SessionProperties.ts:33</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
<div class="lead">
|
||||
<p>Whether the Session will be automatically recorded (<code>RecordingMode.ALWAYS</code>) or not (<code>RecordingMode.MANUAL</code>)</p>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
</section>
|
||||
</div>
|
||||
|
|
|
@ -114,9 +114,14 @@
|
|||
<div class="tsd-signature tsd-kind-icon">role<span class="tsd-signature-symbol">:</span> <a href="../enums/openvidurole.html" class="tsd-signature-type">OpenViduRole</a></div>
|
||||
<aside class="tsd-sources">
|
||||
<ul>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/TokenOptions.ts#L30">TokenOptions.ts:30</a></li>
|
||||
<li>Defined in <a href="https://github.com/OpenVidu/openvidu/tree/master/openvidu-node-client/src/TokenOptions.ts#L33">TokenOptions.ts:33</a></li>
|
||||
</ul>
|
||||
</aside>
|
||||
<div class="tsd-comment tsd-typography">
|
||||
<div class="lead">
|
||||
<p>The role assigned to this token</p>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
</section>
|
||||
</div>
|
||||
|
|
|
@ -57,7 +57,7 @@ export class OpenVidu {
|
|||
* @param sessionId The `sessionId` of the [[Session]] you want to start recording
|
||||
* @param name The name you want to give to the video file. You can access this same value in your clients on recording events (`recordingStarted`, `recordingStopped`)
|
||||
*
|
||||
* @returns A Promise that is resolved to the [[Recording]] if it successfully started and rejected with an Error object if not. This Error object has as `message` property with the following values:
|
||||
* @returns A Promise that is resolved to the [[Recording]] if it successfully started (the recording can be stopped with guarantees) and rejected with an Error object if not. This Error object has as `message` property with the following values:
|
||||
* - `404`: no session exists for the passed `sessionId`
|
||||
* - `400`: the session has no connected participants
|
||||
* - `409`: the session is not configured for using [[MediaMode.ROUTED]] or it is already being recorded
|
||||
|
|
|
@ -17,18 +17,18 @@
|
|||
|
||||
export enum OpenViduRole {
|
||||
|
||||
/**
|
||||
* Can subscribe to published streams of other users
|
||||
*/
|
||||
SUBSCRIBER = 'SUBSCRIBER',
|
||||
/**
|
||||
* Can subscribe to published streams of other users
|
||||
*/
|
||||
SUBSCRIBER = 'SUBSCRIBER',
|
||||
|
||||
/**
|
||||
* SUBSCRIBER permissions + can publish their own streams
|
||||
*/
|
||||
PUBLISHER = 'PUBLISHER',
|
||||
/**
|
||||
* SUBSCRIBER permissions + can publish their own streams
|
||||
*/
|
||||
PUBLISHER = 'PUBLISHER',
|
||||
|
||||
/**
|
||||
* _(not available yet)_ SUBSCRIBER + PUBLIHSER permissions + can force `unpublish()` and `disconnect()` over a third-party stream or user
|
||||
*/
|
||||
MODERATOR = 'MODERATOR'
|
||||
/**
|
||||
* _(not available yet)_ SUBSCRIBER + PUBLIHSER permissions + can force `unpublish()` and `disconnect()` over a third-party stream or user
|
||||
*/
|
||||
MODERATOR = 'MODERATOR'
|
||||
}
|
|
@ -65,7 +65,9 @@ export class Recording {
|
|||
status: Recording.Status;
|
||||
|
||||
/**
|
||||
* Name of the Recording. The video file will be named after this property
|
||||
* Name of the Recording. The video file will be named after this property.
|
||||
* You can access this same value in your clients on recording events
|
||||
* (`recordingStarted`, `recordingStopped`)
|
||||
*/
|
||||
name: string;
|
||||
|
||||
|
@ -93,11 +95,32 @@ export class Recording {
|
|||
|
||||
export namespace Recording {
|
||||
export enum Status {
|
||||
starting, // The recording is starting (cannot be stopped)
|
||||
started, // The recording has started and is going on
|
||||
stopped, // The recording has finished OK
|
||||
available, // The recording is available for downloading. This status is reached for all
|
||||
// stopped recordings if property 'openvidu.recording.free-access' is true
|
||||
failed // The recording has failed
|
||||
|
||||
/**
|
||||
* The recording is starting (cannot be stopped)
|
||||
*/
|
||||
starting,
|
||||
|
||||
/**
|
||||
* The recording has started and is going on
|
||||
*/
|
||||
started,
|
||||
|
||||
/**
|
||||
* The recording has finished OK
|
||||
*/
|
||||
stopped,
|
||||
|
||||
/**
|
||||
* The recording is available for downloading. This status is reached for all
|
||||
* stopped recordings if [OpenVidu Server configuration](http://openvidu.io/docs/reference-docs/openvidu-server-params/)
|
||||
* property <code>openvidu.recording.free-access</code> is true
|
||||
*/
|
||||
available,
|
||||
|
||||
/**
|
||||
* The recording has failed
|
||||
*/
|
||||
failed
|
||||
}
|
||||
}
|
|
@ -103,7 +103,7 @@ export class Session {
|
|||
}
|
||||
|
||||
/**
|
||||
* Gets a new token associated to Session object. This translates into a new request to OpenVidu Server
|
||||
* Gets a new token associated to Session object. This always translates into a new request to OpenVidu Server
|
||||
*
|
||||
* @returns A Promise that is resolved to the _token_ if success and rejected with an Error object if not (due to a `400 (Bad Request)` error in OpenVidu Server)
|
||||
*/
|
||||
|
|
|
@ -21,18 +21,26 @@ import { RecordingMode } from './RecordingMode';
|
|||
|
||||
export interface SessionProperties {
|
||||
|
||||
mediaMode?: MediaMode;
|
||||
recordingMode?: RecordingMode;
|
||||
/**
|
||||
* How the media streams will be sent and received by your clients: routed through OpenVidu Media Server
|
||||
* (`MediaMode.ROUTED`) or attempting direct p2p connections (`MediaMode.RELAYED`, _not available yet_)
|
||||
*/
|
||||
mediaMode?: MediaMode;
|
||||
|
||||
/**
|
||||
* Default value used to initialize property [[RecordingProperties.recordingLayout]] of every recording of this session.
|
||||
* You can easily override this value later by setting [[RecordingProperties.recordingLayout]] to any other value
|
||||
*/
|
||||
defaultRecordingLayout?: RecordingLayout;
|
||||
/**
|
||||
* Whether the Session will be automatically recorded (`RecordingMode.ALWAYS`) or not (`RecordingMode.MANUAL`)
|
||||
*/
|
||||
recordingMode?: RecordingMode;
|
||||
|
||||
/**
|
||||
* Default value used to initialize property [[RecordingProperties.customLayout]] of every recording of this session.
|
||||
* You can easily override this value later by setting [[RecordingProperties.customLayout]] to any other value
|
||||
*/
|
||||
defaultCustomLayout?: string;
|
||||
/**
|
||||
* Default value used to initialize property [[RecordingProperties.recordingLayout]] of every recording of this session.
|
||||
* You can easily override this value later by setting [[RecordingProperties.recordingLayout]] to any other value
|
||||
*/
|
||||
defaultRecordingLayout?: RecordingLayout;
|
||||
|
||||
/**
|
||||
* Default value used to initialize property [[RecordingProperties.customLayout]] of every recording of this session.
|
||||
* You can easily override this value later by setting [[RecordingProperties.customLayout]] to any other value
|
||||
*/
|
||||
defaultCustomLayout?: string;
|
||||
}
|
||||
|
|
|
@ -27,5 +27,8 @@ export interface TokenOptions {
|
|||
*/
|
||||
data: string;
|
||||
|
||||
/**
|
||||
* The role assigned to this token
|
||||
*/
|
||||
role: OpenViduRole;
|
||||
}
|
Loading…
Reference in New Issue