Files
plexgo/models/sdkerrors/gettransienttoken.go

91 lines
2.1 KiB
Go

// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
package sdkerrors
import (
"encoding/json"
"net/http"
)
type GetTransientTokenAuthenticationErrors struct {
Code *int `json:"code,omitempty"`
Message *string `json:"message,omitempty"`
Status *int `json:"status,omitempty"`
}
func (g *GetTransientTokenAuthenticationErrors) GetCode() *int {
if g == nil {
return nil
}
return g.Code
}
func (g *GetTransientTokenAuthenticationErrors) GetMessage() *string {
if g == nil {
return nil
}
return g.Message
}
func (g *GetTransientTokenAuthenticationErrors) GetStatus() *int {
if g == nil {
return nil
}
return g.Status
}
// GetTransientTokenUnauthorized - Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
type GetTransientTokenUnauthorized struct {
Errors []GetTransientTokenAuthenticationErrors `json:"errors,omitempty"`
// Raw HTTP response; suitable for custom response parsing
RawResponse *http.Response `json:"-"`
}
var _ error = &GetTransientTokenUnauthorized{}
func (e *GetTransientTokenUnauthorized) Error() string {
data, _ := json.Marshal(e)
return string(data)
}
type GetTransientTokenErrors struct {
Code *int `json:"code,omitempty"`
Message *string `json:"message,omitempty"`
Status *int `json:"status,omitempty"`
}
func (g *GetTransientTokenErrors) GetCode() *int {
if g == nil {
return nil
}
return g.Code
}
func (g *GetTransientTokenErrors) GetMessage() *string {
if g == nil {
return nil
}
return g.Message
}
func (g *GetTransientTokenErrors) GetStatus() *int {
if g == nil {
return nil
}
return g.Status
}
// GetTransientTokenBadRequest - Bad Request - A parameter was not specified, or was specified incorrectly.
type GetTransientTokenBadRequest struct {
Errors []GetTransientTokenErrors `json:"errors,omitempty"`
// Raw HTTP response; suitable for custom response parsing
RawResponse *http.Response `json:"-"`
}
var _ error = &GetTransientTokenBadRequest{}
func (e *GetTransientTokenBadRequest) Error() string {
data, _ := json.Marshal(e)
return string(data)
}