File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1414def channel_token (channel ):
1515 q = HiddenApiQuery ('channels/{channel}/access_token' )
1616 q .add_urlkw (keys .CHANNEL , channel )
17+ q .add_param (keys .NEED_HTTPS , Boolean .TRUE )
1718 return q
1819
1920
2021@query
2122def vod_token (video_id ):
2223 q = HiddenApiQuery ('vods/{vod}/access_token' )
2324 q .add_urlkw (keys .VOD , video_id )
25+ q .add_param (keys .NEED_HTTPS , Boolean .TRUE )
2426 return q
2527
2628
@@ -41,6 +43,7 @@ def live(channel):
4143 q .add_param (keys .SIG , token [keys .SIG ])
4244 q .add_param (keys .TOKEN , token [keys .TOKEN ])
4345 q .add_param (keys .ALLOW_SOURCE , Boolean .TRUE )
46+ q .add_param (keys .ALLOW_SPECTRE , Boolean .TRUE )
4447 return q
4548
4649
Original file line number Diff line number Diff line change 88
99
1010@query
11- def by_id (channel_id ):
11+ def by_id (channel_id , stream_type = StreamType . LIVE ):
1212 q = Qry ('streams/{id}' )
1313 q .add_urlkw (keys .ID , channel_id )
14+ q .add_param (keys .STREAM_TYPE , StreamType .validate (stream_type ), StreamType .LIVE )
1415 return q
1516
1617
Original file line number Diff line number Diff line change 66"""
77
88ALLOW_SOURCE = 'allow_source'
9+ ALLOW_SPECTRE = 'allow_spectre'
910BROADCAST_TYPE = 'broadcast_type'
1011BROADCASTS = 'broadcasts'
1112CHANNEL = 'channel'
2829NAME = 'name'
2930NAUTH = 'nauth'
3031NAUTHSIG = 'nauthsig'
32+ NEED_HTTPS = 'need_https'
3133NOTIFICATION = 'notification'
3234OFFSET = 'offset'
3335PERIOD = 'period'
You can’t perform that action at this time.
0 commit comments