#[non_exhaustive]pub struct GetVideosRequest<'a> {
pub id: Collection<'a, VideoId>,
pub user_id: Option<Cow<'a, UserIdRef>>,
pub game_id: Option<Cow<'a, CategoryIdRef>>,
pub after: Option<Cow<'a, CursorRef>>,
pub before: Option<Cow<'a, CursorRef>>,
pub first: Option<usize>,
pub language: Option<Cow<'a, str>>,
pub period: Option<VideoPeriod>,
pub sort: Option<Sort>,
pub type_: Option<VideoTypeFilter>,
}
helix
only.Expand description
Query Parameters for Get Videos
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.id: Collection<'a, VideoId>
ID of the video being queried. Limit: 100. If this is specified, you cannot use any of the optional query parameters below.
user_id: Option<Cow<'a, UserIdRef>>
ID of the user who owns the video.
game_id: Option<Cow<'a, CategoryIdRef>>
ID of the game the video is of.
after: Option<Cow<'a, CursorRef>>
Cursor for forward pagination: tells the server where to start fetching the next set of results, in a multi-page response. The cursor value specified here is from the pagination response field of a prior query.
before: Option<Cow<'a, CursorRef>>
Cursor for backward pagination: tells the server where to start fetching the next set of results, in a multi-page response. The cursor value specified here is from the pagination response field of a prior query.
first: Option<usize>
Number of values to be returned when getting videos by user or game ID. Limit: 100. Default: 20.
language: Option<Cow<'a, str>>
Language of the video being queried. Limit: 1.
period: Option<VideoPeriod>
Period during which the video was created. Valid values: “all”, “day”, “week”, “month”. Default: “all”.
sort: Option<Sort>
Sort order of the videos. Valid values: “time”, “trending”, “views”. Default: “time”.
type_: Option<VideoTypeFilter>
Type of video. Valid values: “all”, “upload”, “archive”, “highlight”. Default: “all”.
Implementations§
Source§impl<'a> GetVideosRequest<'a>
impl<'a> GetVideosRequest<'a>
Sourcepub fn builder() -> GetVideosRequestBuilder<'a, ((), (), (), (), (), (), (), (), (), ())>
pub fn builder() -> GetVideosRequestBuilder<'a, ((), (), (), (), (), (), (), (), (), ())>
Create a builder for building GetVideosRequest
.
On the builder, call .id(...)
(optional), .user_id(...)
(optional), .game_id(...)
(optional), .after(...)
(optional), .before(...)
(optional), .first(...)
(optional), .language(...)
(optional), .period(...)
(optional), .sort(...)
(optional), .type_(...)
(optional) to set the values of the fields.
Finally, call .build()
to create the instance of GetVideosRequest
.
Source§impl<'a> GetVideosRequest<'a>
impl<'a> GetVideosRequest<'a>
Sourcepub fn ids(ids: impl Into<Collection<'a, VideoId>>) -> Self
pub fn ids(ids: impl Into<Collection<'a, VideoId>>) -> Self
IDs of the videos being queried.
Sourcepub fn user_id(user_id: impl IntoCow<'a, UserIdRef> + 'a) -> Self
pub fn user_id(user_id: impl IntoCow<'a, UserIdRef> + 'a) -> Self
ID of the user who owns the video.
Sourcepub fn game_id(game_id: impl IntoCow<'a, CategoryIdRef> + 'a) -> Self
pub fn game_id(game_id: impl IntoCow<'a, CategoryIdRef> + 'a) -> Self
ID of the game the video is of.
Trait Implementations§
Source§impl<'a> Clone for GetVideosRequest<'a>
impl<'a> Clone for GetVideosRequest<'a>
Source§fn clone(&self) -> GetVideosRequest<'a>
fn clone(&self) -> GetVideosRequest<'a>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl<'a> Debug for GetVideosRequest<'a>
impl<'a> Debug for GetVideosRequest<'a>
Source§impl<'a> Default for GetVideosRequest<'a>
impl<'a> Default for GetVideosRequest<'a>
Source§fn default() -> GetVideosRequest<'a>
fn default() -> GetVideosRequest<'a>
Source§impl<'de: 'a, 'a> Deserialize<'de> for GetVideosRequest<'a>
impl<'de: 'a, 'a> Deserialize<'de> for GetVideosRequest<'a>
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Paginated for GetVideosRequest<'_>
impl Paginated for GetVideosRequest<'_>
Source§impl<'a> PartialEq for GetVideosRequest<'a>
impl<'a> PartialEq for GetVideosRequest<'a>
Source§impl Request for GetVideosRequest<'_>
impl Request for GetVideosRequest<'_>
Source§const PATH: &'static str = "videos"
const PATH: &'static str = "videos"
channels
for Get Channel InformationSource§const SCOPE: Validator
const SCOPE: Validator
twitch_oauth2
only.Source§const OPT_SCOPE: &'static [Scope] = _
const OPT_SCOPE: &'static [Scope] = _
twitch_oauth2
only.Source§fn get_uri(&self) -> Result<Uri, InvalidUri>
fn get_uri(&self) -> Result<Uri, InvalidUri>
Source§fn get_bare_uri() -> Result<Uri, InvalidUri>
fn get_bare_uri() -> Result<Uri, InvalidUri>
Source§impl RequestGet for GetVideosRequest<'_>
impl RequestGet for GetVideosRequest<'_>
Source§fn create_request(
&self,
token: &str,
client_id: &str,
) -> Result<Request<Bytes>, CreateRequestError>
fn create_request( &self, token: &str, client_id: &str, ) -> Result<Request<Bytes>, CreateRequestError>
http::Request
from this Request
in your client