From c10cf0903f8cfa2ae60b24b4988404c23be2336c Mon Sep 17 00:00:00 2001
From: The Meastro <134454779+the-maestro-bot@users.noreply.github.com>
Date: Mon, 6 May 2024 23:38:13 +0200
Subject: [PATCH] Regenerate the client library according to the new specs
---
api/openapi.yaml | 40 +++++++++++++++++++++++-----------------
api_shows.go | 7 +++++++
configuration.go | 2 +-
docs/Service.md | 10 +++++-----
model_service.go | 16 ++++++++--------
5 files changed, 44 insertions(+), 31 deletions(-)
diff --git a/api/openapi.yaml b/api/openapi.yaml
index 6b6c842..307b74e 100644
--- a/api/openapi.yaml
+++ b/api/openapi.yaml
@@ -13,22 +13,22 @@ security:
tags:
- externalDocs:
description: Official Documentation
- url: shows
+ url: https://docs.movieofthenight.com/resource/shows
name: shows
x-schema: show
- externalDocs:
description: Official Documentation
- url: countries
+ url: https://docs.movieofthenight.com/resource/countries
name: countries
x-schema: country
- externalDocs:
description: Official Documentation
- url: genres
+ url: https://docs.movieofthenight.com/resource/genres
name: genres
x-schema: genre
- externalDocs:
description: Official Documentation
- url: changes
+ url: https://docs.movieofthenight.com/resource/changes
name: changes
x-schema: change
paths:
@@ -40,7 +40,7 @@ paths:
Details of services include names, logos, supported streaming types (subscription, rent, buy, free etc.) and list of available addons/channels.
externalDocs:
description: Official Documentation
- url: countries#get-all-countries
+ url: https://docs.movieofthenight.com/resource/countries#get-all-countries
operationId: getCountries
parameters:
- $ref: '#/components/parameters/outputLanguageParam'
@@ -60,7 +60,7 @@ paths:
Details of services include names, logos, supported streaming types (subscription, rent, buy, free etc.) and list of available addons/channels.
externalDocs:
description: Official Documentation
- url: countries#get-a-country
+ url: https://docs.movieofthenight.com/resource/countries#get-a-country
operationId: getCountry
parameters:
- $ref: '#/components/parameters/countryCodeParam'
@@ -78,7 +78,7 @@ paths:
description: Get the list of supported genres.
externalDocs:
description: Official Documentation
- url: genres#get-all-genres
+ url: https://docs.movieofthenight.com/resource/genres#get-all-genres
operationId: getGenres
parameters:
- $ref: '#/components/parameters/outputLanguageParam'
@@ -96,7 +96,7 @@ paths:
\ the global streaming availability info."
externalDocs:
description: Official Documentation
- url: shows#get-a-show
+ url: https://docs.movieofthenight.com/resource/shows#get-a-show
operationId: getShow
parameters:
- $ref: '#/components/parameters/idParam'
@@ -125,13 +125,14 @@ paths:
and many more!
Apart from the info about the given country-service combinations,
output also includes information about streaming availability in the other services for the given country.
+ Streaming availability info from the other countries are not included in the response.
When show_type is movie or series_granularity is show, items per page is 20.
When show_type is series and series_granularity is episode items per page is 10.
Otherwise, items per page is 15.
externalDocs:
description: Official Documentation
- url: shows#search-shows-by-filters
+ url: https://docs.movieofthenight.com/resource/shows#search-shows-by-filters
operationId: searchShowsByFilters
parameters:
- $ref: '#/components/parameters/countryParam'
@@ -166,10 +167,16 @@ paths:
unless there are more than 20 shows with the exact given title input.
In that case all the items have 100% match with the title will be returned.
+ Streaming availability info for the target country is included in the response,
+ but not for the other countries.
+
+ Results might include shows that are not streamable in the target country.
+ Only criteria for the search are the title and the show type.
+
No pagination is supported.
externalDocs:
description: Official Documentation
- url: shows#search-shows-by-title
+ url: https://docs.movieofthenight.com/resource/shows#search-shows-by-title
operationId: searchShowsByTitle
parameters:
- $ref: '#/components/parameters/titleParam'
@@ -195,7 +202,7 @@ paths:
Changes are listed under changes field, and shows affected by these changes are listed under shows field.
externalDocs:
description: Official Documentation
- url: shows#search-shows-by-title
+ url: https://docs.movieofthenight.com/resource/shows#search-shows-by-title
operationId: getChanges
parameters:
- $ref: '#/components/parameters/countryParam'
@@ -842,7 +849,7 @@ components:
application/json:
examples:
Countries:
- externalValue: https://www.movieofthenight.com/openapi/example/countries
+ externalValue: https://www.movieofthenight.com/v4/examples/countries
summary: Countries
schema:
$ref: '#/components/schemas/countryMap'
@@ -1163,17 +1170,16 @@ components:
streamingOptionTypes:
$ref: '#/components/schemas/streamingOptionTypes'
addons:
- $ref: '#/components/schemas/addonMap'
+ description: Array of the supported addons in the service.
+ items:
+ $ref: '#/components/schemas/addon'
+ type: array
required:
- addons
- streamingOptionTypes
description: Details of a streaming service localized according to the parent
country.
title: service
- addonMap:
- additionalProperties:
- $ref: '#/components/schemas/addon'
- description: Map of the supported addons by their ids.
streamingOptionsMap:
additionalProperties:
description: Array of the streaming options found in a country.
diff --git a/api_shows.go b/api_shows.go
index d32d6ac..5941f07 100644
--- a/api_shows.go
+++ b/api_shows.go
@@ -328,6 +328,7 @@ available subtitles, audios, available video quality
and many more!
Apart from the info about the given country-service combinations,
output also includes information about streaming availability in the other services for the given country.
+Streaming availability info from the other countries are not included in the response.
When show_type is movie or series_granularity is show, items per page is 20.
When show_type is series and series_granularity is episode items per page is 10.
@@ -554,6 +555,12 @@ Maximum amount of items returned are 20
unless there are more than 20 shows with the exact given title input.
In that case all the items have 100% match with the title will be returned.
+Streaming availability info for the target country is included in the response,
+but not for the other countries.
+
+Results might include shows that are not streamable in the target country.
+Only criteria for the search are the title and the show type.
+
No pagination is supported.
diff --git a/configuration.go b/configuration.go
index 23470aa..5c37f07 100644
--- a/configuration.go
+++ b/configuration.go
@@ -89,7 +89,7 @@ type Configuration struct {
func NewConfiguration() *Configuration {
cfg := &Configuration{
DefaultHeader: make(map[string]string),
- UserAgent: "go-streaming-availability/v4.1.0",
+ UserAgent: "go-streaming-availability/v4.2.0",
Debug: false,
Servers: ServerConfigurations{
{
diff --git a/docs/Service.md b/docs/Service.md
index 0d20858..21b65c1 100644
--- a/docs/Service.md
+++ b/docs/Service.md
@@ -10,13 +10,13 @@ Name | Type | Description | Notes
**ThemeColorCode** | **string** | Associated theme color hex code of the service. |
**ImageSet** | [**ServiceImageSet**](ServiceImageSet.md) | Image set of the service. |
**StreamingOptionTypes** | [**StreamingOptionTypes**](StreamingOptionTypes.md) | |
-**Addons** | | Map of the supported addons by their ids. |
+**Addons** | [**[]Addon**](Addon.md) | Array of the supported addons in the service. |
## Methods
### NewService
-`func NewService(id string, name string, homePage string, themeColorCode string, imageSet ServiceImageSet, streamingOptionTypes StreamingOptionTypes, addons map[string]Addon, ) *Service`
+`func NewService(id string, name string, homePage string, themeColorCode string, imageSet ServiceImageSet, streamingOptionTypes StreamingOptionTypes, addons []Addon, ) *Service`
NewService instantiates a new Service object
This constructor will assign default values to properties that have it defined,
@@ -153,20 +153,20 @@ SetStreamingOptionTypes sets StreamingOptionTypes field to given value.
### GetAddons
-`func (o *Service) GetAddons() map[string]Addon`
+`func (o *Service) GetAddons() []Addon`
GetAddons returns the Addons field if non-nil, zero value otherwise.
### GetAddonsOk
-`func (o *Service) GetAddonsOk() (*map[string]Addon, bool)`
+`func (o *Service) GetAddonsOk() (*[]Addon, bool)`
GetAddonsOk returns a tuple with the Addons field if it's non-nil, zero value otherwise
and a boolean to check if the value has been set.
### SetAddons
-`func (o *Service) SetAddons(v map[string]Addon)`
+`func (o *Service) SetAddons(v []Addon)`
SetAddons sets Addons field to given value.
diff --git a/model_service.go b/model_service.go
index c51bf66..96d99a1 100644
--- a/model_service.go
+++ b/model_service.go
@@ -32,8 +32,8 @@ type Service struct {
// Image set of the service.
ImageSet ServiceImageSet `json:"imageSet"`
StreamingOptionTypes StreamingOptionTypes `json:"streamingOptionTypes"`
- // Map of the supported addons by their ids.
- Addons map[string]Addon `json:"addons"`
+ // Array of the supported addons in the service.
+ Addons []Addon `json:"addons"`
}
type _Service Service
@@ -42,7 +42,7 @@ type _Service Service
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewService(id string, name string, homePage string, themeColorCode string, imageSet ServiceImageSet, streamingOptionTypes StreamingOptionTypes, addons map[string]Addon) *Service {
+func NewService(id string, name string, homePage string, themeColorCode string, imageSet ServiceImageSet, streamingOptionTypes StreamingOptionTypes, addons []Addon) *Service {
this := Service{}
this.Id = id
this.Name = name
@@ -207,9 +207,9 @@ func (o *Service) SetStreamingOptionTypes(v StreamingOptionTypes) {
}
// GetAddons returns the Addons field value
-func (o *Service) GetAddons() map[string]Addon {
+func (o *Service) GetAddons() []Addon {
if o == nil {
- var ret map[string]Addon
+ var ret []Addon
return ret
}
@@ -218,15 +218,15 @@ func (o *Service) GetAddons() map[string]Addon {
// GetAddonsOk returns a tuple with the Addons field value
// and a boolean to check if the value has been set.
-func (o *Service) GetAddonsOk() (map[string]Addon, bool) {
+func (o *Service) GetAddonsOk() ([]Addon, bool) {
if o == nil {
- return map[string]Addon{}, false
+ return nil, false
}
return o.Addons, true
}
// SetAddons sets field value
-func (o *Service) SetAddons(v map[string]Addon) {
+func (o *Service) SetAddons(v []Addon) {
o.Addons = v
}