14 KiB
youtubei.js / YT / History
Class: History
Extends
Constructors
new History()
new History(
actions,data,already_parsed):History
Parameters
• actions: Actions
• data: ApiResponse | IBrowseResponse
• already_parsed: boolean = false
Returns
Overrides
Defined in
src/parser/youtube/History.ts:15
Properties
feed_actions
feed_actions:
BrowseFeedActions
Defined in
src/parser/youtube/History.ts:13
sections
sections:
ItemSection[]
Defined in
src/parser/youtube/History.ts:12
Accessors
actions
getactions():Actions
Returns
Inherited from
Defined in
channels
getchannels():ObservedArray<Channel|GridChannel>
Get all the channels in the feed
Returns
ObservedArray<Channel | GridChannel>
Inherited from
Defined in
has_continuation
gethas_continuation():boolean
Checks if the feed has continuation.
Returns
boolean
Inherited from
Defined in
memo
getmemo():Memo
Returns
Inherited from
Defined in
page
getpage():T
Get the original page data
Returns
T
Inherited from
Defined in
page_contents
getpage_contents():ReloadContinuationItemsCommand|SectionList|MusicQueue|RichGrid
Returns contents from the page.
Returns
ReloadContinuationItemsCommand | SectionList | MusicQueue | RichGrid
Inherited from
Defined in
playlists
getplaylists():ObservedArray<GridPlaylist|LockupView|Playlist>
Get all playlists in the feed
Returns
ObservedArray<GridPlaylist | LockupView | Playlist>
Inherited from
Defined in
posts
getposts():ObservedArray<BackstagePost|Post|SharedPost>
Get all the community posts in the feed
Returns
ObservedArray<BackstagePost | Post | SharedPost>
Inherited from
Defined in
secondary_contents
getsecondary_contents():undefined|SuperParsedResult<YTNode>
Returns secondary contents from the page.
Returns
undefined | SuperParsedResult<YTNode>
Inherited from
Defined in
shelves
getshelves():ObservedArray<ReelShelf|RichShelf|Shelf>
Returns all segments/sections from the page.
Returns
ObservedArray<ReelShelf | RichShelf | Shelf>
Inherited from
Defined in
videos
getvideos():ObservedArray<Video|CompactVideo|GridVideo|PlaylistPanelVideo|PlaylistVideo|ReelItem|ShortsLockupView|WatchCardCompactVideo>
Get all the videos in the feed
Returns
ObservedArray<Video | CompactVideo | GridVideo | PlaylistPanelVideo | PlaylistVideo | ReelItem | ShortsLockupView | WatchCardCompactVideo>
Inherited from
Defined in
Methods
getContinuation()
getContinuation():
Promise<History>
Retrieves next batch of contents.
Returns
Promise<History>
Overrides
Defined in
src/parser/youtube/History.ts:24
getContinuationData()
getContinuationData():
Promise<undefined|IBrowseResponse>
Retrieves continuation data as it is.
Returns
Promise<undefined | IBrowseResponse>
Inherited from
Defined in
getShelf()
Finds shelf by title.
Parameters
• title: string
Returns
undefined | ReelShelf | RichShelf | Shelf
Inherited from
Defined in
removeVideo()
removeVideo(
video_id):Promise<boolean>
Removes a video from watch history.
Parameters
• video_id: string
Returns
Promise<boolean>
Defined in
src/parser/youtube/History.ts:34
getPlaylistsFromMemo()
staticgetPlaylistsFromMemo(memo):ObservedArray<GridPlaylist|LockupView|Playlist>
Get all playlists on a given page via memo
Parameters
• memo: Memo
Returns
ObservedArray<GridPlaylist | LockupView | Playlist>
Inherited from
Defined in
getVideosFromMemo()
staticgetVideosFromMemo(memo):ObservedArray<Video|CompactVideo|GridVideo|PlaylistPanelVideo|PlaylistVideo|ReelItem|ShortsLockupView|WatchCardCompactVideo>
Get all videos on a given page via memo
Parameters
• memo: Memo
Returns
ObservedArray<Video | CompactVideo | GridVideo | PlaylistPanelVideo | PlaylistVideo | ReelItem | ShortsLockupView | WatchCardCompactVideo>