mirror of
https://github.com/LukeHagar/plexterraform.git
synced 2025-12-09 20:47:45 +00:00
ci: regenerated with OpenAPI Doc 0.0.3, Speakeasy CLI 1.129.1
This commit is contained in:
136
internal/sdk/pkg/models/operations/getglobalhubs.go
Normal file
136
internal/sdk/pkg/models/operations/getglobalhubs.go
Normal file
@@ -0,0 +1,136 @@
|
||||
// Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
|
||||
package operations
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// OnlyTransient - Only return hubs which are "transient", meaning those which are prone to changing after media playback or addition (e.g. On Deck, or Recently Added).
|
||||
type OnlyTransient int64
|
||||
|
||||
const (
|
||||
OnlyTransientZero OnlyTransient = 0
|
||||
OnlyTransientOne OnlyTransient = 1
|
||||
)
|
||||
|
||||
func (e OnlyTransient) ToPointer() *OnlyTransient {
|
||||
return &e
|
||||
}
|
||||
|
||||
func (e *OnlyTransient) UnmarshalJSON(data []byte) error {
|
||||
var v int64
|
||||
if err := json.Unmarshal(data, &v); err != nil {
|
||||
return err
|
||||
}
|
||||
switch v {
|
||||
case 0:
|
||||
fallthrough
|
||||
case 1:
|
||||
*e = OnlyTransient(v)
|
||||
return nil
|
||||
default:
|
||||
return fmt.Errorf("invalid value for OnlyTransient: %v", v)
|
||||
}
|
||||
}
|
||||
|
||||
type GetGlobalHubsRequest struct {
|
||||
// The number of items to return with each hub.
|
||||
Count *float64 `queryParam:"style=form,explode=true,name=count"`
|
||||
// Only return hubs which are "transient", meaning those which are prone to changing after media playback or addition (e.g. On Deck, or Recently Added).
|
||||
OnlyTransient *OnlyTransient `queryParam:"style=form,explode=true,name=onlyTransient"`
|
||||
}
|
||||
|
||||
func (o *GetGlobalHubsRequest) GetCount() *float64 {
|
||||
if o == nil {
|
||||
return nil
|
||||
}
|
||||
return o.Count
|
||||
}
|
||||
|
||||
func (o *GetGlobalHubsRequest) GetOnlyTransient() *OnlyTransient {
|
||||
if o == nil {
|
||||
return nil
|
||||
}
|
||||
return o.OnlyTransient
|
||||
}
|
||||
|
||||
type GetGlobalHubsErrors struct {
|
||||
Code *float64 `json:"code,omitempty"`
|
||||
Message *string `json:"message,omitempty"`
|
||||
Status *float64 `json:"status,omitempty"`
|
||||
}
|
||||
|
||||
func (o *GetGlobalHubsErrors) GetCode() *float64 {
|
||||
if o == nil {
|
||||
return nil
|
||||
}
|
||||
return o.Code
|
||||
}
|
||||
|
||||
func (o *GetGlobalHubsErrors) GetMessage() *string {
|
||||
if o == nil {
|
||||
return nil
|
||||
}
|
||||
return o.Message
|
||||
}
|
||||
|
||||
func (o *GetGlobalHubsErrors) GetStatus() *float64 {
|
||||
if o == nil {
|
||||
return nil
|
||||
}
|
||||
return o.Status
|
||||
}
|
||||
|
||||
// GetGlobalHubsResponseBody - Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
|
||||
type GetGlobalHubsResponseBody struct {
|
||||
Errors []GetGlobalHubsErrors `json:"errors,omitempty"`
|
||||
}
|
||||
|
||||
func (o *GetGlobalHubsResponseBody) GetErrors() []GetGlobalHubsErrors {
|
||||
if o == nil {
|
||||
return nil
|
||||
}
|
||||
return o.Errors
|
||||
}
|
||||
|
||||
type GetGlobalHubsResponse 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
|
||||
// Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
|
||||
Object *GetGlobalHubsResponseBody
|
||||
}
|
||||
|
||||
func (o *GetGlobalHubsResponse) GetContentType() string {
|
||||
if o == nil {
|
||||
return ""
|
||||
}
|
||||
return o.ContentType
|
||||
}
|
||||
|
||||
func (o *GetGlobalHubsResponse) GetStatusCode() int {
|
||||
if o == nil {
|
||||
return 0
|
||||
}
|
||||
return o.StatusCode
|
||||
}
|
||||
|
||||
func (o *GetGlobalHubsResponse) GetRawResponse() *http.Response {
|
||||
if o == nil {
|
||||
return nil
|
||||
}
|
||||
return o.RawResponse
|
||||
}
|
||||
|
||||
func (o *GetGlobalHubsResponse) GetObject() *GetGlobalHubsResponseBody {
|
||||
if o == nil {
|
||||
return nil
|
||||
}
|
||||
return o.Object
|
||||
}
|
||||
Reference in New Issue
Block a user