OLD | NEW |
1 // This is a generated file (see the discoveryapis_generator project). | 1 // This is a generated file (see the discoveryapis_generator project). |
2 | 2 |
3 library googleapis.youtube.v3; | 3 library googleapis.youtube.v3; |
4 | 4 |
5 import 'dart:core' as core; | 5 import 'dart:core' as core; |
6 import 'dart:async' as async; | 6 import 'dart:async' as async; |
7 import 'dart:convert' as convert; | 7 import 'dart:convert' as convert; |
8 | 8 |
9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; | 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; |
10 import 'package:crypto/crypto.dart' as crypto; | 10 import 'package:crypto/crypto.dart' as crypto; |
(...skipping 2203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2214 "POST", | 2214 "POST", |
2215 body: _body, | 2215 body: _body, |
2216 queryParams: _queryParams, | 2216 queryParams: _queryParams, |
2217 uploadOptions: _uploadOptions, | 2217 uploadOptions: _uploadOptions, |
2218 uploadMedia: _uploadMedia, | 2218 uploadMedia: _uploadMedia, |
2219 downloadOptions: _downloadOptions); | 2219 downloadOptions: _downloadOptions); |
2220 return _response.then((data) => new LiveBroadcast.fromJson(data)); | 2220 return _response.then((data) => new LiveBroadcast.fromJson(data)); |
2221 } | 2221 } |
2222 | 2222 |
2223 /** | 2223 /** |
| 2224 * Binds a YouTube broadcast to a stream or removes an existing binding |
| 2225 * between a broadcast and a stream. A broadcast can only be bound to one |
| 2226 * video stream, though a video stream may be bound to more than one |
| 2227 * broadcast. |
| 2228 * |
| 2229 * Request parameters: |
| 2230 * |
| 2231 * [id] - The id parameter specifies the unique ID of the broadcast that is |
| 2232 * being bound to a video stream. |
| 2233 * |
| 2234 * [part] - The part parameter specifies a comma-separated list of one or more |
| 2235 * liveBroadcast resource properties that the API response will include. The |
| 2236 * part names that you can include in the parameter value are id, snippet, |
| 2237 * contentDetails, and status. |
| 2238 * |
| 2239 * [onBehalfOfContentOwner] - Note: This parameter is intended exclusively for |
| 2240 * YouTube content partners. |
| 2241 * |
| 2242 * The onBehalfOfContentOwner parameter indicates that the request's |
| 2243 * authorization credentials identify a YouTube CMS user who is acting on |
| 2244 * behalf of the content owner specified in the parameter value. This |
| 2245 * parameter is intended for YouTube content partners that own and manage many |
| 2246 * different YouTube channels. It allows content owners to authenticate once |
| 2247 * and get access to all their video and channel data, without having to |
| 2248 * provide authentication credentials for each individual channel. The CMS |
| 2249 * account that the user authenticates with must be linked to the specified |
| 2250 * YouTube content owner. |
| 2251 * |
| 2252 * [onBehalfOfContentOwnerChannel] - This parameter can only be used in a |
| 2253 * properly authorized request. Note: This parameter is intended exclusively |
| 2254 * for YouTube content partners. |
| 2255 * |
| 2256 * The onBehalfOfContentOwnerChannel parameter specifies the YouTube channel |
| 2257 * ID of the channel to which a video is being added. This parameter is |
| 2258 * required when a request specifies a value for the onBehalfOfContentOwner |
| 2259 * parameter, and it can only be used in conjunction with that parameter. In |
| 2260 * addition, the request must be authorized using a CMS account that is linked |
| 2261 * to the content owner that the onBehalfOfContentOwner parameter specifies. |
| 2262 * Finally, the channel that the onBehalfOfContentOwnerChannel parameter value |
| 2263 * specifies must be linked to the content owner that the |
| 2264 * onBehalfOfContentOwner parameter specifies. |
| 2265 * |
| 2266 * This parameter is intended for YouTube content partners that own and manage |
| 2267 * many different YouTube channels. It allows content owners to authenticate |
| 2268 * once and perform actions on behalf of the channel specified in the |
| 2269 * parameter value, without having to provide authentication credentials for |
| 2270 * each separate channel. |
| 2271 * |
| 2272 * [streamId] - The streamId parameter specifies the unique ID of the video |
| 2273 * stream that is being bound to a broadcast. If this parameter is omitted, |
| 2274 * the API will remove any existing binding between the broadcast and a video |
| 2275 * stream. |
| 2276 * |
| 2277 * Completes with a [LiveBroadcast]. |
| 2278 * |
| 2279 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 2280 * error. |
| 2281 * |
| 2282 * If the used [http.Client] completes with an error when making a REST call, |
| 2283 * this method will complete with the same error. |
| 2284 */ |
| 2285 async.Future<LiveBroadcast> bindDirect(core.String id, core.String part, {core
.String onBehalfOfContentOwner, core.String onBehalfOfContentOwnerChannel, core.
String streamId}) { |
| 2286 var _url = null; |
| 2287 var _queryParams = new core.Map(); |
| 2288 var _uploadMedia = null; |
| 2289 var _uploadOptions = null; |
| 2290 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 2291 var _body = null; |
| 2292 |
| 2293 if (id == null) { |
| 2294 throw new core.ArgumentError("Parameter id is required."); |
| 2295 } |
| 2296 _queryParams["id"] = [id]; |
| 2297 if (part == null) { |
| 2298 throw new core.ArgumentError("Parameter part is required."); |
| 2299 } |
| 2300 _queryParams["part"] = [part]; |
| 2301 if (onBehalfOfContentOwner != null) { |
| 2302 _queryParams["onBehalfOfContentOwner"] = [onBehalfOfContentOwner]; |
| 2303 } |
| 2304 if (onBehalfOfContentOwnerChannel != null) { |
| 2305 _queryParams["onBehalfOfContentOwnerChannel"] = [onBehalfOfContentOwnerCha
nnel]; |
| 2306 } |
| 2307 if (streamId != null) { |
| 2308 _queryParams["streamId"] = [streamId]; |
| 2309 } |
| 2310 |
| 2311 _url = 'liveBroadcasts/bind/direct'; |
| 2312 |
| 2313 var _response = _requester.request(_url, |
| 2314 "POST", |
| 2315 body: _body, |
| 2316 queryParams: _queryParams, |
| 2317 uploadOptions: _uploadOptions, |
| 2318 uploadMedia: _uploadMedia, |
| 2319 downloadOptions: _downloadOptions); |
| 2320 return _response.then((data) => new LiveBroadcast.fromJson(data)); |
| 2321 } |
| 2322 |
| 2323 /** |
2224 * Controls the settings for a slate that can be displayed in the broadcast | 2324 * Controls the settings for a slate that can be displayed in the broadcast |
2225 * stream. | 2325 * stream. |
2226 * | 2326 * |
2227 * Request parameters: | 2327 * Request parameters: |
2228 * | 2328 * |
2229 * [id] - The id parameter specifies the YouTube live broadcast ID that | 2329 * [id] - The id parameter specifies the YouTube live broadcast ID that |
2230 * uniquely identifies the broadcast in which the slate is being updated. | 2330 * uniquely identifies the broadcast in which the slate is being updated. |
2231 * | 2331 * |
2232 * [part] - The part parameter specifies a comma-separated list of one or more | 2332 * [part] - The part parameter specifies a comma-separated list of one or more |
2233 * liveBroadcast resource properties that the API response will include. The | 2333 * liveBroadcast resource properties that the API response will include. The |
(...skipping 6731 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8965 * - "kmrb15plus" | 9065 * - "kmrb15plus" |
8966 * - "kmrbAll" | 9066 * - "kmrbAll" |
8967 * - "kmrbR" | 9067 * - "kmrbR" |
8968 * - "kmrbTeenr" | 9068 * - "kmrbTeenr" |
8969 * - "kmrbUnrated" | 9069 * - "kmrbUnrated" |
8970 */ | 9070 */ |
8971 core.String kmrbRating; | 9071 core.String kmrbRating; |
8972 /** | 9072 /** |
8973 * Rating system for Indonesia - Lembaga Sensor Film | 9073 * Rating system for Indonesia - Lembaga Sensor Film |
8974 * Possible string values are: | 9074 * Possible string values are: |
| 9075 * - "lsf13" |
| 9076 * - "lsf17" |
| 9077 * - "lsf21" |
8975 * - "lsfA" | 9078 * - "lsfA" |
8976 * - "lsfBo" | 9079 * - "lsfBo" |
8977 * - "lsfD" | 9080 * - "lsfD" |
8978 * - "lsfR" | 9081 * - "lsfR" |
8979 * - "lsfSu" | 9082 * - "lsfSu" |
8980 * - "lsfUnrated" | 9083 * - "lsfUnrated" |
8981 */ | 9084 */ |
8982 core.String lsfRating; | 9085 core.String lsfRating; |
8983 /** | 9086 /** |
8984 * Rating system for Malta - Film Age-Classification Board | 9087 * Rating system for Malta - Film Age-Classification Board |
(...skipping 2462 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11447 * How severe this issue is to the stream. | 11550 * How severe this issue is to the stream. |
11448 * Possible string values are: | 11551 * Possible string values are: |
11449 * - "error" | 11552 * - "error" |
11450 * - "info" | 11553 * - "info" |
11451 * - "warning" | 11554 * - "warning" |
11452 */ | 11555 */ |
11453 core.String severity; | 11556 core.String severity; |
11454 /** | 11557 /** |
11455 * The kind of error happening. | 11558 * The kind of error happening. |
11456 * Possible string values are: | 11559 * Possible string values are: |
11457 * - "audioBitrate" | |
11458 * - "audioBitrateHigh" | 11560 * - "audioBitrateHigh" |
11459 * - "audioBitrateLow" | 11561 * - "audioBitrateLow" |
| 11562 * - "audioBitrateMismatch" |
11460 * - "audioCodec" | 11563 * - "audioCodec" |
11461 * - "audioCodecMismatch" | 11564 * - "audioCodecMismatch" |
11462 * - "audioSampleRate" | 11565 * - "audioSampleRate" |
11463 * - "audioSampleRateMismatch" | 11566 * - "audioSampleRateMismatch" |
11464 * - "audioStereoMismatch" | 11567 * - "audioStereoMismatch" |
11465 * - "audioTooManyChannel" | 11568 * - "audioTooManyChannels" |
11466 * - "badContainer" | 11569 * - "badContainer" |
11467 * - "bitrateHigh" | 11570 * - "bitrateHigh" |
11468 * - "bitrateLow" | 11571 * - "bitrateLow" |
11469 * - "framerateHigh" | 11572 * - "frameRateHigh" |
11470 * - "framerateMismatch" | 11573 * - "framerateMismatch" |
11471 * - "gopMismatch" | 11574 * - "gopMismatch" |
11472 * - "gopSizeLong" | 11575 * - "gopSizeLong" |
11473 * - "gopSizeOver" | 11576 * - "gopSizeOver" |
11474 * - "gopSizeShort" | 11577 * - "gopSizeShort" |
11475 * - "interlaceVideo" | 11578 * - "interlacedVideo" |
11476 * - "multipleAudioStreams" | 11579 * - "multipleAudioStreams" |
11477 * - "multipleVideoStreams" | 11580 * - "multipleVideoStreams" |
11478 * - "noAudioStream" | 11581 * - "noAudioStream" |
11479 * - "noVideoStream" | 11582 * - "noVideoStream" |
11480 * - "openGop" | 11583 * - "openGop" |
11481 * - "resolutionMismatch" | 11584 * - "resolutionMismatch" |
11482 * - "videoBitrateMismatch" | 11585 * - "videoBitrateMismatch" |
11483 * - "videoCodec" | 11586 * - "videoCodec" |
11484 * - "videoCodecMismatch" | 11587 * - "videoCodecMismatch" |
11485 * - "videoIngestionStarved" | 11588 * - "videoIngestionStarved" |
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11568 _json["isReusable"] = isReusable; | 11671 _json["isReusable"] = isReusable; |
11569 } | 11672 } |
11570 return _json; | 11673 return _json; |
11571 } | 11674 } |
11572 } | 11675 } |
11573 | 11676 |
11574 class LiveStreamHealthStatus { | 11677 class LiveStreamHealthStatus { |
11575 /** The configurations issues on this stream */ | 11678 /** The configurations issues on this stream */ |
11576 core.List<LiveStreamConfigurationIssue> configurationIssues; | 11679 core.List<LiveStreamConfigurationIssue> configurationIssues; |
11577 /** The last time this status was updated (in seconds) */ | 11680 /** The last time this status was updated (in seconds) */ |
11578 core.String lastUpdateTimeS; | 11681 core.String lastUpdateTimeSeconds; |
11579 /** | 11682 /** |
11580 * The status code of this stream | 11683 * The status code of this stream |
11581 * Possible string values are: | 11684 * Possible string values are: |
11582 * - "bad" | 11685 * - "bad" |
11583 * - "good" | 11686 * - "good" |
11584 * - "noData" | 11687 * - "noData" |
11585 * - "ok" | 11688 * - "ok" |
11586 * - "revoked" | 11689 * - "revoked" |
11587 */ | 11690 */ |
11588 core.String status; | 11691 core.String status; |
11589 | 11692 |
11590 LiveStreamHealthStatus(); | 11693 LiveStreamHealthStatus(); |
11591 | 11694 |
11592 LiveStreamHealthStatus.fromJson(core.Map _json) { | 11695 LiveStreamHealthStatus.fromJson(core.Map _json) { |
11593 if (_json.containsKey("configurationIssues")) { | 11696 if (_json.containsKey("configurationIssues")) { |
11594 configurationIssues = _json["configurationIssues"].map((value) => new Live
StreamConfigurationIssue.fromJson(value)).toList(); | 11697 configurationIssues = _json["configurationIssues"].map((value) => new Live
StreamConfigurationIssue.fromJson(value)).toList(); |
11595 } | 11698 } |
11596 if (_json.containsKey("lastUpdateTimeS")) { | 11699 if (_json.containsKey("lastUpdateTimeSeconds")) { |
11597 lastUpdateTimeS = _json["lastUpdateTimeS"]; | 11700 lastUpdateTimeSeconds = _json["lastUpdateTimeSeconds"]; |
11598 } | 11701 } |
11599 if (_json.containsKey("status")) { | 11702 if (_json.containsKey("status")) { |
11600 status = _json["status"]; | 11703 status = _json["status"]; |
11601 } | 11704 } |
11602 } | 11705 } |
11603 | 11706 |
11604 core.Map toJson() { | 11707 core.Map toJson() { |
11605 var _json = new core.Map(); | 11708 var _json = new core.Map(); |
11606 if (configurationIssues != null) { | 11709 if (configurationIssues != null) { |
11607 _json["configurationIssues"] = configurationIssues.map((value) => (value).
toJson()).toList(); | 11710 _json["configurationIssues"] = configurationIssues.map((value) => (value).
toJson()).toList(); |
11608 } | 11711 } |
11609 if (lastUpdateTimeS != null) { | 11712 if (lastUpdateTimeSeconds != null) { |
11610 _json["lastUpdateTimeS"] = lastUpdateTimeS; | 11713 _json["lastUpdateTimeSeconds"] = lastUpdateTimeSeconds; |
11611 } | 11714 } |
11612 if (status != null) { | 11715 if (status != null) { |
11613 _json["status"] = status; | 11716 _json["status"] = status; |
11614 } | 11717 } |
11615 return _json; | 11718 return _json; |
11616 } | 11719 } |
11617 } | 11720 } |
11618 | 11721 |
11619 class LiveStreamListResponse { | 11722 class LiveStreamListResponse { |
11620 /** Etag of this resource. */ | 11723 /** Etag of this resource. */ |
(...skipping 4383 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
16004 } | 16107 } |
16005 if (featuredPlaylistId != null) { | 16108 if (featuredPlaylistId != null) { |
16006 _json["featuredPlaylistId"] = featuredPlaylistId; | 16109 _json["featuredPlaylistId"] = featuredPlaylistId; |
16007 } | 16110 } |
16008 if (textColor != null) { | 16111 if (textColor != null) { |
16009 _json["textColor"] = textColor; | 16112 _json["textColor"] = textColor; |
16010 } | 16113 } |
16011 return _json; | 16114 return _json; |
16012 } | 16115 } |
16013 } | 16116 } |
OLD | NEW |