Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion models.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ type Metadata struct {
ParentTitle string `json:"parentTitle"`
RatingCount int `json:"ratingCount"`
Rating float64 `json:"rating"`
Ratings []Rating `json:"Rating"`
RatingKey string `json:"ratingKey"`
SessionKey string `json:"sessionKey"`
Summary string `json:"summary"`
Expand Down Expand Up @@ -136,7 +137,6 @@ type Media struct {
Height int `json:"height"`
ID json.Number `json:"id"`
OptimizedForStreaming boolOrInt `json:"optimizedForStreaming"` // plex can return int (GetMetadata(), GetPlaylist()) or boolean (GetSessions()): 0 or 1; true or false

Selected bool `json:"selected"`
VideoCodec string `json:"videoCodec"`
VideoFrameRate string `json:"videoFrameRate"`
Expand Down Expand Up @@ -894,3 +894,10 @@ type CurrentSessions struct {
Size int `json:"size"`
} `json:"MediaContainer"`
}

// Rating
type Rating struct {
Image string `json:"image"`
Type string `json:"type"`
Value json.Number `json:"value"`
}