scrapebadger 0.1.0

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.
Files changed (185) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +9 -0
  3. data/LICENSE +21 -0
  4. data/README.md +548 -0
  5. data/Rakefile +10 -0
  6. data/docs/AccountApi.md +76 -0
  7. data/docs/AccountInfo.md +28 -0
  8. data/docs/AmazonApi.md +1244 -0
  9. data/docs/ApartmentsApi.md +373 -0
  10. data/docs/BaiduApi.md +447 -0
  11. data/docs/BillingLogListResponse.md +24 -0
  12. data/docs/BillingLogResponse.md +32 -0
  13. data/docs/BingApi.md +610 -0
  14. data/docs/ChatGPTApi.md +521 -0
  15. data/docs/DepopApi.md +542 -0
  16. data/docs/DuckDuckGoApi.md +700 -0
  17. data/docs/EBayApi.md +1019 -0
  18. data/docs/FacebookApi.md +1671 -0
  19. data/docs/FilterRuleCreate.md +28 -0
  20. data/docs/FilterRuleDeliveryLogListResponse.md +24 -0
  21. data/docs/FilterRuleDeliveryLogResponse.md +44 -0
  22. data/docs/FilterRuleListResponse.md +24 -0
  23. data/docs/FilterRuleResponse.md +40 -0
  24. data/docs/FilterRuleUpdate.md +30 -0
  25. data/docs/FilterRuleValidateRequest.md +18 -0
  26. data/docs/FilterRuleValidateResponse.md +22 -0
  27. data/docs/GoogleApi.md +3175 -0
  28. data/docs/HTTPValidationError.md +18 -0
  29. data/docs/IdealistaApi.md +822 -0
  30. data/docs/ImmobiliareApi.md +773 -0
  31. data/docs/InstagramApi.md +1673 -0
  32. data/docs/LeboncoinApi.md +884 -0
  33. data/docs/LinkedInApi.md +925 -0
  34. data/docs/LoopNetApi.md +529 -0
  35. data/docs/PortalApiRoutersV1TwitterFilterRulesFilterRulePricingResponse.md +20 -0
  36. data/docs/RealtorApi.md +474 -0
  37. data/docs/RedditApi.md +1677 -0
  38. data/docs/RedfinApi.md +616 -0
  39. data/docs/StreamMonitorCreate.md +26 -0
  40. data/docs/StreamMonitorListResponse.md +24 -0
  41. data/docs/StreamMonitorResponse.md +42 -0
  42. data/docs/StreamMonitorUpdate.md +28 -0
  43. data/docs/SubscriptionInfo.md +40 -0
  44. data/docs/TikTokApi.md +2104 -0
  45. data/docs/TweetDeliveryLogListResponse.md +24 -0
  46. data/docs/TweetDeliveryLogResponse.md +44 -0
  47. data/docs/TwitterApi.md +4091 -0
  48. data/docs/ValidationError.md +22 -0
  49. data/docs/ValidationErrorLocInner.md +15 -0
  50. data/docs/VintedApi.md +766 -0
  51. data/docs/WalmartApi.md +904 -0
  52. data/docs/WebApi.md +634 -0
  53. data/docs/WebhookCreate.md +22 -0
  54. data/docs/WebhookListItem.md +28 -0
  55. data/docs/WebhookListResponse.md +20 -0
  56. data/docs/WebhookResponse.md +26 -0
  57. data/docs/WebhookTestRequest.md +18 -0
  58. data/docs/WebhookTestResponse.md +24 -0
  59. data/docs/YahooApi.md +602 -0
  60. data/docs/YandexApi.md +450 -0
  61. data/docs/YouTubeApi.md +2872 -0
  62. data/docs/ZillowApi.md +622 -0
  63. data/git_push.sh +57 -0
  64. data/lib/scrapebadger/api/account_api.rb +79 -0
  65. data/lib/scrapebadger/api/amazon_api.rb +1165 -0
  66. data/lib/scrapebadger/api/apartments_api.rb +377 -0
  67. data/lib/scrapebadger/api/baidu_api.rb +436 -0
  68. data/lib/scrapebadger/api/bing_api.rb +580 -0
  69. data/lib/scrapebadger/api/chat_gpt_api.rb +466 -0
  70. data/lib/scrapebadger/api/depop_api.rb +518 -0
  71. data/lib/scrapebadger/api/duck_duck_go_api.rb +675 -0
  72. data/lib/scrapebadger/api/e_bay_api.rb +1029 -0
  73. data/lib/scrapebadger/api/facebook_api.rb +1492 -0
  74. data/lib/scrapebadger/api/google_api.rb +3191 -0
  75. data/lib/scrapebadger/api/idealista_api.rb +864 -0
  76. data/lib/scrapebadger/api/immobiliare_api.rb +734 -0
  77. data/lib/scrapebadger/api/instagram_api.rb +1555 -0
  78. data/lib/scrapebadger/api/leboncoin_api.rb +818 -0
  79. data/lib/scrapebadger/api/linked_in_api.rb +832 -0
  80. data/lib/scrapebadger/api/loop_net_api.rb +503 -0
  81. data/lib/scrapebadger/api/realtor_api.rb +481 -0
  82. data/lib/scrapebadger/api/reddit_api.rb +1601 -0
  83. data/lib/scrapebadger/api/redfin_api.rb +625 -0
  84. data/lib/scrapebadger/api/tik_tok_api.rb +2029 -0
  85. data/lib/scrapebadger/api/twitter_api.rb +3696 -0
  86. data/lib/scrapebadger/api/vinted_api.rb +705 -0
  87. data/lib/scrapebadger/api/walmart_api.rb +876 -0
  88. data/lib/scrapebadger/api/web_api.rb +547 -0
  89. data/lib/scrapebadger/api/yahoo_api.rb +560 -0
  90. data/lib/scrapebadger/api/yandex_api.rb +422 -0
  91. data/lib/scrapebadger/api/you_tube_api.rb +2520 -0
  92. data/lib/scrapebadger/api/zillow_api.rb +634 -0
  93. data/lib/scrapebadger/api_client.rb +394 -0
  94. data/lib/scrapebadger/api_error.rb +58 -0
  95. data/lib/scrapebadger/configuration.rb +308 -0
  96. data/lib/scrapebadger/models/account_info.rb +288 -0
  97. data/lib/scrapebadger/models/billing_log_list_response.rb +272 -0
  98. data/lib/scrapebadger/models/billing_log_response.rb +334 -0
  99. data/lib/scrapebadger/models/filter_rule_create.rb +427 -0
  100. data/lib/scrapebadger/models/filter_rule_delivery_log_list_response.rb +272 -0
  101. data/lib/scrapebadger/models/filter_rule_delivery_log_response.rb +422 -0
  102. data/lib/scrapebadger/models/filter_rule_list_response.rb +272 -0
  103. data/lib/scrapebadger/models/filter_rule_response.rb +390 -0
  104. data/lib/scrapebadger/models/filter_rule_update.rb +389 -0
  105. data/lib/scrapebadger/models/filter_rule_validate_request.rb +250 -0
  106. data/lib/scrapebadger/models/filter_rule_validate_response.rb +248 -0
  107. data/lib/scrapebadger/models/http_validation_error.rb +216 -0
  108. data/lib/scrapebadger/models/portal_api_routers_v1_twitter_filter_rules_filter_rule_pricing_response.rb +238 -0
  109. data/lib/scrapebadger/models/stream_monitor_create.rb +373 -0
  110. data/lib/scrapebadger/models/stream_monitor_list_response.rb +272 -0
  111. data/lib/scrapebadger/models/stream_monitor_response.rb +406 -0
  112. data/lib/scrapebadger/models/stream_monitor_update.rb +335 -0
  113. data/lib/scrapebadger/models/subscription_info.rb +352 -0
  114. data/lib/scrapebadger/models/tweet_delivery_log_list_response.rb +272 -0
  115. data/lib/scrapebadger/models/tweet_delivery_log_response.rb +422 -0
  116. data/lib/scrapebadger/models/validation_error.rb +255 -0
  117. data/lib/scrapebadger/models/validation_error_loc_inner.rb +104 -0
  118. data/lib/scrapebadger/models/webhook_create.rb +282 -0
  119. data/lib/scrapebadger/models/webhook_list_item.rb +302 -0
  120. data/lib/scrapebadger/models/webhook_list_response.rb +240 -0
  121. data/lib/scrapebadger/models/webhook_response.rb +286 -0
  122. data/lib/scrapebadger/models/webhook_test_request.rb +223 -0
  123. data/lib/scrapebadger/models/webhook_test_response.rb +259 -0
  124. data/lib/scrapebadger/version.rb +15 -0
  125. data/lib/scrapebadger.rb +96 -0
  126. data/scrapebadger.gemspec +39 -0
  127. data/spec/api/account_api_spec.rb +46 -0
  128. data/spec/api/amazon_api_spec.rb +258 -0
  129. data/spec/api/apartments_api_spec.rb +98 -0
  130. data/spec/api/baidu_api_spec.rb +109 -0
  131. data/spec/api/bing_api_spec.rb +141 -0
  132. data/spec/api/chat_gpt_api_spec.rb +123 -0
  133. data/spec/api/depop_api_spec.rb +132 -0
  134. data/spec/api/duck_duck_go_api_spec.rb +162 -0
  135. data/spec/api/e_bay_api_spec.rb +222 -0
  136. data/spec/api/facebook_api_spec.rb +326 -0
  137. data/spec/api/google_api_spec.rb +649 -0
  138. data/spec/api/idealista_api_spec.rb +197 -0
  139. data/spec/api/immobiliare_api_spec.rb +174 -0
  140. data/spec/api/instagram_api_spec.rb +309 -0
  141. data/spec/api/leboncoin_api_spec.rb +184 -0
  142. data/spec/api/linked_in_api_spec.rb +197 -0
  143. data/spec/api/loop_net_api_spec.rb +127 -0
  144. data/spec/api/realtor_api_spec.rb +123 -0
  145. data/spec/api/reddit_api_spec.rb +331 -0
  146. data/spec/api/redfin_api_spec.rb +147 -0
  147. data/spec/api/tik_tok_api_spec.rb +413 -0
  148. data/spec/api/twitter_api_spec.rb +735 -0
  149. data/spec/api/vinted_api_spec.rb +169 -0
  150. data/spec/api/walmart_api_spec.rb +192 -0
  151. data/spec/api/web_api_spec.rb +136 -0
  152. data/spec/api/yahoo_api_spec.rb +137 -0
  153. data/spec/api/yandex_api_spec.rb +111 -0
  154. data/spec/api/you_tube_api_spec.rb +500 -0
  155. data/spec/api/zillow_api_spec.rb +150 -0
  156. data/spec/models/account_info_spec.rb +66 -0
  157. data/spec/models/billing_log_list_response_spec.rb +54 -0
  158. data/spec/models/billing_log_response_spec.rb +78 -0
  159. data/spec/models/filter_rule_create_spec.rb +66 -0
  160. data/spec/models/filter_rule_delivery_log_list_response_spec.rb +54 -0
  161. data/spec/models/filter_rule_delivery_log_response_spec.rb +114 -0
  162. data/spec/models/filter_rule_list_response_spec.rb +54 -0
  163. data/spec/models/filter_rule_response_spec.rb +102 -0
  164. data/spec/models/filter_rule_update_spec.rb +72 -0
  165. data/spec/models/filter_rule_validate_request_spec.rb +36 -0
  166. data/spec/models/filter_rule_validate_response_spec.rb +48 -0
  167. data/spec/models/http_validation_error_spec.rb +36 -0
  168. data/spec/models/portal_api_routers_v1_twitter_filter_rules_filter_rule_pricing_response_spec.rb +42 -0
  169. data/spec/models/stream_monitor_create_spec.rb +60 -0
  170. data/spec/models/stream_monitor_list_response_spec.rb +54 -0
  171. data/spec/models/stream_monitor_response_spec.rb +108 -0
  172. data/spec/models/stream_monitor_update_spec.rb +66 -0
  173. data/spec/models/subscription_info_spec.rb +102 -0
  174. data/spec/models/tweet_delivery_log_list_response_spec.rb +54 -0
  175. data/spec/models/tweet_delivery_log_response_spec.rb +114 -0
  176. data/spec/models/validation_error_loc_inner_spec.rb +21 -0
  177. data/spec/models/validation_error_spec.rb +48 -0
  178. data/spec/models/webhook_create_spec.rb +48 -0
  179. data/spec/models/webhook_list_item_spec.rb +66 -0
  180. data/spec/models/webhook_list_response_spec.rb +42 -0
  181. data/spec/models/webhook_response_spec.rb +60 -0
  182. data/spec/models/webhook_test_request_spec.rb +36 -0
  183. data/spec/models/webhook_test_response_spec.rb +54 -0
  184. data/spec/spec_helper.rb +111 -0
  185. metadata +324 -0
