You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/// A boolean inidicating whether the video is a member-only one. If it's true, you won't be able to request the streaming info of the video except if you provide the cookies of an account that's a member of the channel.
147
152
publicvarmemberOnly:Bool?
148
153
154
+
/// The start time of the video in seconds, represents the time that was already partially watched.
155
+
publicvarstartTime:Int?
156
+
149
157
/// Count of views of the video, in a shortened string.
150
158
///
151
159
/// Possibly not defined when reading in ``YTPlaylist/frontVideos`` properties.
Copy file name to clipboardExpand all lines: Sources/YouTubeKit/YouTubeResponseTypes/VideoInfos/VideoInfosResponse.swift
+8Lines changed: 8 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -89,6 +89,11 @@ public struct VideoInfosResponse: YouTubeResponse {
89
89
/// The aspect ratio of the video (width/height).
90
90
publicvaraspectRatio:Double?
91
91
92
+
/// The start time of the video in seconds, represents the time that was already partially watched or that the "t" parameter is set in the video URL. Currently disabled because we can't make VideoInfosResponse requests with cookies.
93
+
///
94
+
/// - Note: This property is also available on ``YTVideo/startTime``, please use this value.
95
+
//public var startTime: Int? = nil
96
+
92
97
/// Array of formats used to download the video, they usually contain both audio and video data and the download speed is higher than the ``VideoInfosResponse/downloadFormats``.
93
98
//@available(*, deprecated, message: "This property is unstable for the moment.")
94
99
publicvardefaultFormats:[anyDownloadFormat]
@@ -110,6 +115,7 @@ public struct VideoInfosResponse: YouTubeResponse {
110
115
videoURLsExpireAt:Date?=nil,
111
116
viewCount:String?=nil,
112
117
aspectRatio:Double?=nil,
118
+
//startTime: Int? = nil,
113
119
defaultFormats:[anyDownloadFormat]=[],
114
120
downloadFormats:[anyDownloadFormat]=[]
115
121
){
@@ -125,6 +131,7 @@ public struct VideoInfosResponse: YouTubeResponse {
125
131
self.videoURLsExpireAt = videoURLsExpireAt
126
132
self.viewCount = viewCount
127
133
self.aspectRatio = aspectRatio
134
+
//self.startTime = startTime
128
135
self.defaultFormats = defaultFormats
129
136
self.downloadFormats = downloadFormats
130
137
}
@@ -188,6 +195,7 @@ public struct VideoInfosResponse: YouTubeResponse {
0 commit comments