youtube

package
v0.0.0-...-406e220 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 7, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetVideoIDListByHomePageURL

func GetVideoIDListByHomePageURL(url string) ([]string, error)

GetVideoIDListByHomePageURL get video id list by home page url

Types

type ChannelInfo

type ChannelInfo struct {
	ID         string
	RSSLink    string
	Title      string
	ChannelURL string // home page url with channel id
}

ChannelInfo YouTube channel info struct

func GetChannelInfoByHomePageURL

func GetChannelInfoByHomePageURL(url string) (*ChannelInfo, error)

GetChannelInfoByHomePageURL get channel info by home page url, e.g. https://www.youtube.com/@helloworld-cn

type VideoInfo

type VideoInfo struct {
	ID            string
	URL           string
	Title         string
	Description   string
	DatePublished time.Time
	ChannelID     string
	LengthSeconds int
}

VideoInfo YouTube video info struct

func GetVideoInfo

func GetVideoInfo(videoID string) (*VideoInfo, error)

GetVideoInfo get video info

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL