IQ

package
v0.0.0-...-94c74a9 Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2024 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DeviceId = "1008611"

	GetEpisode = "" /* 171-byte string literal not displayed */

	GetIqEpgInfo = "https://pcw-api.iq.com/api/epgInfo/%s?platformId=4&langCode=zh_cn&modeCode=intl&deviceId=ew&uid=&pspStatus="
)
View Source
var (
	GetEpgInfo = "https://itv.ptqy.gitv.tv/api/epgInfo/%s"

	GetVarietyInfo = "https://pcw-api.iqiyi.com/album/source/svlistinfo?cid=6&sourceid=%s&timelist=%s"
	GetAvlistinfo  = "https://pcw-api.iqiyi.com/albums/album/avlistinfo?aid=%s&page=%s&size=200"
)

Functions

func GetIqMateInfo

func GetIqMateInfo(ctx context.Context, sharerUrl string) (r *server.Data, code int)

func GetMateInfo

func GetMateInfo(ctx context.Context, sharerUrl string) (r *server.Data, code int)

func GetVid

func GetVid(sharerUrl string) (vid string, err error, c bool)

Types

type AvEpisode

type AvEpisode struct {
	TvId         int    `json:"tvId"`
	Description  string `json:"description"`
	Subtitle     string `json:"subtitle"`
	Vid          string `json:"vid"`
	Name         string `json:"name"`
	PlayUrl      string `json:"playUrl"`
	IssueTime    int64  `json:"issueTime"`
	PublishTime  int64  `json:"publishTime"`
	ContentType  int    `json:"contentType"`
	PayMark      int    `json:"payMark"`
	PayMarkUrl   string `json:"payMarkUrl"`
	ImageUrl     string `json:"imageUrl"`
	Duration     string `json:"duration"`
	Period       string `json:"period"`
	Exclusive    bool   `json:"exclusive"`
	Order        int    `json:"order"`
	Effective    bool   `json:"effective"`
	QiyiProduced bool   `json:"qiyiProduced"`
	Focus        string `json:"focus"`
	ShortTitle   string `json:"shortTitle"`
	People       struct {
	} `json:"people"`
	InteractionType      int      `json:"interactionType"`
	IsEnabledInteraction int      `json:"isEnabledInteraction"`
	ImageSize            []string `json:"imageSize"`
	ImageProductionType  []string `json:"imageProductionType"`
	OrderName            string   `json:"orderName"`
}

type AvList

type AvList struct {
	AlbumId           string        `json:"albumId"`
	EpisodeList       []AvEpisode   `json:"epsodelist"`
	BeforeEpisodeList []interface{} `json:"beforeEpisodeList"`
	AfterEpisodeList  []interface{} `json:"afterEpisodeList"`
	PreEpisodeList    []interface{} `json:"preEpisodeList"`
	StarEpisodeList   []interface{} `json:"starEpisodeList"`
	Updateprevuelist  []interface{} `json:"updateprevuelist"`
	Vipprevuelist     []interface{} `json:"vipprevuelist"`
	PrePrevueList     []interface{} `json:"prePrevueList"`
	StarPrevueList    []interface{} `json:"starPrevueList"`
	Size              int           `json:"size"`
	Page              int           `json:"page"`
	Total             int           `json:"total"`
	Part              int           `json:"part"`
	LatestOrder       int           `json:"latestOrder"`
	VideoCount        int           `json:"videoCount"`
	HasMore           bool          `json:"hasMore"`
}

type Epg

type Epg struct {
	QipuId             int64       `json:"qipuId"`
	QipuIdStr          string      `json:"qipuIdStr"`
	DefMultiImage      interface{} `json:"defMultiImage"`
	BackGroundPicColor interface{} `json:"backGroundPicColor"`
	ChnId              int         `json:"chnId"`
	Name               string      `json:"name"`
	ShortName          string      `json:"shortName"`
	AlbumPic           string      `json:"albumPic"`
	PosterPic          interface{} `json:"posterPic"`
	AlbumWebpPic       string      `json:"albumWebpPic"`
	Focus              string      `json:"focus"`
	Score              string      `json:"score"`
	Rating             string      `json:"rating"`
	VipInfo            struct {
	} `json:"vipInfo"`
	VipType             string        `json:"vipType"`
	IsExclusive         int           `json:"isExclusive"`
	Is3D                int           `json:"is3D"`
	Is1080              int           `json:"is1080"`
	IsDolby             int           `json:"isDolby"`
	PublishTime         string        `json:"publishTime"`
	InitIssueTime       string        `json:"initIssueTime"`
	Desc                string        `json:"desc"`
	Drm                 string        `json:"drm"`
	Hdr                 string        `json:"hdr"`
	SubTitle            string        `json:"subTitle"`
	ContentType         int           `json:"contentType"`
	IsSeries            int           `json:"isSeries"`
	Order               int           `json:"order"`
	AllowRegion         interface{}   `json:"allowRegion"`
	Categories          []int64       `json:"categories"`
	ShareAllowed        interface{}   `json:"shareAllowed"`
	PlayLocSuffix       string        `json:"playLocSuffix"`
	AlbumLocSuffix      interface{}   `json:"albumLocSuffix"`
	PlayHrefLangPile    interface{}   `json:"playHrefLangPile"`
	AlbumHrefLangPile   interface{}   `json:"albumHrefLangPile"`
	IsQiyiProduced      int           `json:"isQiyiProduced"`
	MatchedLang         int           `json:"matchedLang"`
	AlternativeTitles   []interface{} `json:"alternativeTitles"`
	AlbumPicColor       interface{}   `json:"albumPicColor"`
	IsFollowFeatured    bool          `json:"isFollowFeatured"`
	InfoControlStatus   interface{}   `json:"infoControlStatus"`
	VolunteerTranslates []interface{} `json:"volunteerTranslates"`
	FatherCollectionIds []interface{} `json:"fatherCollectionIds"`
	Season              int           `json:"season"`
	FocusImage          struct {
		FocusImagesWithLang []interface{} `json:"focusImagesWithLang"`
	} `json:"focusImage"`
	FirstPlayTimeLine     interface{} `json:"firstPlayTimeLine"`
	FirstPlayTimeOnlyDate interface{} `json:"firstPlayTimeOnlyDate"`
	PeopleInfosMap        struct {
	} `json:"peopleInfosMap"`
	AlbumId    int         `json:"albumId"`
	AlbumName  string      `json:"albumName"`
	Len        int         `json:"len"`
	Type4K     string      `json:"type4k"`
	Dolby      string      `json:"dolby"`
	SourceCode int         `json:"sourceCode"`
	Pic        string      `json:"pic"`
	PrePic     interface{} `json:"prePic"`
	DefaultVid string      `json:"defaultVid"`
	Screenshot struct {
		ImgUrl     string `json:"imgUrl"`
		WebImgUrl  string `json:"webImgUrl"`
		ImageSize  string `json:"imageSize"`
		Interval   int    `json:"interval"`
		MergeCount string `json:"mergeCount"`
	} `json:"screenshot"`
	FatherEpisodeId  int `json:"fatherEpisodeId"`
	MultiEpisodeInfo struct {
		MultiEpisodeCount int  `json:"multiEpisodeCount"`
		MultiEpisodeOrder int  `json:"multiEpisodeOrder"`
		MultiEpisode      bool `json:"multiEpisode"`
	} `json:"multiEpisodeInfo"`
	ExtraName            string      `json:"extraName"`
	AlbumIdStr           string      `json:"albumIdStr"`
	FatherEpisodeIdStr   string      `json:"fatherEpisodeIdStr"`
	FatherEpisodeIdOrder interface{} `json:"fatherEpisodeIdOrder"`
	AlbumDesc            interface{} `json:"albumDesc"`
	PCount               int         `json:"pCount"`
	PImgSize             interface{} `json:"pImgSize"`
	CImgSize             string      `json:"cImgSize"`
	CWebpImgSize         string      `json:"cWebpImgSize"`
}

type EpgInfo

type EpgInfo struct {
	ChnId            int         `json:"chnId"`
	ChnName          string      `json:"chnName"`
	QipuId           int64       `json:"qipuId"`
	AlbumId          int         `json:"albumId"`
	AlbumName        string      `json:"albumName"`
	Name             string      `json:"name"`
	Focus            string      `json:"focus"`
	AlbumPic         string      `json:"albumPic"`
	PosterPic        string      `json:"posterPic"`
	Score            string      `json:"score"`
	Drm              string      `json:"drm"`
	Hdr              string      `json:"hdr"`
	ShortName        string      `json:"shortName"`
	IsExclusive      int         `json:"isExclusive"`
	Is3D             int         `json:"is3D"`
	SourceCode       int         `json:"sourceCode"`
	Order            int         `json:"order"`
	SuperId          int         `json:"superId"`
	InitIssueTime    string      `json:"initIssueTime"`
	Len              int         `json:"len"`
	VipType          string      `json:"vipType"`
	PublishTime      string      `json:"publishTime"`
	IsSeries         int         `json:"isSeries"`
	ContentType      int         `json:"contentType"`
	ContentTypeV2    int         `json:"contentTypeV2"`
	Type4K           string      `json:"type4k"`
	Dolby            string      `json:"dolby"`
	BusinessTypes    string      `json:"businessTypes"`
	PositiveId       int         `json:"positiveId"`
	InteractType     int         `json:"interactType"`
	Dance            string      `json:"dance"`
	VipCt            string      `json:"vipCt"`
	UpUid            string      `json:"upUid"`
	AlbumPic2        string      `json:"albumPic2"`
	Cormrk           string      `json:"cormrk"`
	CanSub           int         `json:"canSub"`
	PosiPay          int         `json:"posiPay"`
	Ctt              string      `json:"ctt"`
	IeType           string      `json:"ieType"`
	AlbumChnId       int         `json:"albumChnId"`
	PHeat            int         `json:"pHeat"`
	PAlbum           interface{} `json:"pAlbum"`
	ParentPosterPic  string      `json:"parentPosterPic"`
	EtV2             int         `json:"etV2"`
	SuTime           string      `json:"suTime"`
	ShortNameV2      string      `json:"shortNameV2"`
	Copyrmrk         string      `json:"copyrmrk"`
	LimitedFree      int         `json:"limitedFree"`
	FreeEndTime      int         `json:"freeEndTime"`
	SubTitle         string      `json:"subTitle"`
	VQ               string      `json:"vQ"`
	AQ               string      `json:"aQ"`
	PCount           int         `json:"pCount"`
	Desc             string      `json:"desc"`
	Tag              string      `json:"tag"`
	TagV2            string      `json:"tagV2"`
	Color            string      `json:"color"`
	ITime            string      `json:"iTime"`
	FstFrmCov        string      `json:"fstFrmCov"`
	HRecType         string      `json:"hRecType"`
	HRecSentence     string      `json:"hRecSentence"`
	Hot              int         `json:"hot"`
	HotSwitch        int         `json:"hotSwitch"`
	ControlStatus    int         `json:"controlStatus"`
	Rating           string      `json:"rating"`
	MultiEpisodeInfo struct {
		MultiEpisodeCount int  `json:"multiEpisodeCount"`
		MultiEpisodeOrder int  `json:"multiEpisodeOrder"`
		MultiEpisode      bool `json:"multiEpisode"`
	} `json:"multiEpisodeInfo"`
	Pic                string `json:"pic"`
	CImgSize           string `json:"cImgSize"`
	Is1080             int    `json:"is1080"`
	Season             int    `json:"season"`
	InfoControlStatus  int    `json:"infoControlStatus"`
	FatherEpisodeId    int    `json:"fatherEpisodeId"`
	FatherEpisodeIdStr string `json:"fatherEpisodeIdStr"`
	IsQiyiProduced     int    `json:"isQiyiProduced"`
	AlbumIdStr         string `json:"albumIdStr"`
	ContentRating      struct {
		Display bool   `json:"display"`
		Rating  string `json:"rating"`
		Warning string `json:"warning"`
	} `json:"contentRating"`
	IsFollowFeatured    bool          `json:"isFollowFeatured"`
	VolunteerTranslates []interface{} `json:"volunteerTranslates"`
	PlayLocSuffix       string        `json:"playLocSuffix"`
	AllowRegion         []string      `json:"allowRegion"`
	Screenshot          struct {
		ImgUrl     string `json:"imgUrl"`
		WebImgUrl  string `json:"webImgUrl"`
		Interval   int    `json:"interval"`
		ImageSize  string `json:"imageSize"`
		MergeCount string `json:"mergeCount"`
	} `json:"screenshot"`
	CWebpImgSize      string   `json:"cWebpImgSize"`
	IsDolby           int      `json:"isDolby"`
	ExtraName         string   `json:"extraName"`
	QipuIdStr         string   `json:"qipuIdStr"`
	AlternativeTitles []string `json:"alternativeTitles"`
	AlbumWebpPic      string   `json:"albumWebpPic"`
	MatchedLang       int      `json:"matchedLang"`
	DefaultVid        string   `json:"defaultVid"`
	AlbumDesc         string   `json:"albumDesc"`
}

type EpgInfoIQ

type EpgInfoIQ struct {
	Total      int    `json:"total"`
	Pos        int    `json:"pos"`
	HasMore    bool   `json:"hasMore"`
	ChnId      int    `json:"chnId"`
	EpgS       []Epg  `json:"epg"`
	Code       string `json:"code"`
	SourceCode int    `json:"sourceCode"`
	AlbumId    int    `json:"albumId"`
	AlbumName  string `json:"albumName"`
}

type Iqy

type Iqy struct {
	ModeCode  string          `json:"modeCode,omitempty"`
	LangCode  string          `json:"langCode,omitempty"`
	Proxy     string          `json:"proxy,omitempty"`
	VideoList []*server.Video `json:"videoList,omitempty"`
	// contains filtered or unexported fields
}

func CreateIqy

func CreateIqy(req ...url.Request) *Iqy

func NewIq

func NewIq() *Iqy

func (*Iqy) DecodeID

func (i *Iqy) DecodeID(id string) (Rid string, err error)

func (*Iqy) GetBaseInfo

func (i *Iqy) GetBaseInfo(r *server.Data, sharerUrl string, iq bool) (epgInfo EpgInfo, err error)

func (*Iqy) GetEpgInfo

func (i *Iqy) GetEpgInfo(u string) (r EpgInfo, err error)

func (*Iqy) GetEpisodeList

func (i *Iqy) GetEpisodeList(aid string) (r []*server.Video, err error)

func (*Iqy) GetIqMateInfo

func (i *Iqy) GetIqMateInfo(sharerUrl string) (r *server.Data, err error)

func (*Iqy) GetListinfo

func (i *Iqy) GetListinfo(aid string) (r []*server.Video, err error)

func (*Iqy) GetMateInfo

func (i *Iqy) GetMateInfo(sharerUrl string) (r *server.Data, err error)

func (*Iqy) GetVarietyInfo

func (i *Iqy) GetVarietyInfo(id string) (r []*server.Video, err error)

func (*Iqy) RefreshToken

func (i *Iqy) RefreshToken() (err error)

type Rsp

type Rsp struct {
	Code string      `json:"code"`
	Data interface{} `json:"data"`
	Msg  string      `json:"msg"`
}

Jump to

Keyboard shortcuts

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