Documentation
¶
Index ¶
- Variables
- func ChannelsListByUsername(username string)
- func FetchAllType(contentType string)
- func FetchOrRead(pageType string, forceRefresh bool)
- func FetchOrReadAll(forceRefresh bool)
- func GetAllPlaylistItemResponsesFromPlaylistID(id string) []*youtube.PlaylistItemListResponse
- func GetAllVideoItemsFromPlaylistID(id string) []*youtube.VideoListResponse
- func GetChannelIDFromURL(url string) string
- func GetChannelResponseFromID(id string) *youtube.ChannelListResponse
- func GetChannelResponseFromURL(url string) *youtube.ChannelListResponse
- func GetPlaylistIDFromURL(url string) string
- func GetPlaylistItemsResponseFromIDAtIndex(id string, videoIndex int64) *youtube.PlaylistItemListResponse
- func GetPlaylistItemsResponseFromURLAtIndex(url string, videoIndex int64) *youtube.PlaylistItemListResponse
- func GetPlaylistRepsonseFromURL(url string) *youtube.PlaylistListResponse
- func GetPlaylistResponseFromID(id string) *youtube.PlaylistListResponse
- func GetRandomChannel() *youtube.ChannelListResponse
- func GetRandomPlaylist() *youtube.PlaylistListResponse
- func GetRandomPlaylistItem() *youtube.PlaylistItem
- func GetRandomVideo() *youtube.VideoListResponse
- func GetVideoIDFromURL(url string) string
- func GetVideoResponseFromID(id string) *youtube.VideoListResponse
- func GetVideoResponseFromURL(url string) *youtube.VideoListResponse
Constants ¶
This section is empty.
Variables ¶
var ChannelResponses []*youtube.ChannelListResponse
ChannelResponses - holds responses from channels
var Client = &client.Services.YouTube
Client - youtube client for auth and API methods
var PageSize int64 = 50
PageSize - the number of items that will be returned in a single API call
var PlaylistItemResponses []*youtube.PlaylistItemListResponse
PlaylistItemResponses - holds responses for items of a playlist
var PlaylistResponses []*youtube.PlaylistListResponse
PlaylistResponses - holds responses from playlists
var SearchResponses []*youtube.SearchListResponse
SearchResponses - holds response from a search call
var VideoResponses []*youtube.VideoListResponse
VideoResponses - holds responses from videos
Functions ¶
func ChannelsListByUsername ¶
func ChannelsListByUsername(username string)
ChannelsListByUsername - example function from docs
func FetchAllType ¶
func FetchAllType(contentType string)
FetchAllType - Fetches responses for all of a given type
func FetchOrRead ¶
FetchOrRead - Read or fetch and write all values for a specific page type
func FetchOrReadAll ¶
func FetchOrReadAll(forceRefresh bool)
FetchOrReadAll - Fetches all content types from the Youtube API
func GetAllPlaylistItemResponsesFromPlaylistID ¶
func GetAllPlaylistItemResponsesFromPlaylistID(id string) []*youtube.PlaylistItemListResponse
GetAllPlaylistItemResponsesFromPlaylistID - Appends all playlist item responses from an ID to the main list
func GetAllVideoItemsFromPlaylistID ¶
func GetAllVideoItemsFromPlaylistID(id string) []*youtube.VideoListResponse
GetAllVideoItemsFromPlaylistID - Retruns a list of videos from playlist
func GetChannelIDFromURL ¶
GetChannelIDFromURL - Takes a string, splits it on "/" and gets the last field
func GetChannelResponseFromID ¶
func GetChannelResponseFromID(id string) *youtube.ChannelListResponse
GetChannelResponseFromID - Returns a channel response given an ID
func GetChannelResponseFromURL ¶
func GetChannelResponseFromURL(url string) *youtube.ChannelListResponse
GetChannelResponseFromURL - Returns a channel response from a URL
func GetPlaylistIDFromURL ¶
GetPlaylistIDFromURL - Takes a URL string and gets everything to the right of playlist param
func GetPlaylistItemsResponseFromIDAtIndex ¶
func GetPlaylistItemsResponseFromIDAtIndex(id string, videoIndex int64) *youtube.PlaylistItemListResponse
GetPlaylistItemsResponseFromIDAtIndex - Takes an id and position of a video in a playlist and returns a response
func GetPlaylistItemsResponseFromURLAtIndex ¶
func GetPlaylistItemsResponseFromURLAtIndex(url string, videoIndex int64) *youtube.PlaylistItemListResponse
GetPlaylistItemsResponseFromURLAtIndex - Takes a URL string and index, returns playlist items response
func GetPlaylistRepsonseFromURL ¶
func GetPlaylistRepsonseFromURL(url string) *youtube.PlaylistListResponse
GetPlaylistRepsonseFromURL - Takes a URL string and returns an playlist response
func GetPlaylistResponseFromID ¶
func GetPlaylistResponseFromID(id string) *youtube.PlaylistListResponse
GetPlaylistResponseFromID - Takes a playlist id and executes API call to playlists service
func GetRandomChannel ¶
func GetRandomChannel() *youtube.ChannelListResponse
GetRandomChannel - Returns a random playlist channel response
func GetRandomPlaylist ¶
func GetRandomPlaylist() *youtube.PlaylistListResponse
GetRandomPlaylist - Returns a random playlist response
func GetRandomPlaylistItem ¶
func GetRandomPlaylistItem() *youtube.PlaylistItem
GetRandomPlaylistItem - Returns a random playlist video response
func GetRandomVideo ¶
func GetRandomVideo() *youtube.VideoListResponse
GetRandomVideo - Returns a random video response
func GetVideoIDFromURL ¶
GetVideoIDFromURL - Get the video id from a given url
func GetVideoResponseFromID ¶
func GetVideoResponseFromID(id string) *youtube.VideoListResponse
GetVideoResponseFromID - Returns a video response from video ID
func GetVideoResponseFromURL ¶
func GetVideoResponseFromURL(url string) *youtube.VideoListResponse
GetVideoResponseFromURL - Returns a video response from a video URL
Types ¶
This section is empty.