mirror of
https://github.com/LukeHagar/plexgo.git
synced 2025-12-06 12:37:46 +00:00
Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
48a739d923 |
File diff suppressed because one or more lines are too long
@@ -15,7 +15,7 @@ generation:
|
||||
oAuth2ClientCredentialsEnabled: true
|
||||
oAuth2PasswordEnabled: false
|
||||
go:
|
||||
version: 0.20.0
|
||||
version: 0.20.1
|
||||
additionalDependencies: {}
|
||||
allowUnknownFieldsInWeakUnions: false
|
||||
clientServerStatusCodesAsErrors: true
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
speakeasyVersion: 1.528.1
|
||||
speakeasyVersion: 1.529.1
|
||||
sources:
|
||||
my-source:
|
||||
sourceNamespace: my-source
|
||||
@@ -9,19 +9,19 @@ sources:
|
||||
- main
|
||||
plexapi:
|
||||
sourceNamespace: plexapi
|
||||
sourceRevisionDigest: sha256:b5580df6ec4a386e12249ff13f35b916fe5559e101de4a816b53e47d6947f1a5
|
||||
sourceBlobDigest: sha256:6108b6c35fbe7e9163ffe0c804170f5e3a6edb63b8e745454ea8ee249bd790c3
|
||||
sourceRevisionDigest: sha256:ea508e3da23b283f47aeb4384d6b3ab374a27bdffb8d8d8376cedbad3ad77a06
|
||||
sourceBlobDigest: sha256:c210adbd02b0213b9e6f95ffc27f60ec38f8f9040137d55ccf2b650d92ab0ff5
|
||||
tags:
|
||||
- latest
|
||||
- speakeasy-sdk-regen-1743717350
|
||||
- speakeasy-sdk-regen-1743984636
|
||||
targets:
|
||||
plexgo:
|
||||
source: plexapi
|
||||
sourceNamespace: plexapi
|
||||
sourceRevisionDigest: sha256:b5580df6ec4a386e12249ff13f35b916fe5559e101de4a816b53e47d6947f1a5
|
||||
sourceBlobDigest: sha256:6108b6c35fbe7e9163ffe0c804170f5e3a6edb63b8e745454ea8ee249bd790c3
|
||||
sourceRevisionDigest: sha256:ea508e3da23b283f47aeb4384d6b3ab374a27bdffb8d8d8376cedbad3ad77a06
|
||||
sourceBlobDigest: sha256:c210adbd02b0213b9e6f95ffc27f60ec38f8f9040137d55ccf2b650d92ab0ff5
|
||||
codeSamplesNamespace: code-samples-go-plexgo
|
||||
codeSamplesRevisionDigest: sha256:79894823370484c5d10a5e47db8b83467214c4416cf2ce03e19eac6a031c23b9
|
||||
codeSamplesRevisionDigest: sha256:ef5bb03310bad5411cc93a8368bd70b3decee2a407df1bdaab1edd61cd96c5ad
|
||||
workflow:
|
||||
workflowVersion: 1.0.0
|
||||
speakeasyVersion: latest
|
||||
|
||||
12
RELEASES.md
12
RELEASES.md
@@ -1092,4 +1092,14 @@ Based on:
|
||||
### Generated
|
||||
- [go v0.20.0] .
|
||||
### Releases
|
||||
- [Go v0.20.0] https://github.com/LukeHagar/plexgo/releases/tag/v0.20.0 - .
|
||||
- [Go v0.20.0] https://github.com/LukeHagar/plexgo/releases/tag/v0.20.0 - .
|
||||
|
||||
## 2025-04-07 00:10:20
|
||||
### Changes
|
||||
Based on:
|
||||
- OpenAPI Doc
|
||||
- Speakeasy CLI 1.529.1 (2.566.5) https://github.com/speakeasy-api/speakeasy
|
||||
### Generated
|
||||
- [go v0.20.1] .
|
||||
### Releases
|
||||
- [Go v0.20.1] https://github.com/LukeHagar/plexgo/releases/tag/v0.20.1 - .
|
||||
@@ -5,24 +5,24 @@
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ |
|
||||
| `AllowSync` | *bool* | :heavy_check_mark: | N/A | true |
|
||||
| `Art` | *string* | :heavy_check_mark: | N/A | /:/resources/movie-fanart.jpg |
|
||||
| `Composite` | *string* | :heavy_check_mark: | N/A | /library/sections/1/composite/1705615584 |
|
||||
| `Filters` | *bool* | :heavy_check_mark: | N/A | true |
|
||||
| `Refreshing` | *bool* | :heavy_check_mark: | N/A | false |
|
||||
| `Thumb` | *string* | :heavy_check_mark: | N/A | /:/resources/movie.png |
|
||||
| `Key` | *string* | :heavy_check_mark: | N/A | 1 |
|
||||
| `Type` | *string* | :heavy_check_mark: | N/A | movie |
|
||||
| `Title` | *string* | :heavy_check_mark: | N/A | Movies |
|
||||
| `Agent` | *string* | :heavy_check_mark: | N/A | tv.plex.agents.movie |
|
||||
| `Scanner` | *string* | :heavy_check_mark: | N/A | Plex Movie |
|
||||
| `Language` | *string* | :heavy_check_mark: | N/A | en-US |
|
||||
| `UUID` | *string* | :heavy_check_mark: | N/A | 322a231a-b7f7-49f5-920f-14c61199cd30 |
|
||||
| `AllowSync` | *bool* | :heavy_check_mark: | Indicates whether syncing is allowed. | false |
|
||||
| `Art` | *string* | :heavy_check_mark: | URL for the background artwork of the media container. | /:/resources/show-fanart.jpg |
|
||||
| `Composite` | *string* | :heavy_check_mark: | The relative path to the composite media item. | /library/sections/1/composite/1743824484 |
|
||||
| `Filters` | *bool* | :heavy_check_mark: | UNKNOWN | true |
|
||||
| `Refreshing` | *bool* | :heavy_check_mark: | Indicates whether the library is currently being refreshed or updated | true |
|
||||
| `Thumb` | *string* | :heavy_check_mark: | URL for the thumbnail image of the media container. | /:/resources/show.png |
|
||||
| `Key` | *string* | :heavy_check_mark: | The library key representing the unique identifier | 1 |
|
||||
| `Type` | [operations.GetAllLibrariesType](../../models/operations/getalllibrariestype.md) | :heavy_check_mark: | N/A | movie |
|
||||
| `Title` | *string* | :heavy_check_mark: | The title of the library | Movies |
|
||||
| `Agent` | *string* | :heavy_check_mark: | The Plex agent used to match and retrieve media metadata. | tv.plex.agents.movie |
|
||||
| `Scanner` | *string* | :heavy_check_mark: | UNKNOWN | Plex Movie |
|
||||
| `Language` | *string* | :heavy_check_mark: | The Plex library language that has been set | en-US |
|
||||
| `UUID` | *string* | :heavy_check_mark: | The universally unique identifier for the library. | e69655a2-ef48-4aba-bb19-01e7d3cc34d6 |
|
||||
| `UpdatedAt` | *int64* | :heavy_check_mark: | Unix epoch datetime in seconds | 1556281940 |
|
||||
| `CreatedAt` | *int64* | :heavy_check_mark: | Unix epoch datetime in seconds | 1556281940 |
|
||||
| `CreatedAt` | **int64* | :heavy_minus_sign: | N/A | 1556281940 |
|
||||
| `ScannedAt` | *int64* | :heavy_check_mark: | Unix epoch datetime in seconds | 1556281940 |
|
||||
| `Content` | *bool* | :heavy_check_mark: | N/A | true |
|
||||
| `Directory` | *bool* | :heavy_check_mark: | N/A | true |
|
||||
| `ContentChangedAt` | *int64* | :heavy_check_mark: | Unix epoch datetime in seconds | 1556281940 |
|
||||
| `Hidden` | *int* | :heavy_check_mark: | N/A | 0 |
|
||||
| `Content` | *bool* | :heavy_check_mark: | UNKNOWN | true |
|
||||
| `Directory` | *bool* | :heavy_check_mark: | UNKNOWN | true |
|
||||
| `ContentChangedAt` | *int* | :heavy_check_mark: | The number of seconds since the content was last changed relative to now. | 9173960 |
|
||||
| `Hidden` | [*operations.Hidden](../../models/operations/hidden.md) | :heavy_minus_sign: | N/A | 1 |
|
||||
| `Location` | [][operations.GetAllLibrariesLocation](../../models/operations/getalllibrarieslocation.md) | :heavy_check_mark: | N/A | |
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| ------------------ | ------------------ | ------------------ | ------------------ | ------------------ |
|
||||
| `ID` | *int* | :heavy_check_mark: | N/A | 1 |
|
||||
| `Path` | *string* | :heavy_check_mark: | N/A | /movies |
|
||||
| Field | Type | Required | Description | Example |
|
||||
| --------------------------- | --------------------------- | --------------------------- | --------------------------- | --------------------------- |
|
||||
| `ID` | *int* | :heavy_check_mark: | The ID of the location. | 1 |
|
||||
| `Path` | *string* | :heavy_check_mark: | The path to the media item. | /Movies |
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- |
|
||||
| `Size` | *int* | :heavy_check_mark: | N/A | 5 |
|
||||
| `AllowSync` | *bool* | :heavy_check_mark: | N/A | false |
|
||||
| `Title1` | *string* | :heavy_check_mark: | N/A | Plex Library |
|
||||
| `Directory` | [][operations.GetAllLibrariesDirectory](../../models/operations/getalllibrariesdirectory.md) | :heavy_check_mark: | N/A | |
|
||||
| `Size` | *int* | :heavy_check_mark: | Number of media items returned in this response. | 50 |
|
||||
| `AllowSync` | *bool* | :heavy_check_mark: | Indicates whether syncing is allowed. | false |
|
||||
| `Title1` | *string* | :heavy_check_mark: | The primary title of the media container. | TV Series |
|
||||
| `Directory` | [][operations.GetAllLibrariesDirectory](../../models/operations/getalllibrariesdirectory.md) | :heavy_minus_sign: | N/A | |
|
||||
@@ -5,6 +5,6 @@ The libraries available on the Server
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description |
|
||||
| ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- |
|
||||
| `MediaContainer` | [operations.GetAllLibrariesMediaContainer](../../models/operations/getalllibrariesmediacontainer.md) | :heavy_check_mark: | N/A |
|
||||
| Field | Type | Required | Description |
|
||||
| ----------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------- |
|
||||
| `MediaContainer` | [*operations.GetAllLibrariesMediaContainer](../../models/operations/getalllibrariesmediacontainer.md) | :heavy_minus_sign: | N/A |
|
||||
15
docs/models/operations/getalllibrariestype.md
Normal file
15
docs/models/operations/getalllibrariestype.md
Normal file
@@ -0,0 +1,15 @@
|
||||
# GetAllLibrariesType
|
||||
|
||||
The library type
|
||||
|
||||
|
||||
## Values
|
||||
|
||||
| Name | Value |
|
||||
| ---------------------------- | ---------------------------- |
|
||||
| `GetAllLibrariesTypeMovie` | movie |
|
||||
| `GetAllLibrariesTypeTvShow` | show |
|
||||
| `GetAllLibrariesTypeSeason` | season |
|
||||
| `GetAllLibrariesTypeEpisode` | episode |
|
||||
| `GetAllLibrariesTypeArtist` | artist |
|
||||
| `GetAllLibrariesTypeAlbum` | album |
|
||||
11
docs/models/operations/hidden.md
Normal file
11
docs/models/operations/hidden.md
Normal file
@@ -0,0 +1,11 @@
|
||||
# Hidden
|
||||
|
||||
UNKNOWN
|
||||
|
||||
|
||||
## Values
|
||||
|
||||
| Name | Value |
|
||||
| --------------- | --------------- |
|
||||
| `HiddenDisable` | 0 |
|
||||
| `HiddenEnable` | 1 |
|
||||
@@ -3,11 +3,82 @@
|
||||
package operations
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"github.com/LukeHagar/plexgo/internal/utils"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// GetAllLibrariesType - The library type
|
||||
type GetAllLibrariesType string
|
||||
|
||||
const (
|
||||
GetAllLibrariesTypeMovie GetAllLibrariesType = "movie"
|
||||
GetAllLibrariesTypeTvShow GetAllLibrariesType = "show"
|
||||
GetAllLibrariesTypeSeason GetAllLibrariesType = "season"
|
||||
GetAllLibrariesTypeEpisode GetAllLibrariesType = "episode"
|
||||
GetAllLibrariesTypeArtist GetAllLibrariesType = "artist"
|
||||
GetAllLibrariesTypeAlbum GetAllLibrariesType = "album"
|
||||
)
|
||||
|
||||
func (e GetAllLibrariesType) ToPointer() *GetAllLibrariesType {
|
||||
return &e
|
||||
}
|
||||
func (e *GetAllLibrariesType) UnmarshalJSON(data []byte) error {
|
||||
var v string
|
||||
if err := json.Unmarshal(data, &v); err != nil {
|
||||
return err
|
||||
}
|
||||
switch v {
|
||||
case "movie":
|
||||
fallthrough
|
||||
case "show":
|
||||
fallthrough
|
||||
case "season":
|
||||
fallthrough
|
||||
case "episode":
|
||||
fallthrough
|
||||
case "artist":
|
||||
fallthrough
|
||||
case "album":
|
||||
*e = GetAllLibrariesType(v)
|
||||
return nil
|
||||
default:
|
||||
return fmt.Errorf("invalid value for GetAllLibrariesType: %v", v)
|
||||
}
|
||||
}
|
||||
|
||||
// Hidden - UNKNOWN
|
||||
type Hidden int
|
||||
|
||||
const (
|
||||
HiddenDisable Hidden = 0
|
||||
HiddenEnable Hidden = 1
|
||||
)
|
||||
|
||||
func (e Hidden) ToPointer() *Hidden {
|
||||
return &e
|
||||
}
|
||||
func (e *Hidden) UnmarshalJSON(data []byte) error {
|
||||
var v int
|
||||
if err := json.Unmarshal(data, &v); err != nil {
|
||||
return err
|
||||
}
|
||||
switch v {
|
||||
case 0:
|
||||
fallthrough
|
||||
case 1:
|
||||
*e = Hidden(v)
|
||||
return nil
|
||||
default:
|
||||
return fmt.Errorf("invalid value for Hidden: %v", v)
|
||||
}
|
||||
}
|
||||
|
||||
type GetAllLibrariesLocation struct {
|
||||
ID int `json:"id"`
|
||||
// The ID of the location.
|
||||
ID int `json:"id"`
|
||||
// The path to the media item.
|
||||
Path string `json:"path"`
|
||||
}
|
||||
|
||||
@@ -26,33 +97,57 @@ func (o *GetAllLibrariesLocation) GetPath() string {
|
||||
}
|
||||
|
||||
type GetAllLibrariesDirectory struct {
|
||||
AllowSync bool `json:"allowSync"`
|
||||
Art string `json:"art"`
|
||||
Composite string `json:"composite"`
|
||||
Filters bool `json:"filters"`
|
||||
Refreshing bool `json:"refreshing"`
|
||||
Thumb string `json:"thumb"`
|
||||
Key string `json:"key"`
|
||||
Type string `json:"type"`
|
||||
Title string `json:"title"`
|
||||
Agent string `json:"agent"`
|
||||
Scanner string `json:"scanner"`
|
||||
Language string `json:"language"`
|
||||
UUID string `json:"uuid"`
|
||||
// Indicates whether syncing is allowed.
|
||||
AllowSync bool `json:"allowSync"`
|
||||
// URL for the background artwork of the media container.
|
||||
Art string `json:"art"`
|
||||
// The relative path to the composite media item.
|
||||
Composite string `json:"composite"`
|
||||
// UNKNOWN
|
||||
Filters bool `json:"filters"`
|
||||
// Indicates whether the library is currently being refreshed or updated
|
||||
Refreshing bool `json:"refreshing"`
|
||||
// URL for the thumbnail image of the media container.
|
||||
Thumb string `json:"thumb"`
|
||||
// The library key representing the unique identifier
|
||||
Key string `json:"key"`
|
||||
Type GetAllLibrariesType `json:"type"`
|
||||
// The title of the library
|
||||
Title string `json:"title"`
|
||||
// The Plex agent used to match and retrieve media metadata.
|
||||
Agent string `json:"agent"`
|
||||
// UNKNOWN
|
||||
Scanner string `json:"scanner"`
|
||||
// The Plex library language that has been set
|
||||
Language string `json:"language"`
|
||||
// The universally unique identifier for the library.
|
||||
UUID string `json:"uuid"`
|
||||
// Unix epoch datetime in seconds
|
||||
UpdatedAt int64 `json:"updatedAt"`
|
||||
// Unix epoch datetime in seconds
|
||||
CreatedAt int64 `json:"createdAt"`
|
||||
UpdatedAt int64 `json:"updatedAt"`
|
||||
CreatedAt *int64 `json:"createdAt,omitempty"`
|
||||
// Unix epoch datetime in seconds
|
||||
ScannedAt int64 `json:"scannedAt"`
|
||||
Content bool `json:"content"`
|
||||
Directory bool `json:"directory"`
|
||||
// Unix epoch datetime in seconds
|
||||
ContentChangedAt int64 `json:"contentChangedAt"`
|
||||
Hidden int `json:"hidden"`
|
||||
// UNKNOWN
|
||||
Content bool `json:"content"`
|
||||
// UNKNOWN
|
||||
Directory bool `json:"directory"`
|
||||
// The number of seconds since the content was last changed relative to now.
|
||||
ContentChangedAt int `json:"contentChangedAt"`
|
||||
Hidden *Hidden `default:"0" json:"hidden"`
|
||||
Location []GetAllLibrariesLocation `json:"Location"`
|
||||
}
|
||||
|
||||
func (g GetAllLibrariesDirectory) MarshalJSON() ([]byte, error) {
|
||||
return utils.MarshalJSON(g, "", false)
|
||||
}
|
||||
|
||||
func (g *GetAllLibrariesDirectory) UnmarshalJSON(data []byte) error {
|
||||
if err := utils.UnmarshalJSON(data, &g, "", false, false); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (o *GetAllLibrariesDirectory) GetAllowSync() bool {
|
||||
if o == nil {
|
||||
return false
|
||||
@@ -102,9 +197,9 @@ func (o *GetAllLibrariesDirectory) GetKey() string {
|
||||
return o.Key
|
||||
}
|
||||
|
||||
func (o *GetAllLibrariesDirectory) GetType() string {
|
||||
func (o *GetAllLibrariesDirectory) GetType() GetAllLibrariesType {
|
||||
if o == nil {
|
||||
return ""
|
||||
return GetAllLibrariesType("")
|
||||
}
|
||||
return o.Type
|
||||
}
|
||||
@@ -151,9 +246,9 @@ func (o *GetAllLibrariesDirectory) GetUpdatedAt() int64 {
|
||||
return o.UpdatedAt
|
||||
}
|
||||
|
||||
func (o *GetAllLibrariesDirectory) GetCreatedAt() int64 {
|
||||
func (o *GetAllLibrariesDirectory) GetCreatedAt() *int64 {
|
||||
if o == nil {
|
||||
return 0
|
||||
return nil
|
||||
}
|
||||
return o.CreatedAt
|
||||
}
|
||||
@@ -179,16 +274,16 @@ func (o *GetAllLibrariesDirectory) GetDirectory() bool {
|
||||
return o.Directory
|
||||
}
|
||||
|
||||
func (o *GetAllLibrariesDirectory) GetContentChangedAt() int64 {
|
||||
func (o *GetAllLibrariesDirectory) GetContentChangedAt() int {
|
||||
if o == nil {
|
||||
return 0
|
||||
}
|
||||
return o.ContentChangedAt
|
||||
}
|
||||
|
||||
func (o *GetAllLibrariesDirectory) GetHidden() int {
|
||||
func (o *GetAllLibrariesDirectory) GetHidden() *Hidden {
|
||||
if o == nil {
|
||||
return 0
|
||||
return nil
|
||||
}
|
||||
return o.Hidden
|
||||
}
|
||||
@@ -201,10 +296,13 @@ func (o *GetAllLibrariesDirectory) GetLocation() []GetAllLibrariesLocation {
|
||||
}
|
||||
|
||||
type GetAllLibrariesMediaContainer struct {
|
||||
Size int `json:"size"`
|
||||
AllowSync bool `json:"allowSync"`
|
||||
// Number of media items returned in this response.
|
||||
Size int `json:"size"`
|
||||
// Indicates whether syncing is allowed.
|
||||
AllowSync bool `json:"allowSync"`
|
||||
// The primary title of the media container.
|
||||
Title1 string `json:"title1"`
|
||||
Directory []GetAllLibrariesDirectory `json:"Directory"`
|
||||
Directory []GetAllLibrariesDirectory `json:"Directory,omitempty"`
|
||||
}
|
||||
|
||||
func (o *GetAllLibrariesMediaContainer) GetSize() int {
|
||||
@@ -230,19 +328,19 @@ func (o *GetAllLibrariesMediaContainer) GetTitle1() string {
|
||||
|
||||
func (o *GetAllLibrariesMediaContainer) GetDirectory() []GetAllLibrariesDirectory {
|
||||
if o == nil {
|
||||
return []GetAllLibrariesDirectory{}
|
||||
return nil
|
||||
}
|
||||
return o.Directory
|
||||
}
|
||||
|
||||
// GetAllLibrariesResponseBody - The libraries available on the Server
|
||||
type GetAllLibrariesResponseBody struct {
|
||||
MediaContainer GetAllLibrariesMediaContainer `json:"MediaContainer"`
|
||||
MediaContainer *GetAllLibrariesMediaContainer `json:"MediaContainer,omitempty"`
|
||||
}
|
||||
|
||||
func (o *GetAllLibrariesResponseBody) GetMediaContainer() GetAllLibrariesMediaContainer {
|
||||
func (o *GetAllLibrariesResponseBody) GetMediaContainer() *GetAllLibrariesMediaContainer {
|
||||
if o == nil {
|
||||
return GetAllLibrariesMediaContainer{}
|
||||
return nil
|
||||
}
|
||||
return o.MediaContainer
|
||||
}
|
||||
|
||||
@@ -299,9 +299,9 @@ func New(opts ...SDKOption) *PlexAPI {
|
||||
sdkConfiguration: sdkConfiguration{
|
||||
Language: "go",
|
||||
OpenAPIDocVersion: "0.0.3",
|
||||
SDKVersion: "0.20.0",
|
||||
GenVersion: "2.565.1",
|
||||
UserAgent: "speakeasy-sdk/go 0.20.0 2.565.1 0.0.3 github.com/LukeHagar/plexgo",
|
||||
SDKVersion: "0.20.1",
|
||||
GenVersion: "2.566.5",
|
||||
UserAgent: "speakeasy-sdk/go 0.20.1 2.566.5 0.0.3 github.com/LukeHagar/plexgo",
|
||||
ServerDefaults: []map[string]string{
|
||||
{
|
||||
"protocol": "https",
|
||||
|
||||
Reference in New Issue
Block a user