@@ -0,0 +1,2520 @@
1
+ =begin
2
+ #ScrapeBadger API
3
+
4
+ #Unified credit-based scraping API. https://docs.scrapebadger.com
5
+
6
+ The version of the OpenAPI document: 0.1.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.10.0
10
+
11
+ =end
12
+
13
+ require 'cgi'
14
+
15
+ module ScrapeBadger
16
+ class YouTubeApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Batch video detail
23
+ # @param request_body [Hash<String, Object>]
24
+ # @param [Hash] opts the optional parameters
25
+ # @return [Object]
26
+ def youtube_batch_video_detail(request_body, opts = {})
27
+ data, _status_code, _headers = youtube_batch_video_detail_with_http_info(request_body, opts)
28
+ data
29
+ end
30
+
31
+ # Batch video detail
32
+ # @param request_body [Hash<String, Object>]
33
+ # @param [Hash] opts the optional parameters
34
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
35
+ def youtube_batch_video_detail_with_http_info(request_body, opts = {})
36
+ if @api_client.config.debugging
37
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_batch_video_detail ...'
38
+ end
39
+ # verify the required parameter 'request_body' is set
40
+ if @api_client.config.client_side_validation && request_body.nil?
41
+ fail ArgumentError, "Missing the required parameter 'request_body' when calling YouTubeApi.youtube_batch_video_detail"
42
+ end
43
+ # resource path
44
+ local_var_path = '/v1/youtube/videos/batch'
45
+
46
+ # query parameters
47
+ query_params = opts[:query_params] || {}
48
+
49
+ # header parameters
50
+ header_params = opts[:header_params] || {}
51
+ # HTTP header 'Accept' (if needed)
52
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
53
+ # HTTP header 'Content-Type'
54
+ content_type = @api_client.select_header_content_type(['application/json'])
55
+ if !content_type.nil?
56
+ header_params['Content-Type'] = content_type
57
+ end
58
+
59
+ # form parameters
60
+ form_params = opts[:form_params] || {}
61
+
62
+ # http body (model)
63
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(request_body)
64
+
65
+ # return_type
66
+ return_type = opts[:debug_return_type] || 'Object'
67
+
68
+ # auth_names
69
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
70
+
71
+ new_options = opts.merge(
72
+ :operation => :"YouTubeApi.youtube_batch_video_detail",
73
+ :header_params => header_params,
74
+ :query_params => query_params,
75
+ :form_params => form_params,
76
+ :body => post_body,
77
+ :auth_names => auth_names,
78
+ :return_type => return_type
79
+ )
80
+
81
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
82
+ if @api_client.config.debugging
83
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_batch_video_detail\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
84
+ end
85
+ return data, status_code, headers
86
+ end
87
+
88
+ # Channel about
89
+ # @param channel_id [String]
90
+ # @param [Hash] opts the optional parameters
91
+ # @return [Object]
92
+ def youtube_channel_about(channel_id, opts = {})
93
+ data, _status_code, _headers = youtube_channel_about_with_http_info(channel_id, opts)
94
+ data
95
+ end
96
+
97
+ # Channel about
98
+ # @param channel_id [String]
99
+ # @param [Hash] opts the optional parameters
100
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
101
+ def youtube_channel_about_with_http_info(channel_id, opts = {})
102
+ if @api_client.config.debugging
103
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_channel_about ...'
104
+ end
105
+ # verify the required parameter 'channel_id' is set
106
+ if @api_client.config.client_side_validation && channel_id.nil?
107
+ fail ArgumentError, "Missing the required parameter 'channel_id' when calling YouTubeApi.youtube_channel_about"
108
+ end
109
+ # resource path
110
+ local_var_path = '/v1/youtube/channels/{channel_id}/about'.sub('{' + 'channel_id' + '}', CGI.escape(channel_id.to_s))
111
+
112
+ # query parameters
113
+ query_params = opts[:query_params] || {}
114
+
115
+ # header parameters
116
+ header_params = opts[:header_params] || {}
117
+ # HTTP header 'Accept' (if needed)
118
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
119
+
120
+ # form parameters
121
+ form_params = opts[:form_params] || {}
122
+
123
+ # http body (model)
124
+ post_body = opts[:debug_body]
125
+
126
+ # return_type
127
+ return_type = opts[:debug_return_type] || 'Object'
128
+
129
+ # auth_names
130
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
131
+
132
+ new_options = opts.merge(
133
+ :operation => :"YouTubeApi.youtube_channel_about",
134
+ :header_params => header_params,
135
+ :query_params => query_params,
136
+ :form_params => form_params,
137
+ :body => post_body,
138
+ :auth_names => auth_names,
139
+ :return_type => return_type
140
+ )
141
+
142
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
143
+ if @api_client.config.debugging
144
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_channel_about\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
145
+ end
146
+ return data, status_code, headers
147
+ end
148
+
149
+ # Channel playlists
150
+ # @param channel_id [String]
151
+ # @param [Hash] opts the optional parameters
152
+ # @return [Object]
153
+ def youtube_channel_playlists(channel_id, opts = {})
154
+ data, _status_code, _headers = youtube_channel_playlists_with_http_info(channel_id, opts)
155
+ data
156
+ end
157
+
158
+ # Channel playlists
159
+ # @param channel_id [String]
160
+ # @param [Hash] opts the optional parameters
161
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
162
+ def youtube_channel_playlists_with_http_info(channel_id, opts = {})
163
+ if @api_client.config.debugging
164
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_channel_playlists ...'
165
+ end
166
+ # verify the required parameter 'channel_id' is set
167
+ if @api_client.config.client_side_validation && channel_id.nil?
168
+ fail ArgumentError, "Missing the required parameter 'channel_id' when calling YouTubeApi.youtube_channel_playlists"
169
+ end
170
+ # resource path
171
+ local_var_path = '/v1/youtube/channels/{channel_id}/playlists'.sub('{' + 'channel_id' + '}', CGI.escape(channel_id.to_s))
172
+
173
+ # query parameters
174
+ query_params = opts[:query_params] || {}
175
+
176
+ # header parameters
177
+ header_params = opts[:header_params] || {}
178
+ # HTTP header 'Accept' (if needed)
179
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
180
+
181
+ # form parameters
182
+ form_params = opts[:form_params] || {}
183
+
184
+ # http body (model)
185
+ post_body = opts[:debug_body]
186
+
187
+ # return_type
188
+ return_type = opts[:debug_return_type] || 'Object'
189
+
190
+ # auth_names
191
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
192
+
193
+ new_options = opts.merge(
194
+ :operation => :"YouTubeApi.youtube_channel_playlists",
195
+ :header_params => header_params,
196
+ :query_params => query_params,
197
+ :form_params => form_params,
198
+ :body => post_body,
199
+ :auth_names => auth_names,
200
+ :return_type => return_type
201
+ )
202
+
203
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
204
+ if @api_client.config.debugging
205
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_channel_playlists\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
206
+ end
207
+ return data, status_code, headers
208
+ end
209
+
210
+ # Channel shorts
211
+ # @param channel_id [String]
212
+ # @param [Hash] opts the optional parameters
213
+ # @return [Object]
214
+ def youtube_channel_shorts(channel_id, opts = {})
215
+ data, _status_code, _headers = youtube_channel_shorts_with_http_info(channel_id, opts)
216
+ data
217
+ end
218
+
219
+ # Channel shorts
220
+ # @param channel_id [String]
221
+ # @param [Hash] opts the optional parameters
222
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
223
+ def youtube_channel_shorts_with_http_info(channel_id, opts = {})
224
+ if @api_client.config.debugging
225
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_channel_shorts ...'
226
+ end
227
+ # verify the required parameter 'channel_id' is set
228
+ if @api_client.config.client_side_validation && channel_id.nil?
229
+ fail ArgumentError, "Missing the required parameter 'channel_id' when calling YouTubeApi.youtube_channel_shorts"
230
+ end
231
+ # resource path
232
+ local_var_path = '/v1/youtube/channels/{channel_id}/shorts'.sub('{' + 'channel_id' + '}', CGI.escape(channel_id.to_s))
233
+
234
+ # query parameters
235
+ query_params = opts[:query_params] || {}
236
+
237
+ # header parameters
238
+ header_params = opts[:header_params] || {}
239
+ # HTTP header 'Accept' (if needed)
240
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
241
+
242
+ # form parameters
243
+ form_params = opts[:form_params] || {}
244
+
245
+ # http body (model)
246
+ post_body = opts[:debug_body]
247
+
248
+ # return_type
249
+ return_type = opts[:debug_return_type] || 'Object'
250
+
251
+ # auth_names
252
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
253
+
254
+ new_options = opts.merge(
255
+ :operation => :"YouTubeApi.youtube_channel_shorts",
256
+ :header_params => header_params,
257
+ :query_params => query_params,
258
+ :form_params => form_params,
259
+ :body => post_body,
260
+ :auth_names => auth_names,
261
+ :return_type => return_type
262
+ )
263
+
264
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
265
+ if @api_client.config.debugging
266
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_channel_shorts\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
267
+ end
268
+ return data, status_code, headers
269
+ end
270
+
271
+ # Channel streams
272
+ # @param channel_id [String]
273
+ # @param [Hash] opts the optional parameters
274
+ # @return [Object]
275
+ def youtube_channel_streams(channel_id, opts = {})
276
+ data, _status_code, _headers = youtube_channel_streams_with_http_info(channel_id, opts)
277
+ data
278
+ end
279
+
280
+ # Channel streams
281
+ # @param channel_id [String]
282
+ # @param [Hash] opts the optional parameters
283
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
284
+ def youtube_channel_streams_with_http_info(channel_id, opts = {})
285
+ if @api_client.config.debugging
286
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_channel_streams ...'
287
+ end
288
+ # verify the required parameter 'channel_id' is set
289
+ if @api_client.config.client_side_validation && channel_id.nil?
290
+ fail ArgumentError, "Missing the required parameter 'channel_id' when calling YouTubeApi.youtube_channel_streams"
291
+ end
292
+ # resource path
293
+ local_var_path = '/v1/youtube/channels/{channel_id}/streams'.sub('{' + 'channel_id' + '}', CGI.escape(channel_id.to_s))
294
+
295
+ # query parameters
296
+ query_params = opts[:query_params] || {}
297
+
298
+ # header parameters
299
+ header_params = opts[:header_params] || {}
300
+ # HTTP header 'Accept' (if needed)
301
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
302
+
303
+ # form parameters
304
+ form_params = opts[:form_params] || {}
305
+
306
+ # http body (model)
307
+ post_body = opts[:debug_body]
308
+
309
+ # return_type
310
+ return_type = opts[:debug_return_type] || 'Object'
311
+
312
+ # auth_names
313
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
314
+
315
+ new_options = opts.merge(
316
+ :operation => :"YouTubeApi.youtube_channel_streams",
317
+ :header_params => header_params,
318
+ :query_params => query_params,
319
+ :form_params => form_params,
320
+ :body => post_body,
321
+ :auth_names => auth_names,
322
+ :return_type => return_type
323
+ )
324
+
325
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
326
+ if @api_client.config.debugging
327
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_channel_streams\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
328
+ end
329
+ return data, status_code, headers
330
+ end
331
+
332
+ # Channel videos
333
+ # @param channel_id [String]
334
+ # @param [Hash] opts the optional parameters
335
+ # @return [Object]
336
+ def youtube_channel_videos(channel_id, opts = {})
337
+ data, _status_code, _headers = youtube_channel_videos_with_http_info(channel_id, opts)
338
+ data
339
+ end
340
+
341
+ # Channel videos
342
+ # @param channel_id [String]
343
+ # @param [Hash] opts the optional parameters
344
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
345
+ def youtube_channel_videos_with_http_info(channel_id, opts = {})
346
+ if @api_client.config.debugging
347
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_channel_videos ...'
348
+ end
349
+ # verify the required parameter 'channel_id' is set
350
+ if @api_client.config.client_side_validation && channel_id.nil?
351
+ fail ArgumentError, "Missing the required parameter 'channel_id' when calling YouTubeApi.youtube_channel_videos"
352
+ end
353
+ # resource path
354
+ local_var_path = '/v1/youtube/channels/{channel_id}/videos'.sub('{' + 'channel_id' + '}', CGI.escape(channel_id.to_s))
355
+
356
+ # query parameters
357
+ query_params = opts[:query_params] || {}
358
+
359
+ # header parameters
360
+ header_params = opts[:header_params] || {}
361
+ # HTTP header 'Accept' (if needed)
362
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
363
+
364
+ # form parameters
365
+ form_params = opts[:form_params] || {}
366
+
367
+ # http body (model)
368
+ post_body = opts[:debug_body]
369
+
370
+ # return_type
371
+ return_type = opts[:debug_return_type] || 'Object'
372
+
373
+ # auth_names
374
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
375
+
376
+ new_options = opts.merge(
377
+ :operation => :"YouTubeApi.youtube_channel_videos",
378
+ :header_params => header_params,
379
+ :query_params => query_params,
380
+ :form_params => form_params,
381
+ :body => post_body,
382
+ :auth_names => auth_names,
383
+ :return_type => return_type
384
+ )
385
+
386
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
387
+ if @api_client.config.debugging
388
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_channel_videos\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
389
+ end
390
+ return data, status_code, headers
391
+ end
392
+
393
+ # Comment replies
394
+ # @param video_id [String]
395
+ # @param comment_id [String]
396
+ # @param continuation [String] Replies continuation token
397
+ # @param [Hash] opts the optional parameters
398
+ # @return [Object]
399
+ def youtube_comment_replies(video_id, comment_id, continuation, opts = {})
400
+ data, _status_code, _headers = youtube_comment_replies_with_http_info(video_id, comment_id, continuation, opts)
401
+ data
402
+ end
403
+
404
+ # Comment replies
405
+ # @param video_id [String]
406
+ # @param comment_id [String]
407
+ # @param continuation [String] Replies continuation token
408
+ # @param [Hash] opts the optional parameters
409
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
410
+ def youtube_comment_replies_with_http_info(video_id, comment_id, continuation, opts = {})
411
+ if @api_client.config.debugging
412
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_comment_replies ...'
413
+ end
414
+ # verify the required parameter 'video_id' is set
415
+ if @api_client.config.client_side_validation && video_id.nil?
416
+ fail ArgumentError, "Missing the required parameter 'video_id' when calling YouTubeApi.youtube_comment_replies"
417
+ end
418
+ # verify the required parameter 'comment_id' is set
419
+ if @api_client.config.client_side_validation && comment_id.nil?
420
+ fail ArgumentError, "Missing the required parameter 'comment_id' when calling YouTubeApi.youtube_comment_replies"
421
+ end
422
+ # verify the required parameter 'continuation' is set
423
+ if @api_client.config.client_side_validation && continuation.nil?
424
+ fail ArgumentError, "Missing the required parameter 'continuation' when calling YouTubeApi.youtube_comment_replies"
425
+ end
426
+ # resource path
427
+ local_var_path = '/v1/youtube/videos/{video_id}/comments/{comment_id}/replies'.sub('{' + 'video_id' + '}', CGI.escape(video_id.to_s)).sub('{' + 'comment_id' + '}', CGI.escape(comment_id.to_s))
428
+
429
+ # query parameters
430
+ query_params = opts[:query_params] || {}
431
+ query_params[:'continuation'] = continuation
432
+
433
+ # header parameters
434
+ header_params = opts[:header_params] || {}
435
+ # HTTP header 'Accept' (if needed)
436
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
437
+
438
+ # form parameters
439
+ form_params = opts[:form_params] || {}
440
+
441
+ # http body (model)
442
+ post_body = opts[:debug_body]
443
+
444
+ # return_type
445
+ return_type = opts[:debug_return_type] || 'Object'
446
+
447
+ # auth_names
448
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
449
+
450
+ new_options = opts.merge(
451
+ :operation => :"YouTubeApi.youtube_comment_replies",
452
+ :header_params => header_params,
453
+ :query_params => query_params,
454
+ :form_params => form_params,
455
+ :body => post_body,
456
+ :auth_names => auth_names,
457
+ :return_type => return_type
458
+ )
459
+
460
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
461
+ if @api_client.config.debugging
462
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_comment_replies\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
463
+ end
464
+ return data, status_code, headers
465
+ end
466
+
467
+ # Community post comments
468
+ # @param post_id [String]
469
+ # @param [Hash] opts the optional parameters
470
+ # @return [Object]
471
+ def youtube_community_post_comments(post_id, opts = {})
472
+ data, _status_code, _headers = youtube_community_post_comments_with_http_info(post_id, opts)
473
+ data
474
+ end
475
+
476
+ # Community post comments
477
+ # @param post_id [String]
478
+ # @param [Hash] opts the optional parameters
479
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
480
+ def youtube_community_post_comments_with_http_info(post_id, opts = {})
481
+ if @api_client.config.debugging
482
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_community_post_comments ...'
483
+ end
484
+ # verify the required parameter 'post_id' is set
485
+ if @api_client.config.client_side_validation && post_id.nil?
486
+ fail ArgumentError, "Missing the required parameter 'post_id' when calling YouTubeApi.youtube_community_post_comments"
487
+ end
488
+ # resource path
489
+ local_var_path = '/v1/youtube/posts/{post_id}/comments'.sub('{' + 'post_id' + '}', CGI.escape(post_id.to_s))
490
+
491
+ # query parameters
492
+ query_params = opts[:query_params] || {}
493
+
494
+ # header parameters
495
+ header_params = opts[:header_params] || {}
496
+ # HTTP header 'Accept' (if needed)
497
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
498
+
499
+ # form parameters
500
+ form_params = opts[:form_params] || {}
501
+
502
+ # http body (model)
503
+ post_body = opts[:debug_body]
504
+
505
+ # return_type
506
+ return_type = opts[:debug_return_type] || 'Object'
507
+
508
+ # auth_names
509
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
510
+
511
+ new_options = opts.merge(
512
+ :operation => :"YouTubeApi.youtube_community_post_comments",
513
+ :header_params => header_params,
514
+ :query_params => query_params,
515
+ :form_params => form_params,
516
+ :body => post_body,
517
+ :auth_names => auth_names,
518
+ :return_type => return_type
519
+ )
520
+
521
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
522
+ if @api_client.config.debugging
523
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_community_post_comments\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
524
+ end
525
+ return data, status_code, headers
526
+ end
527
+
528
+ # Community posts
529
+ # @param channel_id [String]
530
+ # @param [Hash] opts the optional parameters
531
+ # @return [Object]
532
+ def youtube_community_posts(channel_id, opts = {})
533
+ data, _status_code, _headers = youtube_community_posts_with_http_info(channel_id, opts)
534
+ data
535
+ end
536
+
537
+ # Community posts
538
+ # @param channel_id [String]
539
+ # @param [Hash] opts the optional parameters
540
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
541
+ def youtube_community_posts_with_http_info(channel_id, opts = {})
542
+ if @api_client.config.debugging
543
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_community_posts ...'
544
+ end
545
+ # verify the required parameter 'channel_id' is set
546
+ if @api_client.config.client_side_validation && channel_id.nil?
547
+ fail ArgumentError, "Missing the required parameter 'channel_id' when calling YouTubeApi.youtube_community_posts"
548
+ end
549
+ # resource path
550
+ local_var_path = '/v1/youtube/channels/{channel_id}/community'.sub('{' + 'channel_id' + '}', CGI.escape(channel_id.to_s))
551
+
552
+ # query parameters
553
+ query_params = opts[:query_params] || {}
554
+
555
+ # header parameters
556
+ header_params = opts[:header_params] || {}
557
+ # HTTP header 'Accept' (if needed)
558
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
559
+
560
+ # form parameters
561
+ form_params = opts[:form_params] || {}
562
+
563
+ # http body (model)
564
+ post_body = opts[:debug_body]
565
+
566
+ # return_type
567
+ return_type = opts[:debug_return_type] || 'Object'
568
+
569
+ # auth_names
570
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
571
+
572
+ new_options = opts.merge(
573
+ :operation => :"YouTubeApi.youtube_community_posts",
574
+ :header_params => header_params,
575
+ :query_params => query_params,
576
+ :form_params => form_params,
577
+ :body => post_body,
578
+ :auth_names => auth_names,
579
+ :return_type => return_type
580
+ )
581
+
582
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
583
+ if @api_client.config.debugging
584
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_community_posts\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
585
+ end
586
+ return data, status_code, headers
587
+ end
588
+
589
+ # Content regions
590
+ # @param [Hash] opts the optional parameters
591
+ # @return [Object]
592
+ def youtube_content_regions(opts = {})
593
+ data, _status_code, _headers = youtube_content_regions_with_http_info(opts)
594
+ data
595
+ end
596
+
597
+ # Content regions
598
+ # @param [Hash] opts the optional parameters
599
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
600
+ def youtube_content_regions_with_http_info(opts = {})
601
+ if @api_client.config.debugging
602
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_content_regions ...'
603
+ end
604
+ # resource path
605
+ local_var_path = '/v1/youtube/regions'
606
+
607
+ # query parameters
608
+ query_params = opts[:query_params] || {}
609
+
610
+ # header parameters
611
+ header_params = opts[:header_params] || {}
612
+ # HTTP header 'Accept' (if needed)
613
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
614
+
615
+ # form parameters
616
+ form_params = opts[:form_params] || {}
617
+
618
+ # http body (model)
619
+ post_body = opts[:debug_body]
620
+
621
+ # return_type
622
+ return_type = opts[:debug_return_type] || 'Object'
623
+
624
+ # auth_names
625
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
626
+
627
+ new_options = opts.merge(
628
+ :operation => :"YouTubeApi.youtube_content_regions",
629
+ :header_params => header_params,
630
+ :query_params => query_params,
631
+ :form_params => form_params,
632
+ :body => post_body,
633
+ :auth_names => auth_names,
634
+ :return_type => return_type
635
+ )
636
+
637
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
638
+ if @api_client.config.debugging
639
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_content_regions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
640
+ end
641
+ return data, status_code, headers
642
+ end
643
+
644
+ # Get a community post
645
+ # @param post_id [String]
646
+ # @param [Hash] opts the optional parameters
647
+ # @return [Object]
648
+ def youtube_get_a_community_post(post_id, opts = {})
649
+ data, _status_code, _headers = youtube_get_a_community_post_with_http_info(post_id, opts)
650
+ data
651
+ end
652
+
653
+ # Get a community post
654
+ # @param post_id [String]
655
+ # @param [Hash] opts the optional parameters
656
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
657
+ def youtube_get_a_community_post_with_http_info(post_id, opts = {})
658
+ if @api_client.config.debugging
659
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_get_a_community_post ...'
660
+ end
661
+ # verify the required parameter 'post_id' is set
662
+ if @api_client.config.client_side_validation && post_id.nil?
663
+ fail ArgumentError, "Missing the required parameter 'post_id' when calling YouTubeApi.youtube_get_a_community_post"
664
+ end
665
+ # resource path
666
+ local_var_path = '/v1/youtube/posts/{post_id}'.sub('{' + 'post_id' + '}', CGI.escape(post_id.to_s))
667
+
668
+ # query parameters
669
+ query_params = opts[:query_params] || {}
670
+
671
+ # header parameters
672
+ header_params = opts[:header_params] || {}
673
+ # HTTP header 'Accept' (if needed)
674
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
675
+
676
+ # form parameters
677
+ form_params = opts[:form_params] || {}
678
+
679
+ # http body (model)
680
+ post_body = opts[:debug_body]
681
+
682
+ # return_type
683
+ return_type = opts[:debug_return_type] || 'Object'
684
+
685
+ # auth_names
686
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
687
+
688
+ new_options = opts.merge(
689
+ :operation => :"YouTubeApi.youtube_get_a_community_post",
690
+ :header_params => header_params,
691
+ :query_params => query_params,
692
+ :form_params => form_params,
693
+ :body => post_body,
694
+ :auth_names => auth_names,
695
+ :return_type => return_type
696
+ )
697
+
698
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
699
+ if @api_client.config.debugging
700
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_get_a_community_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
701
+ end
702
+ return data, status_code, headers
703
+ end
704
+
705
+ # Get a mix / radio queue
706
+ # @param playlist_id [String]
707
+ # @param [Hash] opts the optional parameters
708
+ # @return [Object]
709
+ def youtube_get_a_mix_radio_queue(playlist_id, opts = {})
710
+ data, _status_code, _headers = youtube_get_a_mix_radio_queue_with_http_info(playlist_id, opts)
711
+ data
712
+ end
713
+
714
+ # Get a mix / radio queue
715
+ # @param playlist_id [String]
716
+ # @param [Hash] opts the optional parameters
717
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
718
+ def youtube_get_a_mix_radio_queue_with_http_info(playlist_id, opts = {})
719
+ if @api_client.config.debugging
720
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_get_a_mix_radio_queue ...'
721
+ end
722
+ # verify the required parameter 'playlist_id' is set
723
+ if @api_client.config.client_side_validation && playlist_id.nil?
724
+ fail ArgumentError, "Missing the required parameter 'playlist_id' when calling YouTubeApi.youtube_get_a_mix_radio_queue"
725
+ end
726
+ # resource path
727
+ local_var_path = '/v1/youtube/mixes/{playlist_id}'.sub('{' + 'playlist_id' + '}', CGI.escape(playlist_id.to_s))
728
+
729
+ # query parameters
730
+ query_params = opts[:query_params] || {}
731
+
732
+ # header parameters
733
+ header_params = opts[:header_params] || {}
734
+ # HTTP header 'Accept' (if needed)
735
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
736
+
737
+ # form parameters
738
+ form_params = opts[:form_params] || {}
739
+
740
+ # http body (model)
741
+ post_body = opts[:debug_body]
742
+
743
+ # return_type
744
+ return_type = opts[:debug_return_type] || 'Object'
745
+
746
+ # auth_names
747
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
748
+
749
+ new_options = opts.merge(
750
+ :operation => :"YouTubeApi.youtube_get_a_mix_radio_queue",
751
+ :header_params => header_params,
752
+ :query_params => query_params,
753
+ :form_params => form_params,
754
+ :body => post_body,
755
+ :auth_names => auth_names,
756
+ :return_type => return_type
757
+ )
758
+
759
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
760
+ if @api_client.config.debugging
761
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_get_a_mix_radio_queue\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
762
+ end
763
+ return data, status_code, headers
764
+ end
765
+
766
+ # Get a Short
767
+ # @param video_id [String]
768
+ # @param [Hash] opts the optional parameters
769
+ # @return [Object]
770
+ def youtube_get_a_short(video_id, opts = {})
771
+ data, _status_code, _headers = youtube_get_a_short_with_http_info(video_id, opts)
772
+ data
773
+ end
774
+
775
+ # Get a Short
776
+ # @param video_id [String]
777
+ # @param [Hash] opts the optional parameters
778
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
779
+ def youtube_get_a_short_with_http_info(video_id, opts = {})
780
+ if @api_client.config.debugging
781
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_get_a_short ...'
782
+ end
783
+ # verify the required parameter 'video_id' is set
784
+ if @api_client.config.client_side_validation && video_id.nil?
785
+ fail ArgumentError, "Missing the required parameter 'video_id' when calling YouTubeApi.youtube_get_a_short"
786
+ end
787
+ # resource path
788
+ local_var_path = '/v1/youtube/shorts/{video_id}'.sub('{' + 'video_id' + '}', CGI.escape(video_id.to_s))
789
+
790
+ # query parameters
791
+ query_params = opts[:query_params] || {}
792
+
793
+ # header parameters
794
+ header_params = opts[:header_params] || {}
795
+ # HTTP header 'Accept' (if needed)
796
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
797
+
798
+ # form parameters
799
+ form_params = opts[:form_params] || {}
800
+
801
+ # http body (model)
802
+ post_body = opts[:debug_body]
803
+
804
+ # return_type
805
+ return_type = opts[:debug_return_type] || 'Object'
806
+
807
+ # auth_names
808
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
809
+
810
+ new_options = opts.merge(
811
+ :operation => :"YouTubeApi.youtube_get_a_short",
812
+ :header_params => header_params,
813
+ :query_params => query_params,
814
+ :form_params => form_params,
815
+ :body => post_body,
816
+ :auth_names => auth_names,
817
+ :return_type => return_type
818
+ )
819
+
820
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
821
+ if @api_client.config.debugging
822
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_get_a_short\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
823
+ end
824
+ return data, status_code, headers
825
+ end
826
+
827
+ # Get channel detail
828
+ # Channel detail (accepts a UC id, @handle, or custom URL).
829
+ # @param channel_id [String]
830
+ # @param [Hash] opts the optional parameters
831
+ # @option opts [String] :gl
832
+ # @option opts [String] :hl
833
+ # @return [Object]
834
+ def youtube_get_channel_detail(channel_id, opts = {})
835
+ data, _status_code, _headers = youtube_get_channel_detail_with_http_info(channel_id, opts)
836
+ data
837
+ end
838
+
839
+ # Get channel detail
840
+ # Channel detail (accepts a UC id, @handle, or custom URL).
841
+ # @param channel_id [String]
842
+ # @param [Hash] opts the optional parameters
843
+ # @option opts [String] :gl
844
+ # @option opts [String] :hl
845
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
846
+ def youtube_get_channel_detail_with_http_info(channel_id, opts = {})
847
+ if @api_client.config.debugging
848
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_get_channel_detail ...'
849
+ end
850
+ # verify the required parameter 'channel_id' is set
851
+ if @api_client.config.client_side_validation && channel_id.nil?
852
+ fail ArgumentError, "Missing the required parameter 'channel_id' when calling YouTubeApi.youtube_get_channel_detail"
853
+ end
854
+ # resource path
855
+ local_var_path = '/v1/youtube/channels/{channel_id}'.sub('{' + 'channel_id' + '}', CGI.escape(channel_id.to_s))
856
+
857
+ # query parameters
858
+ query_params = opts[:query_params] || {}
859
+ query_params[:'gl'] = opts[:'gl'] if !opts[:'gl'].nil?
860
+ query_params[:'hl'] = opts[:'hl'] if !opts[:'hl'].nil?
861
+
862
+ # header parameters
863
+ header_params = opts[:header_params] || {}
864
+ # HTTP header 'Accept' (if needed)
865
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
866
+
867
+ # form parameters
868
+ form_params = opts[:form_params] || {}
869
+
870
+ # http body (model)
871
+ post_body = opts[:debug_body]
872
+
873
+ # return_type
874
+ return_type = opts[:debug_return_type] || 'Object'
875
+
876
+ # auth_names
877
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
878
+
879
+ new_options = opts.merge(
880
+ :operation => :"YouTubeApi.youtube_get_channel_detail",
881
+ :header_params => header_params,
882
+ :query_params => query_params,
883
+ :form_params => form_params,
884
+ :body => post_body,
885
+ :auth_names => auth_names,
886
+ :return_type => return_type
887
+ )
888
+
889
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
890
+ if @api_client.config.debugging
891
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_get_channel_detail\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
892
+ end
893
+ return data, status_code, headers
894
+ end
895
+
896
+ # Get playlist detail
897
+ # @param playlist_id [String]
898
+ # @param [Hash] opts the optional parameters
899
+ # @return [Object]
900
+ def youtube_get_playlist_detail(playlist_id, opts = {})
901
+ data, _status_code, _headers = youtube_get_playlist_detail_with_http_info(playlist_id, opts)
902
+ data
903
+ end
904
+
905
+ # Get playlist detail
906
+ # @param playlist_id [String]
907
+ # @param [Hash] opts the optional parameters
908
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
909
+ def youtube_get_playlist_detail_with_http_info(playlist_id, opts = {})
910
+ if @api_client.config.debugging
911
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_get_playlist_detail ...'
912
+ end
913
+ # verify the required parameter 'playlist_id' is set
914
+ if @api_client.config.client_side_validation && playlist_id.nil?
915
+ fail ArgumentError, "Missing the required parameter 'playlist_id' when calling YouTubeApi.youtube_get_playlist_detail"
916
+ end
917
+ # resource path
918
+ local_var_path = '/v1/youtube/playlists/{playlist_id}'.sub('{' + 'playlist_id' + '}', CGI.escape(playlist_id.to_s))
919
+
920
+ # query parameters
921
+ query_params = opts[:query_params] || {}
922
+
923
+ # header parameters
924
+ header_params = opts[:header_params] || {}
925
+ # HTTP header 'Accept' (if needed)
926
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
927
+
928
+ # form parameters
929
+ form_params = opts[:form_params] || {}
930
+
931
+ # http body (model)
932
+ post_body = opts[:debug_body]
933
+
934
+ # return_type
935
+ return_type = opts[:debug_return_type] || 'Object'
936
+
937
+ # auth_names
938
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
939
+
940
+ new_options = opts.merge(
941
+ :operation => :"YouTubeApi.youtube_get_playlist_detail",
942
+ :header_params => header_params,
943
+ :query_params => query_params,
944
+ :form_params => form_params,
945
+ :body => post_body,
946
+ :auth_names => auth_names,
947
+ :return_type => return_type
948
+ )
949
+
950
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
951
+ if @api_client.config.debugging
952
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_get_playlist_detail\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
953
+ end
954
+ return data, status_code, headers
955
+ end
956
+
957
+ # Get video detail
958
+ # Full video detail — merged player + next (likes, comments, chapters, related).
959
+ # @param video_id [String]
960
+ # @param [Hash] opts the optional parameters
961
+ # @option opts [String] :gl
962
+ # @option opts [String] :hl
963
+ # @return [Object]
964
+ def youtube_get_video_detail(video_id, opts = {})
965
+ data, _status_code, _headers = youtube_get_video_detail_with_http_info(video_id, opts)
966
+ data
967
+ end
968
+
969
+ # Get video detail
970
+ # Full video detail — merged player + next (likes, comments, chapters, related).
971
+ # @param video_id [String]
972
+ # @param [Hash] opts the optional parameters
973
+ # @option opts [String] :gl
974
+ # @option opts [String] :hl
975
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
976
+ def youtube_get_video_detail_with_http_info(video_id, opts = {})
977
+ if @api_client.config.debugging
978
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_get_video_detail ...'
979
+ end
980
+ # verify the required parameter 'video_id' is set
981
+ if @api_client.config.client_side_validation && video_id.nil?
982
+ fail ArgumentError, "Missing the required parameter 'video_id' when calling YouTubeApi.youtube_get_video_detail"
983
+ end
984
+ # resource path
985
+ local_var_path = '/v1/youtube/videos/{video_id}'.sub('{' + 'video_id' + '}', CGI.escape(video_id.to_s))
986
+
987
+ # query parameters
988
+ query_params = opts[:query_params] || {}
989
+ query_params[:'gl'] = opts[:'gl'] if !opts[:'gl'].nil?
990
+ query_params[:'hl'] = opts[:'hl'] if !opts[:'hl'].nil?
991
+
992
+ # header parameters
993
+ header_params = opts[:header_params] || {}
994
+ # HTTP header 'Accept' (if needed)
995
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
996
+
997
+ # form parameters
998
+ form_params = opts[:form_params] || {}
999
+
1000
+ # http body (model)
1001
+ post_body = opts[:debug_body]
1002
+
1003
+ # return_type
1004
+ return_type = opts[:debug_return_type] || 'Object'
1005
+
1006
+ # auth_names
1007
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1008
+
1009
+ new_options = opts.merge(
1010
+ :operation => :"YouTubeApi.youtube_get_video_detail",
1011
+ :header_params => header_params,
1012
+ :query_params => query_params,
1013
+ :form_params => form_params,
1014
+ :body => post_body,
1015
+ :auth_names => auth_names,
1016
+ :return_type => return_type
1017
+ )
1018
+
1019
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1020
+ if @api_client.config.debugging
1021
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_get_video_detail\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1022
+ end
1023
+ return data, status_code, headers
1024
+ end
1025
+
1026
+ # Guest home feed
1027
+ # @param [Hash] opts the optional parameters
1028
+ # @return [Object]
1029
+ def youtube_guest_home_feed(opts = {})
1030
+ data, _status_code, _headers = youtube_guest_home_feed_with_http_info(opts)
1031
+ data
1032
+ end
1033
+
1034
+ # Guest home feed
1035
+ # @param [Hash] opts the optional parameters
1036
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1037
+ def youtube_guest_home_feed_with_http_info(opts = {})
1038
+ if @api_client.config.debugging
1039
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_guest_home_feed ...'
1040
+ end
1041
+ # resource path
1042
+ local_var_path = '/v1/youtube/home'
1043
+
1044
+ # query parameters
1045
+ query_params = opts[:query_params] || {}
1046
+
1047
+ # header parameters
1048
+ header_params = opts[:header_params] || {}
1049
+ # HTTP header 'Accept' (if needed)
1050
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1051
+
1052
+ # form parameters
1053
+ form_params = opts[:form_params] || {}
1054
+
1055
+ # http body (model)
1056
+ post_body = opts[:debug_body]
1057
+
1058
+ # return_type
1059
+ return_type = opts[:debug_return_type] || 'Object'
1060
+
1061
+ # auth_names
1062
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1063
+
1064
+ new_options = opts.merge(
1065
+ :operation => :"YouTubeApi.youtube_guest_home_feed",
1066
+ :header_params => header_params,
1067
+ :query_params => query_params,
1068
+ :form_params => form_params,
1069
+ :body => post_body,
1070
+ :auth_names => auth_names,
1071
+ :return_type => return_type
1072
+ )
1073
+
1074
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1075
+ if @api_client.config.debugging
1076
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_guest_home_feed\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1077
+ end
1078
+ return data, status_code, headers
1079
+ end
1080
+
1081
+ # Keyword suggestions
1082
+ # Return YouTube keyword autocomplete suggestions.
1083
+ # @param query [String] Partial query prefix
1084
+ # @param [Hash] opts the optional parameters
1085
+ # @option opts [String] :gl
1086
+ # @option opts [String] :hl
1087
+ # @return [Object]
1088
+ def youtube_keyword_suggestions(query, opts = {})
1089
+ data, _status_code, _headers = youtube_keyword_suggestions_with_http_info(query, opts)
1090
+ data
1091
+ end
1092
+
1093
+ # Keyword suggestions
1094
+ # Return YouTube keyword autocomplete suggestions.
1095
+ # @param query [String] Partial query prefix
1096
+ # @param [Hash] opts the optional parameters
1097
+ # @option opts [String] :gl
1098
+ # @option opts [String] :hl
1099
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1100
+ def youtube_keyword_suggestions_with_http_info(query, opts = {})
1101
+ if @api_client.config.debugging
1102
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_keyword_suggestions ...'
1103
+ end
1104
+ # verify the required parameter 'query' is set
1105
+ if @api_client.config.client_side_validation && query.nil?
1106
+ fail ArgumentError, "Missing the required parameter 'query' when calling YouTubeApi.youtube_keyword_suggestions"
1107
+ end
1108
+ # resource path
1109
+ local_var_path = '/v1/youtube/autocomplete'
1110
+
1111
+ # query parameters
1112
+ query_params = opts[:query_params] || {}
1113
+ query_params[:'query'] = query
1114
+ query_params[:'gl'] = opts[:'gl'] if !opts[:'gl'].nil?
1115
+ query_params[:'hl'] = opts[:'hl'] if !opts[:'hl'].nil?
1116
+
1117
+ # header parameters
1118
+ header_params = opts[:header_params] || {}
1119
+ # HTTP header 'Accept' (if needed)
1120
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1121
+
1122
+ # form parameters
1123
+ form_params = opts[:form_params] || {}
1124
+
1125
+ # http body (model)
1126
+ post_body = opts[:debug_body]
1127
+
1128
+ # return_type
1129
+ return_type = opts[:debug_return_type] || 'Object'
1130
+
1131
+ # auth_names
1132
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1133
+
1134
+ new_options = opts.merge(
1135
+ :operation => :"YouTubeApi.youtube_keyword_suggestions",
1136
+ :header_params => header_params,
1137
+ :query_params => query_params,
1138
+ :form_params => form_params,
1139
+ :body => post_body,
1140
+ :auth_names => auth_names,
1141
+ :return_type => return_type
1142
+ )
1143
+
1144
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1145
+ if @api_client.config.debugging
1146
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_keyword_suggestions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1147
+ end
1148
+ return data, status_code, headers
1149
+ end
1150
+
1151
+ # List caption tracks
1152
+ # @param video_id [String]
1153
+ # @param [Hash] opts the optional parameters
1154
+ # @return [Object]
1155
+ def youtube_list_caption_tracks(video_id, opts = {})
1156
+ data, _status_code, _headers = youtube_list_caption_tracks_with_http_info(video_id, opts)
1157
+ data
1158
+ end
1159
+
1160
+ # List caption tracks
1161
+ # @param video_id [String]
1162
+ # @param [Hash] opts the optional parameters
1163
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1164
+ def youtube_list_caption_tracks_with_http_info(video_id, opts = {})
1165
+ if @api_client.config.debugging
1166
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_list_caption_tracks ...'
1167
+ end
1168
+ # verify the required parameter 'video_id' is set
1169
+ if @api_client.config.client_side_validation && video_id.nil?
1170
+ fail ArgumentError, "Missing the required parameter 'video_id' when calling YouTubeApi.youtube_list_caption_tracks"
1171
+ end
1172
+ # resource path
1173
+ local_var_path = '/v1/youtube/videos/{video_id}/captions'.sub('{' + 'video_id' + '}', CGI.escape(video_id.to_s))
1174
+
1175
+ # query parameters
1176
+ query_params = opts[:query_params] || {}
1177
+
1178
+ # header parameters
1179
+ header_params = opts[:header_params] || {}
1180
+ # HTTP header 'Accept' (if needed)
1181
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1182
+
1183
+ # form parameters
1184
+ form_params = opts[:form_params] || {}
1185
+
1186
+ # http body (model)
1187
+ post_body = opts[:debug_body]
1188
+
1189
+ # return_type
1190
+ return_type = opts[:debug_return_type] || 'Object'
1191
+
1192
+ # auth_names
1193
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1194
+
1195
+ new_options = opts.merge(
1196
+ :operation => :"YouTubeApi.youtube_list_caption_tracks",
1197
+ :header_params => header_params,
1198
+ :query_params => query_params,
1199
+ :form_params => form_params,
1200
+ :body => post_body,
1201
+ :auth_names => auth_names,
1202
+ :return_type => return_type
1203
+ )
1204
+
1205
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1206
+ if @api_client.config.debugging
1207
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_list_caption_tracks\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1208
+ end
1209
+ return data, status_code, headers
1210
+ end
1211
+
1212
+ # Live chat messages
1213
+ # @param video_id [String]
1214
+ # @param [Hash] opts the optional parameters
1215
+ # @option opts [String] :continuation
1216
+ # @option opts [Boolean] :replay (default to false)
1217
+ # @return [Object]
1218
+ def youtube_live_chat_messages(video_id, opts = {})
1219
+ data, _status_code, _headers = youtube_live_chat_messages_with_http_info(video_id, opts)
1220
+ data
1221
+ end
1222
+
1223
+ # Live chat messages
1224
+ # @param video_id [String]
1225
+ # @param [Hash] opts the optional parameters
1226
+ # @option opts [String] :continuation
1227
+ # @option opts [Boolean] :replay (default to false)
1228
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1229
+ def youtube_live_chat_messages_with_http_info(video_id, opts = {})
1230
+ if @api_client.config.debugging
1231
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_live_chat_messages ...'
1232
+ end
1233
+ # verify the required parameter 'video_id' is set
1234
+ if @api_client.config.client_side_validation && video_id.nil?
1235
+ fail ArgumentError, "Missing the required parameter 'video_id' when calling YouTubeApi.youtube_live_chat_messages"
1236
+ end
1237
+ # resource path
1238
+ local_var_path = '/v1/youtube/videos/{video_id}/live_chat'.sub('{' + 'video_id' + '}', CGI.escape(video_id.to_s))
1239
+
1240
+ # query parameters
1241
+ query_params = opts[:query_params] || {}
1242
+ query_params[:'continuation'] = opts[:'continuation'] if !opts[:'continuation'].nil?
1243
+ query_params[:'replay'] = opts[:'replay'] if !opts[:'replay'].nil?
1244
+
1245
+ # header parameters
1246
+ header_params = opts[:header_params] || {}
1247
+ # HTTP header 'Accept' (if needed)
1248
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1249
+
1250
+ # form parameters
1251
+ form_params = opts[:form_params] || {}
1252
+
1253
+ # http body (model)
1254
+ post_body = opts[:debug_body]
1255
+
1256
+ # return_type
1257
+ return_type = opts[:debug_return_type] || 'Object'
1258
+
1259
+ # auth_names
1260
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1261
+
1262
+ new_options = opts.merge(
1263
+ :operation => :"YouTubeApi.youtube_live_chat_messages",
1264
+ :header_params => header_params,
1265
+ :query_params => query_params,
1266
+ :form_params => form_params,
1267
+ :body => post_body,
1268
+ :auth_names => auth_names,
1269
+ :return_type => return_type
1270
+ )
1271
+
1272
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1273
+ if @api_client.config.debugging
1274
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_live_chat_messages\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1275
+ end
1276
+ return data, status_code, headers
1277
+ end
1278
+
1279
+ # oEmbed metadata
1280
+ # @param url [String] A YouTube URL
1281
+ # @param [Hash] opts the optional parameters
1282
+ # @return [Object]
1283
+ def youtube_oembed_metadata(url, opts = {})
1284
+ data, _status_code, _headers = youtube_oembed_metadata_with_http_info(url, opts)
1285
+ data
1286
+ end
1287
+
1288
+ # oEmbed metadata
1289
+ # @param url [String] A YouTube URL
1290
+ # @param [Hash] opts the optional parameters
1291
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1292
+ def youtube_oembed_metadata_with_http_info(url, opts = {})
1293
+ if @api_client.config.debugging
1294
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_oembed_metadata ...'
1295
+ end
1296
+ # verify the required parameter 'url' is set
1297
+ if @api_client.config.client_side_validation && url.nil?
1298
+ fail ArgumentError, "Missing the required parameter 'url' when calling YouTubeApi.youtube_oembed_metadata"
1299
+ end
1300
+ # resource path
1301
+ local_var_path = '/v1/youtube/oembed'
1302
+
1303
+ # query parameters
1304
+ query_params = opts[:query_params] || {}
1305
+ query_params[:'url'] = url
1306
+
1307
+ # header parameters
1308
+ header_params = opts[:header_params] || {}
1309
+ # HTTP header 'Accept' (if needed)
1310
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1311
+
1312
+ # form parameters
1313
+ form_params = opts[:form_params] || {}
1314
+
1315
+ # http body (model)
1316
+ post_body = opts[:debug_body]
1317
+
1318
+ # return_type
1319
+ return_type = opts[:debug_return_type] || 'Object'
1320
+
1321
+ # auth_names
1322
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1323
+
1324
+ new_options = opts.merge(
1325
+ :operation => :"YouTubeApi.youtube_oembed_metadata",
1326
+ :header_params => header_params,
1327
+ :query_params => query_params,
1328
+ :form_params => form_params,
1329
+ :body => post_body,
1330
+ :auth_names => auth_names,
1331
+ :return_type => return_type
1332
+ )
1333
+
1334
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1335
+ if @api_client.config.debugging
1336
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_oembed_metadata\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1337
+ end
1338
+ return data, status_code, headers
1339
+ end
1340
+
1341
+ # Playlist items page
1342
+ # @param playlist_id [String]
1343
+ # @param [Hash] opts the optional parameters
1344
+ # @return [Object]
1345
+ def youtube_playlist_items_page(playlist_id, opts = {})
1346
+ data, _status_code, _headers = youtube_playlist_items_page_with_http_info(playlist_id, opts)
1347
+ data
1348
+ end
1349
+
1350
+ # Playlist items page
1351
+ # @param playlist_id [String]
1352
+ # @param [Hash] opts the optional parameters
1353
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1354
+ def youtube_playlist_items_page_with_http_info(playlist_id, opts = {})
1355
+ if @api_client.config.debugging
1356
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_playlist_items_page ...'
1357
+ end
1358
+ # verify the required parameter 'playlist_id' is set
1359
+ if @api_client.config.client_side_validation && playlist_id.nil?
1360
+ fail ArgumentError, "Missing the required parameter 'playlist_id' when calling YouTubeApi.youtube_playlist_items_page"
1361
+ end
1362
+ # resource path
1363
+ local_var_path = '/v1/youtube/playlists/{playlist_id}/items'.sub('{' + 'playlist_id' + '}', CGI.escape(playlist_id.to_s))
1364
+
1365
+ # query parameters
1366
+ query_params = opts[:query_params] || {}
1367
+
1368
+ # header parameters
1369
+ header_params = opts[:header_params] || {}
1370
+ # HTTP header 'Accept' (if needed)
1371
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1372
+
1373
+ # form parameters
1374
+ form_params = opts[:form_params] || {}
1375
+
1376
+ # http body (model)
1377
+ post_body = opts[:debug_body]
1378
+
1379
+ # return_type
1380
+ return_type = opts[:debug_return_type] || 'Object'
1381
+
1382
+ # auth_names
1383
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1384
+
1385
+ new_options = opts.merge(
1386
+ :operation => :"YouTubeApi.youtube_playlist_items_page",
1387
+ :header_params => header_params,
1388
+ :query_params => query_params,
1389
+ :form_params => form_params,
1390
+ :body => post_body,
1391
+ :auth_names => auth_names,
1392
+ :return_type => return_type
1393
+ )
1394
+
1395
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1396
+ if @api_client.config.debugging
1397
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_playlist_items_page\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1398
+ end
1399
+ return data, status_code, headers
1400
+ end
1401
+
1402
+ # Related videos
1403
+ # @param video_id [String]
1404
+ # @param [Hash] opts the optional parameters
1405
+ # @return [Object]
1406
+ def youtube_related_videos(video_id, opts = {})
1407
+ data, _status_code, _headers = youtube_related_videos_with_http_info(video_id, opts)
1408
+ data
1409
+ end
1410
+
1411
+ # Related videos
1412
+ # @param video_id [String]
1413
+ # @param [Hash] opts the optional parameters
1414
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1415
+ def youtube_related_videos_with_http_info(video_id, opts = {})
1416
+ if @api_client.config.debugging
1417
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_related_videos ...'
1418
+ end
1419
+ # verify the required parameter 'video_id' is set
1420
+ if @api_client.config.client_side_validation && video_id.nil?
1421
+ fail ArgumentError, "Missing the required parameter 'video_id' when calling YouTubeApi.youtube_related_videos"
1422
+ end
1423
+ # resource path
1424
+ local_var_path = '/v1/youtube/videos/{video_id}/related'.sub('{' + 'video_id' + '}', CGI.escape(video_id.to_s))
1425
+
1426
+ # query parameters
1427
+ query_params = opts[:query_params] || {}
1428
+
1429
+ # header parameters
1430
+ header_params = opts[:header_params] || {}
1431
+ # HTTP header 'Accept' (if needed)
1432
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1433
+
1434
+ # form parameters
1435
+ form_params = opts[:form_params] || {}
1436
+
1437
+ # http body (model)
1438
+ post_body = opts[:debug_body]
1439
+
1440
+ # return_type
1441
+ return_type = opts[:debug_return_type] || 'Object'
1442
+
1443
+ # auth_names
1444
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1445
+
1446
+ new_options = opts.merge(
1447
+ :operation => :"YouTubeApi.youtube_related_videos",
1448
+ :header_params => header_params,
1449
+ :query_params => query_params,
1450
+ :form_params => form_params,
1451
+ :body => post_body,
1452
+ :auth_names => auth_names,
1453
+ :return_type => return_type
1454
+ )
1455
+
1456
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1457
+ if @api_client.config.debugging
1458
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_related_videos\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1459
+ end
1460
+ return data, status_code, headers
1461
+ end
1462
+
1463
+ # Resolve handle/URL to id
1464
+ # @param [Hash] opts the optional parameters
1465
+ # @option opts [String] :handle
1466
+ # @option opts [String] :url
1467
+ # @return [Object]
1468
+ def youtube_resolve_handle_url_to_id(opts = {})
1469
+ data, _status_code, _headers = youtube_resolve_handle_url_to_id_with_http_info(opts)
1470
+ data
1471
+ end
1472
+
1473
+ # Resolve handle/URL to id
1474
+ # @param [Hash] opts the optional parameters
1475
+ # @option opts [String] :handle
1476
+ # @option opts [String] :url
1477
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1478
+ def youtube_resolve_handle_url_to_id_with_http_info(opts = {})
1479
+ if @api_client.config.debugging
1480
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_resolve_handle_url_to_id ...'
1481
+ end
1482
+ # resource path
1483
+ local_var_path = '/v1/youtube/channels/resolve'
1484
+
1485
+ # query parameters
1486
+ query_params = opts[:query_params] || {}
1487
+ query_params[:'handle'] = opts[:'handle'] if !opts[:'handle'].nil?
1488
+ query_params[:'url'] = opts[:'url'] if !opts[:'url'].nil?
1489
+
1490
+ # header parameters
1491
+ header_params = opts[:header_params] || {}
1492
+ # HTTP header 'Accept' (if needed)
1493
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1494
+
1495
+ # form parameters
1496
+ form_params = opts[:form_params] || {}
1497
+
1498
+ # http body (model)
1499
+ post_body = opts[:debug_body]
1500
+
1501
+ # return_type
1502
+ return_type = opts[:debug_return_type] || 'Object'
1503
+
1504
+ # auth_names
1505
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1506
+
1507
+ new_options = opts.merge(
1508
+ :operation => :"YouTubeApi.youtube_resolve_handle_url_to_id",
1509
+ :header_params => header_params,
1510
+ :query_params => query_params,
1511
+ :form_params => form_params,
1512
+ :body => post_body,
1513
+ :auth_names => auth_names,
1514
+ :return_type => return_type
1515
+ )
1516
+
1517
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1518
+ if @api_client.config.debugging
1519
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_resolve_handle_url_to_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1520
+ end
1521
+ return data, status_code, headers
1522
+ end
1523
+
1524
+ # Search within a channel
1525
+ # @param channel_id [String]
1526
+ # @param query [String] Search keywords
1527
+ # @param [Hash] opts the optional parameters
1528
+ # @return [Object]
1529
+ def youtube_search_within_a_channel(channel_id, query, opts = {})
1530
+ data, _status_code, _headers = youtube_search_within_a_channel_with_http_info(channel_id, query, opts)
1531
+ data
1532
+ end
1533
+
1534
+ # Search within a channel
1535
+ # @param channel_id [String]
1536
+ # @param query [String] Search keywords
1537
+ # @param [Hash] opts the optional parameters
1538
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1539
+ def youtube_search_within_a_channel_with_http_info(channel_id, query, opts = {})
1540
+ if @api_client.config.debugging
1541
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_search_within_a_channel ...'
1542
+ end
1543
+ # verify the required parameter 'channel_id' is set
1544
+ if @api_client.config.client_side_validation && channel_id.nil?
1545
+ fail ArgumentError, "Missing the required parameter 'channel_id' when calling YouTubeApi.youtube_search_within_a_channel"
1546
+ end
1547
+ # verify the required parameter 'query' is set
1548
+ if @api_client.config.client_side_validation && query.nil?
1549
+ fail ArgumentError, "Missing the required parameter 'query' when calling YouTubeApi.youtube_search_within_a_channel"
1550
+ end
1551
+ # resource path
1552
+ local_var_path = '/v1/youtube/channels/{channel_id}/search'.sub('{' + 'channel_id' + '}', CGI.escape(channel_id.to_s))
1553
+
1554
+ # query parameters
1555
+ query_params = opts[:query_params] || {}
1556
+ query_params[:'query'] = query
1557
+
1558
+ # header parameters
1559
+ header_params = opts[:header_params] || {}
1560
+ # HTTP header 'Accept' (if needed)
1561
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1562
+
1563
+ # form parameters
1564
+ form_params = opts[:form_params] || {}
1565
+
1566
+ # http body (model)
1567
+ post_body = opts[:debug_body]
1568
+
1569
+ # return_type
1570
+ return_type = opts[:debug_return_type] || 'Object'
1571
+
1572
+ # auth_names
1573
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1574
+
1575
+ new_options = opts.merge(
1576
+ :operation => :"YouTubeApi.youtube_search_within_a_channel",
1577
+ :header_params => header_params,
1578
+ :query_params => query_params,
1579
+ :form_params => form_params,
1580
+ :body => post_body,
1581
+ :auth_names => auth_names,
1582
+ :return_type => return_type
1583
+ )
1584
+
1585
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1586
+ if @api_client.config.debugging
1587
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_search_within_a_channel\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1588
+ end
1589
+ return data, status_code, headers
1590
+ end
1591
+
1592
+ # Search YouTube
1593
+ # Search videos / channels / playlists with the full filter matrix.
1594
+ # @param query [String] Search keywords
1595
+ # @param [Hash] opts the optional parameters
1596
+ # @option opts [String] :type video|channel|playlist|movie|all
1597
+ # @option opts [String] :sort_by relevance|date|views|rating
1598
+ # @option opts [String] :upload_date hour|today|week|month|year
1599
+ # @option opts [String] :duration short|medium|long
1600
+ # @option opts [String] :features hd,4k,360,vr180,3d,hdr,cc,subtitles,live
1601
+ # @option opts [String] :gl Content region (US, GB, DE…)
1602
+ # @option opts [String] :hl UI language
1603
+ # @option opts [String] :continuation
1604
+ # @return [Object]
1605
+ def youtube_search_youtube(query, opts = {})
1606
+ data, _status_code, _headers = youtube_search_youtube_with_http_info(query, opts)
1607
+ data
1608
+ end
1609
+
1610
+ # Search YouTube
1611
+ # Search videos / channels / playlists with the full filter matrix.
1612
+ # @param query [String] Search keywords
1613
+ # @param [Hash] opts the optional parameters
1614
+ # @option opts [String] :type video|channel|playlist|movie|all
1615
+ # @option opts [String] :sort_by relevance|date|views|rating
1616
+ # @option opts [String] :upload_date hour|today|week|month|year
1617
+ # @option opts [String] :duration short|medium|long
1618
+ # @option opts [String] :features hd,4k,360,vr180,3d,hdr,cc,subtitles,live
1619
+ # @option opts [String] :gl Content region (US, GB, DE…)
1620
+ # @option opts [String] :hl UI language
1621
+ # @option opts [String] :continuation
1622
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1623
+ def youtube_search_youtube_with_http_info(query, opts = {})
1624
+ if @api_client.config.debugging
1625
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_search_youtube ...'
1626
+ end
1627
+ # verify the required parameter 'query' is set
1628
+ if @api_client.config.client_side_validation && query.nil?
1629
+ fail ArgumentError, "Missing the required parameter 'query' when calling YouTubeApi.youtube_search_youtube"
1630
+ end
1631
+ # resource path
1632
+ local_var_path = '/v1/youtube/search'
1633
+
1634
+ # query parameters
1635
+ query_params = opts[:query_params] || {}
1636
+ query_params[:'query'] = query
1637
+ query_params[:'type'] = opts[:'type'] if !opts[:'type'].nil?
1638
+ query_params[:'sort_by'] = opts[:'sort_by'] if !opts[:'sort_by'].nil?
1639
+ query_params[:'upload_date'] = opts[:'upload_date'] if !opts[:'upload_date'].nil?
1640
+ query_params[:'duration'] = opts[:'duration'] if !opts[:'duration'].nil?
1641
+ query_params[:'features'] = opts[:'features'] if !opts[:'features'].nil?
1642
+ query_params[:'gl'] = opts[:'gl'] if !opts[:'gl'].nil?
1643
+ query_params[:'hl'] = opts[:'hl'] if !opts[:'hl'].nil?
1644
+ query_params[:'continuation'] = opts[:'continuation'] if !opts[:'continuation'].nil?
1645
+
1646
+ # header parameters
1647
+ header_params = opts[:header_params] || {}
1648
+ # HTTP header 'Accept' (if needed)
1649
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1650
+
1651
+ # form parameters
1652
+ form_params = opts[:form_params] || {}
1653
+
1654
+ # http body (model)
1655
+ post_body = opts[:debug_body]
1656
+
1657
+ # return_type
1658
+ return_type = opts[:debug_return_type] || 'Object'
1659
+
1660
+ # auth_names
1661
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1662
+
1663
+ new_options = opts.merge(
1664
+ :operation => :"YouTubeApi.youtube_search_youtube",
1665
+ :header_params => header_params,
1666
+ :query_params => query_params,
1667
+ :form_params => form_params,
1668
+ :body => post_body,
1669
+ :auth_names => auth_names,
1670
+ :return_type => return_type
1671
+ )
1672
+
1673
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1674
+ if @api_client.config.debugging
1675
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_search_youtube\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1676
+ end
1677
+ return data, status_code, headers
1678
+ end
1679
+
1680
+ # Search YouTube Music
1681
+ # @param query [String] Search keywords
1682
+ # @param [Hash] opts the optional parameters
1683
+ # @return [Object]
1684
+ def youtube_search_youtube_music(query, opts = {})
1685
+ data, _status_code, _headers = youtube_search_youtube_music_with_http_info(query, opts)
1686
+ data
1687
+ end
1688
+
1689
+ # Search YouTube Music
1690
+ # @param query [String] Search keywords
1691
+ # @param [Hash] opts the optional parameters
1692
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1693
+ def youtube_search_youtube_music_with_http_info(query, opts = {})
1694
+ if @api_client.config.debugging
1695
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_search_youtube_music ...'
1696
+ end
1697
+ # verify the required parameter 'query' is set
1698
+ if @api_client.config.client_side_validation && query.nil?
1699
+ fail ArgumentError, "Missing the required parameter 'query' when calling YouTubeApi.youtube_search_youtube_music"
1700
+ end
1701
+ # resource path
1702
+ local_var_path = '/v1/youtube/music/search'
1703
+
1704
+ # query parameters
1705
+ query_params = opts[:query_params] || {}
1706
+ query_params[:'query'] = query
1707
+
1708
+ # header parameters
1709
+ header_params = opts[:header_params] || {}
1710
+ # HTTP header 'Accept' (if needed)
1711
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1712
+
1713
+ # form parameters
1714
+ form_params = opts[:form_params] || {}
1715
+
1716
+ # http body (model)
1717
+ post_body = opts[:debug_body]
1718
+
1719
+ # return_type
1720
+ return_type = opts[:debug_return_type] || 'Object'
1721
+
1722
+ # auth_names
1723
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1724
+
1725
+ new_options = opts.merge(
1726
+ :operation => :"YouTubeApi.youtube_search_youtube_music",
1727
+ :header_params => header_params,
1728
+ :query_params => query_params,
1729
+ :form_params => form_params,
1730
+ :body => post_body,
1731
+ :auth_names => auth_names,
1732
+ :return_type => return_type
1733
+ )
1734
+
1735
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1736
+ if @api_client.config.debugging
1737
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_search_youtube_music\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1738
+ end
1739
+ return data, status_code, headers
1740
+ end
1741
+
1742
+ # Shorts by sound
1743
+ # @param sound_id [String]
1744
+ # @param [Hash] opts the optional parameters
1745
+ # @return [Object]
1746
+ def youtube_shorts_by_sound(sound_id, opts = {})
1747
+ data, _status_code, _headers = youtube_shorts_by_sound_with_http_info(sound_id, opts)
1748
+ data
1749
+ end
1750
+
1751
+ # Shorts by sound
1752
+ # @param sound_id [String]
1753
+ # @param [Hash] opts the optional parameters
1754
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1755
+ def youtube_shorts_by_sound_with_http_info(sound_id, opts = {})
1756
+ if @api_client.config.debugging
1757
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_shorts_by_sound ...'
1758
+ end
1759
+ # verify the required parameter 'sound_id' is set
1760
+ if @api_client.config.client_side_validation && sound_id.nil?
1761
+ fail ArgumentError, "Missing the required parameter 'sound_id' when calling YouTubeApi.youtube_shorts_by_sound"
1762
+ end
1763
+ # resource path
1764
+ local_var_path = '/v1/youtube/shorts/by_sound/{sound_id}'.sub('{' + 'sound_id' + '}', CGI.escape(sound_id.to_s))
1765
+
1766
+ # query parameters
1767
+ query_params = opts[:query_params] || {}
1768
+
1769
+ # header parameters
1770
+ header_params = opts[:header_params] || {}
1771
+ # HTTP header 'Accept' (if needed)
1772
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1773
+
1774
+ # form parameters
1775
+ form_params = opts[:form_params] || {}
1776
+
1777
+ # http body (model)
1778
+ post_body = opts[:debug_body]
1779
+
1780
+ # return_type
1781
+ return_type = opts[:debug_return_type] || 'Object'
1782
+
1783
+ # auth_names
1784
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1785
+
1786
+ new_options = opts.merge(
1787
+ :operation => :"YouTubeApi.youtube_shorts_by_sound",
1788
+ :header_params => header_params,
1789
+ :query_params => query_params,
1790
+ :form_params => form_params,
1791
+ :body => post_body,
1792
+ :auth_names => auth_names,
1793
+ :return_type => return_type
1794
+ )
1795
+
1796
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1797
+ if @api_client.config.debugging
1798
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_shorts_by_sound\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1799
+ end
1800
+ return data, status_code, headers
1801
+ end
1802
+
1803
+ # Stream formats
1804
+ # Stream/format metadata (best-effort; media URLs may be PO-token gated).
1805
+ # @param video_id [String]
1806
+ # @param [Hash] opts the optional parameters
1807
+ # @option opts [String] :client IOS|ANDROID|WEB (default to 'IOS')
1808
+ # @return [Object]
1809
+ def youtube_stream_formats(video_id, opts = {})
1810
+ data, _status_code, _headers = youtube_stream_formats_with_http_info(video_id, opts)
1811
+ data
1812
+ end
1813
+
1814
+ # Stream formats
1815
+ # Stream/format metadata (best-effort; media URLs may be PO-token gated).
1816
+ # @param video_id [String]
1817
+ # @param [Hash] opts the optional parameters
1818
+ # @option opts [String] :client IOS|ANDROID|WEB (default to 'IOS')
1819
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1820
+ def youtube_stream_formats_with_http_info(video_id, opts = {})
1821
+ if @api_client.config.debugging
1822
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_stream_formats ...'
1823
+ end
1824
+ # verify the required parameter 'video_id' is set
1825
+ if @api_client.config.client_side_validation && video_id.nil?
1826
+ fail ArgumentError, "Missing the required parameter 'video_id' when calling YouTubeApi.youtube_stream_formats"
1827
+ end
1828
+ # resource path
1829
+ local_var_path = '/v1/youtube/videos/{video_id}/streams'.sub('{' + 'video_id' + '}', CGI.escape(video_id.to_s))
1830
+
1831
+ # query parameters
1832
+ query_params = opts[:query_params] || {}
1833
+ query_params[:'client'] = opts[:'client'] if !opts[:'client'].nil?
1834
+
1835
+ # header parameters
1836
+ header_params = opts[:header_params] || {}
1837
+ # HTTP header 'Accept' (if needed)
1838
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1839
+
1840
+ # form parameters
1841
+ form_params = opts[:form_params] || {}
1842
+
1843
+ # http body (model)
1844
+ post_body = opts[:debug_body]
1845
+
1846
+ # return_type
1847
+ return_type = opts[:debug_return_type] || 'Object'
1848
+
1849
+ # auth_names
1850
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1851
+
1852
+ new_options = opts.merge(
1853
+ :operation => :"YouTubeApi.youtube_stream_formats",
1854
+ :header_params => header_params,
1855
+ :query_params => query_params,
1856
+ :form_params => form_params,
1857
+ :body => post_body,
1858
+ :auth_names => auth_names,
1859
+ :return_type => return_type
1860
+ )
1861
+
1862
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1863
+ if @api_client.config.debugging
1864
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_stream_formats\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1865
+ end
1866
+ return data, status_code, headers
1867
+ end
1868
+
1869
+ # Subscriber count (fast)
1870
+ # @param channel_id [String]
1871
+ # @param [Hash] opts the optional parameters
1872
+ # @return [Object]
1873
+ def youtube_subscriber_count_fast(channel_id, opts = {})
1874
+ data, _status_code, _headers = youtube_subscriber_count_fast_with_http_info(channel_id, opts)
1875
+ data
1876
+ end
1877
+
1878
+ # Subscriber count (fast)
1879
+ # @param channel_id [String]
1880
+ # @param [Hash] opts the optional parameters
1881
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1882
+ def youtube_subscriber_count_fast_with_http_info(channel_id, opts = {})
1883
+ if @api_client.config.debugging
1884
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_subscriber_count_fast ...'
1885
+ end
1886
+ # verify the required parameter 'channel_id' is set
1887
+ if @api_client.config.client_side_validation && channel_id.nil?
1888
+ fail ArgumentError, "Missing the required parameter 'channel_id' when calling YouTubeApi.youtube_subscriber_count_fast"
1889
+ end
1890
+ # resource path
1891
+ local_var_path = '/v1/youtube/channels/{channel_id}/subscriber_count'.sub('{' + 'channel_id' + '}', CGI.escape(channel_id.to_s))
1892
+
1893
+ # query parameters
1894
+ query_params = opts[:query_params] || {}
1895
+
1896
+ # header parameters
1897
+ header_params = opts[:header_params] || {}
1898
+ # HTTP header 'Accept' (if needed)
1899
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1900
+
1901
+ # form parameters
1902
+ form_params = opts[:form_params] || {}
1903
+
1904
+ # http body (model)
1905
+ post_body = opts[:debug_body]
1906
+
1907
+ # return_type
1908
+ return_type = opts[:debug_return_type] || 'Object'
1909
+
1910
+ # auth_names
1911
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1912
+
1913
+ new_options = opts.merge(
1914
+ :operation => :"YouTubeApi.youtube_subscriber_count_fast",
1915
+ :header_params => header_params,
1916
+ :query_params => query_params,
1917
+ :form_params => form_params,
1918
+ :body => post_body,
1919
+ :auth_names => auth_names,
1920
+ :return_type => return_type
1921
+ )
1922
+
1923
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1924
+ if @api_client.config.debugging
1925
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_subscriber_count_fast\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1926
+ end
1927
+ return data, status_code, headers
1928
+ end
1929
+
1930
+ # Supported markets
1931
+ # @param [Hash] opts the optional parameters
1932
+ # @return [Object]
1933
+ def youtube_supported_markets(opts = {})
1934
+ data, _status_code, _headers = youtube_supported_markets_with_http_info(opts)
1935
+ data
1936
+ end
1937
+
1938
+ # Supported markets
1939
+ # @param [Hash] opts the optional parameters
1940
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1941
+ def youtube_supported_markets_with_http_info(opts = {})
1942
+ if @api_client.config.debugging
1943
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_supported_markets ...'
1944
+ end
1945
+ # resource path
1946
+ local_var_path = '/v1/youtube/markets'
1947
+
1948
+ # query parameters
1949
+ query_params = opts[:query_params] || {}
1950
+
1951
+ # header parameters
1952
+ header_params = opts[:header_params] || {}
1953
+ # HTTP header 'Accept' (if needed)
1954
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1955
+
1956
+ # form parameters
1957
+ form_params = opts[:form_params] || {}
1958
+
1959
+ # http body (model)
1960
+ post_body = opts[:debug_body]
1961
+
1962
+ # return_type
1963
+ return_type = opts[:debug_return_type] || 'Object'
1964
+
1965
+ # auth_names
1966
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
1967
+
1968
+ new_options = opts.merge(
1969
+ :operation => :"YouTubeApi.youtube_supported_markets",
1970
+ :header_params => header_params,
1971
+ :query_params => query_params,
1972
+ :form_params => form_params,
1973
+ :body => post_body,
1974
+ :auth_names => auth_names,
1975
+ :return_type => return_type
1976
+ )
1977
+
1978
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1979
+ if @api_client.config.debugging
1980
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_supported_markets\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1981
+ end
1982
+ return data, status_code, headers
1983
+ end
1984
+
1985
+ # Trending shorts
1986
+ # @param [Hash] opts the optional parameters
1987
+ # @return [Object]
1988
+ def youtube_trending_shorts(opts = {})
1989
+ data, _status_code, _headers = youtube_trending_shorts_with_http_info(opts)
1990
+ data
1991
+ end
1992
+
1993
+ # Trending shorts
1994
+ # @param [Hash] opts the optional parameters
1995
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1996
+ def youtube_trending_shorts_with_http_info(opts = {})
1997
+ if @api_client.config.debugging
1998
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_trending_shorts ...'
1999
+ end
2000
+ # resource path
2001
+ local_var_path = '/v1/youtube/trending/shorts'
2002
+
2003
+ # query parameters
2004
+ query_params = opts[:query_params] || {}
2005
+
2006
+ # header parameters
2007
+ header_params = opts[:header_params] || {}
2008
+ # HTTP header 'Accept' (if needed)
2009
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
2010
+
2011
+ # form parameters
2012
+ form_params = opts[:form_params] || {}
2013
+
2014
+ # http body (model)
2015
+ post_body = opts[:debug_body]
2016
+
2017
+ # return_type
2018
+ return_type = opts[:debug_return_type] || 'Object'
2019
+
2020
+ # auth_names
2021
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
2022
+
2023
+ new_options = opts.merge(
2024
+ :operation => :"YouTubeApi.youtube_trending_shorts",
2025
+ :header_params => header_params,
2026
+ :query_params => query_params,
2027
+ :form_params => form_params,
2028
+ :body => post_body,
2029
+ :auth_names => auth_names,
2030
+ :return_type => return_type
2031
+ )
2032
+
2033
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
2034
+ if @api_client.config.debugging
2035
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_trending_shorts\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2036
+ end
2037
+ return data, status_code, headers
2038
+ end
2039
+
2040
+ # Trending videos
2041
+ # @param [Hash] opts the optional parameters
2042
+ # @option opts [String] :gl
2043
+ # @option opts [String] :type now|music|gaming|movies (default to 'now')
2044
+ # @return [Object]
2045
+ def youtube_trending_videos(opts = {})
2046
+ data, _status_code, _headers = youtube_trending_videos_with_http_info(opts)
2047
+ data
2048
+ end
2049
+
2050
+ # Trending videos
2051
+ # @param [Hash] opts the optional parameters
2052
+ # @option opts [String] :gl
2053
+ # @option opts [String] :type now|music|gaming|movies (default to 'now')
2054
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
2055
+ def youtube_trending_videos_with_http_info(opts = {})
2056
+ if @api_client.config.debugging
2057
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_trending_videos ...'
2058
+ end
2059
+ # resource path
2060
+ local_var_path = '/v1/youtube/trending'
2061
+
2062
+ # query parameters
2063
+ query_params = opts[:query_params] || {}
2064
+ query_params[:'gl'] = opts[:'gl'] if !opts[:'gl'].nil?
2065
+ query_params[:'type'] = opts[:'type'] if !opts[:'type'].nil?
2066
+
2067
+ # header parameters
2068
+ header_params = opts[:header_params] || {}
2069
+ # HTTP header 'Accept' (if needed)
2070
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
2071
+
2072
+ # form parameters
2073
+ form_params = opts[:form_params] || {}
2074
+
2075
+ # http body (model)
2076
+ post_body = opts[:debug_body]
2077
+
2078
+ # return_type
2079
+ return_type = opts[:debug_return_type] || 'Object'
2080
+
2081
+ # auth_names
2082
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
2083
+
2084
+ new_options = opts.merge(
2085
+ :operation => :"YouTubeApi.youtube_trending_videos",
2086
+ :header_params => header_params,
2087
+ :query_params => query_params,
2088
+ :form_params => form_params,
2089
+ :body => post_body,
2090
+ :auth_names => auth_names,
2091
+ :return_type => return_type
2092
+ )
2093
+
2094
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
2095
+ if @api_client.config.debugging
2096
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_trending_videos\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2097
+ end
2098
+ return data, status_code, headers
2099
+ end
2100
+
2101
+ # UI languages
2102
+ # @param [Hash] opts the optional parameters
2103
+ # @return [Object]
2104
+ def youtube_ui_languages(opts = {})
2105
+ data, _status_code, _headers = youtube_ui_languages_with_http_info(opts)
2106
+ data
2107
+ end
2108
+
2109
+ # UI languages
2110
+ # @param [Hash] opts the optional parameters
2111
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
2112
+ def youtube_ui_languages_with_http_info(opts = {})
2113
+ if @api_client.config.debugging
2114
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_ui_languages ...'
2115
+ end
2116
+ # resource path
2117
+ local_var_path = '/v1/youtube/languages'
2118
+
2119
+ # query parameters
2120
+ query_params = opts[:query_params] || {}
2121
+
2122
+ # header parameters
2123
+ header_params = opts[:header_params] || {}
2124
+ # HTTP header 'Accept' (if needed)
2125
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
2126
+
2127
+ # form parameters
2128
+ form_params = opts[:form_params] || {}
2129
+
2130
+ # http body (model)
2131
+ post_body = opts[:debug_body]
2132
+
2133
+ # return_type
2134
+ return_type = opts[:debug_return_type] || 'Object'
2135
+
2136
+ # auth_names
2137
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
2138
+
2139
+ new_options = opts.merge(
2140
+ :operation => :"YouTubeApi.youtube_ui_languages",
2141
+ :header_params => header_params,
2142
+ :query_params => query_params,
2143
+ :form_params => form_params,
2144
+ :body => post_body,
2145
+ :auth_names => auth_names,
2146
+ :return_type => return_type
2147
+ )
2148
+
2149
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
2150
+ if @api_client.config.debugging
2151
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_ui_languages\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2152
+ end
2153
+ return data, status_code, headers
2154
+ end
2155
+
2156
+ # Video categories
2157
+ # @param [Hash] opts the optional parameters
2158
+ # @option opts [String] :gl (default to 'US')
2159
+ # @return [Object]
2160
+ def youtube_video_categories(opts = {})
2161
+ data, _status_code, _headers = youtube_video_categories_with_http_info(opts)
2162
+ data
2163
+ end
2164
+
2165
+ # Video categories
2166
+ # @param [Hash] opts the optional parameters
2167
+ # @option opts [String] :gl (default to 'US')
2168
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
2169
+ def youtube_video_categories_with_http_info(opts = {})
2170
+ if @api_client.config.debugging
2171
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_video_categories ...'
2172
+ end
2173
+ # resource path
2174
+ local_var_path = '/v1/youtube/categories'
2175
+
2176
+ # query parameters
2177
+ query_params = opts[:query_params] || {}
2178
+ query_params[:'gl'] = opts[:'gl'] if !opts[:'gl'].nil?
2179
+
2180
+ # header parameters
2181
+ header_params = opts[:header_params] || {}
2182
+ # HTTP header 'Accept' (if needed)
2183
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
2184
+
2185
+ # form parameters
2186
+ form_params = opts[:form_params] || {}
2187
+
2188
+ # http body (model)
2189
+ post_body = opts[:debug_body]
2190
+
2191
+ # return_type
2192
+ return_type = opts[:debug_return_type] || 'Object'
2193
+
2194
+ # auth_names
2195
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
2196
+
2197
+ new_options = opts.merge(
2198
+ :operation => :"YouTubeApi.youtube_video_categories",
2199
+ :header_params => header_params,
2200
+ :query_params => query_params,
2201
+ :form_params => form_params,
2202
+ :body => post_body,
2203
+ :auth_names => auth_names,
2204
+ :return_type => return_type
2205
+ )
2206
+
2207
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
2208
+ if @api_client.config.debugging
2209
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_video_categories\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2210
+ end
2211
+ return data, status_code, headers
2212
+ end
2213
+
2214
+ # Video comments
2215
+ # @param video_id [String]
2216
+ # @param [Hash] opts the optional parameters
2217
+ # @option opts [String] :sort_by top|newest (default to 'top')
2218
+ # @option opts [String] :continuation
2219
+ # @return [Object]
2220
+ def youtube_video_comments(video_id, opts = {})
2221
+ data, _status_code, _headers = youtube_video_comments_with_http_info(video_id, opts)
2222
+ data
2223
+ end
2224
+
2225
+ # Video comments
2226
+ # @param video_id [String]
2227
+ # @param [Hash] opts the optional parameters
2228
+ # @option opts [String] :sort_by top|newest (default to 'top')
2229
+ # @option opts [String] :continuation
2230
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
2231
+ def youtube_video_comments_with_http_info(video_id, opts = {})
2232
+ if @api_client.config.debugging
2233
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_video_comments ...'
2234
+ end
2235
+ # verify the required parameter 'video_id' is set
2236
+ if @api_client.config.client_side_validation && video_id.nil?
2237
+ fail ArgumentError, "Missing the required parameter 'video_id' when calling YouTubeApi.youtube_video_comments"
2238
+ end
2239
+ # resource path
2240
+ local_var_path = '/v1/youtube/videos/{video_id}/comments'.sub('{' + 'video_id' + '}', CGI.escape(video_id.to_s))
2241
+
2242
+ # query parameters
2243
+ query_params = opts[:query_params] || {}
2244
+ query_params[:'sort_by'] = opts[:'sort_by'] if !opts[:'sort_by'].nil?
2245
+ query_params[:'continuation'] = opts[:'continuation'] if !opts[:'continuation'].nil?
2246
+
2247
+ # header parameters
2248
+ header_params = opts[:header_params] || {}
2249
+ # HTTP header 'Accept' (if needed)
2250
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
2251
+
2252
+ # form parameters
2253
+ form_params = opts[:form_params] || {}
2254
+
2255
+ # http body (model)
2256
+ post_body = opts[:debug_body]
2257
+
2258
+ # return_type
2259
+ return_type = opts[:debug_return_type] || 'Object'
2260
+
2261
+ # auth_names
2262
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
2263
+
2264
+ new_options = opts.merge(
2265
+ :operation => :"YouTubeApi.youtube_video_comments",
2266
+ :header_params => header_params,
2267
+ :query_params => query_params,
2268
+ :form_params => form_params,
2269
+ :body => post_body,
2270
+ :auth_names => auth_names,
2271
+ :return_type => return_type
2272
+ )
2273
+
2274
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
2275
+ if @api_client.config.debugging
2276
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_video_comments\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2277
+ end
2278
+ return data, status_code, headers
2279
+ end
2280
+
2281
+ # Video transcript
2282
+ # @param video_id [String]
2283
+ # @param [Hash] opts the optional parameters
2284
+ # @option opts [String] :language BCP-47 language code
2285
+ # @return [Object]
2286
+ def youtube_video_transcript(video_id, opts = {})
2287
+ data, _status_code, _headers = youtube_video_transcript_with_http_info(video_id, opts)
2288
+ data
2289
+ end
2290
+
2291
+ # Video transcript
2292
+ # @param video_id [String]
2293
+ # @param [Hash] opts the optional parameters
2294
+ # @option opts [String] :language BCP-47 language code
2295
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
2296
+ def youtube_video_transcript_with_http_info(video_id, opts = {})
2297
+ if @api_client.config.debugging
2298
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_video_transcript ...'
2299
+ end
2300
+ # verify the required parameter 'video_id' is set
2301
+ if @api_client.config.client_side_validation && video_id.nil?
2302
+ fail ArgumentError, "Missing the required parameter 'video_id' when calling YouTubeApi.youtube_video_transcript"
2303
+ end
2304
+ # resource path
2305
+ local_var_path = '/v1/youtube/videos/{video_id}/transcript'.sub('{' + 'video_id' + '}', CGI.escape(video_id.to_s))
2306
+
2307
+ # query parameters
2308
+ query_params = opts[:query_params] || {}
2309
+ query_params[:'language'] = opts[:'language'] if !opts[:'language'].nil?
2310
+
2311
+ # header parameters
2312
+ header_params = opts[:header_params] || {}
2313
+ # HTTP header 'Accept' (if needed)
2314
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
2315
+
2316
+ # form parameters
2317
+ form_params = opts[:form_params] || {}
2318
+
2319
+ # http body (model)
2320
+ post_body = opts[:debug_body]
2321
+
2322
+ # return_type
2323
+ return_type = opts[:debug_return_type] || 'Object'
2324
+
2325
+ # auth_names
2326
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
2327
+
2328
+ new_options = opts.merge(
2329
+ :operation => :"YouTubeApi.youtube_video_transcript",
2330
+ :header_params => header_params,
2331
+ :query_params => query_params,
2332
+ :form_params => form_params,
2333
+ :body => post_body,
2334
+ :auth_names => auth_names,
2335
+ :return_type => return_type
2336
+ )
2337
+
2338
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
2339
+ if @api_client.config.debugging
2340
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_video_transcript\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2341
+ end
2342
+ return data, status_code, headers
2343
+ end
2344
+
2345
+ # Videos under a hashtag
2346
+ # @param tag [String]
2347
+ # @param [Hash] opts the optional parameters
2348
+ # @return [Object]
2349
+ def youtube_videos_under_a_hashtag(tag, opts = {})
2350
+ data, _status_code, _headers = youtube_videos_under_a_hashtag_with_http_info(tag, opts)
2351
+ data
2352
+ end
2353
+
2354
+ # Videos under a hashtag
2355
+ # @param tag [String]
2356
+ # @param [Hash] opts the optional parameters
2357
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
2358
+ def youtube_videos_under_a_hashtag_with_http_info(tag, opts = {})
2359
+ if @api_client.config.debugging
2360
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_videos_under_a_hashtag ...'
2361
+ end
2362
+ # verify the required parameter 'tag' is set
2363
+ if @api_client.config.client_side_validation && tag.nil?
2364
+ fail ArgumentError, "Missing the required parameter 'tag' when calling YouTubeApi.youtube_videos_under_a_hashtag"
2365
+ end
2366
+ # resource path
2367
+ local_var_path = '/v1/youtube/hashtags/{tag}'.sub('{' + 'tag' + '}', CGI.escape(tag.to_s))
2368
+
2369
+ # query parameters
2370
+ query_params = opts[:query_params] || {}
2371
+
2372
+ # header parameters
2373
+ header_params = opts[:header_params] || {}
2374
+ # HTTP header 'Accept' (if needed)
2375
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
2376
+
2377
+ # form parameters
2378
+ form_params = opts[:form_params] || {}
2379
+
2380
+ # http body (model)
2381
+ post_body = opts[:debug_body]
2382
+
2383
+ # return_type
2384
+ return_type = opts[:debug_return_type] || 'Object'
2385
+
2386
+ # auth_names
2387
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
2388
+
2389
+ new_options = opts.merge(
2390
+ :operation => :"YouTubeApi.youtube_videos_under_a_hashtag",
2391
+ :header_params => header_params,
2392
+ :query_params => query_params,
2393
+ :form_params => form_params,
2394
+ :body => post_body,
2395
+ :auth_names => auth_names,
2396
+ :return_type => return_type
2397
+ )
2398
+
2399
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
2400
+ if @api_client.config.debugging
2401
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_videos_under_a_hashtag\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2402
+ end
2403
+ return data, status_code, headers
2404
+ end
2405
+
2406
+ # YouTube scraper health check
2407
+ # Check health of the YouTube scraper service (accepts HEAD for UptimeRobot).
2408
+ # @param [Hash] opts the optional parameters
2409
+ # @return [Object]
2410
+ def youtube_youtube_scraper_health_check(opts = {})
2411
+ data, _status_code, _headers = youtube_youtube_scraper_health_check_with_http_info(opts)
2412
+ data
2413
+ end
2414
+
2415
+ # YouTube scraper health check
2416
+ # Check health of the YouTube scraper service (accepts HEAD for UptimeRobot).
2417
+ # @param [Hash] opts the optional parameters
2418
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
2419
+ def youtube_youtube_scraper_health_check_with_http_info(opts = {})
2420
+ if @api_client.config.debugging
2421
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_youtube_scraper_health_check ...'
2422
+ end
2423
+ # resource path
2424
+ local_var_path = '/v1/youtube/health'
2425
+
2426
+ # query parameters
2427
+ query_params = opts[:query_params] || {}
2428
+
2429
+ # header parameters
2430
+ header_params = opts[:header_params] || {}
2431
+ # HTTP header 'Accept' (if needed)
2432
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
2433
+
2434
+ # form parameters
2435
+ form_params = opts[:form_params] || {}
2436
+
2437
+ # http body (model)
2438
+ post_body = opts[:debug_body]
2439
+
2440
+ # return_type
2441
+ return_type = opts[:debug_return_type] || 'Object'
2442
+
2443
+ # auth_names
2444
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
2445
+
2446
+ new_options = opts.merge(
2447
+ :operation => :"YouTubeApi.youtube_youtube_scraper_health_check",
2448
+ :header_params => header_params,
2449
+ :query_params => query_params,
2450
+ :form_params => form_params,
2451
+ :body => post_body,
2452
+ :auth_names => auth_names,
2453
+ :return_type => return_type
2454
+ )
2455
+
2456
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
2457
+ if @api_client.config.debugging
2458
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_youtube_scraper_health_check\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2459
+ end
2460
+ return data, status_code, headers
2461
+ end
2462
+
2463
+ # YouTube scraper health check
2464
+ # Check health of the YouTube scraper service (accepts HEAD for UptimeRobot).
2465
+ # @param [Hash] opts the optional parameters
2466
+ # @return [Object]
2467
+ def youtube_youtube_scraper_health_check_head(opts = {})
2468
+ data, _status_code, _headers = youtube_youtube_scraper_health_check_head_with_http_info(opts)
2469
+ data
2470
+ end
2471
+
2472
+ # YouTube scraper health check
2473
+ # Check health of the YouTube scraper service (accepts HEAD for UptimeRobot).
2474
+ # @param [Hash] opts the optional parameters
2475
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
2476
+ def youtube_youtube_scraper_health_check_head_with_http_info(opts = {})
2477
+ if @api_client.config.debugging
2478
+ @api_client.config.logger.debug 'Calling API: YouTubeApi.youtube_youtube_scraper_health_check_head ...'
2479
+ end
2480
+ # resource path
2481
+ local_var_path = '/v1/youtube/health'
2482
+
2483
+ # query parameters
2484
+ query_params = opts[:query_params] || {}
2485
+
2486
+ # header parameters
2487
+ header_params = opts[:header_params] || {}
2488
+ # HTTP header 'Accept' (if needed)
2489
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
2490
+
2491
+ # form parameters
2492
+ form_params = opts[:form_params] || {}
2493
+
2494
+ # http body (model)
2495
+ post_body = opts[:debug_body]
2496
+
2497
+ # return_type
2498
+ return_type = opts[:debug_return_type] || 'Object'
2499
+
2500
+ # auth_names
2501
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth']
2502
+
2503
+ new_options = opts.merge(
2504
+ :operation => :"YouTubeApi.youtube_youtube_scraper_health_check_head",
2505
+ :header_params => header_params,
2506
+ :query_params => query_params,
2507
+ :form_params => form_params,
2508
+ :body => post_body,
2509
+ :auth_names => auth_names,
2510
+ :return_type => return_type
2511
+ )
2512
+
2513
+ data, status_code, headers = @api_client.call_api(:HEAD, local_var_path, new_options)
2514
+ if @api_client.config.debugging
2515
+ @api_client.config.logger.debug "API called: YouTubeApi#youtube_youtube_scraper_health_check_head\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2516
+ end
2517
+ return data, status_code, headers
2518
+ end
2519
+ end
2520
+ end