zernio-sdk 0.0.938 → 0.0.939

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3f518306074cb6e1b8a6cf4c10997bf0a440dde55c411b2c5c2220d236c981d7
4
- data.tar.gz: 4852bef71356e8383778f33e67a13ac449f49ce0ac6133055174fe292bac6719
3
+ metadata.gz: 262ea969618883677c6f9c9e1d880f826dee96ef166d81eb10a45b596aaa3965
4
+ data.tar.gz: 384fd02688d9dfff545f211866ce7245d8776599ca62d84587075ae13e80862e
5
5
  SHA512:
6
- metadata.gz: d724933b2389275bd7bf9badb2e322a040958751d930a25e0a7d04ebcc69a0b913e03cdebac7412aae416578ab6f29ea97bca408478d70bd9fd38ee858a9384b
7
- data.tar.gz: 515dd6092b6aaa577bf40db7353631a67c5894ee3a633fd83f932024069ea88d8d1556806358f9e7e2a85622d3351e47053768a671d50f6780403e7b3a72071e
6
+ metadata.gz: 8947524188116fad233204ec3231beba25626c231a5d106b298af7ce3accb604480bc7bb9e33dee44d13d43a65017a7b5b8a5b5289761a620b0bb8037c49a810
7
+ data.tar.gz: 2d18b4a8a864fc7f34c8f1ff1498df5d122eb518b9c0e87e54c5bde6afe506a9f7acf3c5923d9604d78b034835e0f9cc3a6294ce2cea5d952cbca9e16cff3f8d
data/README.md CHANGED
@@ -380,6 +380,7 @@ Class | Method | HTTP request | Description
380
380
  *Zernio::ConnectApi* | [**connect_whats_app_credentials**](docs/ConnectApi.md#connect_whats_app_credentials) | **POST** /v1/connect/whatsapp/credentials | Connect WhatsApp via credentials
381
381
  *Zernio::ConnectApi* | [**connect_whats_app_embedded_signup**](docs/ConnectApi.md#connect_whats_app_embedded_signup) | **POST** /v1/connect/whatsapp/embedded-signup | Connect WhatsApp from Embedded Signup
382
382
  *Zernio::ConnectApi* | [**create_pinterest_board**](docs/ConnectApi.md#create_pinterest_board) | **POST** /v1/accounts/{accountId}/pinterest-boards | Create Pinterest board
383
+ *Zernio::ConnectApi* | [**create_youtube_playlist**](docs/ConnectApi.md#create_youtube_playlist) | **POST** /v1/accounts/{accountId}/youtube-playlists | Create YouTube playlist
383
384
  *Zernio::ConnectApi* | [**get_connect_url**](docs/ConnectApi.md#get_connect_url) | **GET** /v1/connect/{platform} | Get OAuth connect URL
384
385
  *Zernio::ConnectApi* | [**get_facebook_pages**](docs/ConnectApi.md#get_facebook_pages) | **GET** /v1/accounts/{accountId}/facebook-page | List Facebook pages
385
386
  *Zernio::ConnectApi* | [**get_gmb_locations**](docs/ConnectApi.md#get_gmb_locations) | **GET** /v1/accounts/{accountId}/gmb-locations | List Google Business Profile locations
@@ -1229,6 +1230,9 @@ Class | Method | HTTP request | Description
1229
1230
  - [Zernio::CreateWorkflow200Response](docs/CreateWorkflow200Response.md)
1230
1231
  - [Zernio::CreateWorkflow200ResponseWorkflow](docs/CreateWorkflow200ResponseWorkflow.md)
1231
1232
  - [Zernio::CreateWorkflowRequest](docs/CreateWorkflowRequest.md)
1233
+ - [Zernio::CreateYoutubePlaylist201Response](docs/CreateYoutubePlaylist201Response.md)
1234
+ - [Zernio::CreateYoutubePlaylist201ResponsePlaylist](docs/CreateYoutubePlaylist201ResponsePlaylist.md)
1235
+ - [Zernio::CreateYoutubePlaylistRequest](docs/CreateYoutubePlaylistRequest.md)
1232
1236
  - [Zernio::CrosspostDiscordMessage200Response](docs/CrosspostDiscordMessage200Response.md)
1233
1237
  - [Zernio::CtwaAdRequestBody](docs/CtwaAdRequestBody.md)
1234
1238
  - [Zernio::CtwaAdRequestBodyCitiesInner](docs/CtwaAdRequestBodyCitiesInner.md)
data/docs/ConnectApi.md CHANGED
@@ -18,6 +18,7 @@ All URIs are relative to *https://zernio.com/api*
18
18
  | [**connect_whats_app_credentials**](ConnectApi.md#connect_whats_app_credentials) | **POST** /v1/connect/whatsapp/credentials | Connect WhatsApp via credentials |
19
19
  | [**connect_whats_app_embedded_signup**](ConnectApi.md#connect_whats_app_embedded_signup) | **POST** /v1/connect/whatsapp/embedded-signup | Connect WhatsApp from Embedded Signup |
20
20
  | [**create_pinterest_board**](ConnectApi.md#create_pinterest_board) | **POST** /v1/accounts/{accountId}/pinterest-boards | Create Pinterest board |
21
+ | [**create_youtube_playlist**](ConnectApi.md#create_youtube_playlist) | **POST** /v1/accounts/{accountId}/youtube-playlists | Create YouTube playlist |
21
22
  | [**get_connect_url**](ConnectApi.md#get_connect_url) | **GET** /v1/connect/{platform} | Get OAuth connect URL |
22
23
  | [**get_facebook_pages**](ConnectApi.md#get_facebook_pages) | **GET** /v1/accounts/{accountId}/facebook-page | List Facebook pages |
23
24
  | [**get_gmb_locations**](ConnectApi.md#get_gmb_locations) | **GET** /v1/accounts/{accountId}/gmb-locations | List Google Business Profile locations |
@@ -1056,6 +1057,77 @@ end
1056
1057
  - **Accept**: application/json
1057
1058
 
1058
1059
 
1060
+ ## create_youtube_playlist
1061
+
1062
+ > <CreateYoutubePlaylist201Response> create_youtube_playlist(account_id, create_youtube_playlist_request)
1063
+
1064
+ Create YouTube playlist
1065
+
1066
+ Creates an empty playlist on the connected YouTube channel. Requires a title; privacy defaults to private. Returns the same playlist shape as the list endpoint. Pass the returned playlist.id as platformSpecificData.playlistId when publishing a video. Does not change the account's default playlist. Requires the youtube or youtube.force-ssl OAuth scope. Costs 50 YouTube quota units. This operation is not idempotent and is not automatically retried: repeating a request can create another playlist, including after a timeout. List playlists before retrying an ambiguous failure. Official series settings are not exposed by YouTube's public API and must be enabled manually in YouTube's desktop playlist settings.
1067
+
1068
+ ### Examples
1069
+
1070
+ ```ruby
1071
+ require 'time'
1072
+ require 'zernio-sdk'
1073
+ # setup authorization
1074
+ Zernio.configure do |config|
1075
+ # Configure Bearer authorization (JWT): bearerAuth
1076
+ config.access_token = 'YOUR_BEARER_TOKEN'
1077
+ end
1078
+
1079
+ api_instance = Zernio::ConnectApi.new
1080
+ account_id = 'account_id_example' # String |
1081
+ create_youtube_playlist_request = Zernio::CreateYoutubePlaylistRequest.new({title: 'title_example'}) # CreateYoutubePlaylistRequest |
1082
+
1083
+ begin
1084
+ # Create YouTube playlist
1085
+ result = api_instance.create_youtube_playlist(account_id, create_youtube_playlist_request)
1086
+ p result
1087
+ rescue Zernio::ApiError => e
1088
+ puts "Error when calling ConnectApi->create_youtube_playlist: #{e}"
1089
+ end
1090
+ ```
1091
+
1092
+ #### Using the create_youtube_playlist_with_http_info variant
1093
+
1094
+ This returns an Array which contains the response data, status code and headers.
1095
+
1096
+ > <Array(<CreateYoutubePlaylist201Response>, Integer, Hash)> create_youtube_playlist_with_http_info(account_id, create_youtube_playlist_request)
1097
+
1098
+ ```ruby
1099
+ begin
1100
+ # Create YouTube playlist
1101
+ data, status_code, headers = api_instance.create_youtube_playlist_with_http_info(account_id, create_youtube_playlist_request)
1102
+ p status_code # => 2xx
1103
+ p headers # => { ... }
1104
+ p data # => <CreateYoutubePlaylist201Response>
1105
+ rescue Zernio::ApiError => e
1106
+ puts "Error when calling ConnectApi->create_youtube_playlist_with_http_info: #{e}"
1107
+ end
1108
+ ```
1109
+
1110
+ ### Parameters
1111
+
1112
+ | Name | Type | Description | Notes |
1113
+ | ---- | ---- | ----------- | ----- |
1114
+ | **account_id** | **String** | | |
1115
+ | **create_youtube_playlist_request** | [**CreateYoutubePlaylistRequest**](CreateYoutubePlaylistRequest.md) | | |
1116
+
1117
+ ### Return type
1118
+
1119
+ [**CreateYoutubePlaylist201Response**](CreateYoutubePlaylist201Response.md)
1120
+
1121
+ ### Authorization
1122
+
1123
+ [bearerAuth](../README.md#bearerAuth)
1124
+
1125
+ ### HTTP request headers
1126
+
1127
+ - **Content-Type**: application/json
1128
+ - **Accept**: application/json
1129
+
1130
+
1059
1131
  ## get_connect_url
1060
1132
 
1061
1133
  > <GetConnectUrl200Response> get_connect_url(platform, profile_id, opts)
@@ -0,0 +1,18 @@
1
+ # Zernio::CreateYoutubePlaylist201Response
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **playlist** | [**CreateYoutubePlaylist201ResponsePlaylist**](CreateYoutubePlaylist201ResponsePlaylist.md) | | |
8
+
9
+ ## Example
10
+
11
+ ```ruby
12
+ require 'zernio-sdk'
13
+
14
+ instance = Zernio::CreateYoutubePlaylist201Response.new(
15
+ playlist: null
16
+ )
17
+ ```
18
+
@@ -0,0 +1,28 @@
1
+ # Zernio::CreateYoutubePlaylist201ResponsePlaylist
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **id** | **String** | | |
8
+ | **title** | **String** | | |
9
+ | **description** | **String** | | |
10
+ | **privacy** | **String** | | |
11
+ | **item_count** | **Integer** | | |
12
+ | **thumbnail_url** | **String** | | |
13
+
14
+ ## Example
15
+
16
+ ```ruby
17
+ require 'zernio-sdk'
18
+
19
+ instance = Zernio::CreateYoutubePlaylist201ResponsePlaylist.new(
20
+ id: null,
21
+ title: null,
22
+ description: null,
23
+ privacy: null,
24
+ item_count: null,
25
+ thumbnail_url: null
26
+ )
27
+ ```
28
+
@@ -0,0 +1,22 @@
1
+ # Zernio::CreateYoutubePlaylistRequest
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **title** | **String** | Playlist title. Leading and trailing whitespace is removed. | |
8
+ | **description** | **String** | Optional playlist description. | [optional] |
9
+ | **privacy** | **String** | | [optional][default to &#39;private&#39;] |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'zernio-sdk'
15
+
16
+ instance = Zernio::CreateYoutubePlaylistRequest.new(
17
+ title: null,
18
+ description: null,
19
+ privacy: null
20
+ )
21
+ ```
22
+
@@ -1027,6 +1027,80 @@ module Zernio
1027
1027
  return data, status_code, headers
1028
1028
  end
1029
1029
 
1030
+ # Create YouTube playlist
1031
+ # Creates an empty playlist on the connected YouTube channel. Requires a title; privacy defaults to private. Returns the same playlist shape as the list endpoint. Pass the returned playlist.id as platformSpecificData.playlistId when publishing a video. Does not change the account's default playlist. Requires the youtube or youtube.force-ssl OAuth scope. Costs 50 YouTube quota units. This operation is not idempotent and is not automatically retried: repeating a request can create another playlist, including after a timeout. List playlists before retrying an ambiguous failure. Official series settings are not exposed by YouTube's public API and must be enabled manually in YouTube's desktop playlist settings.
1032
+ # @param account_id [String]
1033
+ # @param create_youtube_playlist_request [CreateYoutubePlaylistRequest]
1034
+ # @param [Hash] opts the optional parameters
1035
+ # @return [CreateYoutubePlaylist201Response]
1036
+ def create_youtube_playlist(account_id, create_youtube_playlist_request, opts = {})
1037
+ data, _status_code, _headers = create_youtube_playlist_with_http_info(account_id, create_youtube_playlist_request, opts)
1038
+ data
1039
+ end
1040
+
1041
+ # Create YouTube playlist
1042
+ # Creates an empty playlist on the connected YouTube channel. Requires a title; privacy defaults to private. Returns the same playlist shape as the list endpoint. Pass the returned playlist.id as platformSpecificData.playlistId when publishing a video. Does not change the account&#39;s default playlist. Requires the youtube or youtube.force-ssl OAuth scope. Costs 50 YouTube quota units. This operation is not idempotent and is not automatically retried: repeating a request can create another playlist, including after a timeout. List playlists before retrying an ambiguous failure. Official series settings are not exposed by YouTube&#39;s public API and must be enabled manually in YouTube&#39;s desktop playlist settings.
1043
+ # @param account_id [String]
1044
+ # @param create_youtube_playlist_request [CreateYoutubePlaylistRequest]
1045
+ # @param [Hash] opts the optional parameters
1046
+ # @return [Array<(CreateYoutubePlaylist201Response, Integer, Hash)>] CreateYoutubePlaylist201Response data, response status code and response headers
1047
+ def create_youtube_playlist_with_http_info(account_id, create_youtube_playlist_request, opts = {})
1048
+ if @api_client.config.debugging
1049
+ @api_client.config.logger.debug 'Calling API: ConnectApi.create_youtube_playlist ...'
1050
+ end
1051
+ # verify the required parameter 'account_id' is set
1052
+ if @api_client.config.client_side_validation && account_id.nil?
1053
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling ConnectApi.create_youtube_playlist"
1054
+ end
1055
+ # verify the required parameter 'create_youtube_playlist_request' is set
1056
+ if @api_client.config.client_side_validation && create_youtube_playlist_request.nil?
1057
+ fail ArgumentError, "Missing the required parameter 'create_youtube_playlist_request' when calling ConnectApi.create_youtube_playlist"
1058
+ end
1059
+ # resource path
1060
+ local_var_path = '/v1/accounts/{accountId}/youtube-playlists'.sub('{' + 'accountId' + '}', CGI.escape(account_id.to_s))
1061
+
1062
+ # query parameters
1063
+ query_params = opts[:query_params] || {}
1064
+
1065
+ # header parameters
1066
+ header_params = opts[:header_params] || {}
1067
+ # HTTP header 'Accept' (if needed)
1068
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1069
+ # HTTP header 'Content-Type'
1070
+ content_type = @api_client.select_header_content_type(['application/json'])
1071
+ if !content_type.nil?
1072
+ header_params['Content-Type'] = content_type
1073
+ end
1074
+
1075
+ # form parameters
1076
+ form_params = opts[:form_params] || {}
1077
+
1078
+ # http body (model)
1079
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(create_youtube_playlist_request)
1080
+
1081
+ # return_type
1082
+ return_type = opts[:debug_return_type] || 'CreateYoutubePlaylist201Response'
1083
+
1084
+ # auth_names
1085
+ auth_names = opts[:debug_auth_names] || ['bearerAuth']
1086
+
1087
+ new_options = opts.merge(
1088
+ :operation => :"ConnectApi.create_youtube_playlist",
1089
+ :header_params => header_params,
1090
+ :query_params => query_params,
1091
+ :form_params => form_params,
1092
+ :body => post_body,
1093
+ :auth_names => auth_names,
1094
+ :return_type => return_type
1095
+ )
1096
+
1097
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
1098
+ if @api_client.config.debugging
1099
+ @api_client.config.logger.debug "API called: ConnectApi#create_youtube_playlist\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1100
+ end
1101
+ return data, status_code, headers
1102
+ end
1103
+
1030
1104
  # Get OAuth connect URL
1031
1105
  # Initiate an OAuth connection flow. Returns an authUrl to redirect the user to. Standard flow: Zernio hosts the selection UI, then redirects to your redirect_url. Headless mode (headless=true): user is redirected to your redirect_url with OAuth data for custom UI. Use the platform-specific selection endpoints to complete. TikTok: every connection now goes through the TikTok for Business app. One TikTok account per profile, so connecting on a profile that already holds one replaces it. Reconnecting the SAME account keeps it and all of its history; authorizing a DIFFERENT TikTok account takes the slot over and permanently deletes the previous account's analytics, inbox and DM history. The two are told apart by the `@handle` stored at the last connect, so an account whose handle has been renamed on TikTok since then reads as a different account. An authorization that leaves out a permission the connected account needs changes nothing at all and comes back as `missing_tiktok_permissions`; connect again and accept every permission on TikTok's screen.
1032
1106
  # @param platform [String] Social media platform to connect. &#x60;snapchat&#x60; is a closed beta with no public release date: it returns 403 &#x60;PLATFORM_BETA_RESTRICTED&#x60; until the account is approved.
@@ -0,0 +1,164 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
5
+
6
+ The version of the OpenAPI document: 1.0.4
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Zernio
17
+ class CreateYoutubePlaylist201Response < ApiModelBase
18
+ attr_accessor :playlist
19
+
20
+ # Attribute mapping from ruby-style variable name to JSON key.
21
+ def self.attribute_map
22
+ {
23
+ :'playlist' => :'playlist'
24
+ }
25
+ end
26
+
27
+ # Returns attribute mapping this model knows about
28
+ def self.acceptable_attribute_map
29
+ attribute_map
30
+ end
31
+
32
+ # Returns all the JSON keys this model knows about
33
+ def self.acceptable_attributes
34
+ acceptable_attribute_map.values
35
+ end
36
+
37
+ # Attribute type mapping.
38
+ def self.openapi_types
39
+ {
40
+ :'playlist' => :'CreateYoutubePlaylist201ResponsePlaylist'
41
+ }
42
+ end
43
+
44
+ # List of attributes with nullable: true
45
+ def self.openapi_nullable
46
+ Set.new([
47
+ ])
48
+ end
49
+
50
+ # Initializes the object
51
+ # @param [Hash] attributes Model attributes in the form of hash
52
+ def initialize(attributes = {})
53
+ if (!attributes.is_a?(Hash))
54
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Zernio::CreateYoutubePlaylist201Response` initialize method"
55
+ end
56
+
57
+ # check to see if the attribute exists and convert string to symbol for hash key
58
+ acceptable_attribute_map = self.class.acceptable_attribute_map
59
+ attributes = attributes.each_with_object({}) { |(k, v), h|
60
+ if (!acceptable_attribute_map.key?(k.to_sym))
61
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Zernio::CreateYoutubePlaylist201Response`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
62
+ end
63
+ h[k.to_sym] = v
64
+ }
65
+
66
+ if attributes.key?(:'playlist')
67
+ self.playlist = attributes[:'playlist']
68
+ else
69
+ self.playlist = nil
70
+ end
71
+ end
72
+
73
+ # Show invalid properties with the reasons. Usually used together with valid?
74
+ # @return Array for valid properties with the reasons
75
+ def list_invalid_properties
76
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
77
+ invalid_properties = Array.new
78
+ if @playlist.nil?
79
+ invalid_properties.push('invalid value for "playlist", playlist cannot be nil.')
80
+ end
81
+
82
+ invalid_properties
83
+ end
84
+
85
+ # Check to see if the all the properties in the model are valid
86
+ # @return true if the model is valid
87
+ def valid?
88
+ warn '[DEPRECATED] the `valid?` method is obsolete'
89
+ return false if @playlist.nil?
90
+ true
91
+ end
92
+
93
+ # Custom attribute writer method with validation
94
+ # @param [Object] playlist Value to be assigned
95
+ def playlist=(playlist)
96
+ if playlist.nil?
97
+ fail ArgumentError, 'playlist cannot be nil'
98
+ end
99
+
100
+ @playlist = playlist
101
+ end
102
+
103
+ # Checks equality by comparing each attribute.
104
+ # @param [Object] Object to be compared
105
+ def ==(o)
106
+ return true if self.equal?(o)
107
+ self.class == o.class &&
108
+ playlist == o.playlist
109
+ end
110
+
111
+ # @see the `==` method
112
+ # @param [Object] Object to be compared
113
+ def eql?(o)
114
+ self == o
115
+ end
116
+
117
+ # Calculates hash code according to all attributes.
118
+ # @return [Integer] Hash code
119
+ def hash
120
+ [playlist].hash
121
+ end
122
+
123
+ # Builds the object from hash
124
+ # @param [Hash] attributes Model attributes in the form of hash
125
+ # @return [Object] Returns the model itself
126
+ def self.build_from_hash(attributes)
127
+ return nil unless attributes.is_a?(Hash)
128
+ attributes = attributes.transform_keys(&:to_sym)
129
+ transformed_hash = {}
130
+ openapi_types.each_pair do |key, type|
131
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
132
+ transformed_hash["#{key}"] = nil
133
+ elsif type =~ /\AArray<(.*)>/i
134
+ # check to ensure the input is an array given that the attribute
135
+ # is documented as an array but the input is not
136
+ if attributes[attribute_map[key]].is_a?(Array)
137
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
138
+ end
139
+ elsif !attributes[attribute_map[key]].nil?
140
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
141
+ end
142
+ end
143
+ new(transformed_hash)
144
+ end
145
+
146
+ # Returns the object in the form of hash
147
+ # @return [Hash] Returns the object in the form of hash
148
+ def to_hash
149
+ hash = {}
150
+ self.class.attribute_map.each_pair do |attr, param|
151
+ value = self.send(attr)
152
+ if value.nil?
153
+ is_nullable = self.class.openapi_nullable.include?(attr)
154
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
155
+ end
156
+
157
+ hash[param] = _to_hash(value)
158
+ end
159
+ hash
160
+ end
161
+
162
+ end
163
+
164
+ end
@@ -0,0 +1,318 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
5
+
6
+ The version of the OpenAPI document: 1.0.4
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Zernio
17
+ class CreateYoutubePlaylist201ResponsePlaylist < ApiModelBase
18
+ attr_accessor :id
19
+
20
+ attr_accessor :title
21
+
22
+ attr_accessor :description
23
+
24
+ attr_accessor :privacy
25
+
26
+ attr_accessor :item_count
27
+
28
+ attr_accessor :thumbnail_url
29
+
30
+ class EnumAttributeValidator
31
+ attr_reader :datatype
32
+ attr_reader :allowable_values
33
+
34
+ def initialize(datatype, allowable_values)
35
+ @allowable_values = allowable_values.map do |value|
36
+ case datatype.to_s
37
+ when /Integer/i
38
+ value.to_i
39
+ when /Float/i
40
+ value.to_f
41
+ else
42
+ value
43
+ end
44
+ end
45
+ end
46
+
47
+ def valid?(value)
48
+ !value || allowable_values.include?(value)
49
+ end
50
+ end
51
+
52
+ # Attribute mapping from ruby-style variable name to JSON key.
53
+ def self.attribute_map
54
+ {
55
+ :'id' => :'id',
56
+ :'title' => :'title',
57
+ :'description' => :'description',
58
+ :'privacy' => :'privacy',
59
+ :'item_count' => :'itemCount',
60
+ :'thumbnail_url' => :'thumbnailUrl'
61
+ }
62
+ end
63
+
64
+ # Returns attribute mapping this model knows about
65
+ def self.acceptable_attribute_map
66
+ attribute_map
67
+ end
68
+
69
+ # Returns all the JSON keys this model knows about
70
+ def self.acceptable_attributes
71
+ acceptable_attribute_map.values
72
+ end
73
+
74
+ # Attribute type mapping.
75
+ def self.openapi_types
76
+ {
77
+ :'id' => :'String',
78
+ :'title' => :'String',
79
+ :'description' => :'String',
80
+ :'privacy' => :'String',
81
+ :'item_count' => :'Integer',
82
+ :'thumbnail_url' => :'String'
83
+ }
84
+ end
85
+
86
+ # List of attributes with nullable: true
87
+ def self.openapi_nullable
88
+ Set.new([
89
+ ])
90
+ end
91
+
92
+ # Initializes the object
93
+ # @param [Hash] attributes Model attributes in the form of hash
94
+ def initialize(attributes = {})
95
+ if (!attributes.is_a?(Hash))
96
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Zernio::CreateYoutubePlaylist201ResponsePlaylist` initialize method"
97
+ end
98
+
99
+ # check to see if the attribute exists and convert string to symbol for hash key
100
+ acceptable_attribute_map = self.class.acceptable_attribute_map
101
+ attributes = attributes.each_with_object({}) { |(k, v), h|
102
+ if (!acceptable_attribute_map.key?(k.to_sym))
103
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Zernio::CreateYoutubePlaylist201ResponsePlaylist`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
104
+ end
105
+ h[k.to_sym] = v
106
+ }
107
+
108
+ if attributes.key?(:'id')
109
+ self.id = attributes[:'id']
110
+ else
111
+ self.id = nil
112
+ end
113
+
114
+ if attributes.key?(:'title')
115
+ self.title = attributes[:'title']
116
+ else
117
+ self.title = nil
118
+ end
119
+
120
+ if attributes.key?(:'description')
121
+ self.description = attributes[:'description']
122
+ else
123
+ self.description = nil
124
+ end
125
+
126
+ if attributes.key?(:'privacy')
127
+ self.privacy = attributes[:'privacy']
128
+ else
129
+ self.privacy = nil
130
+ end
131
+
132
+ if attributes.key?(:'item_count')
133
+ self.item_count = attributes[:'item_count']
134
+ else
135
+ self.item_count = nil
136
+ end
137
+
138
+ if attributes.key?(:'thumbnail_url')
139
+ self.thumbnail_url = attributes[:'thumbnail_url']
140
+ else
141
+ self.thumbnail_url = nil
142
+ end
143
+ end
144
+
145
+ # Show invalid properties with the reasons. Usually used together with valid?
146
+ # @return Array for valid properties with the reasons
147
+ def list_invalid_properties
148
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
149
+ invalid_properties = Array.new
150
+ if @id.nil?
151
+ invalid_properties.push('invalid value for "id", id cannot be nil.')
152
+ end
153
+
154
+ if @title.nil?
155
+ invalid_properties.push('invalid value for "title", title cannot be nil.')
156
+ end
157
+
158
+ if @description.nil?
159
+ invalid_properties.push('invalid value for "description", description cannot be nil.')
160
+ end
161
+
162
+ if @privacy.nil?
163
+ invalid_properties.push('invalid value for "privacy", privacy cannot be nil.')
164
+ end
165
+
166
+ if @item_count.nil?
167
+ invalid_properties.push('invalid value for "item_count", item_count cannot be nil.')
168
+ end
169
+
170
+ if @thumbnail_url.nil?
171
+ invalid_properties.push('invalid value for "thumbnail_url", thumbnail_url cannot be nil.')
172
+ end
173
+
174
+ invalid_properties
175
+ end
176
+
177
+ # Check to see if the all the properties in the model are valid
178
+ # @return true if the model is valid
179
+ def valid?
180
+ warn '[DEPRECATED] the `valid?` method is obsolete'
181
+ return false if @id.nil?
182
+ return false if @title.nil?
183
+ return false if @description.nil?
184
+ return false if @privacy.nil?
185
+ privacy_validator = EnumAttributeValidator.new('String', ["private", "public", "unlisted"])
186
+ return false unless privacy_validator.valid?(@privacy)
187
+ return false if @item_count.nil?
188
+ return false if @thumbnail_url.nil?
189
+ true
190
+ end
191
+
192
+ # Custom attribute writer method with validation
193
+ # @param [Object] id Value to be assigned
194
+ def id=(id)
195
+ if id.nil?
196
+ fail ArgumentError, 'id cannot be nil'
197
+ end
198
+
199
+ @id = id
200
+ end
201
+
202
+ # Custom attribute writer method with validation
203
+ # @param [Object] title Value to be assigned
204
+ def title=(title)
205
+ if title.nil?
206
+ fail ArgumentError, 'title cannot be nil'
207
+ end
208
+
209
+ @title = title
210
+ end
211
+
212
+ # Custom attribute writer method with validation
213
+ # @param [Object] description Value to be assigned
214
+ def description=(description)
215
+ if description.nil?
216
+ fail ArgumentError, 'description cannot be nil'
217
+ end
218
+
219
+ @description = description
220
+ end
221
+
222
+ # Custom attribute writer method checking allowed values (enum).
223
+ # @param [Object] privacy Object to be assigned
224
+ def privacy=(privacy)
225
+ validator = EnumAttributeValidator.new('String', ["private", "public", "unlisted"])
226
+ unless validator.valid?(privacy)
227
+ fail ArgumentError, "invalid value for \"privacy\", must be one of #{validator.allowable_values}."
228
+ end
229
+ @privacy = privacy
230
+ end
231
+
232
+ # Custom attribute writer method with validation
233
+ # @param [Object] item_count Value to be assigned
234
+ def item_count=(item_count)
235
+ if item_count.nil?
236
+ fail ArgumentError, 'item_count cannot be nil'
237
+ end
238
+
239
+ @item_count = item_count
240
+ end
241
+
242
+ # Custom attribute writer method with validation
243
+ # @param [Object] thumbnail_url Value to be assigned
244
+ def thumbnail_url=(thumbnail_url)
245
+ if thumbnail_url.nil?
246
+ fail ArgumentError, 'thumbnail_url cannot be nil'
247
+ end
248
+
249
+ @thumbnail_url = thumbnail_url
250
+ end
251
+
252
+ # Checks equality by comparing each attribute.
253
+ # @param [Object] Object to be compared
254
+ def ==(o)
255
+ return true if self.equal?(o)
256
+ self.class == o.class &&
257
+ id == o.id &&
258
+ title == o.title &&
259
+ description == o.description &&
260
+ privacy == o.privacy &&
261
+ item_count == o.item_count &&
262
+ thumbnail_url == o.thumbnail_url
263
+ end
264
+
265
+ # @see the `==` method
266
+ # @param [Object] Object to be compared
267
+ def eql?(o)
268
+ self == o
269
+ end
270
+
271
+ # Calculates hash code according to all attributes.
272
+ # @return [Integer] Hash code
273
+ def hash
274
+ [id, title, description, privacy, item_count, thumbnail_url].hash
275
+ end
276
+
277
+ # Builds the object from hash
278
+ # @param [Hash] attributes Model attributes in the form of hash
279
+ # @return [Object] Returns the model itself
280
+ def self.build_from_hash(attributes)
281
+ return nil unless attributes.is_a?(Hash)
282
+ attributes = attributes.transform_keys(&:to_sym)
283
+ transformed_hash = {}
284
+ openapi_types.each_pair do |key, type|
285
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
286
+ transformed_hash["#{key}"] = nil
287
+ elsif type =~ /\AArray<(.*)>/i
288
+ # check to ensure the input is an array given that the attribute
289
+ # is documented as an array but the input is not
290
+ if attributes[attribute_map[key]].is_a?(Array)
291
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
292
+ end
293
+ elsif !attributes[attribute_map[key]].nil?
294
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
295
+ end
296
+ end
297
+ new(transformed_hash)
298
+ end
299
+
300
+ # Returns the object in the form of hash
301
+ # @return [Hash] Returns the object in the form of hash
302
+ def to_hash
303
+ hash = {}
304
+ self.class.attribute_map.each_pair do |attr, param|
305
+ value = self.send(attr)
306
+ if value.nil?
307
+ is_nullable = self.class.openapi_nullable.include?(attr)
308
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
309
+ end
310
+
311
+ hash[param] = _to_hash(value)
312
+ end
313
+ hash
314
+ end
315
+
316
+ end
317
+
318
+ end
@@ -0,0 +1,229 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
5
+
6
+ The version of the OpenAPI document: 1.0.4
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Zernio
17
+ class CreateYoutubePlaylistRequest < ApiModelBase
18
+ # Playlist title. Leading and trailing whitespace is removed.
19
+ attr_accessor :title
20
+
21
+ # Optional playlist description.
22
+ attr_accessor :description
23
+
24
+ attr_accessor :privacy
25
+
26
+ class EnumAttributeValidator
27
+ attr_reader :datatype
28
+ attr_reader :allowable_values
29
+
30
+ def initialize(datatype, allowable_values)
31
+ @allowable_values = allowable_values.map do |value|
32
+ case datatype.to_s
33
+ when /Integer/i
34
+ value.to_i
35
+ when /Float/i
36
+ value.to_f
37
+ else
38
+ value
39
+ end
40
+ end
41
+ end
42
+
43
+ def valid?(value)
44
+ !value || allowable_values.include?(value)
45
+ end
46
+ end
47
+
48
+ # Attribute mapping from ruby-style variable name to JSON key.
49
+ def self.attribute_map
50
+ {
51
+ :'title' => :'title',
52
+ :'description' => :'description',
53
+ :'privacy' => :'privacy'
54
+ }
55
+ end
56
+
57
+ # Returns attribute mapping this model knows about
58
+ def self.acceptable_attribute_map
59
+ attribute_map
60
+ end
61
+
62
+ # Returns all the JSON keys this model knows about
63
+ def self.acceptable_attributes
64
+ acceptable_attribute_map.values
65
+ end
66
+
67
+ # Attribute type mapping.
68
+ def self.openapi_types
69
+ {
70
+ :'title' => :'String',
71
+ :'description' => :'String',
72
+ :'privacy' => :'String'
73
+ }
74
+ end
75
+
76
+ # List of attributes with nullable: true
77
+ def self.openapi_nullable
78
+ Set.new([
79
+ ])
80
+ end
81
+
82
+ # Initializes the object
83
+ # @param [Hash] attributes Model attributes in the form of hash
84
+ def initialize(attributes = {})
85
+ if (!attributes.is_a?(Hash))
86
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Zernio::CreateYoutubePlaylistRequest` initialize method"
87
+ end
88
+
89
+ # check to see if the attribute exists and convert string to symbol for hash key
90
+ acceptable_attribute_map = self.class.acceptable_attribute_map
91
+ attributes = attributes.each_with_object({}) { |(k, v), h|
92
+ if (!acceptable_attribute_map.key?(k.to_sym))
93
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Zernio::CreateYoutubePlaylistRequest`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
94
+ end
95
+ h[k.to_sym] = v
96
+ }
97
+
98
+ if attributes.key?(:'title')
99
+ self.title = attributes[:'title']
100
+ else
101
+ self.title = nil
102
+ end
103
+
104
+ if attributes.key?(:'description')
105
+ self.description = attributes[:'description']
106
+ end
107
+
108
+ if attributes.key?(:'privacy')
109
+ self.privacy = attributes[:'privacy']
110
+ else
111
+ self.privacy = 'private'
112
+ end
113
+ end
114
+
115
+ # Show invalid properties with the reasons. Usually used together with valid?
116
+ # @return Array for valid properties with the reasons
117
+ def list_invalid_properties
118
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
119
+ invalid_properties = Array.new
120
+ if @title.nil?
121
+ invalid_properties.push('invalid value for "title", title cannot be nil.')
122
+ end
123
+
124
+ if @title.to_s.length < 1
125
+ invalid_properties.push('invalid value for "title", the character length must be greater than or equal to 1.')
126
+ end
127
+
128
+ invalid_properties
129
+ end
130
+
131
+ # Check to see if the all the properties in the model are valid
132
+ # @return true if the model is valid
133
+ def valid?
134
+ warn '[DEPRECATED] the `valid?` method is obsolete'
135
+ return false if @title.nil?
136
+ return false if @title.to_s.length < 1
137
+ privacy_validator = EnumAttributeValidator.new('String', ["private", "public", "unlisted"])
138
+ return false unless privacy_validator.valid?(@privacy)
139
+ true
140
+ end
141
+
142
+ # Custom attribute writer method with validation
143
+ # @param [Object] title Value to be assigned
144
+ def title=(title)
145
+ if title.nil?
146
+ fail ArgumentError, 'title cannot be nil'
147
+ end
148
+
149
+ if title.to_s.length < 1
150
+ fail ArgumentError, 'invalid value for "title", the character length must be greater than or equal to 1.'
151
+ end
152
+
153
+ @title = title
154
+ end
155
+
156
+ # Custom attribute writer method checking allowed values (enum).
157
+ # @param [Object] privacy Object to be assigned
158
+ def privacy=(privacy)
159
+ validator = EnumAttributeValidator.new('String', ["private", "public", "unlisted"])
160
+ unless validator.valid?(privacy)
161
+ fail ArgumentError, "invalid value for \"privacy\", must be one of #{validator.allowable_values}."
162
+ end
163
+ @privacy = privacy
164
+ end
165
+
166
+ # Checks equality by comparing each attribute.
167
+ # @param [Object] Object to be compared
168
+ def ==(o)
169
+ return true if self.equal?(o)
170
+ self.class == o.class &&
171
+ title == o.title &&
172
+ description == o.description &&
173
+ privacy == o.privacy
174
+ end
175
+
176
+ # @see the `==` method
177
+ # @param [Object] Object to be compared
178
+ def eql?(o)
179
+ self == o
180
+ end
181
+
182
+ # Calculates hash code according to all attributes.
183
+ # @return [Integer] Hash code
184
+ def hash
185
+ [title, description, privacy].hash
186
+ end
187
+
188
+ # Builds the object from hash
189
+ # @param [Hash] attributes Model attributes in the form of hash
190
+ # @return [Object] Returns the model itself
191
+ def self.build_from_hash(attributes)
192
+ return nil unless attributes.is_a?(Hash)
193
+ attributes = attributes.transform_keys(&:to_sym)
194
+ transformed_hash = {}
195
+ openapi_types.each_pair do |key, type|
196
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
197
+ transformed_hash["#{key}"] = nil
198
+ elsif type =~ /\AArray<(.*)>/i
199
+ # check to ensure the input is an array given that the attribute
200
+ # is documented as an array but the input is not
201
+ if attributes[attribute_map[key]].is_a?(Array)
202
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
203
+ end
204
+ elsif !attributes[attribute_map[key]].nil?
205
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
206
+ end
207
+ end
208
+ new(transformed_hash)
209
+ end
210
+
211
+ # Returns the object in the form of hash
212
+ # @return [Hash] Returns the object in the form of hash
213
+ def to_hash
214
+ hash = {}
215
+ self.class.attribute_map.each_pair do |attr, param|
216
+ value = self.send(attr)
217
+ if value.nil?
218
+ is_nullable = self.class.openapi_nullable.include?(attr)
219
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
220
+ end
221
+
222
+ hash[param] = _to_hash(value)
223
+ end
224
+ hash
225
+ end
226
+
227
+ end
228
+
229
+ end
@@ -11,5 +11,5 @@ Generator version: 7.19.0
11
11
  =end
12
12
 
13
13
  module Zernio
14
- VERSION = '0.0.938'
14
+ VERSION = '0.0.939'
15
15
  end
data/lib/zernio-sdk.rb CHANGED
@@ -445,6 +445,9 @@ require 'zernio-sdk/models/create_whats_app_template_request_library_template_bu
445
445
  require 'zernio-sdk/models/create_workflow200_response'
446
446
  require 'zernio-sdk/models/create_workflow200_response_workflow'
447
447
  require 'zernio-sdk/models/create_workflow_request'
448
+ require 'zernio-sdk/models/create_youtube_playlist201_response'
449
+ require 'zernio-sdk/models/create_youtube_playlist201_response_playlist'
450
+ require 'zernio-sdk/models/create_youtube_playlist_request'
448
451
  require 'zernio-sdk/models/crosspost_discord_message200_response'
449
452
  require 'zernio-sdk/models/ctwa_ad_request_body'
450
453
  require 'zernio-sdk/models/ctwa_ad_request_body_cities_inner'
data/openapi.yaml CHANGED
@@ -25738,6 +25738,74 @@ paths:
25738
25738
  '400': { description: Not a YouTube account }
25739
25739
  '401': { $ref: '#/components/responses/Unauthorized' }
25740
25740
  '404': { description: Account not found }
25741
+ post:
25742
+ operationId: createYoutubePlaylist
25743
+ x-resource-group: "accounts"
25744
+ tags: [Connect]
25745
+ summary: Create YouTube playlist
25746
+ description: >
25747
+ Creates an empty playlist on the connected YouTube channel. Requires a title;
25748
+ privacy defaults to private. Returns the same playlist shape as the list endpoint.
25749
+ Pass the returned playlist.id as platformSpecificData.playlistId when publishing
25750
+ a video. Does not change the account's default playlist.
25751
+ Requires the youtube or youtube.force-ssl OAuth scope. Costs 50 YouTube quota units.
25752
+ This operation is not idempotent and is not automatically retried: repeating a
25753
+ request can create another playlist, including after a timeout. List playlists
25754
+ before retrying an ambiguous failure. Official series settings are not exposed
25755
+ by YouTube's public API and must be enabled manually in YouTube's desktop playlist settings.
25756
+ parameters:
25757
+ - name: accountId
25758
+ in: path
25759
+ required: true
25760
+ schema: { type: string }
25761
+ requestBody:
25762
+ required: true
25763
+ content:
25764
+ application/json:
25765
+ schema:
25766
+ type: object
25767
+ required: [title]
25768
+ properties:
25769
+ title: { type: string, minLength: 1, description: "Playlist title. Leading and trailing whitespace is removed." }
25770
+ description: { type: string, description: "Optional playlist description." }
25771
+ privacy: { type: string, enum: [private, public, unlisted], default: private }
25772
+ example:
25773
+ title: "Tutorials"
25774
+ description: "Step-by-step video tutorials"
25775
+ privacy: "private"
25776
+ responses:
25777
+ '201':
25778
+ description: Playlist created
25779
+ content:
25780
+ application/json:
25781
+ schema:
25782
+ type: object
25783
+ required: [playlist]
25784
+ properties:
25785
+ playlist:
25786
+ type: object
25787
+ required: [id, title, description, privacy, itemCount, thumbnailUrl]
25788
+ properties:
25789
+ id: { type: string }
25790
+ title: { type: string }
25791
+ description: { type: string }
25792
+ privacy: { type: string, enum: [private, public, unlisted] }
25793
+ itemCount: { type: integer }
25794
+ thumbnailUrl: { type: string }
25795
+ example:
25796
+ playlist:
25797
+ id: "PLxxxxxxxxxxxxx"
25798
+ title: "Tutorials"
25799
+ description: "Step-by-step video tutorials"
25800
+ privacy: "private"
25801
+ itemCount: 0
25802
+ thumbnailUrl: ""
25803
+ '400': { $ref: '#/components/responses/BadRequest' }
25804
+ '401': { $ref: '#/components/responses/Unauthorized' }
25805
+ '403': { description: "API key lacks access to the account or YouTube denied permission." }
25806
+ '404': { description: "Account not found or inaccessible." }
25807
+ '429': { description: "YouTube rate limit exceeded." }
25808
+ '502': { description: "YouTube request failed. Check existing playlists before retrying, because the playlist may have been created." }
25741
25809
  put:
25742
25810
  x-resource-group: "accounts"
25743
25811
  operationId: updateYoutubeDefaultPlaylist
@@ -215,6 +215,19 @@ describe 'ConnectApi' do
215
215
  end
216
216
  end
217
217
 
218
+ # unit tests for create_youtube_playlist
219
+ # Create YouTube playlist
220
+ # Creates an empty playlist on the connected YouTube channel. Requires a title; privacy defaults to private. Returns the same playlist shape as the list endpoint. Pass the returned playlist.id as platformSpecificData.playlistId when publishing a video. Does not change the account&#39;s default playlist. Requires the youtube or youtube.force-ssl OAuth scope. Costs 50 YouTube quota units. This operation is not idempotent and is not automatically retried: repeating a request can create another playlist, including after a timeout. List playlists before retrying an ambiguous failure. Official series settings are not exposed by YouTube&#39;s public API and must be enabled manually in YouTube&#39;s desktop playlist settings.
221
+ # @param account_id
222
+ # @param create_youtube_playlist_request
223
+ # @param [Hash] opts the optional parameters
224
+ # @return [CreateYoutubePlaylist201Response]
225
+ describe 'create_youtube_playlist test' do
226
+ it 'should work' do
227
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
228
+ end
229
+ end
230
+
218
231
  # unit tests for get_connect_url
219
232
  # Get OAuth connect URL
220
233
  # Initiate an OAuth connection flow. Returns an authUrl to redirect the user to. Standard flow: Zernio hosts the selection UI, then redirects to your redirect_url. Headless mode (headless&#x3D;true): user is redirected to your redirect_url with OAuth data for custom UI. Use the platform-specific selection endpoints to complete. TikTok: every connection now goes through the TikTok for Business app. One TikTok account per profile, so connecting on a profile that already holds one replaces it. Reconnecting the SAME account keeps it and all of its history; authorizing a DIFFERENT TikTok account takes the slot over and permanently deletes the previous account&#39;s analytics, inbox and DM history. The two are told apart by the &#x60;@handle&#x60; stored at the last connect, so an account whose handle has been renamed on TikTok since then reads as a different account. An authorization that leaves out a permission the connected account needs changes nothing at all and comes back as &#x60;missing_tiktok_permissions&#x60;; connect again and accept every permission on TikTok&#39;s screen.
@@ -0,0 +1,70 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
5
+
6
+ The version of the OpenAPI document: 1.0.4
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+ require 'date'
16
+
17
+ # Unit tests for Zernio::CreateYoutubePlaylist201ResponsePlaylist
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe Zernio::CreateYoutubePlaylist201ResponsePlaylist do
21
+ #let(:instance) { Zernio::CreateYoutubePlaylist201ResponsePlaylist.new }
22
+
23
+ describe 'test an instance of CreateYoutubePlaylist201ResponsePlaylist' do
24
+ it 'should create an instance of CreateYoutubePlaylist201ResponsePlaylist' do
25
+ # uncomment below to test the instance creation
26
+ #expect(instance).to be_instance_of(Zernio::CreateYoutubePlaylist201ResponsePlaylist)
27
+ end
28
+ end
29
+
30
+ describe 'test attribute "id"' do
31
+ it 'should work' do
32
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
33
+ end
34
+ end
35
+
36
+ describe 'test attribute "title"' do
37
+ it 'should work' do
38
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
39
+ end
40
+ end
41
+
42
+ describe 'test attribute "description"' do
43
+ it 'should work' do
44
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
45
+ end
46
+ end
47
+
48
+ describe 'test attribute "privacy"' do
49
+ it 'should work' do
50
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
51
+ # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["private", "public", "unlisted"])
52
+ # validator.allowable_values.each do |value|
53
+ # expect { instance.privacy = value }.not_to raise_error
54
+ # end
55
+ end
56
+ end
57
+
58
+ describe 'test attribute "item_count"' do
59
+ it 'should work' do
60
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
61
+ end
62
+ end
63
+
64
+ describe 'test attribute "thumbnail_url"' do
65
+ it 'should work' do
66
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
67
+ end
68
+ end
69
+
70
+ end
@@ -0,0 +1,36 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
5
+
6
+ The version of the OpenAPI document: 1.0.4
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+ require 'date'
16
+
17
+ # Unit tests for Zernio::CreateYoutubePlaylist201Response
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe Zernio::CreateYoutubePlaylist201Response do
21
+ #let(:instance) { Zernio::CreateYoutubePlaylist201Response.new }
22
+
23
+ describe 'test an instance of CreateYoutubePlaylist201Response' do
24
+ it 'should create an instance of CreateYoutubePlaylist201Response' do
25
+ # uncomment below to test the instance creation
26
+ #expect(instance).to be_instance_of(Zernio::CreateYoutubePlaylist201Response)
27
+ end
28
+ end
29
+
30
+ describe 'test attribute "playlist"' do
31
+ it 'should work' do
32
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
33
+ end
34
+ end
35
+
36
+ end
@@ -0,0 +1,52 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
5
+
6
+ The version of the OpenAPI document: 1.0.4
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+ require 'date'
16
+
17
+ # Unit tests for Zernio::CreateYoutubePlaylistRequest
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe Zernio::CreateYoutubePlaylistRequest do
21
+ #let(:instance) { Zernio::CreateYoutubePlaylistRequest.new }
22
+
23
+ describe 'test an instance of CreateYoutubePlaylistRequest' do
24
+ it 'should create an instance of CreateYoutubePlaylistRequest' do
25
+ # uncomment below to test the instance creation
26
+ #expect(instance).to be_instance_of(Zernio::CreateYoutubePlaylistRequest)
27
+ end
28
+ end
29
+
30
+ describe 'test attribute "title"' do
31
+ it 'should work' do
32
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
33
+ end
34
+ end
35
+
36
+ describe 'test attribute "description"' do
37
+ it 'should work' do
38
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
39
+ end
40
+ end
41
+
42
+ describe 'test attribute "privacy"' do
43
+ it 'should work' do
44
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
45
+ # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["private", "public", "unlisted"])
46
+ # validator.allowable_values.each do |value|
47
+ # expect { instance.privacy = value }.not_to raise_error
48
+ # end
49
+ end
50
+ end
51
+
52
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zernio-sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.938
4
+ version: 0.0.939
5
5
  platform: ruby
6
6
  authors:
7
7
  - OpenAPI-Generator
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-09-11 00:00:00.000000000 Z
11
+ date: 2026-09-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -517,6 +517,9 @@ files:
517
517
  - docs/CreateWorkflow200Response.md
518
518
  - docs/CreateWorkflow200ResponseWorkflow.md
519
519
  - docs/CreateWorkflowRequest.md
520
+ - docs/CreateYoutubePlaylist201Response.md
521
+ - docs/CreateYoutubePlaylist201ResponsePlaylist.md
522
+ - docs/CreateYoutubePlaylistRequest.md
520
523
  - docs/CrosspostDiscordMessage200Response.md
521
524
  - docs/CtwaAdRequestBody.md
522
525
  - docs/CtwaAdRequestBodyCitiesInner.md
@@ -2675,6 +2678,9 @@ files:
2675
2678
  - lib/zernio-sdk/models/create_workflow200_response.rb
2676
2679
  - lib/zernio-sdk/models/create_workflow200_response_workflow.rb
2677
2680
  - lib/zernio-sdk/models/create_workflow_request.rb
2681
+ - lib/zernio-sdk/models/create_youtube_playlist201_response.rb
2682
+ - lib/zernio-sdk/models/create_youtube_playlist201_response_playlist.rb
2683
+ - lib/zernio-sdk/models/create_youtube_playlist_request.rb
2678
2684
  - lib/zernio-sdk/models/crosspost_discord_message200_response.rb
2679
2685
  - lib/zernio-sdk/models/ctwa_ad_request_body.rb
2680
2686
  - lib/zernio-sdk/models/ctwa_ad_request_body_cities_inner.rb
@@ -4781,6 +4787,9 @@ files:
4781
4787
  - spec/models/create_workflow200_response_spec.rb
4782
4788
  - spec/models/create_workflow200_response_workflow_spec.rb
4783
4789
  - spec/models/create_workflow_request_spec.rb
4790
+ - spec/models/create_youtube_playlist201_response_playlist_spec.rb
4791
+ - spec/models/create_youtube_playlist201_response_spec.rb
4792
+ - spec/models/create_youtube_playlist_request_spec.rb
4784
4793
  - spec/models/crosspost_discord_message200_response_spec.rb
4785
4794
  - spec/models/ctwa_ad_request_body_cities_inner_spec.rb
4786
4795
  - spec/models/ctwa_ad_request_body_creatives_inner_spec.rb
@@ -6797,6 +6806,7 @@ test_files:
6797
6806
  - spec/models/start_sms_registration_request_spec.rb
6798
6807
  - spec/models/start_sms_registration_request_campaign_spec.rb
6799
6808
  - spec/models/x_article_entity_one_of3_spec.rb
6809
+ - spec/models/create_youtube_playlist201_response_spec.rb
6800
6810
  - spec/models/duplicate_workflow201_response_workflow_spec.rb
6801
6811
  - spec/models/inbox_webhook_conversation_spec.rb
6802
6812
  - spec/models/list_comment_automations200_response_automations_inner_stats_spec.rb
@@ -6944,6 +6954,7 @@ test_files:
6944
6954
  - spec/models/get_ad_comments200_response_pagination_spec.rb
6945
6955
  - spec/models/update_google_business_food_menus200_response_spec.rb
6946
6956
  - spec/models/update_campaign_targeting_request_targeting_devices_inner_one_of_spec.rb
6957
+ - spec/models/create_youtube_playlist201_response_playlist_spec.rb
6947
6958
  - spec/models/block_whats_app_users_request_spec.rb
6948
6959
  - spec/models/onboard_business_agent201_response_spec.rb
6949
6960
  - spec/models/post_user_id_spec.rb
@@ -7865,6 +7876,7 @@ test_files:
7865
7876
  - spec/models/select_snapchat_profile_request_spec.rb
7866
7877
  - spec/models/get_google_business_location_details200_response_profile_spec.rb
7867
7878
  - spec/models/get_inbox_post_comments200_response_post_spec.rb
7879
+ - spec/models/create_youtube_playlist_request_spec.rb
7868
7880
  - spec/models/get_ad200_response_spec.rb
7869
7881
  - spec/models/update_account_request_x_capabilities_spec.rb
7870
7882
  - spec/models/bulk_update_ad_campaign_status200_response_spec.rb