Class: MusicubeApiClientRuby::RecordingApi
- Inherits:
-
Object
- Object
- MusicubeApiClientRuby::RecordingApi
- Defined in:
- lib/musicube_api_client_ruby/api/recording_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#initialize(api_client = ApiClient.default) ⇒ RecordingApi
constructor
A new instance of RecordingApi.
-
#recordings_by_ids_with_musical_features(ids, opts = {}) ⇒ Array<RecordingMinimalWithMusicalFeaturesDTO>
AI generated moods, musical features and more for recordings.
-
#recordings_by_ids_with_musical_features_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingMinimalWithMusicalFeaturesDTO>, Integer, Hash)>
AI generated moods, musical features and more for recordings.
-
#recordings_by_ids_with_similarities(ids, opts = {}) ⇒ Array<RecordingForSimilaritySearchDTO>
Similar recordings for a list of recordings.
-
#recordings_by_ids_with_similarities_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingForSimilaritySearchDTO>, Integer, Hash)>
Similar recordings for a list of recordings.
-
#recordings_by_ids_with_taggrams(ids, opts = {}) ⇒ Array<RecordingMinimalWithTaggramsDTO>
Timeseries of AI generated moods, musical features and more for a list of recordings.
-
#recordings_by_ids_with_taggrams_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingMinimalWithTaggramsDTO>, Integer, Hash)>
Timeseries of AI generated moods, musical features and more for a list of recordings.
-
#recordings_by_ids_with_tagstrengths(ids, opts = {}) ⇒ Array<RecordingMinimalWithTagstrengthsDTO>
Strengths as numerical representations for AI generated moods, musical features and more for recordings.
-
#recordings_by_ids_with_tagstrengths_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingMinimalWithTagstrengthsDTO>, Integer, Hash)>
Strengths as numerical representations for AI generated moods, musical features and more for recordings.
-
#recordings_large_by_ids(ids, opts = {}) ⇒ Array<RecordingLargeDTO>
Recordings by IDs with a large response.
-
#recordings_large_by_ids_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingLargeDTO>, Integer, Hash)>
Recordings by IDs with a large response.
-
#recordings_medium_by_ids(ids, opts = {}) ⇒ Array<RecordingMediumDTO>
Recordings by IDs with a medium sized response.
-
#recordings_medium_by_ids_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingMediumDTO>, Integer, Hash)>
Recordings by IDs with a medium sized response.
-
#recordings_small_by_ids(ids, opts = {}) ⇒ Array<RecordingSmallDTO>
Recordings by IDs with a small response.
-
#recordings_small_by_ids_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingSmallDTO>, Integer, Hash)>
Recordings by IDs with a small response.
-
#search_recordings(opts = {}) ⇒ RecordingListDTO
Recordings by contributors, moods, musical features and more.
-
#search_recordings_granular(search_recording_granular_dto, opts = {}) ⇒ RecordingListDTO
Recordings by granular search options.
-
#search_recordings_granular_abstraction(search_recording_granular_abstraction_dto, opts = {}) ⇒ RecordingListDTO
Recordings by abstracted wordings and granular search options.
-
#search_recordings_granular_abstraction_with_http_info(search_recording_granular_abstraction_dto, opts = {}) ⇒ Array<(RecordingListDTO, Integer, Hash)>
Recordings by abstracted wordings and granular search options.
-
#search_recordings_granular_with_http_info(search_recording_granular_dto, opts = {}) ⇒ Array<(RecordingListDTO, Integer, Hash)>
Recordings by granular search options.
-
#search_recordings_with_http_info(opts = {}) ⇒ Array<(RecordingListDTO, Integer, Hash)>
Recordings by contributors, moods, musical features and more.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ RecordingApi
Returns a new instance of RecordingApi.
19 20 21 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 19 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
17 18 19 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 17 def api_client @api_client end |
Instance Method Details
#recordings_by_ids_with_musical_features(ids, opts = {}) ⇒ Array<RecordingMinimalWithMusicalFeaturesDTO>
AI generated moods, musical features and more for recordings.
26 27 28 29 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 26 def recordings_by_ids_with_musical_features(ids, opts = {}) data, _status_code, _headers = recordings_by_ids_with_musical_features_with_http_info(ids, opts) data end |
#recordings_by_ids_with_musical_features_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingMinimalWithMusicalFeaturesDTO>, Integer, Hash)>
AI generated moods, musical features and more for recordings.
35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 35 def recordings_by_ids_with_musical_features_with_http_info(ids, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: RecordingApi.recordings_by_ids_with_musical_features ...' end # verify the required parameter 'ids' is set if @api_client.config.client_side_validation && ids.nil? fail ArgumentError, "Missing the required parameter 'ids' when calling RecordingApi.recordings_by_ids_with_musical_features" end # resource path local_var_path = '/api/v1/public/recording/{ids}/musicalFeatures'.sub('{' + 'ids' + '}', CGI.escape(ids.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'Array<RecordingMinimalWithMusicalFeaturesDTO>' # auth_names auth_names = opts[:debug_auth_names] || ['bearer-jwt'] = opts.merge( :operation => :"RecordingApi.recordings_by_ids_with_musical_features", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#recordings_by_ids_with_musical_features\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#recordings_by_ids_with_similarities(ids, opts = {}) ⇒ Array<RecordingForSimilaritySearchDTO>
Similar recordings for a list of recordings.
87 88 89 90 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 87 def recordings_by_ids_with_similarities(ids, opts = {}) data, _status_code, _headers = recordings_by_ids_with_similarities_with_http_info(ids, opts) data end |
#recordings_by_ids_with_similarities_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingForSimilaritySearchDTO>, Integer, Hash)>
Similar recordings for a list of recordings.
96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 96 def recordings_by_ids_with_similarities_with_http_info(ids, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: RecordingApi.recordings_by_ids_with_similarities ...' end # verify the required parameter 'ids' is set if @api_client.config.client_side_validation && ids.nil? fail ArgumentError, "Missing the required parameter 'ids' when calling RecordingApi.recordings_by_ids_with_similarities" end # resource path local_var_path = '/api/v1/public/recording/{ids}/similarities'.sub('{' + 'ids' + '}', CGI.escape(ids.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'Array<RecordingForSimilaritySearchDTO>' # auth_names auth_names = opts[:debug_auth_names] || ['bearer-jwt'] = opts.merge( :operation => :"RecordingApi.recordings_by_ids_with_similarities", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#recordings_by_ids_with_similarities\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#recordings_by_ids_with_taggrams(ids, opts = {}) ⇒ Array<RecordingMinimalWithTaggramsDTO>
Timeseries of AI generated moods, musical features and more for a list of recordings.
153 154 155 156 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 153 def recordings_by_ids_with_taggrams(ids, opts = {}) data, _status_code, _headers = recordings_by_ids_with_taggrams_with_http_info(ids, opts) data end |
#recordings_by_ids_with_taggrams_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingMinimalWithTaggramsDTO>, Integer, Hash)>
Timeseries of AI generated moods, musical features and more for a list of recordings.
167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 167 def recordings_by_ids_with_taggrams_with_http_info(ids, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: RecordingApi.recordings_by_ids_with_taggrams ...' end # verify the required parameter 'ids' is set if @api_client.config.client_side_validation && ids.nil? fail ArgumentError, "Missing the required parameter 'ids' when calling RecordingApi.recordings_by_ids_with_taggrams" end allowable_values = ["instrument", "vocals", "energy", "soundGeneration", "rhythm", "songRating", "performanceRating", "productionRating", "moodCluster", "tonality", "arousal", "valence", "pleasantness", "engagement", "timbre", "roughness", "harmony", "texture", "groovyness", "space", "audienceAge", "audienceRegion", "audienceGender", "originRegion", "originDecade", "languageOfPerformance", "level1Genre", "level2Genre"] if @api_client.config.client_side_validation && opts[:'category_name'] && !allowable_values.include?(opts[:'category_name']) fail ArgumentError, "invalid value for \"category_name\", must be one of #{allowable_values}" end # resource path local_var_path = '/api/v1/public/recording/{ids}/taggrams'.sub('{' + 'ids' + '}', CGI.escape(ids.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'categoryName'] = opts[:'category_name'] if !opts[:'category_name'].nil? query_params[:'tagName'] = opts[:'tag_name'] if !opts[:'tag_name'].nil? query_params[:'genreName'] = opts[:'genre_name'] if !opts[:'genre_name'].nil? query_params[:'fromTimestamp'] = opts[:'from_timestamp'] if !opts[:'from_timestamp'].nil? query_params[:'fillWithZero'] = opts[:'fill_with_zero'] if !opts[:'fill_with_zero'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'Array<RecordingMinimalWithTaggramsDTO>' # auth_names auth_names = opts[:debug_auth_names] || ['bearer-jwt'] = opts.merge( :operation => :"RecordingApi.recordings_by_ids_with_taggrams", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#recordings_by_ids_with_taggrams\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#recordings_by_ids_with_tagstrengths(ids, opts = {}) ⇒ Array<RecordingMinimalWithTagstrengthsDTO>
Strengths as numerical representations for AI generated moods, musical features and more for recordings.
231 232 233 234 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 231 def (ids, opts = {}) data, _status_code, _headers = (ids, opts) data end |
#recordings_by_ids_with_tagstrengths_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingMinimalWithTagstrengthsDTO>, Integer, Hash)>
Strengths as numerical representations for AI generated moods, musical features and more for recordings.
243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 243 def (ids, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: RecordingApi.recordings_by_ids_with_tagstrengths ...' end # verify the required parameter 'ids' is set if @api_client.config.client_side_validation && ids.nil? fail ArgumentError, "Missing the required parameter 'ids' when calling RecordingApi.recordings_by_ids_with_tagstrengths" end allowable_values = ["instrument", "vocals", "energy", "soundGeneration", "rhythm", "songRating", "performanceRating", "productionRating", "moodCluster", "tonality", "arousal", "valence", "pleasantness", "engagement", "timbre", "roughness", "harmony", "texture", "groovyness", "space", "audienceAge", "audienceRegion", "audienceGender", "originRegion", "originDecade", "languageOfPerformance", "level1Genre", "level2Genre"] if @api_client.config.client_side_validation && opts[:'category_name'] && !allowable_values.include?(opts[:'category_name']) fail ArgumentError, "invalid value for \"category_name\", must be one of #{allowable_values}" end # resource path local_var_path = '/api/v1/public/recording/{ids}/tagstrengths'.sub('{' + 'ids' + '}', CGI.escape(ids.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'categoryName'] = opts[:'category_name'] if !opts[:'category_name'].nil? query_params[:'tagName'] = opts[:'tag_name'] if !opts[:'tag_name'].nil? query_params[:'genreName'] = opts[:'genre_name'] if !opts[:'genre_name'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'Array<RecordingMinimalWithTagstrengthsDTO>' # auth_names auth_names = opts[:debug_auth_names] || ['bearer-jwt'] = opts.merge( :operation => :"RecordingApi.recordings_by_ids_with_tagstrengths", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#recordings_by_ids_with_tagstrengths\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#recordings_large_by_ids(ids, opts = {}) ⇒ Array<RecordingLargeDTO>
Recordings by IDs with a large response.
302 303 304 305 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 302 def recordings_large_by_ids(ids, opts = {}) data, _status_code, _headers = recordings_large_by_ids_with_http_info(ids, opts) data end |
#recordings_large_by_ids_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingLargeDTO>, Integer, Hash)>
Recordings by IDs with a large response.
311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 311 def recordings_large_by_ids_with_http_info(ids, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: RecordingApi.recordings_large_by_ids ...' end # verify the required parameter 'ids' is set if @api_client.config.client_side_validation && ids.nil? fail ArgumentError, "Missing the required parameter 'ids' when calling RecordingApi.recordings_large_by_ids" end # resource path local_var_path = '/api/v1/public/recording/l/{ids}'.sub('{' + 'ids' + '}', CGI.escape(ids.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'Array<RecordingLargeDTO>' # auth_names auth_names = opts[:debug_auth_names] || ['bearer-jwt'] = opts.merge( :operation => :"RecordingApi.recordings_large_by_ids", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#recordings_large_by_ids\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#recordings_medium_by_ids(ids, opts = {}) ⇒ Array<RecordingMediumDTO>
Recordings by IDs with a medium sized response.
366 367 368 369 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 366 def recordings_medium_by_ids(ids, opts = {}) data, _status_code, _headers = recordings_medium_by_ids_with_http_info(ids, opts) data end |
#recordings_medium_by_ids_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingMediumDTO>, Integer, Hash)>
Recordings by IDs with a medium sized response.
378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 378 def recordings_medium_by_ids_with_http_info(ids, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: RecordingApi.recordings_medium_by_ids ...' end # verify the required parameter 'ids' is set if @api_client.config.client_side_validation && ids.nil? fail ArgumentError, "Missing the required parameter 'ids' when calling RecordingApi.recordings_medium_by_ids" end # resource path local_var_path = '/api/v1/public/recording/m/{ids}'.sub('{' + 'ids' + '}', CGI.escape(ids.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil? query_params[:'size'] = opts[:'size'] if !opts[:'size'].nil? query_params[:'sort'] = @api_client.build_collection_param(opts[:'sort'], :multi) if !opts[:'sort'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'Array<RecordingMediumDTO>' # auth_names auth_names = opts[:debug_auth_names] || ['bearer-jwt'] = opts.merge( :operation => :"RecordingApi.recordings_medium_by_ids", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#recordings_medium_by_ids\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#recordings_small_by_ids(ids, opts = {}) ⇒ Array<RecordingSmallDTO>
Recordings by IDs with a small response.
433 434 435 436 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 433 def recordings_small_by_ids(ids, opts = {}) data, _status_code, _headers = recordings_small_by_ids_with_http_info(ids, opts) data end |
#recordings_small_by_ids_with_http_info(ids, opts = {}) ⇒ Array<(Array<RecordingSmallDTO>, Integer, Hash)>
Recordings by IDs with a small response.
442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 442 def recordings_small_by_ids_with_http_info(ids, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: RecordingApi.recordings_small_by_ids ...' end # verify the required parameter 'ids' is set if @api_client.config.client_side_validation && ids.nil? fail ArgumentError, "Missing the required parameter 'ids' when calling RecordingApi.recordings_small_by_ids" end # resource path local_var_path = '/api/v1/public/recording/s/{ids}'.sub('{' + 'ids' + '}', CGI.escape(ids.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'Array<RecordingSmallDTO>' # auth_names auth_names = opts[:debug_auth_names] || ['bearer-jwt'] = opts.merge( :operation => :"RecordingApi.recordings_small_by_ids", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#recordings_small_by_ids\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#search_recordings(opts = {}) ⇒ RecordingListDTO
Recordings by contributors, moods, musical features and more.
530 531 532 533 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 530 def search_recordings(opts = {}) data, _status_code, _headers = search_recordings_with_http_info(opts) data end |
#search_recordings_granular(search_recording_granular_dto, opts = {}) ⇒ RecordingListDTO
Recordings by granular search options.
772 773 774 775 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 772 def search_recordings_granular(search_recording_granular_dto, opts = {}) data, _status_code, _headers = search_recordings_granular_with_http_info(search_recording_granular_dto, opts) data end |
#search_recordings_granular_abstraction(search_recording_granular_abstraction_dto, opts = {}) ⇒ RecordingListDTO
Recordings by abstracted wordings and granular search options.
838 839 840 841 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 838 def search_recordings_granular_abstraction(search_recording_granular_abstraction_dto, opts = {}) data, _status_code, _headers = search_recordings_granular_abstraction_with_http_info(search_recording_granular_abstraction_dto, opts) data end |
#search_recordings_granular_abstraction_with_http_info(search_recording_granular_abstraction_dto, opts = {}) ⇒ Array<(RecordingListDTO, Integer, Hash)>
Recordings by abstracted wordings and granular search options.
847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 847 def search_recordings_granular_abstraction_with_http_info(search_recording_granular_abstraction_dto, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: RecordingApi.search_recordings_granular_abstraction ...' end # verify the required parameter 'search_recording_granular_abstraction_dto' is set if @api_client.config.client_side_validation && search_recording_granular_abstraction_dto.nil? fail ArgumentError, "Missing the required parameter 'search_recording_granular_abstraction_dto' when calling RecordingApi.search_recordings_granular_abstraction" end # resource path local_var_path = '/api/v1/public/recording/searchGranularAbstraction' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' content_type = @api_client.select_header_content_type(['application/json']) if !content_type.nil? header_params['Content-Type'] = content_type end # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(search_recording_granular_abstraction_dto) # return_type return_type = opts[:debug_return_type] || 'RecordingListDTO' # auth_names auth_names = opts[:debug_auth_names] || ['bearer-jwt'] = opts.merge( :operation => :"RecordingApi.search_recordings_granular_abstraction", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:POST, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#search_recordings_granular_abstraction\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#search_recordings_granular_with_http_info(search_recording_granular_dto, opts = {}) ⇒ Array<(RecordingListDTO, Integer, Hash)>
Recordings by granular search options.
781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 781 def search_recordings_granular_with_http_info(search_recording_granular_dto, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: RecordingApi.search_recordings_granular ...' end # verify the required parameter 'search_recording_granular_dto' is set if @api_client.config.client_side_validation && search_recording_granular_dto.nil? fail ArgumentError, "Missing the required parameter 'search_recording_granular_dto' when calling RecordingApi.search_recordings_granular" end # resource path local_var_path = '/api/v1/public/recording/searchGranular' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' content_type = @api_client.select_header_content_type(['application/json']) if !content_type.nil? header_params['Content-Type'] = content_type end # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(search_recording_granular_dto) # return_type return_type = opts[:debug_return_type] || 'RecordingListDTO' # auth_names auth_names = opts[:debug_auth_names] || ['bearer-jwt'] = opts.merge( :operation => :"RecordingApi.search_recordings_granular", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:POST, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#search_recordings_granular\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#search_recordings_with_http_info(opts = {}) ⇒ Array<(RecordingListDTO, Integer, Hash)>
Recordings by contributors, moods, musical features and more.
575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 |
# File 'lib/musicube_api_client_ruby/api/recording_api.rb', line 575 def search_recordings_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: RecordingApi.search_recordings ...' end allowable_values = ["en", "es", "fr", "de", "jp", "cn", "IT", "RU"] if @api_client.config.client_side_validation && opts[:'language'] && !allowable_values.include?(opts[:'language']) fail ArgumentError, "invalid value for \"language\", must be one of #{allowable_values}" end allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"] if @api_client.config.client_side_validation && opts[:'primary_mood_cluster'] && !allowable_values.include?(opts[:'primary_mood_cluster']) fail ArgumentError, "invalid value for \"primary_mood_cluster\", must be one of #{allowable_values}" end allowable_values = ["very sad", "sad", "moderate valence", "positive", "very positive", "varying valence"] if @api_client.config.client_side_validation && opts[:'valence'] && !allowable_values.include?(opts[:'valence']) fail ArgumentError, "invalid value for \"valence\", must be one of #{allowable_values}" end allowable_values = ["very calm", "calm", "moderate arousal", "energetic", "very energetic", "varying arousal"] if @api_client.config.client_side_validation && opts[:'arousal'] && !allowable_values.include?(opts[:'arousal']) fail ArgumentError, "invalid value for \"arousal\", must be one of #{allowable_values}" end allowable_values = ["very unpleasant", "unpleasant", "neutral pleasantness", "pleasant", "very pleasant", "varying pleasantness"] if @api_client.config.client_side_validation && opts[:'pleasantness'] && !allowable_values.include?(opts[:'pleasantness']) fail ArgumentError, "invalid value for \"pleasantness\", must be one of #{allowable_values}" end allowable_values = ["very unengaging", "unengaging", "neutral engagement", "engaging", "very engaging", "varying engagement"] if @api_client.config.client_side_validation && opts[:'engagement'] && !allowable_values.include?(opts[:'engagement']) fail ArgumentError, "invalid value for \"engagement\", must be one of #{allowable_values}" end allowable_values = ["instrumental", "female vocals", "male vocals", "mixed vocals", "diverse gender vocals"] if @api_client.config.client_side_validation && opts[:'vocals'] && !allowable_values.include?(opts[:'vocals']) fail ArgumentError, "invalid value for \"vocals\", must be one of #{allowable_values}" end allowable_values = ["electric guitar", "piano", "electronics", "guitar", "strings", "synthesizer", "wind", "saxophone", "flute", "trumpet", "drum kit", "keys", "accordion", "violin", "harpsichord", "choir", "cello", "electric bass", "organ", "brass", "percussion", "vocals", "double bass", "harp"] if @api_client.config.client_side_validation && opts[:'dominant_instrument'] && !allowable_values.include?(opts[:'dominant_instrument']) fail ArgumentError, "invalid value for \"dominant_instrument\", must be one of #{allowable_values}" end allowable_values = ["very quiet", "quiet", "moderate", "loud", "very loud", "dynamic"] if @api_client.config.client_side_validation && opts[:'energy'] && !allowable_values.include?(opts[:'energy']) fail ArgumentError, "invalid value for \"energy\", must be one of #{allowable_values}" end allowable_values = ["acoustic", "electric", "electronic", "mixed sound generation"] if @api_client.config.client_side_validation && opts[:'sound_generation'] && !allowable_values.include?(opts[:'sound_generation']) fail ArgumentError, "invalid value for \"sound_generation\", must be one of #{allowable_values}" end allowable_values = ["very slow", "slow", "mid-tempo", "fast", "very fast", "varying tempo"] if @api_client.config.client_side_validation && opts[:'tempo'] && !allowable_values.include?(opts[:'tempo']) fail ArgumentError, "invalid value for \"tempo\", must be one of #{allowable_values}" end allowable_values = ["major key", "minor key", "neutral key"] if @api_client.config.client_side_validation && opts[:'scale'] && !allowable_values.include?(opts[:'scale']) fail ArgumentError, "invalid value for \"scale\", must be one of #{allowable_values}" end allowable_values = ["C", "C#", "D", "D#", "E", "F", "F#", "G", "G#", "A", "A#", "B", "unclear"] if @api_client.config.client_side_validation && opts[:'key'] && !allowable_values.include?(opts[:'key']) fail ArgumentError, "invalid value for \"key\", must be one of #{allowable_values}" end allowable_values = ["common time", "triple meter", "complex time signature", "binary rhythm", "ternary rhythm"] if @api_client.config.client_side_validation && opts[:'rhythm'] && !allowable_values.include?(opts[:'rhythm']) fail ArgumentError, "invalid value for \"rhythm\", must be one of #{allowable_values}" end allowable_values = ["brassy", "bright", "clear", "deep", "distorted", "flat", "full", "groovy", "melodious", "natural", "resonant", "shrill", "steady", "thin", "warm"] if @api_client.config.client_side_validation && opts[:'primary_sound_character'] && !allowable_values.include?(opts[:'primary_sound_character']) fail ArgumentError, "invalid value for \"primary_sound_character\", must be one of #{allowable_values}" end allowable_values = ["very warm", "warm", "moderate timbre", "bright", "very bright"] if @api_client.config.client_side_validation && opts[:'timbre'] && !allowable_values.include?(opts[:'timbre']) fail ArgumentError, "invalid value for \"timbre\", must be one of #{allowable_values}" end allowable_values = ["very clear", "clear", "moderate roughness", "distorted", "very distorted"] if @api_client.config.client_side_validation && opts[:'roughness'] && !allowable_values.include?(opts[:'roughness']) fail ArgumentError, "invalid value for \"roughness\", must be one of #{allowable_values}" end allowable_values = ["monotonous", "moderate melodiousness", "melodious", "atonal"] if @api_client.config.client_side_validation && opts[:'tonality'] && !allowable_values.include?(opts[:'tonality']) fail ArgumentError, "invalid value for \"tonality\", must be one of #{allowable_values}" end allowable_values = ["very dissonant", "dissonant", "moderate harmonies", "harmonious", "very harmonious"] if @api_client.config.client_side_validation && opts[:'harmony'] && !allowable_values.include?(opts[:'harmony']) fail ArgumentError, "invalid value for \"harmony\", must be one of #{allowable_values}" end allowable_values = ["very thin", "thin", "moderate texture", "full", "very full"] if @api_client.config.client_side_validation && opts[:'texture'] && !allowable_values.include?(opts[:'texture']) fail ArgumentError, "invalid value for \"texture\", must be one of #{allowable_values}" end allowable_values = ["very steady", "steady", "moderate rhythm feel", "groovy", "very groovy"] if @api_client.config.client_side_validation && opts[:'groovyness'] && !allowable_values.include?(opts[:'groovyness']) fail ArgumentError, "invalid value for \"groovyness\", must be one of #{allowable_values}" end allowable_values = ["very compact", "compact", "moderate space", "wide", "very wide"] if @api_client.config.client_side_validation && opts[:'space'] && !allowable_values.include?(opts[:'space']) fail ArgumentError, "invalid value for \"space\", must be one of #{allowable_values}" end allowable_values = ["pre-1950s", "1950s", "1960s", "1970s", "1980s", "1990s", "2000s", "2010s", "2020s"] if @api_client.config.client_side_validation && opts[:'origin_decade'] && !allowable_values.include?(opts[:'origin_decade']) fail ArgumentError, "invalid value for \"origin_decade\", must be one of #{allowable_values}" end allowable_values = ["curateable", "uncurateable"] if @api_client.config.client_side_validation && opts[:'curateability'] && !allowable_values.include?(opts[:'curateability']) fail ArgumentError, "invalid value for \"curateability\", must be one of #{allowable_values}" end allowable_values = ["background", "sport", "focus", "christmas", "film", "summer", "adverts", "party", "relax"] if @api_client.config.client_side_validation && opts[:'use_case'] && !allowable_values.include?(opts[:'use_case']) fail ArgumentError, "invalid value for \"use_case\", must be one of #{allowable_values}" end allowable_values = ["Spotify", "TikTok", "Unfitting", "YouTube"] if @api_client.config.client_side_validation && opts[:'channel_suitability'] && !allowable_values.include?(opts[:'channel_suitability']) fail ArgumentError, "invalid value for \"channel_suitability\", must be one of #{allowable_values}" end allowable_values = ["true", "false"] if @api_client.config.client_side_validation && opts[:'shuffled'] && !allowable_values.include?(opts[:'shuffled']) fail ArgumentError, "invalid value for \"shuffled\", must be one of #{allowable_values}" end allowable_values = ["popularityDesc", "popularityAsc", "releaseDateDesc", "releaseDateAsc"] if @api_client.config.client_side_validation && opts[:'sort'] && !allowable_values.include?(opts[:'sort']) fail ArgumentError, "invalid value for \"sort\", must be one of #{allowable_values}" end # resource path local_var_path = '/api/v1/public/recording/search' # query parameters query_params = opts[:query_params] || {} query_params[:'similarToRecording'] = opts[:'similar_to_recording'] if !opts[:'similar_to_recording'].nil? query_params[:'contributor'] = opts[:'contributor'] if !opts[:'contributor'].nil? query_params[:'mainArtist'] = opts[:'main_artist'] if !opts[:'main_artist'].nil? query_params[:'composer'] = opts[:'composer'] if !opts[:'composer'].nil? query_params[:'title'] = opts[:'title'] if !opts[:'title'].nil? query_params[:'language'] = opts[:'language'] if !opts[:'language'].nil? query_params[:'genre'] = opts[:'genre'] if !opts[:'genre'].nil? query_params[:'primaryMoodCluster'] = opts[:'primary_mood_cluster'] if !opts[:'primary_mood_cluster'].nil? query_params[:'valence'] = opts[:'valence'] if !opts[:'valence'].nil? query_params[:'arousal'] = opts[:'arousal'] if !opts[:'arousal'].nil? query_params[:'pleasantness'] = opts[:'pleasantness'] if !opts[:'pleasantness'].nil? query_params[:'engagement'] = opts[:'engagement'] if !opts[:'engagement'].nil? query_params[:'vocals'] = opts[:'vocals'] if !opts[:'vocals'].nil? query_params[:'dominantInstrument'] = opts[:'dominant_instrument'] if !opts[:'dominant_instrument'].nil? query_params[:'energy'] = opts[:'energy'] if !opts[:'energy'].nil? query_params[:'soundGeneration'] = opts[:'sound_generation'] if !opts[:'sound_generation'].nil? query_params[:'tempo'] = opts[:'tempo'] if !opts[:'tempo'].nil? query_params[:'scale'] = opts[:'scale'] if !opts[:'scale'].nil? query_params[:'key'] = opts[:'key'] if !opts[:'key'].nil? query_params[:'rhythm'] = opts[:'rhythm'] if !opts[:'rhythm'].nil? query_params[:'primarySoundCharacter'] = opts[:'primary_sound_character'] if !opts[:'primary_sound_character'].nil? query_params[:'timbre'] = opts[:'timbre'] if !opts[:'timbre'].nil? query_params[:'roughness'] = opts[:'roughness'] if !opts[:'roughness'].nil? query_params[:'tonality'] = opts[:'tonality'] if !opts[:'tonality'].nil? query_params[:'harmony'] = opts[:'harmony'] if !opts[:'harmony'].nil? query_params[:'texture'] = opts[:'texture'] if !opts[:'texture'].nil? query_params[:'groovyness'] = opts[:'groovyness'] if !opts[:'groovyness'].nil? query_params[:'space'] = opts[:'space'] if !opts[:'space'].nil? query_params[:'originDecade'] = opts[:'origin_decade'] if !opts[:'origin_decade'].nil? query_params[:'curateability'] = opts[:'curateability'] if !opts[:'curateability'].nil? query_params[:'useCase'] = opts[:'use_case'] if !opts[:'use_case'].nil? query_params[:'channelSuitability'] = opts[:'channel_suitability'] if !opts[:'channel_suitability'].nil? query_params[:'songtradrTrackId'] = opts[:'songtradr_track_id'] if !opts[:'songtradr_track_id'].nil? query_params[:'shuffled'] = opts[:'shuffled'] if !opts[:'shuffled'].nil? query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil? query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil? query_params[:'size'] = opts[:'size'] if !opts[:'size'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'RecordingListDTO' # auth_names auth_names = opts[:debug_auth_names] || ['bearer-jwt'] = opts.merge( :operation => :"RecordingApi.search_recordings", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#search_recordings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |