thetvdb

package
v0.0.0-...-bd7e42f Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2021 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const ApiVersion = "2.2.0"

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	Search *SearchService
	Series *SeriesService

	Url string
	// contains filtered or unexported fields
}

func NewClient

func NewClient(loginParams LoginParams, httpClient *http.Client) (*Client, error)

type EpisodeResult

type EpisodeResult struct {
	AbsoluteNumber     *int     `json:"absoluteNumber"`
	AiredEpisodeNumber *int     `json:"airedEpisodeNumber"`
	AiredSeason        *int     `json:"airedSeason"`
	AirsAfterSeason    *int     `json:"airsAfterSeason"`
	AirsBeforeEpisode  *int     `json:"airsBeforeEpisode"`
	AirsBeforeSeason   *int     `json:"airsBeforeSeason"`
	Directors          []string `json:"directors"`
	DvdChapter         *int     `json:"dvdChapter"`
	DvdDiscid          *string  `json:"dvdDiscid"`
	DvdEpisodeNumber   *int     `json:"dvdEpisodeNumber"`
	DvdSeason          *int     `json:"dvdSeason"`
	EpisodeName        *string  `json:"episodeName"`
	Filename           *string  `json:"filename"`
	FirstAired         *string  `json:"firstAired"`
	GuestStars         []string `json:"guestStars"`
	Id                 *int     `json:"id"`
	ImdbId             *string  `json:"imdbId"`
	LastUpdated        *int     `json:"lastUpdated"`
	LastUpdatedBy      *int     `json:"lastUpdatedBy"`
	Overview           *string  `json:"overview"`
	ProductionCode     *string  `json:"productionCode"`
	SeriesId           *int     `json:"seriesId"`
	ShowUrl            *string  `json:"showUrl"`
	SiteRating         *float64 `json:"siteRating"`
	SiteRatingCount    *int     `json:"siteRatingCount"`
	ThumbAdded         *string  `json:"thumbAdded"`
	ThumbAuthor        *int     `json:"thumbAuthor"`
	ThumbHeight        *string  `json:"thumbHeight"`
	ThumbWidth         *string  `json:"thumbWidth"`
	Writers            []string `json:"writers"`
}
type Links struct {
	First    *int `json:"first"`
	Last     *int `json:"last"`
	Next     *int `json:"next"`
	Previous *int `json:"previous"`
}

type LoginParams

type LoginParams struct {
	ApiKey   string  `json:"apikey"`
	UserKey  *string `json:"userkey,omitempty"`
	UserName *string `json:"username,omitempty"`
}

type SearchSeriesParams

type SearchSeriesParams struct {
	Name     *string
	ImdbId   *string
	Zap2itId *string
}

type SearchSeriesResult

type SearchSeriesResult struct {
	Data []SeriesResult `json:"data"`
}

type SearchService

type SearchService struct {
	Url       string
	UrlSeries string
	// contains filtered or unexported fields
}

func (*SearchService) Series

type SeriesEpisodesParams

type SeriesEpisodesParams struct {
	Id   int
	Page *int // starts at 1
}

type SeriesEpisodesResult

type SeriesEpisodesResult struct {
	Data  []EpisodeResult `json:"data"`
	Links *Links          `json:"links"`
}

type SeriesGetParams

type SeriesGetParams struct {
	Id int
}

type SeriesGetResult

type SeriesGetResult struct {
	Data SeriesResult `json:"data"`
}

type SeriesResult

type SeriesResult struct {
	Added           *string  `json:"added"`
	AirsDayOfWeek   *string  `json:"airsDayOfWeek"`
	AirsTime        *string  `json:"airsTime"`
	Aliases         []string `json:"aliases"`
	Banner          *string  `json:"banner"`
	FirstAired      *string  `json:"firstAired"`
	Genra           []string `json:"genre"`
	Id              *int     `json:"id"`
	ImdbId          *string  `json:"imdbId"`
	LastUpdated     *int     `json:"lastUpdated"`
	Network         *string  `json:"network"`
	NetworkId       *string  `json:"networkId"`
	Overview        *string  `json:"overview"`
	Rating          *string  `json:"rating"`
	Runtime         *string  `json:"runtime"`
	SeriesId        *string  `json:"seriesId"`
	SeriesName      *string  `json:"seriesName"`
	SiteRating      *float64 `json:"siteRating"`
	SiteRatingCount *int     `json:"siteRatingCount"`
	Slug            *string  `json:"slug"`
	Status          *string  `json:"status"`
	Zap2itId        *string  `json:"zap2itId"`
}

type SeriesService

type SeriesService struct {
	Url         string
	UrlGet      string
	UrlEpisodes string
	// contains filtered or unexported fields
}

func (*SeriesService) Episodes

func (*SeriesService) Get

Jump to

Keyboard shortcuts

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