plex

package module
v0.0.0-...-87f7ae4 Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2015 License: MIT Imports: 4 Imported by: 0

README

go-plex-api

Go package for working with the Plex Media Server API.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Country

type Country struct {
	XMLName xml.Name `xml:"Country"`
	Tag     string   `xml:"tag,attr"`
}

type Director

type Director struct {
	XMLName xml.Name `xml:"Director"`
	Tag     string   `xml:"tag,attr"`
}

type Directory

type Directory struct {
	XMLName      xml.Name   `xml:"Directory"`
	LocationList []Location `xml:"Location"`
	Count        int        `xml:"count,attr"`
	Key          string     `xml:"key,attr"`
	Title        string     `xml:"title,attr"`
	Art          string     `xml:"art,attr"`
	Composite    string     `xml:"composite,attr"`
	Filters      int        `xml:"filters,attr"`
	Refreshing   int        `xml:"refreshing,attr"`
	Thumb        string     `xml:"thumb,attr"`
	Type         string     `xml:"type,attr"`
	Agent        string     `xml:"agent,attr"`
	Scanner      string     `xml:"scanner,attr"`
	Language     string     `xml:"language,attr"`
	Uuid         string     `xml:"uuid,attr"`
	UpdatedAt    string     `xml:"updatedAt,attr"`
	CreatedAt    string     `xml:"createdAt,attr"`
	AllowSync    int        `xml:"allowSync,attr"`
}

type Genre

type Genre struct {
	XMLName xml.Name `xml:"Genre"`
	Tag     string   `xml:"tag,attr"`
}

type Location

type Location struct {
	XMLName xml.Name `xml:"Location"`
	Id      int      `xml:"id,attr"`
	Path    string   `xml:"path,attr"`
}

type MediaContainer

type MediaContainer struct {
	XMLName                       xml.Name    `xml:"MediaContainer"`
	DirectoryList                 []Directory `xml:"Directory"`
	VideoList                     []Video     `xml:"Video"`
	Size                          int         `xml:"size,attr"`
	AllowCameraUpload             int         `xml:"allowCameraUpload,attr"`
	AllowSync                     int         `xml:"allowSync,attr"`
	AllowChannelAccess            int         `xml:"allowChannelAccess,attr"`
	RequestParametersInCookie     int         `xml:"requestParametersInCookie,attr"`
	Sync                          int         `xml:"sync,attr"`
	TranscoderActiveVideoSessions int         `xml:"transcoderActiveVideoSessions, attr`
	TranscoderAudio               int         `xml:"transcoderAudio,attr"`
	TranscoderVideo               int         `xml:"transcoderVideo,attr"`
	TranscoderVideoBitrates       string      `xml:"transcoderVideoBitrates,attr"`
	TranscoderVideoQualities      string      `xml:"transcoderVideoQualities,attr"`
	TranscoderVideoResolutions    string      `xml:"transcoderVideoResolutions,attr"`
	FriendlyName                  string      `xml:"friendlyName,attr"`
	MachineIdentifier             string      `xml:"machineIdentifier,attr"`
}

type PlexClient

type PlexClient struct {
	SERVER_URL string
}

func New

func New(server string) PlexClient

Creates new client to the given Plex Server Url

func (*PlexClient) GetDirectories

func (p *PlexClient) GetDirectories(url string) ([]Directory, error)

Makes call for Plex directories and return the the result

func (*PlexClient) GetVideos

func (p *PlexClient) GetVideos(url string) ([]Video, error)

Get all video

type Role

type Role struct {
	XMLName xml.Name `xml:"Role"`
	Tag     string   `xml:"tag,attr"`
}

type Video

type Video struct {
	XMLName               xml.Name `xml:"Video"`
	RatingKey             string   `xml:"ratingKey,attr"`
	Key                   string   `xml:"key,attr"`
	Studio                string   `xml:"studio,attr"`
	Type                  string   `xml:"type,attr"`
	Title                 string   `xml:"title,attr"`
	TitleSort             string   `xml:"titleSort,attr"`
	ContentRating         string   `xml:"contentRating,attr"`
	Summary               string   `xml:"summary,attr"`
	Rating                string   `xml:"rating,attr"`
	ViewOffset            string   `xml:"viewOffset,attr"`
	LastViewedAt          string   `xml:"lastViewedAt,attr"`
	Year                  string   `xml:"year,attr"`
	Tagline               string   `xml:"tagline,attr"`
	Thumb                 string   `xml:"thumb,attr"`
	Art                   string   `xml:"art,attr"`
	Duration              string   `xml:"duration,attr"`
	OriginallyAvailableAt string   `xml:"originallyAvailableAt,attr"`
	AddedAt               string   `xml:"addedAt,attr"`
	UpdatedAt             string   `xml:"updatedAt,attr"`
	ChapterSource         string   `xml:"chapterSource,attr"`
}

type Writer

type Writer struct {
	XMLName xml.Name `xml:"Writer"`
	Tag     string   `xml:"tag,attr"`
}

Jump to

Keyboard shortcuts

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