// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.

package operations

import (
	"github.com/LukeHagar/plexgo/internal/utils"
	"github.com/LukeHagar/plexgo/models/components"
	"net/http"
)

type AddExtrasGlobals struct {
	// Indicates the client accepts the indicated media types
	Accepts *components.Accepts `default:"application/xml" header:"style=simple,explode=false,name=accepts"`
	// An opaque identifier unique to the client
	ClientIdentifier *string `header:"style=simple,explode=false,name=X-Plex-Client-Identifier"`
	// The name of the client product
	Product *string `header:"style=simple,explode=false,name=X-Plex-Product"`
	// The version of the client application
	Version *string `header:"style=simple,explode=false,name=X-Plex-Version"`
	// The platform of the client
	Platform *string `header:"style=simple,explode=false,name=X-Plex-Platform"`
	// The version of the platform
	PlatformVersion *string `header:"style=simple,explode=false,name=X-Plex-Platform-Version"`
	// A relatively friendly name for the client device
	Device *string `header:"style=simple,explode=false,name=X-Plex-Device"`
	// A potentially less friendly identifier for the device model
	Model *string `header:"style=simple,explode=false,name=X-Plex-Model"`
	// The device vendor
	DeviceVendor *string `header:"style=simple,explode=false,name=X-Plex-Device-Vendor"`
	// A friendly name for the client
	DeviceName *string `header:"style=simple,explode=false,name=X-Plex-Device-Name"`
	// The marketplace on which the client application is distributed
	Marketplace *string `header:"style=simple,explode=false,name=X-Plex-Marketplace"`
}

func (a AddExtrasGlobals) MarshalJSON() ([]byte, error) {
	return utils.MarshalJSON(a, "", false)
}

func (a *AddExtrasGlobals) UnmarshalJSON(data []byte) error {
	if err := utils.UnmarshalJSON(data, &a, "", false, nil); err != nil {
		return err
	}
	return nil
}

func (a *AddExtrasGlobals) GetAccepts() *components.Accepts {
	if a == nil {
		return nil
	}
	return a.Accepts
}

func (a *AddExtrasGlobals) GetClientIdentifier() *string {
	if a == nil {
		return nil
	}
	return a.ClientIdentifier
}

func (a *AddExtrasGlobals) GetProduct() *string {
	if a == nil {
		return nil
	}
	return a.Product
}

func (a *AddExtrasGlobals) GetVersion() *string {
	if a == nil {
		return nil
	}
	return a.Version
}

func (a *AddExtrasGlobals) GetPlatform() *string {
	if a == nil {
		return nil
	}
	return a.Platform
}

func (a *AddExtrasGlobals) GetPlatformVersion() *string {
	if a == nil {
		return nil
	}
	return a.PlatformVersion
}

func (a *AddExtrasGlobals) GetDevice() *string {
	if a == nil {
		return nil
	}
	return a.Device
}

func (a *AddExtrasGlobals) GetModel() *string {
	if a == nil {
		return nil
	}
	return a.Model
}

func (a *AddExtrasGlobals) GetDeviceVendor() *string {
	if a == nil {
		return nil
	}
	return a.DeviceVendor
}

func (a *AddExtrasGlobals) GetDeviceName() *string {
	if a == nil {
		return nil
	}
	return a.DeviceName
}

func (a *AddExtrasGlobals) GetMarketplace() *string {
	if a == nil {
		return nil
	}
	return a.Marketplace
}

