// 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 TerminateSessionGlobals 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 (t TerminateSessionGlobals) MarshalJSON() ([]byte, error) {
	return utils.MarshalJSON(t, "", false)
}

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

func (t *TerminateSessionGlobals) GetAccepts() *components.Accepts {
	if t == nil {
		return nil
	}
	return t.Accepts
}

func (t *TerminateSessionGlobals) GetClientIdentifier() *string {
	if t == nil {
		return nil
	}
	return t.ClientIdentifier
}

func (t *TerminateSessionGlobals) GetProduct() *string {
	if t == nil {
		return nil
	}
	return t.Product
}

func (t *TerminateSessionGlobals) GetVersion() *string {
	if t == nil {
		return nil
	}
	return t.Version
}

func (t *TerminateSessionGlobals) GetPlatform() *string {
	if t == nil {
		return nil
	}
	return t.Platform
}

func (t *TerminateSessionGlobals) GetPlatformVersion() *string {
	if t == nil {
		return nil
	}
	return t.PlatformVersion
}

func (t *TerminateSessionGlobals) GetDevice() *string {
	if t == nil {
		return nil
	}
	return t.Device
}

func (t *TerminateSessionGlobals) GetModel() *string {
	if t == nil {
		return nil
	}
	return t.Model
}

func (t *TerminateSessionGlobals) GetDeviceVendor() *string {
	if t == nil {
		return nil
	}
	return t.DeviceVendor
}

func (t *TerminateSessionGlobals) GetDeviceName() *string {
	if t == nil {
		return nil
	}
	return t.DeviceName
}

func (t *TerminateSessionGlobals) GetMarketplace() *string {
	if t == nil {
		return nil
	}
	return t.Marketplace
}

type TerminateSessionRequest 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"`
	// The session id (found in the `Session` element in [/status/sessions](#tag/Status/operation/statusGetSlash))
	SessionID string `queryParam:"style=form,explode=true,name=sessionId"`
	// The reason to give to the user (typically displayed in the client)
	Reason *string `queryParam:"style=form,explode=true,name=reason"`
}

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

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

func (t *TerminateSessionRequest) GetAccepts() *components.Accepts {
	if t == nil {
		return nil
	}
	return t.Accepts
}

func (t *TerminateSessionRequest) GetClientIdentifier() *string {
	if t == nil {
		return nil
	}
	return t.ClientIdentifier
}

func (t *TerminateSessionRequest) GetProduct() *string {
	if t == nil {
		return nil
	}
	return t.Product
}

func (t *TerminateSessionRequest) GetVersion() *string {
	if t == nil {
		return nil
	}
	return t.Version
}

func (t *TerminateSessionRequest) GetPlatform() *string {
	if t == nil {
		return nil
	}
	return t.Platform
}

func (t *TerminateSessionRequest) GetPlatformVersion() *string {
	if t == nil {
		return nil
	}
	return t.PlatformVersion
}

func (t *TerminateSessionRequest) GetDevice() *string {
	if t == nil {
		return nil
	}
	return t.Device
}

func (t *TerminateSessionRequest) GetModel() *string {
	if t == nil {
		return nil
	}
	return t.Model
}

func (t *TerminateSessionRequest) GetDeviceVendor() *string {
	if t == nil {
		return nil
	}
	return t.DeviceVendor
}

func (t *TerminateSessionRequest) GetDeviceName() *string {
	if t == nil {
		return nil
	}
	return t.DeviceName
}

func (t *TerminateSessionRequest) GetMarketplace() *string {
	if t == nil {
		return nil
	}
	return t.Marketplace
}

func (t *TerminateSessionRequest) GetSessionID() string {
	if t == nil {
		return ""
	}
	return t.SessionID
}

func (t *TerminateSessionRequest) GetReason() *string {
	if t == nil {
		return nil
	}
	return t.Reason
}

type TerminateSessionResponse 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 (t *TerminateSessionResponse) GetContentType() string {
	if t == nil {
		return ""
	}
	return t.ContentType
}

func (t *TerminateSessionResponse) GetStatusCode() int {
	if t == nil {
		return 0
	}
	return t.StatusCode
}

func (t *TerminateSessionResponse) GetRawResponse() *http.Response {
	if t == nil {
		return nil
	}
	return t.RawResponse
}
