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

package sdkerrors

import (
	"encoding/json"
	"net/http"
)

type GetTokenDetailsErrors struct {
	Code    *int    `json:"code,omitempty"`
	Message *string `json:"message,omitempty"`
	Status  *int    `json:"status,omitempty"`
}

func (g *GetTokenDetailsErrors) GetCode() *int {
	if g == nil {
		return nil
	}
	return g.Code
}

func (g *GetTokenDetailsErrors) GetMessage() *string {
	if g == nil {
		return nil
	}
	return g.Message
}

func (g *GetTokenDetailsErrors) GetStatus() *int {
	if g == nil {
		return nil
	}
	return g.Status
}

// GetTokenDetailsUnauthorized - Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
type GetTokenDetailsUnauthorized struct {
	Errors []GetTokenDetailsErrors `json:"errors,omitempty"`
	// Raw HTTP response; suitable for custom response parsing
	RawResponse *http.Response `json:"-"`
}

var _ error = &GetTokenDetailsUnauthorized{}

func (e *GetTokenDetailsUnauthorized) Error() string {
	data, _ := json.Marshal(e)
	return string(data)
}

type Errors struct {
	Code    *int    `json:"code,omitempty"`
	Message *string `json:"message,omitempty"`
	Status  *int    `json:"status,omitempty"`
}

func (e *Errors) GetCode() *int {
	if e == nil {
		return nil
	}
	return e.Code
}

func (e *Errors) GetMessage() *string {
	if e == nil {
		return nil
	}
	return e.Message
}

func (e *Errors) GetStatus() *int {
	if e == nil {
		return nil
	}
	return e.Status
}

// GetTokenDetailsBadRequest - Bad Request - A parameter was not specified, or was specified incorrectly.
type GetTokenDetailsBadRequest struct {
	Errors []Errors `json:"errors,omitempty"`
	// Raw HTTP response; suitable for custom response parsing
	RawResponse *http.Response `json:"-"`
}

var _ error = &GetTokenDetailsBadRequest{}

func (e *GetTokenDetailsBadRequest) Error() string {
	data, _ := json.Marshal(e)
	return string(data)
}