type AddExtrasRequest struct {
	// Indicates the client accepts the indicated media types
	Accepts *components.Accepts `default:"application/xml" header:"style=simple,explode=false,name=accepts"`
	// An opaque identifier unique to the client
	ClientIdentifier *string `header:"style=simple,explode=false,name=X-Plex-Client-Identifier"`
	// The name of the client product
	Product *string `header:"style=simple,explode=false,name=X-Plex-Product"`
	// The version of the client application
	Version *string `header:"style=simple,explode=false,name=X-Plex-Version"`
	// The platform of the client
	Platform *string `header:"style=simple,explode=false,name=X-Plex-Platform"`
	// The version of the platform
	PlatformVersion *string `header:"style=simple,explode=false,name=X-Plex-Platform-Version"`
	// A relatively friendly name for the client device
	Device *string `header:"style=simple,explode=false,name=X-Plex-Device"`
	// A potentially less friendly identifier for the device model
	Model *string `header:"style=simple,explode=false,name=X-Plex-Model"`
	// The device vendor
	DeviceVendor *string `header:"style=simple,explode=false,name=X-Plex-Device-Vendor"`
	// A friendly name for the client
	DeviceName *string `header:"style=simple,explode=false,name=X-Plex-Device-Name"`
	// The marketplace on which the client application is distributed
	Marketplace *string `header:"style=simple,explode=false,name=X-Plex-Marketplace"`
	Ids         string  `pathParam:"style=simple,explode=false,name=ids"`
	// The metadata type of the extra
	ExtraType *int64 `queryParam:"style=form,explode=true,name=extraType"`
	// The URL of the extra
	URL string `queryParam:"style=form,explode=true,name=url"`
	// The title to filter by or assign
	Title *string `queryParam:"style=form,explode=true,name=title"`
}

func (a AddExtrasRequest) MarshalJSON() ([]byte, error) {
	return utils.MarshalJSON(a, "", false)
}

func (a *AddExtrasRequest) UnmarshalJSON(data []byte) error {
	if err := utils.UnmarshalJSON(data, &a, "", false, []string{"ids", "url"}); err != nil {
		return err
	}
	return nil
}

func (a *AddExtrasRequest) GetAccepts() *components.Accepts {
	if a == nil {
		return nil
	}
	return a.Accepts
}

func (a *AddExtrasRequest) GetClientIdentifier() *string {
	if a == nil {
		return nil
	}
	return a.ClientIdentifier
}

func (a *AddExtrasRequest) GetProduct() *string {
	if a == nil {
		return nil
	}
	return a.Product
}

func (a *AddExtrasRequest) GetVersion() *string {
	if a == nil {
		return nil
	}
	return a.Version
}

func (a *AddExtrasRequest) GetPlatform() *string {
	if a == nil {
		return nil
	}
	return a.Platform
}

func (a *AddExtrasRequest) GetPlatformVersion() *string {
	if a == nil {
		return nil
	}
	return a.PlatformVersion
}

func (a *AddExtrasRequest) GetDevice() *string {
	if a == nil {
		return nil
	}
	return a.Device
}

func (a *AddExtrasRequest) GetModel() *string {
	if a == nil {
		return nil
	}
	return a.Model
}

func (a *AddExtrasRequest) GetDeviceVendor() *string {
	if a == nil {
		return nil
	}
	return a.DeviceVendor
}

func (a *AddExtrasRequest) GetDeviceName() *string {
	if a == nil {
		return nil
	}
	return a.DeviceName
}

func (a *AddExtrasRequest) GetMarketplace() *string {
	if a == nil {
		return nil
	}
	return a.Marketplace
}

func (a *AddExtrasRequest) GetIds() string {
	if a == nil {
		return ""
	}
	return a.Ids
}

func (a *AddExtrasRequest) GetExtraType() *int64 {
	if a == nil {
		return nil
	}
	return a.ExtraType
}

func (a *AddExtrasRequest) GetURL() string {
	if a == nil {
		return ""
	}
	return a.URL
}

func (a *AddExtrasRequest) GetTitle() *string {
	if a == nil {
		return nil
	}
	return a.Title
}

type AddExtrasResponse 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
}

func (a *AddExtrasResponse) GetContentType() string {
	if a == nil {
		return ""
	}
	return a.ContentType
}

func (a *AddExtrasResponse) GetStatusCode() int {
	if a == nil {
		return 0
	}
	return a.StatusCode
}

func (a *AddExtrasResponse) GetRawResponse() *http.Response {
	if a == nil {
		return nil
	}
	return a.RawResponse
}
