twilio 5.0.0 → 5.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/rest/Oauth.d.ts +4 -0
- package/lib/rest/{Media.js → Oauth.js} +3 -3
- package/lib/rest/{MediaBase.d.ts → OauthBase.d.ts} +4 -4
- package/lib/rest/{MediaBase.js → OauthBase.js} +5 -5
- package/lib/rest/Twilio.d.ts +5 -5
- package/lib/rest/Twilio.js +5 -5
- package/lib/rest/api/v2010/account/call.d.ts +34 -10
- package/lib/rest/api/v2010/account/call.js +8 -0
- package/lib/rest/api/v2010/account/conference/participant.d.ts +6 -0
- package/lib/rest/api/v2010/account/conference/participant.js +2 -0
- package/lib/rest/api/v2010/account/conference.d.ts +24 -0
- package/lib/rest/api/v2010/account/conference.js +8 -0
- package/lib/rest/api/v2010/account/message.d.ts +12 -0
- package/lib/rest/api/v2010/account/message.js +4 -0
- package/lib/rest/content/v1/content/approvalCreate.d.ts +3 -3
- package/lib/rest/content/v1/content/approvalCreate.js +7 -7
- package/lib/rest/content/v1/content/approvalFetch.d.ts +5 -5
- package/lib/rest/content/v1/content/approvalFetch.js +14 -14
- package/lib/rest/content/v1/content.d.ts +20 -0
- package/lib/rest/content/v1/content.js +10 -1
- package/lib/rest/conversations/v1/service/conversation.d.ts +6 -6
- package/lib/rest/flexApi/v1/plugin.d.ts +4 -0
- package/lib/rest/flexApi/v1/plugin.js +4 -0
- package/lib/rest/numbers/v1/portingPortInFetch.d.ts +6 -0
- package/lib/rest/numbers/v1/portingPortInFetch.js +2 -0
- package/lib/rest/numbers/v2/regulatoryCompliance/bundle.d.ts +12 -0
- package/lib/rest/numbers/v2/regulatoryCompliance/bundle.js +4 -0
- package/lib/rest/oauth/V1.d.ts +20 -0
- package/lib/rest/oauth/V1.js +42 -0
- package/lib/rest/oauth/v1/authorize.d.ts +69 -0
- package/lib/rest/oauth/v1/authorize.js +83 -0
- package/lib/rest/oauth/v1/token.d.ts +88 -0
- package/lib/rest/oauth/v1/token.js +98 -0
- package/lib/rest/trusthub/v1/complianceRegistrationInquiries.d.ts +84 -10
- package/lib/rest/trusthub/v1/complianceRegistrationInquiries.js +92 -28
- package/lib/rest/trusthub/v1/customerProfiles/customerProfilesEntityAssignments.d.ts +6 -0
- package/lib/rest/trusthub/v1/customerProfiles/customerProfilesEntityAssignments.js +2 -0
- package/lib/rest/trusthub/v1/trustProducts/trustProductsEntityAssignments.d.ts +6 -0
- package/lib/rest/trusthub/v1/trustProducts/trustProductsEntityAssignments.js +2 -0
- package/lib/rest/trusthub/v1/trustProducts.d.ts +16 -16
- package/lib/twiml/VoiceResponse.d.ts +2 -2
- package/package.json +1 -1
- package/lib/rest/Media.d.ts +0 -4
- package/lib/rest/media/V1.d.ts +0 -25
- package/lib/rest/media/V1.js +0 -51
- package/lib/rest/media/v1/mediaProcessor.d.ts +0 -317
- package/lib/rest/media/v1/mediaProcessor.js +0 -256
- package/lib/rest/media/v1/mediaRecording.d.ts +0 -309
- package/lib/rest/media/v1/mediaRecording.js +0 -226
- package/lib/rest/media/v1/playerStreamer/playbackGrant.d.ts +0 -151
- package/lib/rest/media/v1/playerStreamer/playbackGrant.js +0 -146
- package/lib/rest/media/v1/playerStreamer.d.ts +0 -327
- package/lib/rest/media/v1/playerStreamer.js +0 -264
|
@@ -1,146 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* This code was generated by
|
|
4
|
-
* ___ _ _ _ _ _ _ ____ ____ ____ _ ____ ____ _ _ ____ ____ ____ ___ __ __
|
|
5
|
-
* | | | | | | | | | __ | | |__| | __ | __ |___ |\ | |___ |__/ |__| | | | |__/
|
|
6
|
-
* | |_|_| | |___ | |__| |__| | | | |__] |___ | \| |___ | \ | | | |__| | \
|
|
7
|
-
*
|
|
8
|
-
* Twilio - Media
|
|
9
|
-
* This is the public Twilio REST API.
|
|
10
|
-
*
|
|
11
|
-
* NOTE: This class is auto generated by OpenAPI Generator.
|
|
12
|
-
* https://openapi-generator.tech
|
|
13
|
-
* Do not edit the class manually.
|
|
14
|
-
*/
|
|
15
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.PlaybackGrantListInstance = exports.PlaybackGrantInstance = exports.PlaybackGrantContextImpl = void 0;
|
|
17
|
-
const util_1 = require("util");
|
|
18
|
-
const deserialize = require("../../../../base/deserialize");
|
|
19
|
-
const serialize = require("../../../../base/serialize");
|
|
20
|
-
const utility_1 = require("../../../../base/utility");
|
|
21
|
-
class PlaybackGrantContextImpl {
|
|
22
|
-
constructor(_version, sid) {
|
|
23
|
-
this._version = _version;
|
|
24
|
-
if (!(0, utility_1.isValidPathParam)(sid)) {
|
|
25
|
-
throw new Error("Parameter 'sid' is not valid.");
|
|
26
|
-
}
|
|
27
|
-
this._solution = { sid };
|
|
28
|
-
this._uri = `/PlayerStreamers/${sid}/PlaybackGrant`;
|
|
29
|
-
}
|
|
30
|
-
create(params, callback) {
|
|
31
|
-
if (params instanceof Function) {
|
|
32
|
-
callback = params;
|
|
33
|
-
params = {};
|
|
34
|
-
}
|
|
35
|
-
else {
|
|
36
|
-
params = params || {};
|
|
37
|
-
}
|
|
38
|
-
let data = {};
|
|
39
|
-
if (params["ttl"] !== undefined)
|
|
40
|
-
data["Ttl"] = params["ttl"];
|
|
41
|
-
if (params["accessControlAllowOrigin"] !== undefined)
|
|
42
|
-
data["AccessControlAllowOrigin"] = params["accessControlAllowOrigin"];
|
|
43
|
-
const headers = {};
|
|
44
|
-
headers["Content-Type"] = "application/x-www-form-urlencoded";
|
|
45
|
-
const instance = this;
|
|
46
|
-
let operationVersion = instance._version, operationPromise = operationVersion.create({
|
|
47
|
-
uri: instance._uri,
|
|
48
|
-
method: "post",
|
|
49
|
-
data,
|
|
50
|
-
headers,
|
|
51
|
-
});
|
|
52
|
-
operationPromise = operationPromise.then((payload) => new PlaybackGrantInstance(operationVersion, payload, instance._solution.sid));
|
|
53
|
-
operationPromise = instance._version.setPromiseCallback(operationPromise, callback);
|
|
54
|
-
return operationPromise;
|
|
55
|
-
}
|
|
56
|
-
fetch(callback) {
|
|
57
|
-
const instance = this;
|
|
58
|
-
let operationVersion = instance._version, operationPromise = operationVersion.fetch({
|
|
59
|
-
uri: instance._uri,
|
|
60
|
-
method: "get",
|
|
61
|
-
});
|
|
62
|
-
operationPromise = operationPromise.then((payload) => new PlaybackGrantInstance(operationVersion, payload, instance._solution.sid));
|
|
63
|
-
operationPromise = instance._version.setPromiseCallback(operationPromise, callback);
|
|
64
|
-
return operationPromise;
|
|
65
|
-
}
|
|
66
|
-
/**
|
|
67
|
-
* Provide a user-friendly representation
|
|
68
|
-
*
|
|
69
|
-
* @returns Object
|
|
70
|
-
*/
|
|
71
|
-
toJSON() {
|
|
72
|
-
return this._solution;
|
|
73
|
-
}
|
|
74
|
-
[util_1.inspect.custom](_depth, options) {
|
|
75
|
-
return (0, util_1.inspect)(this.toJSON(), options);
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
exports.PlaybackGrantContextImpl = PlaybackGrantContextImpl;
|
|
79
|
-
class PlaybackGrantInstance {
|
|
80
|
-
constructor(_version, payload, sid) {
|
|
81
|
-
this._version = _version;
|
|
82
|
-
this.sid = payload.sid;
|
|
83
|
-
this.url = payload.url;
|
|
84
|
-
this.accountSid = payload.account_sid;
|
|
85
|
-
this.dateCreated = deserialize.iso8601DateTime(payload.date_created);
|
|
86
|
-
this.grant = payload.grant;
|
|
87
|
-
this._solution = { sid };
|
|
88
|
-
}
|
|
89
|
-
get _proxy() {
|
|
90
|
-
this._context =
|
|
91
|
-
this._context ||
|
|
92
|
-
new PlaybackGrantContextImpl(this._version, this._solution.sid);
|
|
93
|
-
return this._context;
|
|
94
|
-
}
|
|
95
|
-
create(params, callback) {
|
|
96
|
-
return this._proxy.create(params, callback);
|
|
97
|
-
}
|
|
98
|
-
/**
|
|
99
|
-
* Fetch a PlaybackGrantInstance
|
|
100
|
-
*
|
|
101
|
-
* @param callback - Callback to handle processed record
|
|
102
|
-
*
|
|
103
|
-
* @returns Resolves to processed PlaybackGrantInstance
|
|
104
|
-
*/
|
|
105
|
-
fetch(callback) {
|
|
106
|
-
return this._proxy.fetch(callback);
|
|
107
|
-
}
|
|
108
|
-
/**
|
|
109
|
-
* Provide a user-friendly representation
|
|
110
|
-
*
|
|
111
|
-
* @returns Object
|
|
112
|
-
*/
|
|
113
|
-
toJSON() {
|
|
114
|
-
return {
|
|
115
|
-
sid: this.sid,
|
|
116
|
-
url: this.url,
|
|
117
|
-
accountSid: this.accountSid,
|
|
118
|
-
dateCreated: this.dateCreated,
|
|
119
|
-
grant: this.grant,
|
|
120
|
-
};
|
|
121
|
-
}
|
|
122
|
-
[util_1.inspect.custom](_depth, options) {
|
|
123
|
-
return (0, util_1.inspect)(this.toJSON(), options);
|
|
124
|
-
}
|
|
125
|
-
}
|
|
126
|
-
exports.PlaybackGrantInstance = PlaybackGrantInstance;
|
|
127
|
-
function PlaybackGrantListInstance(version, sid) {
|
|
128
|
-
if (!(0, utility_1.isValidPathParam)(sid)) {
|
|
129
|
-
throw new Error("Parameter 'sid' is not valid.");
|
|
130
|
-
}
|
|
131
|
-
const instance = (() => instance.get());
|
|
132
|
-
instance.get = function get() {
|
|
133
|
-
return new PlaybackGrantContextImpl(version, sid);
|
|
134
|
-
};
|
|
135
|
-
instance._version = version;
|
|
136
|
-
instance._solution = { sid };
|
|
137
|
-
instance._uri = ``;
|
|
138
|
-
instance.toJSON = function toJSON() {
|
|
139
|
-
return instance._solution;
|
|
140
|
-
};
|
|
141
|
-
instance[util_1.inspect.custom] = function inspectImpl(_depth, options) {
|
|
142
|
-
return (0, util_1.inspect)(instance.toJSON(), options);
|
|
143
|
-
};
|
|
144
|
-
return instance;
|
|
145
|
-
}
|
|
146
|
-
exports.PlaybackGrantListInstance = PlaybackGrantListInstance;
|
|
@@ -1,327 +0,0 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
import { inspect, InspectOptions } from "util";
|
|
3
|
-
import Page, { TwilioResponsePayload } from "../../../base/Page";
|
|
4
|
-
import Response from "../../../http/response";
|
|
5
|
-
import V1 from "../V1";
|
|
6
|
-
import { PlaybackGrantListInstance } from "./playerStreamer/playbackGrant";
|
|
7
|
-
export type PlayerStreamerEndedReason = "ended-via-api" | "max-duration-exceeded" | "stream-disconnected-by-source" | "unexpected-failure";
|
|
8
|
-
export type PlayerStreamerOrder = "asc" | "desc";
|
|
9
|
-
export type PlayerStreamerStatus = "created" | "started" | "ended" | "failed";
|
|
10
|
-
export type PlayerStreamerUpdateStatus = "ended";
|
|
11
|
-
/**
|
|
12
|
-
* Options to pass to update a PlayerStreamerInstance
|
|
13
|
-
*/
|
|
14
|
-
export interface PlayerStreamerContextUpdateOptions {
|
|
15
|
-
/** */
|
|
16
|
-
status: PlayerStreamerUpdateStatus;
|
|
17
|
-
}
|
|
18
|
-
/**
|
|
19
|
-
* Options to pass to create a PlayerStreamerInstance
|
|
20
|
-
*/
|
|
21
|
-
export interface PlayerStreamerListInstanceCreateOptions {
|
|
22
|
-
/** Specifies whether the PlayerStreamer is configured to stream video. Defaults to `true`. */
|
|
23
|
-
video?: boolean;
|
|
24
|
-
/** The URL to which Twilio will send asynchronous webhook requests for every PlayerStreamer event. See [Status Callbacks](/docs/live/api/status-callbacks) for more details. */
|
|
25
|
-
statusCallback?: string;
|
|
26
|
-
/** The HTTP method Twilio should use to call the `status_callback` URL. Can be `POST` or `GET` and the default is `POST`. */
|
|
27
|
-
statusCallbackMethod?: string;
|
|
28
|
-
/** The maximum time, in seconds, that the PlayerStreamer is active (`created` or `started`) before automatically ends. The default value is 300 seconds, and the maximum value is 90000 seconds. Once this maximum duration is reached, Twilio will end the PlayerStreamer, regardless of whether media is still streaming. */
|
|
29
|
-
maxDuration?: number;
|
|
30
|
-
}
|
|
31
|
-
/**
|
|
32
|
-
* Options to pass to each
|
|
33
|
-
*/
|
|
34
|
-
export interface PlayerStreamerListInstanceEachOptions {
|
|
35
|
-
/** The sort order of the list by `date_created`. Can be: `asc` (ascending) or `desc` (descending) with `desc` as the default. */
|
|
36
|
-
order?: PlayerStreamerOrder;
|
|
37
|
-
/** Status to filter by, with possible values `created`, `started`, `ended`, or `failed`. */
|
|
38
|
-
status?: PlayerStreamerStatus;
|
|
39
|
-
/** How many resources to return in each list page. The default is 50, and the maximum is 1000. */
|
|
40
|
-
pageSize?: number;
|
|
41
|
-
/** Function to process each record. If this and a positional callback are passed, this one will be used */
|
|
42
|
-
callback?: (item: PlayerStreamerInstance, done: (err?: Error) => void) => void;
|
|
43
|
-
/** Function to be called upon completion of streaming */
|
|
44
|
-
done?: Function;
|
|
45
|
-
/** Upper limit for the number of records to return. each() guarantees never to return more than limit. Default is no limit */
|
|
46
|
-
limit?: number;
|
|
47
|
-
}
|
|
48
|
-
/**
|
|
49
|
-
* Options to pass to list
|
|
50
|
-
*/
|
|
51
|
-
export interface PlayerStreamerListInstanceOptions {
|
|
52
|
-
/** The sort order of the list by `date_created`. Can be: `asc` (ascending) or `desc` (descending) with `desc` as the default. */
|
|
53
|
-
order?: PlayerStreamerOrder;
|
|
54
|
-
/** Status to filter by, with possible values `created`, `started`, `ended`, or `failed`. */
|
|
55
|
-
status?: PlayerStreamerStatus;
|
|
56
|
-
/** How many resources to return in each list page. The default is 50, and the maximum is 1000. */
|
|
57
|
-
pageSize?: number;
|
|
58
|
-
/** Upper limit for the number of records to return. list() guarantees never to return more than limit. Default is no limit */
|
|
59
|
-
limit?: number;
|
|
60
|
-
}
|
|
61
|
-
/**
|
|
62
|
-
* Options to pass to page
|
|
63
|
-
*/
|
|
64
|
-
export interface PlayerStreamerListInstancePageOptions {
|
|
65
|
-
/** The sort order of the list by `date_created`. Can be: `asc` (ascending) or `desc` (descending) with `desc` as the default. */
|
|
66
|
-
order?: PlayerStreamerOrder;
|
|
67
|
-
/** Status to filter by, with possible values `created`, `started`, `ended`, or `failed`. */
|
|
68
|
-
status?: PlayerStreamerStatus;
|
|
69
|
-
/** How many resources to return in each list page. The default is 50, and the maximum is 1000. */
|
|
70
|
-
pageSize?: number;
|
|
71
|
-
/** Page Number, this value is simply for client state */
|
|
72
|
-
pageNumber?: number;
|
|
73
|
-
/** PageToken provided by the API */
|
|
74
|
-
pageToken?: string;
|
|
75
|
-
}
|
|
76
|
-
export interface PlayerStreamerContext {
|
|
77
|
-
playbackGrant: PlaybackGrantListInstance;
|
|
78
|
-
/**
|
|
79
|
-
* Fetch a PlayerStreamerInstance
|
|
80
|
-
*
|
|
81
|
-
* @param callback - Callback to handle processed record
|
|
82
|
-
*
|
|
83
|
-
* @returns Resolves to processed PlayerStreamerInstance
|
|
84
|
-
*/
|
|
85
|
-
fetch(callback?: (error: Error | null, item?: PlayerStreamerInstance) => any): Promise<PlayerStreamerInstance>;
|
|
86
|
-
/**
|
|
87
|
-
* Update a PlayerStreamerInstance
|
|
88
|
-
*
|
|
89
|
-
* @param params - Parameter for request
|
|
90
|
-
* @param callback - Callback to handle processed record
|
|
91
|
-
*
|
|
92
|
-
* @returns Resolves to processed PlayerStreamerInstance
|
|
93
|
-
*/
|
|
94
|
-
update(params: PlayerStreamerContextUpdateOptions, callback?: (error: Error | null, item?: PlayerStreamerInstance) => any): Promise<PlayerStreamerInstance>;
|
|
95
|
-
/**
|
|
96
|
-
* Provide a user-friendly representation
|
|
97
|
-
*/
|
|
98
|
-
toJSON(): any;
|
|
99
|
-
[inspect.custom](_depth: any, options: InspectOptions): any;
|
|
100
|
-
}
|
|
101
|
-
export interface PlayerStreamerContextSolution {
|
|
102
|
-
sid: string;
|
|
103
|
-
}
|
|
104
|
-
export declare class PlayerStreamerContextImpl implements PlayerStreamerContext {
|
|
105
|
-
protected _version: V1;
|
|
106
|
-
protected _solution: PlayerStreamerContextSolution;
|
|
107
|
-
protected _uri: string;
|
|
108
|
-
protected _playbackGrant?: PlaybackGrantListInstance;
|
|
109
|
-
constructor(_version: V1, sid: string);
|
|
110
|
-
get playbackGrant(): PlaybackGrantListInstance;
|
|
111
|
-
fetch(callback?: (error: Error | null, item?: PlayerStreamerInstance) => any): Promise<PlayerStreamerInstance>;
|
|
112
|
-
update(params: PlayerStreamerContextUpdateOptions, callback?: (error: Error | null, item?: PlayerStreamerInstance) => any): Promise<PlayerStreamerInstance>;
|
|
113
|
-
/**
|
|
114
|
-
* Provide a user-friendly representation
|
|
115
|
-
*
|
|
116
|
-
* @returns Object
|
|
117
|
-
*/
|
|
118
|
-
toJSON(): PlayerStreamerContextSolution;
|
|
119
|
-
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
120
|
-
}
|
|
121
|
-
interface PlayerStreamerPayload extends TwilioResponsePayload {
|
|
122
|
-
player_streamers: PlayerStreamerResource[];
|
|
123
|
-
}
|
|
124
|
-
interface PlayerStreamerResource {
|
|
125
|
-
account_sid: string;
|
|
126
|
-
date_created: Date;
|
|
127
|
-
date_updated: Date;
|
|
128
|
-
video: boolean;
|
|
129
|
-
links: Record<string, string>;
|
|
130
|
-
sid: string;
|
|
131
|
-
status: PlayerStreamerStatus;
|
|
132
|
-
url: string;
|
|
133
|
-
status_callback: string;
|
|
134
|
-
status_callback_method: string;
|
|
135
|
-
ended_reason: PlayerStreamerEndedReason;
|
|
136
|
-
max_duration: number;
|
|
137
|
-
}
|
|
138
|
-
export declare class PlayerStreamerInstance {
|
|
139
|
-
protected _version: V1;
|
|
140
|
-
protected _solution: PlayerStreamerContextSolution;
|
|
141
|
-
protected _context?: PlayerStreamerContext;
|
|
142
|
-
constructor(_version: V1, payload: PlayerStreamerResource, sid?: string);
|
|
143
|
-
/**
|
|
144
|
-
* The SID of the [Account](https://www.twilio.com/docs/iam/api/account) that created the PlayerStreamer resource.
|
|
145
|
-
*/
|
|
146
|
-
accountSid: string;
|
|
147
|
-
/**
|
|
148
|
-
* The date and time in GMT when the resource was created specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
|
|
149
|
-
*/
|
|
150
|
-
dateCreated: Date;
|
|
151
|
-
/**
|
|
152
|
-
* The date and time in GMT when the resource was last updated specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
|
|
153
|
-
*/
|
|
154
|
-
dateUpdated: Date;
|
|
155
|
-
/**
|
|
156
|
-
* Specifies whether the PlayerStreamer is configured to stream video. Defaults to `true`.
|
|
157
|
-
*/
|
|
158
|
-
video: boolean;
|
|
159
|
-
/**
|
|
160
|
-
* The URLs of related resources.
|
|
161
|
-
*/
|
|
162
|
-
links: Record<string, string>;
|
|
163
|
-
/**
|
|
164
|
-
* The unique string generated to identify the PlayerStreamer resource.
|
|
165
|
-
*/
|
|
166
|
-
sid: string;
|
|
167
|
-
status: PlayerStreamerStatus;
|
|
168
|
-
/**
|
|
169
|
-
* The absolute URL of the resource.
|
|
170
|
-
*/
|
|
171
|
-
url: string;
|
|
172
|
-
/**
|
|
173
|
-
* The URL to which Twilio will send asynchronous webhook requests for every PlayerStreamer event. See [Status Callbacks](/docs/live/api/status-callbacks) for more details.
|
|
174
|
-
*/
|
|
175
|
-
statusCallback: string;
|
|
176
|
-
/**
|
|
177
|
-
* The HTTP method Twilio should use to call the `status_callback` URL. Can be `POST` or `GET` and the default is `POST`.
|
|
178
|
-
*/
|
|
179
|
-
statusCallbackMethod: string;
|
|
180
|
-
endedReason: PlayerStreamerEndedReason;
|
|
181
|
-
/**
|
|
182
|
-
* The maximum time, in seconds, that the PlayerStreamer is active (`created` or `started`) before automatically ends. The default value is 300 seconds, and the maximum value is 90000 seconds. Once this maximum duration is reached, Twilio will end the PlayerStreamer, regardless of whether media is still streaming.
|
|
183
|
-
*/
|
|
184
|
-
maxDuration: number;
|
|
185
|
-
private get _proxy();
|
|
186
|
-
/**
|
|
187
|
-
* Fetch a PlayerStreamerInstance
|
|
188
|
-
*
|
|
189
|
-
* @param callback - Callback to handle processed record
|
|
190
|
-
*
|
|
191
|
-
* @returns Resolves to processed PlayerStreamerInstance
|
|
192
|
-
*/
|
|
193
|
-
fetch(callback?: (error: Error | null, item?: PlayerStreamerInstance) => any): Promise<PlayerStreamerInstance>;
|
|
194
|
-
/**
|
|
195
|
-
* Update a PlayerStreamerInstance
|
|
196
|
-
*
|
|
197
|
-
* @param params - Parameter for request
|
|
198
|
-
* @param callback - Callback to handle processed record
|
|
199
|
-
*
|
|
200
|
-
* @returns Resolves to processed PlayerStreamerInstance
|
|
201
|
-
*/
|
|
202
|
-
update(params: PlayerStreamerContextUpdateOptions, callback?: (error: Error | null, item?: PlayerStreamerInstance) => any): Promise<PlayerStreamerInstance>;
|
|
203
|
-
/**
|
|
204
|
-
* Access the playbackGrant.
|
|
205
|
-
*/
|
|
206
|
-
playbackGrant(): PlaybackGrantListInstance;
|
|
207
|
-
/**
|
|
208
|
-
* Provide a user-friendly representation
|
|
209
|
-
*
|
|
210
|
-
* @returns Object
|
|
211
|
-
*/
|
|
212
|
-
toJSON(): {
|
|
213
|
-
accountSid: string;
|
|
214
|
-
dateCreated: Date;
|
|
215
|
-
dateUpdated: Date;
|
|
216
|
-
video: boolean;
|
|
217
|
-
links: Record<string, string>;
|
|
218
|
-
sid: string;
|
|
219
|
-
status: PlayerStreamerStatus;
|
|
220
|
-
url: string;
|
|
221
|
-
statusCallback: string;
|
|
222
|
-
statusCallbackMethod: string;
|
|
223
|
-
endedReason: PlayerStreamerEndedReason;
|
|
224
|
-
maxDuration: number;
|
|
225
|
-
};
|
|
226
|
-
[inspect.custom](_depth: any, options: InspectOptions): string;
|
|
227
|
-
}
|
|
228
|
-
export interface PlayerStreamerSolution {
|
|
229
|
-
}
|
|
230
|
-
export interface PlayerStreamerListInstance {
|
|
231
|
-
_version: V1;
|
|
232
|
-
_solution: PlayerStreamerSolution;
|
|
233
|
-
_uri: string;
|
|
234
|
-
(sid: string): PlayerStreamerContext;
|
|
235
|
-
get(sid: string): PlayerStreamerContext;
|
|
236
|
-
/**
|
|
237
|
-
* Create a PlayerStreamerInstance
|
|
238
|
-
*
|
|
239
|
-
* @param callback - Callback to handle processed record
|
|
240
|
-
*
|
|
241
|
-
* @returns Resolves to processed PlayerStreamerInstance
|
|
242
|
-
*/
|
|
243
|
-
create(callback?: (error: Error | null, item?: PlayerStreamerInstance) => any): Promise<PlayerStreamerInstance>;
|
|
244
|
-
/**
|
|
245
|
-
* Create a PlayerStreamerInstance
|
|
246
|
-
*
|
|
247
|
-
* @param params - Parameter for request
|
|
248
|
-
* @param callback - Callback to handle processed record
|
|
249
|
-
*
|
|
250
|
-
* @returns Resolves to processed PlayerStreamerInstance
|
|
251
|
-
*/
|
|
252
|
-
create(params: PlayerStreamerListInstanceCreateOptions, callback?: (error: Error | null, item?: PlayerStreamerInstance) => any): Promise<PlayerStreamerInstance>;
|
|
253
|
-
/**
|
|
254
|
-
* Streams PlayerStreamerInstance records from the API.
|
|
255
|
-
*
|
|
256
|
-
* This operation lazily loads records as efficiently as possible until the limit
|
|
257
|
-
* is reached.
|
|
258
|
-
*
|
|
259
|
-
* The results are passed into the callback function, so this operation is memory
|
|
260
|
-
* efficient.
|
|
261
|
-
*
|
|
262
|
-
* If a function is passed as the first argument, it will be used as the callback
|
|
263
|
-
* function.
|
|
264
|
-
*
|
|
265
|
-
* @param { PlayerStreamerListInstanceEachOptions } [params] - Options for request
|
|
266
|
-
* @param { function } [callback] - Function to process each record
|
|
267
|
-
*/
|
|
268
|
-
each(callback?: (item: PlayerStreamerInstance, done: (err?: Error) => void) => void): void;
|
|
269
|
-
each(params: PlayerStreamerListInstanceEachOptions, callback?: (item: PlayerStreamerInstance, done: (err?: Error) => void) => void): void;
|
|
270
|
-
/**
|
|
271
|
-
* Retrieve a single target page of PlayerStreamerInstance records from the API.
|
|
272
|
-
*
|
|
273
|
-
* The request is executed immediately.
|
|
274
|
-
*
|
|
275
|
-
* @param { string } [targetUrl] - API-generated URL for the requested results page
|
|
276
|
-
* @param { function } [callback] - Callback to handle list of records
|
|
277
|
-
*/
|
|
278
|
-
getPage(targetUrl: string, callback?: (error: Error | null, items: PlayerStreamerPage) => any): Promise<PlayerStreamerPage>;
|
|
279
|
-
/**
|
|
280
|
-
* Lists PlayerStreamerInstance records from the API as a list.
|
|
281
|
-
*
|
|
282
|
-
* If a function is passed as the first argument, it will be used as the callback
|
|
283
|
-
* function.
|
|
284
|
-
*
|
|
285
|
-
* @param { PlayerStreamerListInstanceOptions } [params] - Options for request
|
|
286
|
-
* @param { function } [callback] - Callback to handle list of records
|
|
287
|
-
*/
|
|
288
|
-
list(callback?: (error: Error | null, items: PlayerStreamerInstance[]) => any): Promise<PlayerStreamerInstance[]>;
|
|
289
|
-
list(params: PlayerStreamerListInstanceOptions, callback?: (error: Error | null, items: PlayerStreamerInstance[]) => any): Promise<PlayerStreamerInstance[]>;
|
|
290
|
-
/**
|
|
291
|
-
* Retrieve a single page of PlayerStreamerInstance records from the API.
|
|
292
|
-
*
|
|
293
|
-
* The request is executed immediately.
|
|
294
|
-
*
|
|
295
|
-
* If a function is passed as the first argument, it will be used as the callback
|
|
296
|
-
* function.
|
|
297
|
-
*
|
|
298
|
-
* @param { PlayerStreamerListInstancePageOptions } [params] - Options for request
|
|
299
|
-
* @param { function } [callback] - Callback to handle list of records
|
|
300
|
-
*/
|
|
301
|
-
page(callback?: (error: Error | null, items: PlayerStreamerPage) => any): Promise<PlayerStreamerPage>;
|
|
302
|
-
page(params: PlayerStreamerListInstancePageOptions, callback?: (error: Error | null, items: PlayerStreamerPage) => any): Promise<PlayerStreamerPage>;
|
|
303
|
-
/**
|
|
304
|
-
* Provide a user-friendly representation
|
|
305
|
-
*/
|
|
306
|
-
toJSON(): any;
|
|
307
|
-
[inspect.custom](_depth: any, options: InspectOptions): any;
|
|
308
|
-
}
|
|
309
|
-
export declare function PlayerStreamerListInstance(version: V1): PlayerStreamerListInstance;
|
|
310
|
-
export declare class PlayerStreamerPage extends Page<V1, PlayerStreamerPayload, PlayerStreamerResource, PlayerStreamerInstance> {
|
|
311
|
-
/**
|
|
312
|
-
* Initialize the PlayerStreamerPage
|
|
313
|
-
*
|
|
314
|
-
* @param version - Version of the resource
|
|
315
|
-
* @param response - Response from the API
|
|
316
|
-
* @param solution - Path solution
|
|
317
|
-
*/
|
|
318
|
-
constructor(version: V1, response: Response<string>, solution: PlayerStreamerSolution);
|
|
319
|
-
/**
|
|
320
|
-
* Build an instance of PlayerStreamerInstance
|
|
321
|
-
*
|
|
322
|
-
* @param payload - Payload response from the API
|
|
323
|
-
*/
|
|
324
|
-
getInstance(payload: PlayerStreamerResource): PlayerStreamerInstance;
|
|
325
|
-
[inspect.custom](depth: any, options: InspectOptions): string;
|
|
326
|
-
}
|
|
327
|
-
export {};
|