// Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT. package operations import ( "github.com/LukeHagar/terraform-provider-PlexAPI/internal/sdk/pkg/utils" "net/http" "time" ) type GetSearchResultsRequest struct { // The search query string to use Query string `queryParam:"style=form,explode=true,name=query"` } func (o *GetSearchResultsRequest) GetQuery() string { if o == nil { return "" } return o.Query } type GetSearchResultsErrors struct { Code *float64 `json:"code,omitempty"` Message *string `json:"message,omitempty"` Status *float64 `json:"status,omitempty"` } func (o *GetSearchResultsErrors) GetCode() *float64 { if o == nil { return nil } return o.Code } func (o *GetSearchResultsErrors) GetMessage() *string { if o == nil { return nil } return o.Message } func (o *GetSearchResultsErrors) GetStatus() *float64 { if o == nil { return nil } return o.Status } // GetSearchResultsSearchResponseBody - Unauthorized - Returned if the X-Plex-Token is missing from the header or query. type GetSearchResultsSearchResponseBody struct { Errors []GetSearchResultsErrors `json:"errors,omitempty"` } func (o *GetSearchResultsSearchResponseBody) GetErrors() []GetSearchResultsErrors { if o == nil { return nil } return o.Errors } type GetSearchResultsPart struct { ID *float64 `json:"id,omitempty"` Key *string `json:"key,omitempty"` Duration *float64 `json:"duration,omitempty"` File *string `json:"file,omitempty"` Size *float64 `json:"size,omitempty"` AudioProfile *string `json:"audioProfile,omitempty"` Container *string `json:"container,omitempty"` VideoProfile *string `json:"videoProfile,omitempty"` } func (o *GetSearchResultsPart) GetID() *float64 { if o == nil { return nil } return o.ID } func (o *GetSearchResultsPart) GetKey() *string { if o == nil { return nil } return o.Key } func (o *GetSearchResultsPart) GetDuration() *float64 { if o == nil { return nil } return o.Duration } func (o *GetSearchResultsPart) GetFile() *string { if o == nil { return nil } return o.File } func (o *GetSearchResultsPart) GetSize() *float64 { if o == nil { return nil } return o.Size } func (o *GetSearchResultsPart) GetAudioProfile() *string { if o == nil { return nil } return o.AudioProfile } func (o *GetSearchResultsPart) GetContainer() *string { if o == nil { return nil } return o.Container } func (o *GetSearchResultsPart) GetVideoProfile() *string { if o == nil { return nil } return o.VideoProfile } type GetSearchResultsMedia struct { ID *float64 `json:"id,omitempty"` Duration *float64 `json:"duration,omitempty"` Bitrate *float64 `json:"bitrate,omitempty"` Width *float64 `json:"width,omitempty"` Height *float64 `json:"height,omitempty"` AspectRatio *float64 `json:"aspectRatio,omitempty"` AudioChannels *float64 `json:"audioChannels,omitempty"` AudioCodec *string `json:"audioCodec,omitempty"` VideoCodec *string `json:"videoCodec,omitempty"` VideoResolution *float64 `json:"videoResolution,omitempty"` Container *string `json:"container,omitempty"` VideoFrameRate *string `json:"videoFrameRate,omitempty"` AudioProfile *string `json:"audioProfile,omitempty"` VideoProfile *string `json:"videoProfile,omitempty"` Part []GetSearchResultsPart `json:"Part,omitempty"` } func (o *GetSearchResultsMedia) GetID() *float64 { if o == nil { return nil } return o.ID } func (o *GetSearchResultsMedia) GetDuration() *float64 { if o == nil { return nil } return o.Duration } func (o *GetSearchResultsMedia) GetBitrate() *float64 { if o == nil { return nil } return o.Bitrate } func (o *GetSearchResultsMedia) GetWidth() *float64 { if o == nil { return nil } return o.Width } func (o *GetSearchResultsMedia) GetHeight() *float64 { if o == nil { return nil } return o.Height } func (o *GetSearchResultsMedia) GetAspectRatio() *float64 { if o == nil { return nil } return o.AspectRatio } func (o *GetSearchResultsMedia) GetAudioChannels() *float64 { if o == nil { return nil } return o.AudioChannels } func (o *GetSearchResultsMedia) GetAudioCodec() *string { if o == nil { return nil } return o.AudioCodec } func (o *GetSearchResultsMedia) GetVideoCodec() *string { if o == nil { return nil } return o.VideoCodec } func (o *GetSearchResultsMedia) GetVideoResolution() *float64 { if o == nil { return nil } return o.VideoResolution } func (o *GetSearchResultsMedia) GetContainer() *string { if o == nil { return nil } return o.Container } func (o *GetSearchResultsMedia) GetVideoFrameRate() *string { if o == nil { return nil } return o.VideoFrameRate } func (o *GetSearchResultsMedia) GetAudioProfile() *string { if o == nil { return nil } return o.AudioProfile } func (o *GetSearchResultsMedia) GetVideoProfile() *string { if o == nil { return nil } return o.VideoProfile } func (o *GetSearchResultsMedia) GetPart() []GetSearchResultsPart { if o == nil { return nil } return o.Part } type GetSearchResultsGenre struct { Tag *string `json:"tag,omitempty"` } func (o *GetSearchResultsGenre) GetTag() *string { if o == nil { return nil } return o.Tag } type GetSearchResultsDirector struct { Tag *string `json:"tag,omitempty"` } func (o *GetSearchResultsDirector) GetTag() *string { if o == nil { return nil } return o.Tag } type GetSearchResultsWriter struct { Tag *string `json:"tag,omitempty"` } func (o *GetSearchResultsWriter) GetTag() *string { if o == nil { return nil } return o.Tag } type GetSearchResultsCountry struct { Tag *string `json:"tag,omitempty"` } func (o *GetSearchResultsCountry) GetTag() *string { if o == nil { return nil } return o.Tag } type GetSearchResultsRole struct { Tag *string `json:"tag,omitempty"` } func (o *GetSearchResultsRole) GetTag() *string { if o == nil { return nil } return o.Tag } type GetSearchResultsMetadata struct { AllowSync *bool `json:"allowSync,omitempty"` LibrarySectionID *float64 `json:"librarySectionID,omitempty"` LibrarySectionTitle *string `json:"librarySectionTitle,omitempty"` LibrarySectionUUID *string `json:"librarySectionUUID,omitempty"` Personal *bool `json:"personal,omitempty"` SourceTitle *string `json:"sourceTitle,omitempty"` RatingKey *float64 `json:"ratingKey,omitempty"` Key *string `json:"key,omitempty"` GUID *string `json:"guid,omitempty"` Studio *string `json:"studio,omitempty"` Type *string `json:"type,omitempty"` Title *string `json:"title,omitempty"` ContentRating *string `json:"contentRating,omitempty"` Summary *string `json:"summary,omitempty"` Rating *float64 `json:"rating,omitempty"` AudienceRating *float64 `json:"audienceRating,omitempty"` Year *float64 `json:"year,omitempty"` Tagline *string `json:"tagline,omitempty"` Thumb *string `json:"thumb,omitempty"` Art *string `json:"art,omitempty"` Duration *float64 `json:"duration,omitempty"` OriginallyAvailableAt *time.Time `json:"originallyAvailableAt,omitempty"` AddedAt *float64 `json:"addedAt,omitempty"` UpdatedAt *float64 `json:"updatedAt,omitempty"` AudienceRatingImage *string `json:"audienceRatingImage,omitempty"` ChapterSource *string `json:"chapterSource,omitempty"` PrimaryExtraKey *string `json:"primaryExtraKey,omitempty"` RatingImage *string `json:"ratingImage,omitempty"` Media []GetSearchResultsMedia `json:"Media,omitempty"` Genre []GetSearchResultsGenre `json:"Genre,omitempty"` Director []GetSearchResultsDirector `json:"Director,omitempty"` Writer []GetSearchResultsWriter `json:"Writer,omitempty"` Country []GetSearchResultsCountry `json:"Country,omitempty"` Role []GetSearchResultsRole `json:"Role,omitempty"` } func (g GetSearchResultsMetadata) MarshalJSON() ([]byte, error) { return utils.MarshalJSON(g, "", false) } func (g *GetSearchResultsMetadata) UnmarshalJSON(data []byte) error { if err := utils.UnmarshalJSON(data, &g, "", false, false); err != nil { return err } return nil } func (o *GetSearchResultsMetadata) GetAllowSync() *bool { if o == nil { return nil } return o.AllowSync } func (o *GetSearchResultsMetadata) GetLibrarySectionID() *float64 { if o == nil { return nil } return o.LibrarySectionID } func (o *GetSearchResultsMetadata) GetLibrarySectionTitle() *string { if o == nil { return nil } return o.LibrarySectionTitle } func (o *GetSearchResultsMetadata) GetLibrarySectionUUID() *string { if o == nil { return nil } return o.LibrarySectionUUID } func (o *GetSearchResultsMetadata) GetPersonal() *bool { if o == nil { return nil } return o.Personal } func (o *GetSearchResultsMetadata) GetSourceTitle() *string { if o == nil { return nil } return o.SourceTitle } func (o *GetSearchResultsMetadata) GetRatingKey() *float64 { if o == nil { return nil } return o.RatingKey } func (o *GetSearchResultsMetadata) GetKey() *string { if o == nil { return nil } return o.Key } func (o *GetSearchResultsMetadata) GetGUID() *string { if o == nil { return nil } return o.GUID } func (o *GetSearchResultsMetadata) GetStudio() *string { if o == nil { return nil } return o.Studio } func (o *GetSearchResultsMetadata) GetType() *string { if o == nil { return nil } return o.Type } func (o *GetSearchResultsMetadata) GetTitle() *string { if o == nil { return nil } return o.Title } func (o *GetSearchResultsMetadata) GetContentRating() *string { if o == nil { return nil } return o.ContentRating } func (o *GetSearchResultsMetadata) GetSummary() *string { if o == nil { return nil } return o.Summary } func (o *GetSearchResultsMetadata) GetRating() *float64 { if o == nil { return nil } return o.Rating } func (o *GetSearchResultsMetadata) GetAudienceRating() *float64 { if o == nil { return nil } return o.AudienceRating } func (o *GetSearchResultsMetadata) GetYear() *float64 { if o == nil { return nil } return o.Year } func (o *GetSearchResultsMetadata) GetTagline() *string { if o == nil { return nil } return o.Tagline } func (o *GetSearchResultsMetadata) GetThumb() *string { if o == nil { return nil } return o.Thumb } func (o *GetSearchResultsMetadata) GetArt() *string { if o == nil { return nil } return o.Art } func (o *GetSearchResultsMetadata) GetDuration() *float64 { if o == nil { return nil } return o.Duration } func (o *GetSearchResultsMetadata) GetOriginallyAvailableAt() *time.Time { if o == nil { return nil } return o.OriginallyAvailableAt } func (o *GetSearchResultsMetadata) GetAddedAt() *float64 { if o == nil { return nil } return o.AddedAt } func (o *GetSearchResultsMetadata) GetUpdatedAt() *float64 { if o == nil { return nil } return o.UpdatedAt } func (o *GetSearchResultsMetadata) GetAudienceRatingImage() *string { if o == nil { return nil } return o.AudienceRatingImage } func (o *GetSearchResultsMetadata) GetChapterSource() *string { if o == nil { return nil } return o.ChapterSource } func (o *GetSearchResultsMetadata) GetPrimaryExtraKey() *string { if o == nil { return nil } return o.PrimaryExtraKey } func (o *GetSearchResultsMetadata) GetRatingImage() *string { if o == nil { return nil } return o.RatingImage } func (o *GetSearchResultsMetadata) GetMedia() []GetSearchResultsMedia { if o == nil { return nil } return o.Media } func (o *GetSearchResultsMetadata) GetGenre() []GetSearchResultsGenre { if o == nil { return nil } return o.Genre } func (o *GetSearchResultsMetadata) GetDirector() []GetSearchResultsDirector { if o == nil { return nil } return o.Director } func (o *GetSearchResultsMetadata) GetWriter() []GetSearchResultsWriter { if o == nil { return nil } return o.Writer } func (o *GetSearchResultsMetadata) GetCountry() []GetSearchResultsCountry { if o == nil { return nil } return o.Country } func (o *GetSearchResultsMetadata) GetRole() []GetSearchResultsRole { if o == nil { return nil } return o.Role } type Provider struct { Key *string `json:"key,omitempty"` Title *string `json:"title,omitempty"` Type *string `json:"type,omitempty"` } func (o *Provider) GetKey() *string { if o == nil { return nil } return o.Key } func (o *Provider) GetTitle() *string { if o == nil { return nil } return o.Title } func (o *Provider) GetType() *string { if o == nil { return nil } return o.Type } type GetSearchResultsMediaContainer struct { Size *float64 `json:"size,omitempty"` Identifier *string `json:"identifier,omitempty"` MediaTagPrefix *string `json:"mediaTagPrefix,omitempty"` MediaTagVersion *float64 `json:"mediaTagVersion,omitempty"` Metadata []GetSearchResultsMetadata `json:"Metadata,omitempty"` Provider []Provider `json:"Provider,omitempty"` } func (o *GetSearchResultsMediaContainer) GetSize() *float64 { if o == nil { return nil } return o.Size } func (o *GetSearchResultsMediaContainer) GetIdentifier() *string { if o == nil { return nil } return o.Identifier } func (o *GetSearchResultsMediaContainer) GetMediaTagPrefix() *string { if o == nil { return nil } return o.MediaTagPrefix } func (o *GetSearchResultsMediaContainer) GetMediaTagVersion() *float64 { if o == nil { return nil } return o.MediaTagVersion } func (o *GetSearchResultsMediaContainer) GetMetadata() []GetSearchResultsMetadata { if o == nil { return nil } return o.Metadata } func (o *GetSearchResultsMediaContainer) GetProvider() []Provider { if o == nil { return nil } return o.Provider } // GetSearchResultsResponseBody - Search Results type GetSearchResultsResponseBody struct { MediaContainer *GetSearchResultsMediaContainer `json:"MediaContainer,omitempty"` } func (o *GetSearchResultsResponseBody) GetMediaContainer() *GetSearchResultsMediaContainer { if o == nil { return nil } return o.MediaContainer } type GetSearchResultsResponse struct { // HTTP response content type for this operation ContentType string // HTTP response status code for this operation StatusCode int // Raw HTTP response; suitable for custom response parsing RawResponse *http.Response // Search Results TwoHundredApplicationJSONObject *GetSearchResultsResponseBody // Unauthorized - Returned if the X-Plex-Token is missing from the header or query. FourHundredAndOneApplicationJSONObject *GetSearchResultsSearchResponseBody } func (o *GetSearchResultsResponse) GetContentType() string { if o == nil { return "" } return o.ContentType } func (o *GetSearchResultsResponse) GetStatusCode() int { if o == nil { return 0 } return o.StatusCode } func (o *GetSearchResultsResponse) GetRawResponse() *http.Response { if o == nil { return nil } return o.RawResponse } func (o *GetSearchResultsResponse) GetTwoHundredApplicationJSONObject() *GetSearchResultsResponseBody { if o == nil { return nil } return o.TwoHundredApplicationJSONObject } func (o *GetSearchResultsResponse) GetFourHundredAndOneApplicationJSONObject() *GetSearchResultsSearchResponseBody { if o == nil { return nil } return o.FourHundredAndOneApplicationJSONObject }