musicube_api_client_ruby 1.1.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/CODE_OF_CONDUCT.md +84 -0
- data/Gemfile +9 -0
- data/README.md +223 -0
- data/Rakefile +10 -0
- data/bin/console +15 -0
- data/bin/setup +8 -0
- data/docs/AllowedValuesApi.md +200 -0
- data/docs/CategoryMediumDTO.md +22 -0
- data/docs/CategoryMinimalDTO.md +18 -0
- data/docs/ConfigAccessDTO.md +20 -0
- data/docs/ConfigIdentifierDTO.md +20 -0
- data/docs/ContributorTypeDTO.md +18 -0
- data/docs/ErrorResponse.md +26 -0
- data/docs/FieldSummaryDTO.md +22 -0
- data/docs/FileDTO.md +50 -0
- data/docs/FileListDTO.md +24 -0
- data/docs/FileMinimalWithUrlDTO.md +22 -0
- data/docs/FileSmallDTO.md +46 -0
- data/docs/FileUploadDTO.md +22 -0
- data/docs/FileWIthUrlDTO.md +20 -0
- data/docs/FilesSummaryDTO.md +30 -0
- data/docs/ForgotPasswordDTO.md +20 -0
- data/docs/GenreDTO.md +20 -0
- data/docs/GenreMinimalDTO.md +18 -0
- data/docs/GenresSummaryDTO.md +22 -0
- data/docs/InitPutRecordingAudioDTO.md +22 -0
- data/docs/JwtTokenDTO.md +22 -0
- data/docs/LoginDTO.md +24 -0
- data/docs/MusicalFeaturesDTO.md +186 -0
- data/docs/PLineDTO.md +20 -0
- data/docs/PartyApi.md +75 -0
- data/docs/PartyLargeDTO.md +32 -0
- data/docs/PartySmallDTO.md +20 -0
- data/docs/PlaylistApi.md +221 -0
- data/docs/PlaylistLargeDTO.md +38 -0
- data/docs/ProductMediumDTO.md +34 -0
- data/docs/ProductPartyDTO.md +20 -0
- data/docs/RecordingApi.md +789 -0
- data/docs/RecordingForSimilaritySearchDTO.md +20 -0
- data/docs/RecordingGenrePredictionDTO.md +22 -0
- data/docs/RecordingLargeDTO.md +40 -0
- data/docs/RecordingListDTO.md +24 -0
- data/docs/RecordingMediumDTO.md +36 -0
- data/docs/RecordingMinimalWithMusicalFeaturesDTO.md +20 -0
- data/docs/RecordingMinimalWithTaggramsDTO.md +22 -0
- data/docs/RecordingMinimalWithTagstrengthsDTO.md +20 -0
- data/docs/RecordingPartyDTO.md +20 -0
- data/docs/RecordingPlaylistDTO.md +24 -0
- data/docs/RecordingSmallDTO.md +24 -0
- data/docs/RecordingTagSmallDTO.md +18 -0
- data/docs/SaveFileRecordingDTO.md +236 -0
- data/docs/SavePlaylistDTO.md +34 -0
- data/docs/SaveRecordingGenreDTO.md +22 -0
- data/docs/SaveRecordingPartyDTO.md +20 -0
- data/docs/SaveRecordingPlaylistDTO.md +22 -0
- data/docs/SaveRecordingTagDTO.md +20 -0
- data/docs/SaveReferrerDTO.md +20 -0
- data/docs/SaveTaggramsDTO.md +82 -0
- data/docs/SaveUserDTO.md +28 -0
- data/docs/SearchFilterValuesDTO.md +98 -0
- data/docs/SearchRecordingGranularAbstractionDTO.md +20 -0
- data/docs/SearchRecordingGranularDTO.md +22 -0
- data/docs/SignUpDTO.md +24 -0
- data/docs/TagDTO.md +22 -0
- data/docs/TagSmallDTO.md +20 -0
- data/docs/TaggramDTO.md +26 -0
- data/docs/TagsSummaryDTO.md +22 -0
- data/docs/TagstrengthDTO.md +26 -0
- data/docs/TitleDTO.md +18 -0
- data/docs/TokenRequest.md +18 -0
- data/docs/TrackToMediumProductDTO.md +22 -0
- data/docs/UpdatePasswordDTO.md +20 -0
- data/docs/UsageDTO.md +18 -0
- data/docs/UserApi.md +1936 -0
- data/docs/UserDTO.md +56 -0
- data/git_push.sh +57 -0
- data/lib/musicube_api_client_ruby/api/allowed_values_api.rb +213 -0
- data/lib/musicube_api_client_ruby/api/party_api.rb +84 -0
- data/lib/musicube_api_client_ruby/api/playlist_api.rb +222 -0
- data/lib/musicube_api_client_ruby/api/recording_api.rb +900 -0
- data/lib/musicube_api_client_ruby/api/user_api.rb +2642 -0
- data/lib/musicube_api_client_ruby/api_client.rb +428 -0
- data/lib/musicube_api_client_ruby/api_error.rb +58 -0
- data/lib/musicube_api_client_ruby/configuration.rb +380 -0
- data/lib/musicube_api_client_ruby/models/category_medium_dto.rb +250 -0
- data/lib/musicube_api_client_ruby/models/category_minimal_dto.rb +225 -0
- data/lib/musicube_api_client_ruby/models/config_access_dto.rb +287 -0
- data/lib/musicube_api_client_ruby/models/config_identifier_dto.rb +239 -0
- data/lib/musicube_api_client_ruby/models/contributor_type_dto.rb +225 -0
- data/lib/musicube_api_client_ruby/models/error_response.rb +276 -0
- data/lib/musicube_api_client_ruby/models/field_summary_dto.rb +253 -0
- data/lib/musicube_api_client_ruby/models/file_dto.rb +450 -0
- data/lib/musicube_api_client_ruby/models/file_list_dto.rb +269 -0
- data/lib/musicube_api_client_ruby/models/file_minimal_with_url_dto.rb +253 -0
- data/lib/musicube_api_client_ruby/models/file_small_dto.rb +432 -0
- data/lib/musicube_api_client_ruby/models/file_upload_dto.rb +244 -0
- data/lib/musicube_api_client_ruby/models/file_w_ith_url_dto.rb +239 -0
- data/lib/musicube_api_client_ruby/models/files_summary_dto.rb +287 -0
- data/lib/musicube_api_client_ruby/models/forgot_password_dto.rb +267 -0
- data/lib/musicube_api_client_ruby/models/genre_dto.rb +239 -0
- data/lib/musicube_api_client_ruby/models/genre_minimal_dto.rb +225 -0
- data/lib/musicube_api_client_ruby/models/genres_summary_dto.rb +248 -0
- data/lib/musicube_api_client_ruby/models/init_put_recording_audio_dto.rb +238 -0
- data/lib/musicube_api_client_ruby/models/jwt_token_dto.rb +248 -0
- data/lib/musicube_api_client_ruby/models/login_dto.rb +257 -0
- data/lib/musicube_api_client_ruby/models/musical_features_dto.rb +1532 -0
- data/lib/musicube_api_client_ruby/models/p_line_dto.rb +234 -0
- data/lib/musicube_api_client_ruby/models/party_large_dto.rb +288 -0
- data/lib/musicube_api_client_ruby/models/party_small_dto.rb +239 -0
- data/lib/musicube_api_client_ruby/models/playlist_large_dto.rb +353 -0
- data/lib/musicube_api_client_ruby/models/product_medium_dto.rb +316 -0
- data/lib/musicube_api_client_ruby/models/product_party_dto.rb +236 -0
- data/lib/musicube_api_client_ruby/models/recording_for_similarity_search_dto.rb +239 -0
- data/lib/musicube_api_client_ruby/models/recording_genre_prediction_dto.rb +253 -0
- data/lib/musicube_api_client_ruby/models/recording_large_dto.rb +366 -0
- data/lib/musicube_api_client_ruby/models/recording_list_dto.rb +269 -0
- data/lib/musicube_api_client_ruby/models/recording_medium_dto.rb +340 -0
- data/lib/musicube_api_client_ruby/models/recording_minimal_with_musical_features_dto.rb +236 -0
- data/lib/musicube_api_client_ruby/models/recording_minimal_with_taggrams_dto.rb +248 -0
- data/lib/musicube_api_client_ruby/models/recording_minimal_with_tagstrengths_dto.rb +236 -0
- data/lib/musicube_api_client_ruby/models/recording_party_dto.rb +236 -0
- data/lib/musicube_api_client_ruby/models/recording_playlist_dto.rb +247 -0
- data/lib/musicube_api_client_ruby/models/recording_small_dto.rb +268 -0
- data/lib/musicube_api_client_ruby/models/recording_tag_small_dto.rb +225 -0
- data/lib/musicube_api_client_ruby/models/save_file_recording_dto.rb +1847 -0
- data/lib/musicube_api_client_ruby/models/save_playlist_dto.rb +350 -0
- data/lib/musicube_api_client_ruby/models/save_recording_genre_dto.rb +243 -0
- data/lib/musicube_api_client_ruby/models/save_recording_party_dto.rb +273 -0
- data/lib/musicube_api_client_ruby/models/save_recording_playlist_dto.rb +248 -0
- data/lib/musicube_api_client_ruby/models/save_recording_tag_dto.rb +234 -0
- data/lib/musicube_api_client_ruby/models/save_referrer_dto.rb +229 -0
- data/lib/musicube_api_client_ruby/models/save_taggrams_dto.rb +574 -0
- data/lib/musicube_api_client_ruby/models/save_user_dto.rb +317 -0
- data/lib/musicube_api_client_ruby/models/search_filter_values_dto.rb +867 -0
- data/lib/musicube_api_client_ruby/models/search_recording_granular_abstraction_dto.rb +270 -0
- data/lib/musicube_api_client_ruby/models/search_recording_granular_dto.rb +245 -0
- data/lib/musicube_api_client_ruby/models/sign_up_dto.rb +262 -0
- data/lib/musicube_api_client_ruby/models/tag_dto.rb +250 -0
- data/lib/musicube_api_client_ruby/models/tag_small_dto.rb +239 -0
- data/lib/musicube_api_client_ruby/models/taggram_dto.rb +271 -0
- data/lib/musicube_api_client_ruby/models/tags_summary_dto.rb +250 -0
- data/lib/musicube_api_client_ruby/models/tagstrength_dto.rb +269 -0
- data/lib/musicube_api_client_ruby/models/title_dto.rb +225 -0
- data/lib/musicube_api_client_ruby/models/token_request.rb +224 -0
- data/lib/musicube_api_client_ruby/models/track_to_medium_product_dto.rb +248 -0
- data/lib/musicube_api_client_ruby/models/update_password_dto.rb +238 -0
- data/lib/musicube_api_client_ruby/models/usage_dto.rb +220 -0
- data/lib/musicube_api_client_ruby/models/user_dto.rb +481 -0
- data/lib/musicube_api_client_ruby/version.rb +15 -0
- data/lib/musicube_api_client_ruby.rb +108 -0
- data/musicube_api_client_ruby.gemspec +39 -0
- data/openapi-generator-config.yaml +9 -0
- data/spec/api/allowed_values_api_spec.rb +68 -0
- data/spec/api/party_api_spec.rb +46 -0
- data/spec/api/playlist_api_spec.rb +72 -0
- data/spec/api/recording_api_spec.rb +192 -0
- data/spec/api/user_api_spec.rb +507 -0
- data/spec/api_client_spec.rb +223 -0
- data/spec/configuration_spec.rb +82 -0
- data/spec/models/category_medium_dto_spec.rb +46 -0
- data/spec/models/category_minimal_dto_spec.rb +34 -0
- data/spec/models/config_access_dto_spec.rb +48 -0
- data/spec/models/config_identifier_dto_spec.rb +40 -0
- data/spec/models/contributor_type_dto_spec.rb +34 -0
- data/spec/models/error_response_spec.rb +58 -0
- data/spec/models/field_summary_dto_spec.rb +46 -0
- data/spec/models/file_dto_spec.rb +142 -0
- data/spec/models/file_list_dto_spec.rb +52 -0
- data/spec/models/file_minimal_with_url_dto_spec.rb +46 -0
- data/spec/models/file_small_dto_spec.rb +130 -0
- data/spec/models/file_upload_dto_spec.rb +46 -0
- data/spec/models/file_w_ith_url_dto_spec.rb +40 -0
- data/spec/models/files_summary_dto_spec.rb +70 -0
- data/spec/models/forgot_password_dto_spec.rb +44 -0
- data/spec/models/genre_dto_spec.rb +40 -0
- data/spec/models/genre_minimal_dto_spec.rb +34 -0
- data/spec/models/genres_summary_dto_spec.rb +46 -0
- data/spec/models/init_put_recording_audio_dto_spec.rb +46 -0
- data/spec/models/jwt_token_dto_spec.rb +46 -0
- data/spec/models/login_dto_spec.rb +52 -0
- data/spec/models/musical_features_dto_spec.rb +706 -0
- data/spec/models/p_line_dto_spec.rb +40 -0
- data/spec/models/party_large_dto_spec.rb +76 -0
- data/spec/models/party_small_dto_spec.rb +40 -0
- data/spec/models/playlist_large_dto_spec.rb +98 -0
- data/spec/models/product_medium_dto_spec.rb +82 -0
- data/spec/models/product_party_dto_spec.rb +40 -0
- data/spec/models/recording_for_similarity_search_dto_spec.rb +40 -0
- data/spec/models/recording_genre_prediction_dto_spec.rb +46 -0
- data/spec/models/recording_large_dto_spec.rb +100 -0
- data/spec/models/recording_list_dto_spec.rb +52 -0
- data/spec/models/recording_medium_dto_spec.rb +88 -0
- data/spec/models/recording_minimal_with_musical_features_dto_spec.rb +40 -0
- data/spec/models/recording_minimal_with_taggrams_dto_spec.rb +46 -0
- data/spec/models/recording_minimal_with_tagstrengths_dto_spec.rb +40 -0
- data/spec/models/recording_party_dto_spec.rb +40 -0
- data/spec/models/recording_playlist_dto_spec.rb +52 -0
- data/spec/models/recording_small_dto_spec.rb +52 -0
- data/spec/models/recording_tag_small_dto_spec.rb +34 -0
- data/spec/models/save_file_recording_dto_spec.rb +880 -0
- data/spec/models/save_playlist_dto_spec.rb +86 -0
- data/spec/models/save_recording_genre_dto_spec.rb +46 -0
- data/spec/models/save_recording_party_dto_spec.rb +44 -0
- data/spec/models/save_recording_playlist_dto_spec.rb +46 -0
- data/spec/models/save_recording_tag_dto_spec.rb +40 -0
- data/spec/models/save_referrer_dto_spec.rb +40 -0
- data/spec/models/save_taggrams_dto_spec.rb +226 -0
- data/spec/models/save_user_dto_spec.rb +72 -0
- data/spec/models/search_filter_values_dto_spec.rb +274 -0
- data/spec/models/search_recording_granular_abstraction_dto_spec.rb +44 -0
- data/spec/models/search_recording_granular_dto_spec.rb +46 -0
- data/spec/models/sign_up_dto_spec.rb +52 -0
- data/spec/models/tag_dto_spec.rb +46 -0
- data/spec/models/tag_small_dto_spec.rb +40 -0
- data/spec/models/taggram_dto_spec.rb +58 -0
- data/spec/models/tags_summary_dto_spec.rb +46 -0
- data/spec/models/tagstrength_dto_spec.rb +58 -0
- data/spec/models/title_dto_spec.rb +34 -0
- data/spec/models/token_request_spec.rb +34 -0
- data/spec/models/track_to_medium_product_dto_spec.rb +46 -0
- data/spec/models/update_password_dto_spec.rb +40 -0
- data/spec/models/usage_dto_spec.rb +34 -0
- data/spec/models/user_dto_spec.rb +148 -0
- data/spec/musicube_api_client_ruby_spec.rb +11 -0
- data/spec/spec_helper.rb +111 -0
- metadata +415 -0
@@ -0,0 +1,2642 @@
|
|
1
|
+
=begin
|
2
|
+
#Songtradr API
|
3
|
+
|
4
|
+
#This is the Songtradr API. Use it to retrieve deep music metadata and trigger processes like auto-tagging. You can also use the API to manage your account and musicube cloud data. **Authentication** 1. Reach out to support@songtradr.com to receive a free account or use your login data if you are already signed up. 2. To authenticate, you need to login via the POST /api/v1/user/login endpoint. 3. The endpoint responds with a jwtToken which you can use in all following API requests as a bearer token. **Rate Limiting** The current limit is 120 Requests per minute. Reach out to us via support@songtradr.com if you need to request more. **Getting Started with auto-tagging** 1. If you want to get your own files auto-tagged, use the POST /api/v1/user/file/{name}/initUpload endpoint. It responds with a presigned S3 link where you can upload your file. 2. You can check the processing status of your file via the GET /api/v1/user/file/{name}/filesStatus endpoint. 3. As soon as processing is done, you can request the generated data via the GET /api/v1/user/files endpoint. **Getting Started with search** You can either search the released music via the /public/recording endpoints or your own private uploaded music via the /user/file/ endpoints. 1. If you want to search the world's released music, a good starting point is the GET /api/v1/public/recording/search endpoint. Please find the extensive list of parameters that serve as semantic search filters. 2. If you want to search your own previously uploaded music, a good starting point is the GET GET /api/v1/user/files endpoint. It has the same extensive list of parameters that serve as semantic search filters.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.12.21
|
7
|
+
Contact: info@songtradr.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 6.6.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'cgi'
|
14
|
+
|
15
|
+
module MusicubeApiClientRuby
|
16
|
+
class UserApi
|
17
|
+
attr_accessor :api_client
|
18
|
+
|
19
|
+
def initialize(api_client = ApiClient.default)
|
20
|
+
@api_client = api_client
|
21
|
+
end
|
22
|
+
# @param save_referrer_dto [SaveReferrerDTO]
|
23
|
+
# @param [Hash] opts the optional parameters
|
24
|
+
# @return [Object]
|
25
|
+
def create_user_referrer(save_referrer_dto, opts = {})
|
26
|
+
data, _status_code, _headers = create_user_referrer_with_http_info(save_referrer_dto, opts)
|
27
|
+
data
|
28
|
+
end
|
29
|
+
|
30
|
+
# @param save_referrer_dto [SaveReferrerDTO]
|
31
|
+
# @param [Hash] opts the optional parameters
|
32
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
33
|
+
def create_user_referrer_with_http_info(save_referrer_dto, opts = {})
|
34
|
+
if @api_client.config.debugging
|
35
|
+
@api_client.config.logger.debug 'Calling API: UserApi.create_user_referrer ...'
|
36
|
+
end
|
37
|
+
# verify the required parameter 'save_referrer_dto' is set
|
38
|
+
if @api_client.config.client_side_validation && save_referrer_dto.nil?
|
39
|
+
fail ArgumentError, "Missing the required parameter 'save_referrer_dto' when calling UserApi.create_user_referrer"
|
40
|
+
end
|
41
|
+
# resource path
|
42
|
+
local_var_path = '/api/v1/user/referrers/new'
|
43
|
+
|
44
|
+
# query parameters
|
45
|
+
query_params = opts[:query_params] || {}
|
46
|
+
|
47
|
+
# header parameters
|
48
|
+
header_params = opts[:header_params] || {}
|
49
|
+
# HTTP header 'Accept' (if needed)
|
50
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
51
|
+
# HTTP header 'Content-Type'
|
52
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
53
|
+
if !content_type.nil?
|
54
|
+
header_params['Content-Type'] = content_type
|
55
|
+
end
|
56
|
+
|
57
|
+
# form parameters
|
58
|
+
form_params = opts[:form_params] || {}
|
59
|
+
|
60
|
+
# http body (model)
|
61
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(save_referrer_dto)
|
62
|
+
|
63
|
+
# return_type
|
64
|
+
return_type = opts[:debug_return_type] || 'Object'
|
65
|
+
|
66
|
+
# auth_names
|
67
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
68
|
+
|
69
|
+
new_options = opts.merge(
|
70
|
+
:operation => :"UserApi.create_user_referrer",
|
71
|
+
:header_params => header_params,
|
72
|
+
:query_params => query_params,
|
73
|
+
:form_params => form_params,
|
74
|
+
:body => post_body,
|
75
|
+
:auth_names => auth_names,
|
76
|
+
:return_type => return_type
|
77
|
+
)
|
78
|
+
|
79
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
80
|
+
if @api_client.config.debugging
|
81
|
+
@api_client.config.logger.debug "API called: UserApi#create_user_referrer\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
82
|
+
end
|
83
|
+
return data, status_code, headers
|
84
|
+
end
|
85
|
+
|
86
|
+
# Delete file.
|
87
|
+
# @param object_key [String] ObjectKey of the file that should be deleted.
|
88
|
+
# @param [Hash] opts the optional parameters
|
89
|
+
# @return [Object]
|
90
|
+
def delete_user_file(object_key, opts = {})
|
91
|
+
data, _status_code, _headers = delete_user_file_with_http_info(object_key, opts)
|
92
|
+
data
|
93
|
+
end
|
94
|
+
|
95
|
+
# Delete file.
|
96
|
+
# @param object_key [String] ObjectKey of the file that should be deleted.
|
97
|
+
# @param [Hash] opts the optional parameters
|
98
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
99
|
+
def delete_user_file_with_http_info(object_key, opts = {})
|
100
|
+
if @api_client.config.debugging
|
101
|
+
@api_client.config.logger.debug 'Calling API: UserApi.delete_user_file ...'
|
102
|
+
end
|
103
|
+
# verify the required parameter 'object_key' is set
|
104
|
+
if @api_client.config.client_side_validation && object_key.nil?
|
105
|
+
fail ArgumentError, "Missing the required parameter 'object_key' when calling UserApi.delete_user_file"
|
106
|
+
end
|
107
|
+
# resource path
|
108
|
+
local_var_path = '/api/v1/user/file/{objectKey}'.sub('{' + 'objectKey' + '}', CGI.escape(object_key.to_s))
|
109
|
+
|
110
|
+
# query parameters
|
111
|
+
query_params = opts[:query_params] || {}
|
112
|
+
|
113
|
+
# header parameters
|
114
|
+
header_params = opts[:header_params] || {}
|
115
|
+
# HTTP header 'Accept' (if needed)
|
116
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/hal+json', 'application/json'])
|
117
|
+
|
118
|
+
# form parameters
|
119
|
+
form_params = opts[:form_params] || {}
|
120
|
+
|
121
|
+
# http body (model)
|
122
|
+
post_body = opts[:debug_body]
|
123
|
+
|
124
|
+
# return_type
|
125
|
+
return_type = opts[:debug_return_type] || 'Object'
|
126
|
+
|
127
|
+
# auth_names
|
128
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
129
|
+
|
130
|
+
new_options = opts.merge(
|
131
|
+
:operation => :"UserApi.delete_user_file",
|
132
|
+
:header_params => header_params,
|
133
|
+
:query_params => query_params,
|
134
|
+
:form_params => form_params,
|
135
|
+
:body => post_body,
|
136
|
+
:auth_names => auth_names,
|
137
|
+
:return_type => return_type
|
138
|
+
)
|
139
|
+
|
140
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
141
|
+
if @api_client.config.debugging
|
142
|
+
@api_client.config.logger.debug "API called: UserApi#delete_user_file\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
143
|
+
end
|
144
|
+
return data, status_code, headers
|
145
|
+
end
|
146
|
+
|
147
|
+
# Edit details for a logged-in user
|
148
|
+
# @param save_user_dto [SaveUserDTO]
|
149
|
+
# @param [Hash] opts the optional parameters
|
150
|
+
# @return [Object]
|
151
|
+
def edit_me(save_user_dto, opts = {})
|
152
|
+
data, _status_code, _headers = edit_me_with_http_info(save_user_dto, opts)
|
153
|
+
data
|
154
|
+
end
|
155
|
+
|
156
|
+
# Edit details for a logged-in user
|
157
|
+
# @param save_user_dto [SaveUserDTO]
|
158
|
+
# @param [Hash] opts the optional parameters
|
159
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
160
|
+
def edit_me_with_http_info(save_user_dto, opts = {})
|
161
|
+
if @api_client.config.debugging
|
162
|
+
@api_client.config.logger.debug 'Calling API: UserApi.edit_me ...'
|
163
|
+
end
|
164
|
+
# verify the required parameter 'save_user_dto' is set
|
165
|
+
if @api_client.config.client_side_validation && save_user_dto.nil?
|
166
|
+
fail ArgumentError, "Missing the required parameter 'save_user_dto' when calling UserApi.edit_me"
|
167
|
+
end
|
168
|
+
# resource path
|
169
|
+
local_var_path = '/api/v1/user/me'
|
170
|
+
|
171
|
+
# query parameters
|
172
|
+
query_params = opts[:query_params] || {}
|
173
|
+
|
174
|
+
# header parameters
|
175
|
+
header_params = opts[:header_params] || {}
|
176
|
+
# HTTP header 'Accept' (if needed)
|
177
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
178
|
+
# HTTP header 'Content-Type'
|
179
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
180
|
+
if !content_type.nil?
|
181
|
+
header_params['Content-Type'] = content_type
|
182
|
+
end
|
183
|
+
|
184
|
+
# form parameters
|
185
|
+
form_params = opts[:form_params] || {}
|
186
|
+
|
187
|
+
# http body (model)
|
188
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(save_user_dto)
|
189
|
+
|
190
|
+
# return_type
|
191
|
+
return_type = opts[:debug_return_type] || 'Object'
|
192
|
+
|
193
|
+
# auth_names
|
194
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
195
|
+
|
196
|
+
new_options = opts.merge(
|
197
|
+
:operation => :"UserApi.edit_me",
|
198
|
+
:header_params => header_params,
|
199
|
+
:query_params => query_params,
|
200
|
+
:form_params => form_params,
|
201
|
+
:body => post_body,
|
202
|
+
:auth_names => auth_names,
|
203
|
+
:return_type => return_type
|
204
|
+
)
|
205
|
+
|
206
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
207
|
+
if @api_client.config.debugging
|
208
|
+
@api_client.config.logger.debug "API called: UserApi#edit_me\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
209
|
+
end
|
210
|
+
return data, status_code, headers
|
211
|
+
end
|
212
|
+
|
213
|
+
# Send a password reset email
|
214
|
+
# @param forgot_password_dto [ForgotPasswordDTO]
|
215
|
+
# @param [Hash] opts the optional parameters
|
216
|
+
# @return [Object]
|
217
|
+
def forgot_password(forgot_password_dto, opts = {})
|
218
|
+
data, _status_code, _headers = forgot_password_with_http_info(forgot_password_dto, opts)
|
219
|
+
data
|
220
|
+
end
|
221
|
+
|
222
|
+
# Send a password reset email
|
223
|
+
# @param forgot_password_dto [ForgotPasswordDTO]
|
224
|
+
# @param [Hash] opts the optional parameters
|
225
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
226
|
+
def forgot_password_with_http_info(forgot_password_dto, opts = {})
|
227
|
+
if @api_client.config.debugging
|
228
|
+
@api_client.config.logger.debug 'Calling API: UserApi.forgot_password ...'
|
229
|
+
end
|
230
|
+
# verify the required parameter 'forgot_password_dto' is set
|
231
|
+
if @api_client.config.client_side_validation && forgot_password_dto.nil?
|
232
|
+
fail ArgumentError, "Missing the required parameter 'forgot_password_dto' when calling UserApi.forgot_password"
|
233
|
+
end
|
234
|
+
# resource path
|
235
|
+
local_var_path = '/api/v1/user/forgot-password'
|
236
|
+
|
237
|
+
# query parameters
|
238
|
+
query_params = opts[:query_params] || {}
|
239
|
+
|
240
|
+
# header parameters
|
241
|
+
header_params = opts[:header_params] || {}
|
242
|
+
# HTTP header 'Accept' (if needed)
|
243
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/hal+json', 'application/json'])
|
244
|
+
# HTTP header 'Content-Type'
|
245
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
246
|
+
if !content_type.nil?
|
247
|
+
header_params['Content-Type'] = content_type
|
248
|
+
end
|
249
|
+
|
250
|
+
# form parameters
|
251
|
+
form_params = opts[:form_params] || {}
|
252
|
+
|
253
|
+
# http body (model)
|
254
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(forgot_password_dto)
|
255
|
+
|
256
|
+
# return_type
|
257
|
+
return_type = opts[:debug_return_type] || 'Object'
|
258
|
+
|
259
|
+
# auth_names
|
260
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
261
|
+
|
262
|
+
new_options = opts.merge(
|
263
|
+
:operation => :"UserApi.forgot_password",
|
264
|
+
:header_params => header_params,
|
265
|
+
:query_params => query_params,
|
266
|
+
:form_params => form_params,
|
267
|
+
:body => post_body,
|
268
|
+
:auth_names => auth_names,
|
269
|
+
:return_type => return_type
|
270
|
+
)
|
271
|
+
|
272
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
273
|
+
if @api_client.config.debugging
|
274
|
+
@api_client.config.logger.debug "API called: UserApi#forgot_password\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
275
|
+
end
|
276
|
+
return data, status_code, headers
|
277
|
+
end
|
278
|
+
|
279
|
+
# Initialize a file upload. Responds with an URL where the file can be uploaded.
|
280
|
+
# @param name [String] The Name of the file that will be uploaded
|
281
|
+
# @param folder [String] The Name of the folder that the file will be placed in
|
282
|
+
# @param [Hash] opts the optional parameters
|
283
|
+
# @option opts [FileUploadDTO] :file_upload_dto
|
284
|
+
# @return [InitPutRecordingAudioDTO]
|
285
|
+
def initiate_user_file_upload(name, folder, opts = {})
|
286
|
+
data, _status_code, _headers = initiate_user_file_upload_with_http_info(name, folder, opts)
|
287
|
+
data
|
288
|
+
end
|
289
|
+
|
290
|
+
# Initialize a file upload. Responds with an URL where the file can be uploaded.
|
291
|
+
# @param name [String] The Name of the file that will be uploaded
|
292
|
+
# @param folder [String] The Name of the folder that the file will be placed in
|
293
|
+
# @param [Hash] opts the optional parameters
|
294
|
+
# @option opts [FileUploadDTO] :file_upload_dto
|
295
|
+
# @return [Array<(InitPutRecordingAudioDTO, Integer, Hash)>] InitPutRecordingAudioDTO data, response status code and response headers
|
296
|
+
def initiate_user_file_upload_with_http_info(name, folder, opts = {})
|
297
|
+
if @api_client.config.debugging
|
298
|
+
@api_client.config.logger.debug 'Calling API: UserApi.initiate_user_file_upload ...'
|
299
|
+
end
|
300
|
+
# verify the required parameter 'name' is set
|
301
|
+
if @api_client.config.client_side_validation && name.nil?
|
302
|
+
fail ArgumentError, "Missing the required parameter 'name' when calling UserApi.initiate_user_file_upload"
|
303
|
+
end
|
304
|
+
# verify the required parameter 'folder' is set
|
305
|
+
if @api_client.config.client_side_validation && folder.nil?
|
306
|
+
fail ArgumentError, "Missing the required parameter 'folder' when calling UserApi.initiate_user_file_upload"
|
307
|
+
end
|
308
|
+
# resource path
|
309
|
+
local_var_path = '/api/v1/user/file/{name}/initUpload'.sub('{' + 'name' + '}', CGI.escape(name.to_s))
|
310
|
+
|
311
|
+
# query parameters
|
312
|
+
query_params = opts[:query_params] || {}
|
313
|
+
query_params[:'folder'] = folder
|
314
|
+
|
315
|
+
# header parameters
|
316
|
+
header_params = opts[:header_params] || {}
|
317
|
+
# HTTP header 'Accept' (if needed)
|
318
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
319
|
+
# HTTP header 'Content-Type'
|
320
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
321
|
+
if !content_type.nil?
|
322
|
+
header_params['Content-Type'] = content_type
|
323
|
+
end
|
324
|
+
|
325
|
+
# form parameters
|
326
|
+
form_params = opts[:form_params] || {}
|
327
|
+
|
328
|
+
# http body (model)
|
329
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'file_upload_dto'])
|
330
|
+
|
331
|
+
# return_type
|
332
|
+
return_type = opts[:debug_return_type] || 'InitPutRecordingAudioDTO'
|
333
|
+
|
334
|
+
# auth_names
|
335
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
336
|
+
|
337
|
+
new_options = opts.merge(
|
338
|
+
:operation => :"UserApi.initiate_user_file_upload",
|
339
|
+
:header_params => header_params,
|
340
|
+
:query_params => query_params,
|
341
|
+
:form_params => form_params,
|
342
|
+
:body => post_body,
|
343
|
+
:auth_names => auth_names,
|
344
|
+
:return_type => return_type
|
345
|
+
)
|
346
|
+
|
347
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
348
|
+
if @api_client.config.debugging
|
349
|
+
@api_client.config.logger.debug "API called: UserApi#initiate_user_file_upload\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
350
|
+
end
|
351
|
+
return data, status_code, headers
|
352
|
+
end
|
353
|
+
|
354
|
+
# Login to generate a bearer token.
|
355
|
+
# @param login_dto [LoginDTO]
|
356
|
+
# @param [Hash] opts the optional parameters
|
357
|
+
# @return [JwtTokenDTO]
|
358
|
+
def login(login_dto, opts = {})
|
359
|
+
data, _status_code, _headers = login_with_http_info(login_dto, opts)
|
360
|
+
data
|
361
|
+
end
|
362
|
+
|
363
|
+
# Login to generate a bearer token.
|
364
|
+
# @param login_dto [LoginDTO]
|
365
|
+
# @param [Hash] opts the optional parameters
|
366
|
+
# @return [Array<(JwtTokenDTO, Integer, Hash)>] JwtTokenDTO data, response status code and response headers
|
367
|
+
def login_with_http_info(login_dto, opts = {})
|
368
|
+
if @api_client.config.debugging
|
369
|
+
@api_client.config.logger.debug 'Calling API: UserApi.login ...'
|
370
|
+
end
|
371
|
+
# verify the required parameter 'login_dto' is set
|
372
|
+
if @api_client.config.client_side_validation && login_dto.nil?
|
373
|
+
fail ArgumentError, "Missing the required parameter 'login_dto' when calling UserApi.login"
|
374
|
+
end
|
375
|
+
# resource path
|
376
|
+
local_var_path = '/api/v1/user/login'
|
377
|
+
|
378
|
+
# query parameters
|
379
|
+
query_params = opts[:query_params] || {}
|
380
|
+
|
381
|
+
# header parameters
|
382
|
+
header_params = opts[:header_params] || {}
|
383
|
+
# HTTP header 'Accept' (if needed)
|
384
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
385
|
+
# HTTP header 'Content-Type'
|
386
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
387
|
+
if !content_type.nil?
|
388
|
+
header_params['Content-Type'] = content_type
|
389
|
+
end
|
390
|
+
|
391
|
+
# form parameters
|
392
|
+
form_params = opts[:form_params] || {}
|
393
|
+
|
394
|
+
# http body (model)
|
395
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(login_dto)
|
396
|
+
|
397
|
+
# return_type
|
398
|
+
return_type = opts[:debug_return_type] || 'JwtTokenDTO'
|
399
|
+
|
400
|
+
# auth_names
|
401
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
402
|
+
|
403
|
+
new_options = opts.merge(
|
404
|
+
:operation => :"UserApi.login",
|
405
|
+
:header_params => header_params,
|
406
|
+
:query_params => query_params,
|
407
|
+
:form_params => form_params,
|
408
|
+
:body => post_body,
|
409
|
+
:auth_names => auth_names,
|
410
|
+
:return_type => return_type
|
411
|
+
)
|
412
|
+
|
413
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
414
|
+
if @api_client.config.debugging
|
415
|
+
@api_client.config.logger.debug "API called: UserApi#login\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
416
|
+
end
|
417
|
+
return data, status_code, headers
|
418
|
+
end
|
419
|
+
|
420
|
+
# Details for a logged-in user
|
421
|
+
# @param [Hash] opts the optional parameters
|
422
|
+
# @return [UserDTO]
|
423
|
+
def me(opts = {})
|
424
|
+
data, _status_code, _headers = me_with_http_info(opts)
|
425
|
+
data
|
426
|
+
end
|
427
|
+
|
428
|
+
# Details for a logged-in user
|
429
|
+
# @param [Hash] opts the optional parameters
|
430
|
+
# @return [Array<(UserDTO, Integer, Hash)>] UserDTO data, response status code and response headers
|
431
|
+
def me_with_http_info(opts = {})
|
432
|
+
if @api_client.config.debugging
|
433
|
+
@api_client.config.logger.debug 'Calling API: UserApi.me ...'
|
434
|
+
end
|
435
|
+
# resource path
|
436
|
+
local_var_path = '/api/v1/user/me'
|
437
|
+
|
438
|
+
# query parameters
|
439
|
+
query_params = opts[:query_params] || {}
|
440
|
+
|
441
|
+
# header parameters
|
442
|
+
header_params = opts[:header_params] || {}
|
443
|
+
# HTTP header 'Accept' (if needed)
|
444
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
445
|
+
|
446
|
+
# form parameters
|
447
|
+
form_params = opts[:form_params] || {}
|
448
|
+
|
449
|
+
# http body (model)
|
450
|
+
post_body = opts[:debug_body]
|
451
|
+
|
452
|
+
# return_type
|
453
|
+
return_type = opts[:debug_return_type] || 'UserDTO'
|
454
|
+
|
455
|
+
# auth_names
|
456
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
457
|
+
|
458
|
+
new_options = opts.merge(
|
459
|
+
:operation => :"UserApi.me",
|
460
|
+
:header_params => header_params,
|
461
|
+
:query_params => query_params,
|
462
|
+
:form_params => form_params,
|
463
|
+
:body => post_body,
|
464
|
+
:auth_names => auth_names,
|
465
|
+
:return_type => return_type
|
466
|
+
)
|
467
|
+
|
468
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
469
|
+
if @api_client.config.debugging
|
470
|
+
@api_client.config.logger.debug "API called: UserApi#me\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
471
|
+
end
|
472
|
+
return data, status_code, headers
|
473
|
+
end
|
474
|
+
|
475
|
+
# Timeseries of AI generated moods, musical features and more for recordings in your folder.
|
476
|
+
# @param folder_name [String] Folder name
|
477
|
+
# @param [Hash] opts the optional parameters
|
478
|
+
# @option opts [String] :category_name Show only taggrams for one category.
|
479
|
+
# @option opts [String] :tag_name Show only taggrams for one tag.
|
480
|
+
# @option opts [String] :genre_name Show only taggrams for one genre.
|
481
|
+
# @option opts [Float] :from_timestamp Show only taggrams data starting from from this timestamp in seconds.
|
482
|
+
# @option opts [Boolean] :fill_with_zero If set to true, empty timeseries are filled with timeseries of 0.0 values.
|
483
|
+
# @option opts [Integer] :page Zero-based page index (0..N) (default to 0)
|
484
|
+
# @option opts [Integer] :size The size of the page to be returned (default to 20)
|
485
|
+
# @option opts [Array<String>] :sort Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
|
486
|
+
# @return [Array<RecordingMinimalWithTaggramsDTO>]
|
487
|
+
def recordings_by_folder_with_taggrams(folder_name, opts = {})
|
488
|
+
data, _status_code, _headers = recordings_by_folder_with_taggrams_with_http_info(folder_name, opts)
|
489
|
+
data
|
490
|
+
end
|
491
|
+
|
492
|
+
# Timeseries of AI generated moods, musical features and more for recordings in your folder.
|
493
|
+
# @param folder_name [String] Folder name
|
494
|
+
# @param [Hash] opts the optional parameters
|
495
|
+
# @option opts [String] :category_name Show only taggrams for one category.
|
496
|
+
# @option opts [String] :tag_name Show only taggrams for one tag.
|
497
|
+
# @option opts [String] :genre_name Show only taggrams for one genre.
|
498
|
+
# @option opts [Float] :from_timestamp Show only taggrams data starting from from this timestamp in seconds.
|
499
|
+
# @option opts [Boolean] :fill_with_zero If set to true, empty timeseries are filled with timeseries of 0.0 values.
|
500
|
+
# @option opts [Integer] :page Zero-based page index (0..N) (default to 0)
|
501
|
+
# @option opts [Integer] :size The size of the page to be returned (default to 20)
|
502
|
+
# @option opts [Array<String>] :sort Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
|
503
|
+
# @return [Array<(Array<RecordingMinimalWithTaggramsDTO>, Integer, Hash)>] Array<RecordingMinimalWithTaggramsDTO> data, response status code and response headers
|
504
|
+
def recordings_by_folder_with_taggrams_with_http_info(folder_name, opts = {})
|
505
|
+
if @api_client.config.debugging
|
506
|
+
@api_client.config.logger.debug 'Calling API: UserApi.recordings_by_folder_with_taggrams ...'
|
507
|
+
end
|
508
|
+
# verify the required parameter 'folder_name' is set
|
509
|
+
if @api_client.config.client_side_validation && folder_name.nil?
|
510
|
+
fail ArgumentError, "Missing the required parameter 'folder_name' when calling UserApi.recordings_by_folder_with_taggrams"
|
511
|
+
end
|
512
|
+
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"]
|
513
|
+
if @api_client.config.client_side_validation && opts[:'category_name'] && !allowable_values.include?(opts[:'category_name'])
|
514
|
+
fail ArgumentError, "invalid value for \"category_name\", must be one of #{allowable_values}"
|
515
|
+
end
|
516
|
+
# resource path
|
517
|
+
local_var_path = '/api/v1/user/folder/{folderName}/taggrams'.sub('{' + 'folderName' + '}', CGI.escape(folder_name.to_s))
|
518
|
+
|
519
|
+
# query parameters
|
520
|
+
query_params = opts[:query_params] || {}
|
521
|
+
query_params[:'categoryName'] = opts[:'category_name'] if !opts[:'category_name'].nil?
|
522
|
+
query_params[:'tagName'] = opts[:'tag_name'] if !opts[:'tag_name'].nil?
|
523
|
+
query_params[:'genreName'] = opts[:'genre_name'] if !opts[:'genre_name'].nil?
|
524
|
+
query_params[:'fromTimestamp'] = opts[:'from_timestamp'] if !opts[:'from_timestamp'].nil?
|
525
|
+
query_params[:'fillWithZero'] = opts[:'fill_with_zero'] if !opts[:'fill_with_zero'].nil?
|
526
|
+
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
527
|
+
query_params[:'size'] = opts[:'size'] if !opts[:'size'].nil?
|
528
|
+
query_params[:'sort'] = @api_client.build_collection_param(opts[:'sort'], :multi) if !opts[:'sort'].nil?
|
529
|
+
|
530
|
+
# header parameters
|
531
|
+
header_params = opts[:header_params] || {}
|
532
|
+
# HTTP header 'Accept' (if needed)
|
533
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
534
|
+
|
535
|
+
# form parameters
|
536
|
+
form_params = opts[:form_params] || {}
|
537
|
+
|
538
|
+
# http body (model)
|
539
|
+
post_body = opts[:debug_body]
|
540
|
+
|
541
|
+
# return_type
|
542
|
+
return_type = opts[:debug_return_type] || 'Array<RecordingMinimalWithTaggramsDTO>'
|
543
|
+
|
544
|
+
# auth_names
|
545
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
546
|
+
|
547
|
+
new_options = opts.merge(
|
548
|
+
:operation => :"UserApi.recordings_by_folder_with_taggrams",
|
549
|
+
:header_params => header_params,
|
550
|
+
:query_params => query_params,
|
551
|
+
:form_params => form_params,
|
552
|
+
:body => post_body,
|
553
|
+
:auth_names => auth_names,
|
554
|
+
:return_type => return_type
|
555
|
+
)
|
556
|
+
|
557
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
558
|
+
if @api_client.config.debugging
|
559
|
+
@api_client.config.logger.debug "API called: UserApi#recordings_by_folder_with_taggrams\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
560
|
+
end
|
561
|
+
return data, status_code, headers
|
562
|
+
end
|
563
|
+
|
564
|
+
# Strengths as numerical representations for AI generated moods, musical features and more for recordings in your folder.
|
565
|
+
# @param folder_name [String] Folder name
|
566
|
+
# @param [Hash] opts the optional parameters
|
567
|
+
# @option opts [String] :category_name Show only taggrams for one category.
|
568
|
+
# @option opts [String] :tag_name Show only taggrams for one tag.
|
569
|
+
# @option opts [String] :genre_name Show only taggrams for one genre.
|
570
|
+
# @option opts [Integer] :page Zero-based page index (0..N) (default to 0)
|
571
|
+
# @option opts [Integer] :size The size of the page to be returned (default to 20)
|
572
|
+
# @option opts [Array<String>] :sort Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
|
573
|
+
# @return [Array<RecordingMinimalWithTagstrengthsDTO>]
|
574
|
+
def recordings_by_folder_with_tagstrengths(folder_name, opts = {})
|
575
|
+
data, _status_code, _headers = recordings_by_folder_with_tagstrengths_with_http_info(folder_name, opts)
|
576
|
+
data
|
577
|
+
end
|
578
|
+
|
579
|
+
# Strengths as numerical representations for AI generated moods, musical features and more for recordings in your folder.
|
580
|
+
# @param folder_name [String] Folder name
|
581
|
+
# @param [Hash] opts the optional parameters
|
582
|
+
# @option opts [String] :category_name Show only taggrams for one category.
|
583
|
+
# @option opts [String] :tag_name Show only taggrams for one tag.
|
584
|
+
# @option opts [String] :genre_name Show only taggrams for one genre.
|
585
|
+
# @option opts [Integer] :page Zero-based page index (0..N) (default to 0)
|
586
|
+
# @option opts [Integer] :size The size of the page to be returned (default to 20)
|
587
|
+
# @option opts [Array<String>] :sort Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
|
588
|
+
# @return [Array<(Array<RecordingMinimalWithTagstrengthsDTO>, Integer, Hash)>] Array<RecordingMinimalWithTagstrengthsDTO> data, response status code and response headers
|
589
|
+
def recordings_by_folder_with_tagstrengths_with_http_info(folder_name, opts = {})
|
590
|
+
if @api_client.config.debugging
|
591
|
+
@api_client.config.logger.debug 'Calling API: UserApi.recordings_by_folder_with_tagstrengths ...'
|
592
|
+
end
|
593
|
+
# verify the required parameter 'folder_name' is set
|
594
|
+
if @api_client.config.client_side_validation && folder_name.nil?
|
595
|
+
fail ArgumentError, "Missing the required parameter 'folder_name' when calling UserApi.recordings_by_folder_with_tagstrengths"
|
596
|
+
end
|
597
|
+
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"]
|
598
|
+
if @api_client.config.client_side_validation && opts[:'category_name'] && !allowable_values.include?(opts[:'category_name'])
|
599
|
+
fail ArgumentError, "invalid value for \"category_name\", must be one of #{allowable_values}"
|
600
|
+
end
|
601
|
+
# resource path
|
602
|
+
local_var_path = '/api/v1/user/folder/{folderName}/tagstrengths'.sub('{' + 'folderName' + '}', CGI.escape(folder_name.to_s))
|
603
|
+
|
604
|
+
# query parameters
|
605
|
+
query_params = opts[:query_params] || {}
|
606
|
+
query_params[:'categoryName'] = opts[:'category_name'] if !opts[:'category_name'].nil?
|
607
|
+
query_params[:'tagName'] = opts[:'tag_name'] if !opts[:'tag_name'].nil?
|
608
|
+
query_params[:'genreName'] = opts[:'genre_name'] if !opts[:'genre_name'].nil?
|
609
|
+
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
610
|
+
query_params[:'size'] = opts[:'size'] if !opts[:'size'].nil?
|
611
|
+
query_params[:'sort'] = @api_client.build_collection_param(opts[:'sort'], :multi) if !opts[:'sort'].nil?
|
612
|
+
|
613
|
+
# header parameters
|
614
|
+
header_params = opts[:header_params] || {}
|
615
|
+
# HTTP header 'Accept' (if needed)
|
616
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
617
|
+
|
618
|
+
# form parameters
|
619
|
+
form_params = opts[:form_params] || {}
|
620
|
+
|
621
|
+
# http body (model)
|
622
|
+
post_body = opts[:debug_body]
|
623
|
+
|
624
|
+
# return_type
|
625
|
+
return_type = opts[:debug_return_type] || 'Array<RecordingMinimalWithTagstrengthsDTO>'
|
626
|
+
|
627
|
+
# auth_names
|
628
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
629
|
+
|
630
|
+
new_options = opts.merge(
|
631
|
+
:operation => :"UserApi.recordings_by_folder_with_tagstrengths",
|
632
|
+
:header_params => header_params,
|
633
|
+
:query_params => query_params,
|
634
|
+
:form_params => form_params,
|
635
|
+
:body => post_body,
|
636
|
+
:auth_names => auth_names,
|
637
|
+
:return_type => return_type
|
638
|
+
)
|
639
|
+
|
640
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
641
|
+
if @api_client.config.debugging
|
642
|
+
@api_client.config.logger.debug "API called: UserApi#recordings_by_folder_with_tagstrengths\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
643
|
+
end
|
644
|
+
return data, status_code, headers
|
645
|
+
end
|
646
|
+
|
647
|
+
# List, search and create playlist of your own files.
|
648
|
+
# @param [Hash] opts the optional parameters
|
649
|
+
# @option opts [String] :isrc Search for a ISRC
|
650
|
+
# @option opts [String] :contributor Search for a name that was involved as any contributor.
|
651
|
+
# @option opts [String] :main_artist Search for a main artist.
|
652
|
+
# @option opts [String] :composer Search for a composer.
|
653
|
+
# @option opts [String] :title Search for a title.
|
654
|
+
# @option opts [String] :language Search for a language of the lyrics.
|
655
|
+
# @option opts [Array<String>] :genre_names
|
656
|
+
# @option opts [Array<String>] :tag_names
|
657
|
+
# @option opts [Time] :release_date
|
658
|
+
# @option opts [String] :primary_mood_cluster
|
659
|
+
# @option opts [String] :secondary_mood_cluster
|
660
|
+
# @option opts [String] :tertiary_mood_cluster
|
661
|
+
# @option opts [String] :valence
|
662
|
+
# @option opts [String] :arousal
|
663
|
+
# @option opts [String] :pleasantness
|
664
|
+
# @option opts [String] :engagement
|
665
|
+
# @option opts [String] :vocals
|
666
|
+
# @option opts [String] :dominant_instrument
|
667
|
+
# @option opts [String] :secondary_instrument
|
668
|
+
# @option opts [String] :tertiary_instrument
|
669
|
+
# @option opts [String] :energy
|
670
|
+
# @option opts [String] :sound_generation
|
671
|
+
# @option opts [String] :tempo
|
672
|
+
# @option opts [String] :scale
|
673
|
+
# @option opts [String] :rhythm
|
674
|
+
# @option opts [String] :primary_sound_character
|
675
|
+
# @option opts [String] :timbre
|
676
|
+
# @option opts [String] :roughness
|
677
|
+
# @option opts [String] :tonality
|
678
|
+
# @option opts [String] :harmony
|
679
|
+
# @option opts [String] :texture
|
680
|
+
# @option opts [String] :groovyness
|
681
|
+
# @option opts [String] :space
|
682
|
+
# @option opts [String] :production_rating
|
683
|
+
# @option opts [String] :performance_rating
|
684
|
+
# @option opts [String] :song_rating
|
685
|
+
# @option opts [String] :audience_age
|
686
|
+
# @option opts [String] :audience_region
|
687
|
+
# @option opts [String] :audience_gender
|
688
|
+
# @option opts [String] :origin_decade
|
689
|
+
# @option opts [String] :curateability
|
690
|
+
# @option opts [String] :use_case
|
691
|
+
# @option opts [String] :channel_suitability
|
692
|
+
# @option opts [String] :similar_to_recording
|
693
|
+
# @option opts [String] :create_playlist_with_name
|
694
|
+
# @option opts [String] :songtradr_track_id
|
695
|
+
# @option opts [String] :usage_name
|
696
|
+
# @option opts [Integer] :bpm_min Search for a minimal bpm.
|
697
|
+
# @option opts [Integer] :bpm_max Search for a maximal bpm.
|
698
|
+
# @option opts [String] :name Search for a file name.
|
699
|
+
# @option opts [String] :folder Search for a folder.
|
700
|
+
# @option opts [String] :extension Search for a file extension.
|
701
|
+
# @option opts [Time] :upload_end_time
|
702
|
+
# @option opts [Time] :min_upload_end_time
|
703
|
+
# @option opts [Time] :max_upload_end_time
|
704
|
+
# @option opts [String] :fingerprint_status Search for a fingerprint status.
|
705
|
+
# @option opts [String] :inference_status Search for a inference status.
|
706
|
+
# @option opts [Integer] :page Zero-based page index (0..N) (default to 0)
|
707
|
+
# @option opts [Integer] :size The size of the page to be returned (default to 100)
|
708
|
+
# @option opts [Array<String>] :sort Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
|
709
|
+
# @return [FileListDTO]
|
710
|
+
def save_playlist(opts = {})
|
711
|
+
data, _status_code, _headers = save_playlist_with_http_info(opts)
|
712
|
+
data
|
713
|
+
end
|
714
|
+
|
715
|
+
# List, search and create playlist of your own files.
|
716
|
+
# @param [Hash] opts the optional parameters
|
717
|
+
# @option opts [String] :isrc Search for a ISRC
|
718
|
+
# @option opts [String] :contributor Search for a name that was involved as any contributor.
|
719
|
+
# @option opts [String] :main_artist Search for a main artist.
|
720
|
+
# @option opts [String] :composer Search for a composer.
|
721
|
+
# @option opts [String] :title Search for a title.
|
722
|
+
# @option opts [String] :language Search for a language of the lyrics.
|
723
|
+
# @option opts [Array<String>] :genre_names
|
724
|
+
# @option opts [Array<String>] :tag_names
|
725
|
+
# @option opts [Time] :release_date
|
726
|
+
# @option opts [String] :primary_mood_cluster
|
727
|
+
# @option opts [String] :secondary_mood_cluster
|
728
|
+
# @option opts [String] :tertiary_mood_cluster
|
729
|
+
# @option opts [String] :valence
|
730
|
+
# @option opts [String] :arousal
|
731
|
+
# @option opts [String] :pleasantness
|
732
|
+
# @option opts [String] :engagement
|
733
|
+
# @option opts [String] :vocals
|
734
|
+
# @option opts [String] :dominant_instrument
|
735
|
+
# @option opts [String] :secondary_instrument
|
736
|
+
# @option opts [String] :tertiary_instrument
|
737
|
+
# @option opts [String] :energy
|
738
|
+
# @option opts [String] :sound_generation
|
739
|
+
# @option opts [String] :tempo
|
740
|
+
# @option opts [String] :scale
|
741
|
+
# @option opts [String] :rhythm
|
742
|
+
# @option opts [String] :primary_sound_character
|
743
|
+
# @option opts [String] :timbre
|
744
|
+
# @option opts [String] :roughness
|
745
|
+
# @option opts [String] :tonality
|
746
|
+
# @option opts [String] :harmony
|
747
|
+
# @option opts [String] :texture
|
748
|
+
# @option opts [String] :groovyness
|
749
|
+
# @option opts [String] :space
|
750
|
+
# @option opts [String] :production_rating
|
751
|
+
# @option opts [String] :performance_rating
|
752
|
+
# @option opts [String] :song_rating
|
753
|
+
# @option opts [String] :audience_age
|
754
|
+
# @option opts [String] :audience_region
|
755
|
+
# @option opts [String] :audience_gender
|
756
|
+
# @option opts [String] :origin_decade
|
757
|
+
# @option opts [String] :curateability
|
758
|
+
# @option opts [String] :use_case
|
759
|
+
# @option opts [String] :channel_suitability
|
760
|
+
# @option opts [String] :similar_to_recording
|
761
|
+
# @option opts [String] :create_playlist_with_name
|
762
|
+
# @option opts [String] :songtradr_track_id
|
763
|
+
# @option opts [String] :usage_name
|
764
|
+
# @option opts [Integer] :bpm_min Search for a minimal bpm.
|
765
|
+
# @option opts [Integer] :bpm_max Search for a maximal bpm.
|
766
|
+
# @option opts [String] :name Search for a file name.
|
767
|
+
# @option opts [String] :folder Search for a folder.
|
768
|
+
# @option opts [String] :extension Search for a file extension.
|
769
|
+
# @option opts [Time] :upload_end_time
|
770
|
+
# @option opts [Time] :min_upload_end_time
|
771
|
+
# @option opts [Time] :max_upload_end_time
|
772
|
+
# @option opts [String] :fingerprint_status Search for a fingerprint status.
|
773
|
+
# @option opts [String] :inference_status Search for a inference status.
|
774
|
+
# @option opts [Integer] :page Zero-based page index (0..N) (default to 0)
|
775
|
+
# @option opts [Integer] :size The size of the page to be returned (default to 100)
|
776
|
+
# @option opts [Array<String>] :sort Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
|
777
|
+
# @return [Array<(FileListDTO, Integer, Hash)>] FileListDTO data, response status code and response headers
|
778
|
+
def save_playlist_with_http_info(opts = {})
|
779
|
+
if @api_client.config.debugging
|
780
|
+
@api_client.config.logger.debug 'Calling API: UserApi.save_playlist ...'
|
781
|
+
end
|
782
|
+
allowable_values = ["en", "es", "fr", "de", "jp", "cn", "IT", "RU"]
|
783
|
+
if @api_client.config.client_side_validation && opts[:'language'] && !allowable_values.include?(opts[:'language'])
|
784
|
+
fail ArgumentError, "invalid value for \"language\", must be one of #{allowable_values}"
|
785
|
+
end
|
786
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
787
|
+
if @api_client.config.client_side_validation && opts[:'primary_mood_cluster'] && !allowable_values.include?(opts[:'primary_mood_cluster'])
|
788
|
+
fail ArgumentError, "invalid value for \"primary_mood_cluster\", must be one of #{allowable_values}"
|
789
|
+
end
|
790
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
791
|
+
if @api_client.config.client_side_validation && opts[:'secondary_mood_cluster'] && !allowable_values.include?(opts[:'secondary_mood_cluster'])
|
792
|
+
fail ArgumentError, "invalid value for \"secondary_mood_cluster\", must be one of #{allowable_values}"
|
793
|
+
end
|
794
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
795
|
+
if @api_client.config.client_side_validation && opts[:'tertiary_mood_cluster'] && !allowable_values.include?(opts[:'tertiary_mood_cluster'])
|
796
|
+
fail ArgumentError, "invalid value for \"tertiary_mood_cluster\", must be one of #{allowable_values}"
|
797
|
+
end
|
798
|
+
allowable_values = ["very sad", "sad", "moderate valence", "positive", "very positive", "varying valence"]
|
799
|
+
if @api_client.config.client_side_validation && opts[:'valence'] && !allowable_values.include?(opts[:'valence'])
|
800
|
+
fail ArgumentError, "invalid value for \"valence\", must be one of #{allowable_values}"
|
801
|
+
end
|
802
|
+
allowable_values = ["very calm", "calm", "moderate arousal", "energetic", "very energetic", "varying arousal"]
|
803
|
+
if @api_client.config.client_side_validation && opts[:'arousal'] && !allowable_values.include?(opts[:'arousal'])
|
804
|
+
fail ArgumentError, "invalid value for \"arousal\", must be one of #{allowable_values}"
|
805
|
+
end
|
806
|
+
allowable_values = ["very unpleasant", "unpleasant", "neutral pleasantness", "pleasant", "very pleasant", "varying pleasantness"]
|
807
|
+
if @api_client.config.client_side_validation && opts[:'pleasantness'] && !allowable_values.include?(opts[:'pleasantness'])
|
808
|
+
fail ArgumentError, "invalid value for \"pleasantness\", must be one of #{allowable_values}"
|
809
|
+
end
|
810
|
+
allowable_values = ["very unengaging", "unengaging", "neutral engagement", "engaging", "very engaging", "varying engagement"]
|
811
|
+
if @api_client.config.client_side_validation && opts[:'engagement'] && !allowable_values.include?(opts[:'engagement'])
|
812
|
+
fail ArgumentError, "invalid value for \"engagement\", must be one of #{allowable_values}"
|
813
|
+
end
|
814
|
+
allowable_values = ["instrumental", "female vocals", "male vocals", "mixed vocals", "diverse gender vocals"]
|
815
|
+
if @api_client.config.client_side_validation && opts[:'vocals'] && !allowable_values.include?(opts[:'vocals'])
|
816
|
+
fail ArgumentError, "invalid value for \"vocals\", must be one of #{allowable_values}"
|
817
|
+
end
|
818
|
+
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"]
|
819
|
+
if @api_client.config.client_side_validation && opts[:'dominant_instrument'] && !allowable_values.include?(opts[:'dominant_instrument'])
|
820
|
+
fail ArgumentError, "invalid value for \"dominant_instrument\", must be one of #{allowable_values}"
|
821
|
+
end
|
822
|
+
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"]
|
823
|
+
if @api_client.config.client_side_validation && opts[:'secondary_instrument'] && !allowable_values.include?(opts[:'secondary_instrument'])
|
824
|
+
fail ArgumentError, "invalid value for \"secondary_instrument\", must be one of #{allowable_values}"
|
825
|
+
end
|
826
|
+
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"]
|
827
|
+
if @api_client.config.client_side_validation && opts[:'tertiary_instrument'] && !allowable_values.include?(opts[:'tertiary_instrument'])
|
828
|
+
fail ArgumentError, "invalid value for \"tertiary_instrument\", must be one of #{allowable_values}"
|
829
|
+
end
|
830
|
+
allowable_values = ["very quiet", "quiet", "moderate", "loud", "very loud", "dynamic"]
|
831
|
+
if @api_client.config.client_side_validation && opts[:'energy'] && !allowable_values.include?(opts[:'energy'])
|
832
|
+
fail ArgumentError, "invalid value for \"energy\", must be one of #{allowable_values}"
|
833
|
+
end
|
834
|
+
allowable_values = ["acoustic", "electric", "electronic", "mixed sound generation"]
|
835
|
+
if @api_client.config.client_side_validation && opts[:'sound_generation'] && !allowable_values.include?(opts[:'sound_generation'])
|
836
|
+
fail ArgumentError, "invalid value for \"sound_generation\", must be one of #{allowable_values}"
|
837
|
+
end
|
838
|
+
allowable_values = ["very slow", "slow", "mid-tempo", "fast", "very fast", "varying tempo"]
|
839
|
+
if @api_client.config.client_side_validation && opts[:'tempo'] && !allowable_values.include?(opts[:'tempo'])
|
840
|
+
fail ArgumentError, "invalid value for \"tempo\", must be one of #{allowable_values}"
|
841
|
+
end
|
842
|
+
allowable_values = ["major key", "minor key", "neutral key"]
|
843
|
+
if @api_client.config.client_side_validation && opts[:'scale'] && !allowable_values.include?(opts[:'scale'])
|
844
|
+
fail ArgumentError, "invalid value for \"scale\", must be one of #{allowable_values}"
|
845
|
+
end
|
846
|
+
allowable_values = ["common time", "triple meter", "complex time signature", "binary rhythm", "ternary rhythm"]
|
847
|
+
if @api_client.config.client_side_validation && opts[:'rhythm'] && !allowable_values.include?(opts[:'rhythm'])
|
848
|
+
fail ArgumentError, "invalid value for \"rhythm\", must be one of #{allowable_values}"
|
849
|
+
end
|
850
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
851
|
+
if @api_client.config.client_side_validation && opts[:'primary_sound_character'] && !allowable_values.include?(opts[:'primary_sound_character'])
|
852
|
+
fail ArgumentError, "invalid value for \"primary_sound_character\", must be one of #{allowable_values}"
|
853
|
+
end
|
854
|
+
allowable_values = ["very warm", "warm", "moderate timbre", "bright", "very bright"]
|
855
|
+
if @api_client.config.client_side_validation && opts[:'timbre'] && !allowable_values.include?(opts[:'timbre'])
|
856
|
+
fail ArgumentError, "invalid value for \"timbre\", must be one of #{allowable_values}"
|
857
|
+
end
|
858
|
+
allowable_values = ["very clear", "clear", "moderate roughness", "distorted", "very distorted"]
|
859
|
+
if @api_client.config.client_side_validation && opts[:'roughness'] && !allowable_values.include?(opts[:'roughness'])
|
860
|
+
fail ArgumentError, "invalid value for \"roughness\", must be one of #{allowable_values}"
|
861
|
+
end
|
862
|
+
allowable_values = ["monotonous", "moderate melodiousness", "melodious", "atonal"]
|
863
|
+
if @api_client.config.client_side_validation && opts[:'tonality'] && !allowable_values.include?(opts[:'tonality'])
|
864
|
+
fail ArgumentError, "invalid value for \"tonality\", must be one of #{allowable_values}"
|
865
|
+
end
|
866
|
+
allowable_values = ["very dissonant", "dissonant", "moderate harmonies", "harmonious", "very harmonious"]
|
867
|
+
if @api_client.config.client_side_validation && opts[:'harmony'] && !allowable_values.include?(opts[:'harmony'])
|
868
|
+
fail ArgumentError, "invalid value for \"harmony\", must be one of #{allowable_values}"
|
869
|
+
end
|
870
|
+
allowable_values = ["very thin", "thin", "moderate texture", "full", "very full"]
|
871
|
+
if @api_client.config.client_side_validation && opts[:'texture'] && !allowable_values.include?(opts[:'texture'])
|
872
|
+
fail ArgumentError, "invalid value for \"texture\", must be one of #{allowable_values}"
|
873
|
+
end
|
874
|
+
allowable_values = ["very steady", "steady", "moderate rhythm feel", "groovy", "very groovy"]
|
875
|
+
if @api_client.config.client_side_validation && opts[:'groovyness'] && !allowable_values.include?(opts[:'groovyness'])
|
876
|
+
fail ArgumentError, "invalid value for \"groovyness\", must be one of #{allowable_values}"
|
877
|
+
end
|
878
|
+
allowable_values = ["very compact", "compact", "moderate space", "wide", "very wide"]
|
879
|
+
if @api_client.config.client_side_validation && opts[:'space'] && !allowable_values.include?(opts[:'space'])
|
880
|
+
fail ArgumentError, "invalid value for \"space\", must be one of #{allowable_values}"
|
881
|
+
end
|
882
|
+
allowable_values = ["low production quality", "medium production quality", "high production quality"]
|
883
|
+
if @api_client.config.client_side_validation && opts[:'production_rating'] && !allowable_values.include?(opts[:'production_rating'])
|
884
|
+
fail ArgumentError, "invalid value for \"production_rating\", must be one of #{allowable_values}"
|
885
|
+
end
|
886
|
+
allowable_values = ["low performance quality", "medium performance quality", "high performance quality"]
|
887
|
+
if @api_client.config.client_side_validation && opts[:'performance_rating'] && !allowable_values.include?(opts[:'performance_rating'])
|
888
|
+
fail ArgumentError, "invalid value for \"performance_rating\", must be one of #{allowable_values}"
|
889
|
+
end
|
890
|
+
allowable_values = ["low song quality", "medium song quality", "high song quality"]
|
891
|
+
if @api_client.config.client_side_validation && opts[:'song_rating'] && !allowable_values.include?(opts[:'song_rating'])
|
892
|
+
fail ArgumentError, "invalid value for \"song_rating\", must be one of #{allowable_values}"
|
893
|
+
end
|
894
|
+
allowable_values = ["Generation Z", "Younger Generation Y", "Older Generation Y", "Generation X", "Younger Generation B", "Older Generation B"]
|
895
|
+
if @api_client.config.client_side_validation && opts[:'audience_age'] && !allowable_values.include?(opts[:'audience_age'])
|
896
|
+
fail ArgumentError, "invalid value for \"audience_age\", must be one of #{allowable_values}"
|
897
|
+
end
|
898
|
+
allowable_values = ["Australia and New Zealand", "Central America and the Carribean", "Central and Southern Asia", "Eastern Asia", "Eastern Europe", "Northern Africa and Western Asia", "Northern America", "Oceania", "South America", "South-Eastern Asia", "Southern Europe", "Sub-Saharan Africa", "Western and Northern Europe"]
|
899
|
+
if @api_client.config.client_side_validation && opts[:'audience_region'] && !allowable_values.include?(opts[:'audience_region'])
|
900
|
+
fail ArgumentError, "invalid value for \"audience_region\", must be one of #{allowable_values}"
|
901
|
+
end
|
902
|
+
allowable_values = ["male", "female"]
|
903
|
+
if @api_client.config.client_side_validation && opts[:'audience_gender'] && !allowable_values.include?(opts[:'audience_gender'])
|
904
|
+
fail ArgumentError, "invalid value for \"audience_gender\", must be one of #{allowable_values}"
|
905
|
+
end
|
906
|
+
allowable_values = ["pre-1950s", "1950s", "1960s", "1970s", "1980s", "1990s", "2000s", "2010s", "2020s"]
|
907
|
+
if @api_client.config.client_side_validation && opts[:'origin_decade'] && !allowable_values.include?(opts[:'origin_decade'])
|
908
|
+
fail ArgumentError, "invalid value for \"origin_decade\", must be one of #{allowable_values}"
|
909
|
+
end
|
910
|
+
allowable_values = ["curateable", "uncurateable"]
|
911
|
+
if @api_client.config.client_side_validation && opts[:'curateability'] && !allowable_values.include?(opts[:'curateability'])
|
912
|
+
fail ArgumentError, "invalid value for \"curateability\", must be one of #{allowable_values}"
|
913
|
+
end
|
914
|
+
allowable_values = ["background", "sport", "focus", "christmas", "film", "summer", "adverts", "party", "relax"]
|
915
|
+
if @api_client.config.client_side_validation && opts[:'use_case'] && !allowable_values.include?(opts[:'use_case'])
|
916
|
+
fail ArgumentError, "invalid value for \"use_case\", must be one of #{allowable_values}"
|
917
|
+
end
|
918
|
+
allowable_values = ["Spotify", "TikTok", "Unfitting", "YouTube"]
|
919
|
+
if @api_client.config.client_side_validation && opts[:'channel_suitability'] && !allowable_values.include?(opts[:'channel_suitability'])
|
920
|
+
fail ArgumentError, "invalid value for \"channel_suitability\", must be one of #{allowable_values}"
|
921
|
+
end
|
922
|
+
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 0
|
923
|
+
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling UserApi.save_playlist, must be greater than or equal to 0.'
|
924
|
+
end
|
925
|
+
|
926
|
+
if @api_client.config.client_side_validation && !opts[:'size'].nil? && opts[:'size'] < 1
|
927
|
+
fail ArgumentError, 'invalid value for "opts[:"size"]" when calling UserApi.save_playlist, must be greater than or equal to 1.'
|
928
|
+
end
|
929
|
+
|
930
|
+
# resource path
|
931
|
+
local_var_path = '/api/v1/user/savePlaylist'
|
932
|
+
|
933
|
+
# query parameters
|
934
|
+
query_params = opts[:query_params] || {}
|
935
|
+
query_params[:'ISRC'] = opts[:'isrc'] if !opts[:'isrc'].nil?
|
936
|
+
query_params[:'contributor'] = opts[:'contributor'] if !opts[:'contributor'].nil?
|
937
|
+
query_params[:'mainArtist'] = opts[:'main_artist'] if !opts[:'main_artist'].nil?
|
938
|
+
query_params[:'composer'] = opts[:'composer'] if !opts[:'composer'].nil?
|
939
|
+
query_params[:'title'] = opts[:'title'] if !opts[:'title'].nil?
|
940
|
+
query_params[:'language'] = opts[:'language'] if !opts[:'language'].nil?
|
941
|
+
query_params[:'genreNames'] = @api_client.build_collection_param(opts[:'genre_names'], :multi) if !opts[:'genre_names'].nil?
|
942
|
+
query_params[:'tagNames'] = @api_client.build_collection_param(opts[:'tag_names'], :multi) if !opts[:'tag_names'].nil?
|
943
|
+
query_params[:'releaseDate'] = opts[:'release_date'] if !opts[:'release_date'].nil?
|
944
|
+
query_params[:'primaryMoodCluster'] = opts[:'primary_mood_cluster'] if !opts[:'primary_mood_cluster'].nil?
|
945
|
+
query_params[:'secondaryMoodCluster'] = opts[:'secondary_mood_cluster'] if !opts[:'secondary_mood_cluster'].nil?
|
946
|
+
query_params[:'tertiaryMoodCluster'] = opts[:'tertiary_mood_cluster'] if !opts[:'tertiary_mood_cluster'].nil?
|
947
|
+
query_params[:'valence'] = opts[:'valence'] if !opts[:'valence'].nil?
|
948
|
+
query_params[:'arousal'] = opts[:'arousal'] if !opts[:'arousal'].nil?
|
949
|
+
query_params[:'pleasantness'] = opts[:'pleasantness'] if !opts[:'pleasantness'].nil?
|
950
|
+
query_params[:'engagement'] = opts[:'engagement'] if !opts[:'engagement'].nil?
|
951
|
+
query_params[:'vocals'] = opts[:'vocals'] if !opts[:'vocals'].nil?
|
952
|
+
query_params[:'dominantInstrument'] = opts[:'dominant_instrument'] if !opts[:'dominant_instrument'].nil?
|
953
|
+
query_params[:'secondaryInstrument'] = opts[:'secondary_instrument'] if !opts[:'secondary_instrument'].nil?
|
954
|
+
query_params[:'tertiaryInstrument'] = opts[:'tertiary_instrument'] if !opts[:'tertiary_instrument'].nil?
|
955
|
+
query_params[:'energy'] = opts[:'energy'] if !opts[:'energy'].nil?
|
956
|
+
query_params[:'soundGeneration'] = opts[:'sound_generation'] if !opts[:'sound_generation'].nil?
|
957
|
+
query_params[:'tempo'] = opts[:'tempo'] if !opts[:'tempo'].nil?
|
958
|
+
query_params[:'scale'] = opts[:'scale'] if !opts[:'scale'].nil?
|
959
|
+
query_params[:'rhythm'] = opts[:'rhythm'] if !opts[:'rhythm'].nil?
|
960
|
+
query_params[:'primarySoundCharacter'] = opts[:'primary_sound_character'] if !opts[:'primary_sound_character'].nil?
|
961
|
+
query_params[:'timbre'] = opts[:'timbre'] if !opts[:'timbre'].nil?
|
962
|
+
query_params[:'roughness'] = opts[:'roughness'] if !opts[:'roughness'].nil?
|
963
|
+
query_params[:'tonality'] = opts[:'tonality'] if !opts[:'tonality'].nil?
|
964
|
+
query_params[:'harmony'] = opts[:'harmony'] if !opts[:'harmony'].nil?
|
965
|
+
query_params[:'texture'] = opts[:'texture'] if !opts[:'texture'].nil?
|
966
|
+
query_params[:'groovyness'] = opts[:'groovyness'] if !opts[:'groovyness'].nil?
|
967
|
+
query_params[:'space'] = opts[:'space'] if !opts[:'space'].nil?
|
968
|
+
query_params[:'productionRating'] = opts[:'production_rating'] if !opts[:'production_rating'].nil?
|
969
|
+
query_params[:'performanceRating'] = opts[:'performance_rating'] if !opts[:'performance_rating'].nil?
|
970
|
+
query_params[:'songRating'] = opts[:'song_rating'] if !opts[:'song_rating'].nil?
|
971
|
+
query_params[:'audienceAge'] = opts[:'audience_age'] if !opts[:'audience_age'].nil?
|
972
|
+
query_params[:'audienceRegion'] = opts[:'audience_region'] if !opts[:'audience_region'].nil?
|
973
|
+
query_params[:'audienceGender'] = opts[:'audience_gender'] if !opts[:'audience_gender'].nil?
|
974
|
+
query_params[:'originDecade'] = opts[:'origin_decade'] if !opts[:'origin_decade'].nil?
|
975
|
+
query_params[:'curateability'] = opts[:'curateability'] if !opts[:'curateability'].nil?
|
976
|
+
query_params[:'useCase'] = opts[:'use_case'] if !opts[:'use_case'].nil?
|
977
|
+
query_params[:'channelSuitability'] = opts[:'channel_suitability'] if !opts[:'channel_suitability'].nil?
|
978
|
+
query_params[:'similarToRecording'] = opts[:'similar_to_recording'] if !opts[:'similar_to_recording'].nil?
|
979
|
+
query_params[:'createPlaylistWithName'] = opts[:'create_playlist_with_name'] if !opts[:'create_playlist_with_name'].nil?
|
980
|
+
query_params[:'songtradrTrackId'] = opts[:'songtradr_track_id'] if !opts[:'songtradr_track_id'].nil?
|
981
|
+
query_params[:'usageName'] = opts[:'usage_name'] if !opts[:'usage_name'].nil?
|
982
|
+
query_params[:'bpmMin'] = opts[:'bpm_min'] if !opts[:'bpm_min'].nil?
|
983
|
+
query_params[:'bpmMax'] = opts[:'bpm_max'] if !opts[:'bpm_max'].nil?
|
984
|
+
query_params[:'name'] = opts[:'name'] if !opts[:'name'].nil?
|
985
|
+
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
986
|
+
query_params[:'extension'] = opts[:'extension'] if !opts[:'extension'].nil?
|
987
|
+
query_params[:'uploadEndTime'] = opts[:'upload_end_time'] if !opts[:'upload_end_time'].nil?
|
988
|
+
query_params[:'minUploadEndTime'] = opts[:'min_upload_end_time'] if !opts[:'min_upload_end_time'].nil?
|
989
|
+
query_params[:'maxUploadEndTime'] = opts[:'max_upload_end_time'] if !opts[:'max_upload_end_time'].nil?
|
990
|
+
query_params[:'fingerprintStatus'] = opts[:'fingerprint_status'] if !opts[:'fingerprint_status'].nil?
|
991
|
+
query_params[:'inferenceStatus'] = opts[:'inference_status'] if !opts[:'inference_status'].nil?
|
992
|
+
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
993
|
+
query_params[:'size'] = opts[:'size'] if !opts[:'size'].nil?
|
994
|
+
query_params[:'sort'] = @api_client.build_collection_param(opts[:'sort'], :multi) if !opts[:'sort'].nil?
|
995
|
+
|
996
|
+
# header parameters
|
997
|
+
header_params = opts[:header_params] || {}
|
998
|
+
# HTTP header 'Accept' (if needed)
|
999
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1000
|
+
|
1001
|
+
# form parameters
|
1002
|
+
form_params = opts[:form_params] || {}
|
1003
|
+
|
1004
|
+
# http body (model)
|
1005
|
+
post_body = opts[:debug_body]
|
1006
|
+
|
1007
|
+
# return_type
|
1008
|
+
return_type = opts[:debug_return_type] || 'FileListDTO'
|
1009
|
+
|
1010
|
+
# auth_names
|
1011
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
1012
|
+
|
1013
|
+
new_options = opts.merge(
|
1014
|
+
:operation => :"UserApi.save_playlist",
|
1015
|
+
:header_params => header_params,
|
1016
|
+
:query_params => query_params,
|
1017
|
+
:form_params => form_params,
|
1018
|
+
:body => post_body,
|
1019
|
+
:auth_names => auth_names,
|
1020
|
+
:return_type => return_type
|
1021
|
+
)
|
1022
|
+
|
1023
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1024
|
+
if @api_client.config.debugging
|
1025
|
+
@api_client.config.logger.debug "API called: UserApi#save_playlist\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1026
|
+
end
|
1027
|
+
return data, status_code, headers
|
1028
|
+
end
|
1029
|
+
|
1030
|
+
# Sign up a new user.
|
1031
|
+
# @param save_user_dto [SaveUserDTO]
|
1032
|
+
# @param [Hash] opts the optional parameters
|
1033
|
+
# @return [SignUpDTO]
|
1034
|
+
def sign_up(save_user_dto, opts = {})
|
1035
|
+
data, _status_code, _headers = sign_up_with_http_info(save_user_dto, opts)
|
1036
|
+
data
|
1037
|
+
end
|
1038
|
+
|
1039
|
+
# Sign up a new user.
|
1040
|
+
# @param save_user_dto [SaveUserDTO]
|
1041
|
+
# @param [Hash] opts the optional parameters
|
1042
|
+
# @return [Array<(SignUpDTO, Integer, Hash)>] SignUpDTO data, response status code and response headers
|
1043
|
+
def sign_up_with_http_info(save_user_dto, opts = {})
|
1044
|
+
if @api_client.config.debugging
|
1045
|
+
@api_client.config.logger.debug 'Calling API: UserApi.sign_up ...'
|
1046
|
+
end
|
1047
|
+
# verify the required parameter 'save_user_dto' is set
|
1048
|
+
if @api_client.config.client_side_validation && save_user_dto.nil?
|
1049
|
+
fail ArgumentError, "Missing the required parameter 'save_user_dto' when calling UserApi.sign_up"
|
1050
|
+
end
|
1051
|
+
# resource path
|
1052
|
+
local_var_path = '/api/v1/user/sign-up'
|
1053
|
+
|
1054
|
+
# query parameters
|
1055
|
+
query_params = opts[:query_params] || {}
|
1056
|
+
|
1057
|
+
# header parameters
|
1058
|
+
header_params = opts[:header_params] || {}
|
1059
|
+
# HTTP header 'Accept' (if needed)
|
1060
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1061
|
+
# HTTP header 'Content-Type'
|
1062
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1063
|
+
if !content_type.nil?
|
1064
|
+
header_params['Content-Type'] = content_type
|
1065
|
+
end
|
1066
|
+
|
1067
|
+
# form parameters
|
1068
|
+
form_params = opts[:form_params] || {}
|
1069
|
+
|
1070
|
+
# http body (model)
|
1071
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(save_user_dto)
|
1072
|
+
|
1073
|
+
# return_type
|
1074
|
+
return_type = opts[:debug_return_type] || 'SignUpDTO'
|
1075
|
+
|
1076
|
+
# auth_names
|
1077
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
1078
|
+
|
1079
|
+
new_options = opts.merge(
|
1080
|
+
:operation => :"UserApi.sign_up",
|
1081
|
+
:header_params => header_params,
|
1082
|
+
:query_params => query_params,
|
1083
|
+
:form_params => form_params,
|
1084
|
+
:body => post_body,
|
1085
|
+
:auth_names => auth_names,
|
1086
|
+
:return_type => return_type
|
1087
|
+
)
|
1088
|
+
|
1089
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1090
|
+
if @api_client.config.debugging
|
1091
|
+
@api_client.config.logger.debug "API called: UserApi#sign_up\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1092
|
+
end
|
1093
|
+
return data, status_code, headers
|
1094
|
+
end
|
1095
|
+
|
1096
|
+
# Generates a new JWT token for the given refresh token
|
1097
|
+
# @param token_request [TokenRequest]
|
1098
|
+
# @param [Hash] opts the optional parameters
|
1099
|
+
# @return [JwtTokenDTO]
|
1100
|
+
def token(token_request, opts = {})
|
1101
|
+
data, _status_code, _headers = token_with_http_info(token_request, opts)
|
1102
|
+
data
|
1103
|
+
end
|
1104
|
+
|
1105
|
+
# Generates a new JWT token for the given refresh token
|
1106
|
+
# @param token_request [TokenRequest]
|
1107
|
+
# @param [Hash] opts the optional parameters
|
1108
|
+
# @return [Array<(JwtTokenDTO, Integer, Hash)>] JwtTokenDTO data, response status code and response headers
|
1109
|
+
def token_with_http_info(token_request, opts = {})
|
1110
|
+
if @api_client.config.debugging
|
1111
|
+
@api_client.config.logger.debug 'Calling API: UserApi.token ...'
|
1112
|
+
end
|
1113
|
+
# verify the required parameter 'token_request' is set
|
1114
|
+
if @api_client.config.client_side_validation && token_request.nil?
|
1115
|
+
fail ArgumentError, "Missing the required parameter 'token_request' when calling UserApi.token"
|
1116
|
+
end
|
1117
|
+
# resource path
|
1118
|
+
local_var_path = '/api/v1/user/token'
|
1119
|
+
|
1120
|
+
# query parameters
|
1121
|
+
query_params = opts[:query_params] || {}
|
1122
|
+
|
1123
|
+
# header parameters
|
1124
|
+
header_params = opts[:header_params] || {}
|
1125
|
+
# HTTP header 'Accept' (if needed)
|
1126
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1127
|
+
# HTTP header 'Content-Type'
|
1128
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1129
|
+
if !content_type.nil?
|
1130
|
+
header_params['Content-Type'] = content_type
|
1131
|
+
end
|
1132
|
+
|
1133
|
+
# form parameters
|
1134
|
+
form_params = opts[:form_params] || {}
|
1135
|
+
|
1136
|
+
# http body (model)
|
1137
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(token_request)
|
1138
|
+
|
1139
|
+
# return_type
|
1140
|
+
return_type = opts[:debug_return_type] || 'JwtTokenDTO'
|
1141
|
+
|
1142
|
+
# auth_names
|
1143
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
1144
|
+
|
1145
|
+
new_options = opts.merge(
|
1146
|
+
:operation => :"UserApi.token",
|
1147
|
+
:header_params => header_params,
|
1148
|
+
:query_params => query_params,
|
1149
|
+
:form_params => form_params,
|
1150
|
+
:body => post_body,
|
1151
|
+
:auth_names => auth_names,
|
1152
|
+
:return_type => return_type
|
1153
|
+
)
|
1154
|
+
|
1155
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1156
|
+
if @api_client.config.debugging
|
1157
|
+
@api_client.config.logger.debug "API called: UserApi#token\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1158
|
+
end
|
1159
|
+
return data, status_code, headers
|
1160
|
+
end
|
1161
|
+
|
1162
|
+
# Update password by using the password reset token
|
1163
|
+
# @param update_password_dto [UpdatePasswordDTO]
|
1164
|
+
# @param [Hash] opts the optional parameters
|
1165
|
+
# @return [Object]
|
1166
|
+
def update_password(update_password_dto, opts = {})
|
1167
|
+
data, _status_code, _headers = update_password_with_http_info(update_password_dto, opts)
|
1168
|
+
data
|
1169
|
+
end
|
1170
|
+
|
1171
|
+
# Update password by using the password reset token
|
1172
|
+
# @param update_password_dto [UpdatePasswordDTO]
|
1173
|
+
# @param [Hash] opts the optional parameters
|
1174
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
1175
|
+
def update_password_with_http_info(update_password_dto, opts = {})
|
1176
|
+
if @api_client.config.debugging
|
1177
|
+
@api_client.config.logger.debug 'Calling API: UserApi.update_password ...'
|
1178
|
+
end
|
1179
|
+
# verify the required parameter 'update_password_dto' is set
|
1180
|
+
if @api_client.config.client_side_validation && update_password_dto.nil?
|
1181
|
+
fail ArgumentError, "Missing the required parameter 'update_password_dto' when calling UserApi.update_password"
|
1182
|
+
end
|
1183
|
+
# resource path
|
1184
|
+
local_var_path = '/api/v1/user/update-password'
|
1185
|
+
|
1186
|
+
# query parameters
|
1187
|
+
query_params = opts[:query_params] || {}
|
1188
|
+
|
1189
|
+
# header parameters
|
1190
|
+
header_params = opts[:header_params] || {}
|
1191
|
+
# HTTP header 'Accept' (if needed)
|
1192
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/hal+json', 'application/json'])
|
1193
|
+
# HTTP header 'Content-Type'
|
1194
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1195
|
+
if !content_type.nil?
|
1196
|
+
header_params['Content-Type'] = content_type
|
1197
|
+
end
|
1198
|
+
|
1199
|
+
# form parameters
|
1200
|
+
form_params = opts[:form_params] || {}
|
1201
|
+
|
1202
|
+
# http body (model)
|
1203
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(update_password_dto)
|
1204
|
+
|
1205
|
+
# return_type
|
1206
|
+
return_type = opts[:debug_return_type] || 'Object'
|
1207
|
+
|
1208
|
+
# auth_names
|
1209
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
1210
|
+
|
1211
|
+
new_options = opts.merge(
|
1212
|
+
:operation => :"UserApi.update_password",
|
1213
|
+
:header_params => header_params,
|
1214
|
+
:query_params => query_params,
|
1215
|
+
:form_params => form_params,
|
1216
|
+
:body => post_body,
|
1217
|
+
:auth_names => auth_names,
|
1218
|
+
:return_type => return_type
|
1219
|
+
)
|
1220
|
+
|
1221
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1222
|
+
if @api_client.config.debugging
|
1223
|
+
@api_client.config.logger.debug "API called: UserApi#update_password\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1224
|
+
end
|
1225
|
+
return data, status_code, headers
|
1226
|
+
end
|
1227
|
+
|
1228
|
+
# Create and edit metadata of your files.
|
1229
|
+
# @param object_key [String] ObjectKey of the file that should be edited.
|
1230
|
+
# @param save_file_recording_dto [SaveFileRecordingDTO]
|
1231
|
+
# @param [Hash] opts the optional parameters
|
1232
|
+
# @return [Object]
|
1233
|
+
def update_user_file_recording(object_key, save_file_recording_dto, opts = {})
|
1234
|
+
data, _status_code, _headers = update_user_file_recording_with_http_info(object_key, save_file_recording_dto, opts)
|
1235
|
+
data
|
1236
|
+
end
|
1237
|
+
|
1238
|
+
# Create and edit metadata of your files.
|
1239
|
+
# @param object_key [String] ObjectKey of the file that should be edited.
|
1240
|
+
# @param save_file_recording_dto [SaveFileRecordingDTO]
|
1241
|
+
# @param [Hash] opts the optional parameters
|
1242
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
1243
|
+
def update_user_file_recording_with_http_info(object_key, save_file_recording_dto, opts = {})
|
1244
|
+
if @api_client.config.debugging
|
1245
|
+
@api_client.config.logger.debug 'Calling API: UserApi.update_user_file_recording ...'
|
1246
|
+
end
|
1247
|
+
# verify the required parameter 'object_key' is set
|
1248
|
+
if @api_client.config.client_side_validation && object_key.nil?
|
1249
|
+
fail ArgumentError, "Missing the required parameter 'object_key' when calling UserApi.update_user_file_recording"
|
1250
|
+
end
|
1251
|
+
# verify the required parameter 'save_file_recording_dto' is set
|
1252
|
+
if @api_client.config.client_side_validation && save_file_recording_dto.nil?
|
1253
|
+
fail ArgumentError, "Missing the required parameter 'save_file_recording_dto' when calling UserApi.update_user_file_recording"
|
1254
|
+
end
|
1255
|
+
# resource path
|
1256
|
+
local_var_path = '/api/v1/user/file/{objectKey}'.sub('{' + 'objectKey' + '}', CGI.escape(object_key.to_s))
|
1257
|
+
|
1258
|
+
# query parameters
|
1259
|
+
query_params = opts[:query_params] || {}
|
1260
|
+
|
1261
|
+
# header parameters
|
1262
|
+
header_params = opts[:header_params] || {}
|
1263
|
+
# HTTP header 'Accept' (if needed)
|
1264
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1265
|
+
# HTTP header 'Content-Type'
|
1266
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1267
|
+
if !content_type.nil?
|
1268
|
+
header_params['Content-Type'] = content_type
|
1269
|
+
end
|
1270
|
+
|
1271
|
+
# form parameters
|
1272
|
+
form_params = opts[:form_params] || {}
|
1273
|
+
|
1274
|
+
# http body (model)
|
1275
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(save_file_recording_dto)
|
1276
|
+
|
1277
|
+
# return_type
|
1278
|
+
return_type = opts[:debug_return_type] || 'Object'
|
1279
|
+
|
1280
|
+
# auth_names
|
1281
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
1282
|
+
|
1283
|
+
new_options = opts.merge(
|
1284
|
+
:operation => :"UserApi.update_user_file_recording",
|
1285
|
+
:header_params => header_params,
|
1286
|
+
:query_params => query_params,
|
1287
|
+
:form_params => form_params,
|
1288
|
+
:body => post_body,
|
1289
|
+
:auth_names => auth_names,
|
1290
|
+
:return_type => return_type
|
1291
|
+
)
|
1292
|
+
|
1293
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1294
|
+
if @api_client.config.debugging
|
1295
|
+
@api_client.config.logger.debug "API called: UserApi#update_user_file_recording\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1296
|
+
end
|
1297
|
+
return data, status_code, headers
|
1298
|
+
end
|
1299
|
+
|
1300
|
+
# Details and a download link for a file.
|
1301
|
+
# @param object_key [String] ObjectKey of the file that should be edited.
|
1302
|
+
# @param [Hash] opts the optional parameters
|
1303
|
+
# @return [FileWIthUrlDTO]
|
1304
|
+
def user_file(object_key, opts = {})
|
1305
|
+
data, _status_code, _headers = user_file_with_http_info(object_key, opts)
|
1306
|
+
data
|
1307
|
+
end
|
1308
|
+
|
1309
|
+
# Details and a download link for a file.
|
1310
|
+
# @param object_key [String] ObjectKey of the file that should be edited.
|
1311
|
+
# @param [Hash] opts the optional parameters
|
1312
|
+
# @return [Array<(FileWIthUrlDTO, Integer, Hash)>] FileWIthUrlDTO data, response status code and response headers
|
1313
|
+
def user_file_with_http_info(object_key, opts = {})
|
1314
|
+
if @api_client.config.debugging
|
1315
|
+
@api_client.config.logger.debug 'Calling API: UserApi.user_file ...'
|
1316
|
+
end
|
1317
|
+
# verify the required parameter 'object_key' is set
|
1318
|
+
if @api_client.config.client_side_validation && object_key.nil?
|
1319
|
+
fail ArgumentError, "Missing the required parameter 'object_key' when calling UserApi.user_file"
|
1320
|
+
end
|
1321
|
+
# resource path
|
1322
|
+
local_var_path = '/api/v1/user/file/{objectKey}'.sub('{' + 'objectKey' + '}', CGI.escape(object_key.to_s))
|
1323
|
+
|
1324
|
+
# query parameters
|
1325
|
+
query_params = opts[:query_params] || {}
|
1326
|
+
|
1327
|
+
# header parameters
|
1328
|
+
header_params = opts[:header_params] || {}
|
1329
|
+
# HTTP header 'Accept' (if needed)
|
1330
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1331
|
+
|
1332
|
+
# form parameters
|
1333
|
+
form_params = opts[:form_params] || {}
|
1334
|
+
|
1335
|
+
# http body (model)
|
1336
|
+
post_body = opts[:debug_body]
|
1337
|
+
|
1338
|
+
# return_type
|
1339
|
+
return_type = opts[:debug_return_type] || 'FileWIthUrlDTO'
|
1340
|
+
|
1341
|
+
# auth_names
|
1342
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
1343
|
+
|
1344
|
+
new_options = opts.merge(
|
1345
|
+
:operation => :"UserApi.user_file",
|
1346
|
+
:header_params => header_params,
|
1347
|
+
:query_params => query_params,
|
1348
|
+
:form_params => form_params,
|
1349
|
+
:body => post_body,
|
1350
|
+
:auth_names => auth_names,
|
1351
|
+
:return_type => return_type
|
1352
|
+
)
|
1353
|
+
|
1354
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
1355
|
+
if @api_client.config.debugging
|
1356
|
+
@api_client.config.logger.debug "API called: UserApi#user_file\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1357
|
+
end
|
1358
|
+
return data, status_code, headers
|
1359
|
+
end
|
1360
|
+
|
1361
|
+
# List and search your own files.
|
1362
|
+
# @param [Hash] opts the optional parameters
|
1363
|
+
# @option opts [String] :isrc Search for a ISRC
|
1364
|
+
# @option opts [String] :contributor Search for a name that was involved as any contributor.
|
1365
|
+
# @option opts [String] :main_artist Search for a main artist.
|
1366
|
+
# @option opts [String] :composer Search for a composer.
|
1367
|
+
# @option opts [String] :title Search for a title.
|
1368
|
+
# @option opts [String] :language Search for a language of the lyrics.
|
1369
|
+
# @option opts [Array<String>] :genre_names
|
1370
|
+
# @option opts [Array<String>] :tag_names
|
1371
|
+
# @option opts [Time] :release_date
|
1372
|
+
# @option opts [String] :primary_mood_cluster
|
1373
|
+
# @option opts [String] :secondary_mood_cluster
|
1374
|
+
# @option opts [String] :tertiary_mood_cluster
|
1375
|
+
# @option opts [String] :valence
|
1376
|
+
# @option opts [String] :arousal
|
1377
|
+
# @option opts [String] :pleasantness
|
1378
|
+
# @option opts [String] :engagement
|
1379
|
+
# @option opts [String] :vocals
|
1380
|
+
# @option opts [String] :dominant_instrument
|
1381
|
+
# @option opts [String] :secondary_instrument
|
1382
|
+
# @option opts [String] :tertiary_instrument
|
1383
|
+
# @option opts [String] :energy
|
1384
|
+
# @option opts [String] :sound_generation
|
1385
|
+
# @option opts [String] :tempo
|
1386
|
+
# @option opts [String] :scale
|
1387
|
+
# @option opts [String] :rhythm
|
1388
|
+
# @option opts [String] :primary_sound_character
|
1389
|
+
# @option opts [String] :timbre
|
1390
|
+
# @option opts [String] :roughness
|
1391
|
+
# @option opts [String] :tonality
|
1392
|
+
# @option opts [String] :harmony
|
1393
|
+
# @option opts [String] :texture
|
1394
|
+
# @option opts [String] :groovyness
|
1395
|
+
# @option opts [String] :space
|
1396
|
+
# @option opts [String] :production_rating
|
1397
|
+
# @option opts [String] :performance_rating
|
1398
|
+
# @option opts [String] :song_rating
|
1399
|
+
# @option opts [String] :audience_age
|
1400
|
+
# @option opts [String] :audience_region
|
1401
|
+
# @option opts [String] :audience_gender
|
1402
|
+
# @option opts [String] :origin_decade
|
1403
|
+
# @option opts [String] :curateability
|
1404
|
+
# @option opts [String] :use_case
|
1405
|
+
# @option opts [String] :channel_suitability
|
1406
|
+
# @option opts [String] :similar_to_recording
|
1407
|
+
# @option opts [String] :songtradr_track_id
|
1408
|
+
# @option opts [String] :usage_name
|
1409
|
+
# @option opts [Integer] :bpm_min Search for a minimal bpm.
|
1410
|
+
# @option opts [Integer] :bpm_max Search for a maximal bpm.
|
1411
|
+
# @option opts [String] :name Search for a file name.
|
1412
|
+
# @option opts [String] :folder Search for a folder.
|
1413
|
+
# @option opts [String] :extension Search for a file extension.
|
1414
|
+
# @option opts [Time] :upload_end_time
|
1415
|
+
# @option opts [Time] :min_upload_end_time
|
1416
|
+
# @option opts [Time] :max_upload_end_time
|
1417
|
+
# @option opts [String] :fingerprint_status Search for a fingerprint status.
|
1418
|
+
# @option opts [String] :inference_status Search for a inference status.
|
1419
|
+
# @option opts [Integer] :page Zero-based page index (0..N) (default to 0)
|
1420
|
+
# @option opts [Integer] :size The size of the page to be returned (default to 100)
|
1421
|
+
# @option opts [Array<String>] :sort Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
|
1422
|
+
# @return [FileListDTO]
|
1423
|
+
def user_files(opts = {})
|
1424
|
+
data, _status_code, _headers = user_files_with_http_info(opts)
|
1425
|
+
data
|
1426
|
+
end
|
1427
|
+
|
1428
|
+
# List and search your own files.
|
1429
|
+
# @param [Hash] opts the optional parameters
|
1430
|
+
# @option opts [String] :isrc Search for a ISRC
|
1431
|
+
# @option opts [String] :contributor Search for a name that was involved as any contributor.
|
1432
|
+
# @option opts [String] :main_artist Search for a main artist.
|
1433
|
+
# @option opts [String] :composer Search for a composer.
|
1434
|
+
# @option opts [String] :title Search for a title.
|
1435
|
+
# @option opts [String] :language Search for a language of the lyrics.
|
1436
|
+
# @option opts [Array<String>] :genre_names
|
1437
|
+
# @option opts [Array<String>] :tag_names
|
1438
|
+
# @option opts [Time] :release_date
|
1439
|
+
# @option opts [String] :primary_mood_cluster
|
1440
|
+
# @option opts [String] :secondary_mood_cluster
|
1441
|
+
# @option opts [String] :tertiary_mood_cluster
|
1442
|
+
# @option opts [String] :valence
|
1443
|
+
# @option opts [String] :arousal
|
1444
|
+
# @option opts [String] :pleasantness
|
1445
|
+
# @option opts [String] :engagement
|
1446
|
+
# @option opts [String] :vocals
|
1447
|
+
# @option opts [String] :dominant_instrument
|
1448
|
+
# @option opts [String] :secondary_instrument
|
1449
|
+
# @option opts [String] :tertiary_instrument
|
1450
|
+
# @option opts [String] :energy
|
1451
|
+
# @option opts [String] :sound_generation
|
1452
|
+
# @option opts [String] :tempo
|
1453
|
+
# @option opts [String] :scale
|
1454
|
+
# @option opts [String] :rhythm
|
1455
|
+
# @option opts [String] :primary_sound_character
|
1456
|
+
# @option opts [String] :timbre
|
1457
|
+
# @option opts [String] :roughness
|
1458
|
+
# @option opts [String] :tonality
|
1459
|
+
# @option opts [String] :harmony
|
1460
|
+
# @option opts [String] :texture
|
1461
|
+
# @option opts [String] :groovyness
|
1462
|
+
# @option opts [String] :space
|
1463
|
+
# @option opts [String] :production_rating
|
1464
|
+
# @option opts [String] :performance_rating
|
1465
|
+
# @option opts [String] :song_rating
|
1466
|
+
# @option opts [String] :audience_age
|
1467
|
+
# @option opts [String] :audience_region
|
1468
|
+
# @option opts [String] :audience_gender
|
1469
|
+
# @option opts [String] :origin_decade
|
1470
|
+
# @option opts [String] :curateability
|
1471
|
+
# @option opts [String] :use_case
|
1472
|
+
# @option opts [String] :channel_suitability
|
1473
|
+
# @option opts [String] :similar_to_recording
|
1474
|
+
# @option opts [String] :songtradr_track_id
|
1475
|
+
# @option opts [String] :usage_name
|
1476
|
+
# @option opts [Integer] :bpm_min Search for a minimal bpm.
|
1477
|
+
# @option opts [Integer] :bpm_max Search for a maximal bpm.
|
1478
|
+
# @option opts [String] :name Search for a file name.
|
1479
|
+
# @option opts [String] :folder Search for a folder.
|
1480
|
+
# @option opts [String] :extension Search for a file extension.
|
1481
|
+
# @option opts [Time] :upload_end_time
|
1482
|
+
# @option opts [Time] :min_upload_end_time
|
1483
|
+
# @option opts [Time] :max_upload_end_time
|
1484
|
+
# @option opts [String] :fingerprint_status Search for a fingerprint status.
|
1485
|
+
# @option opts [String] :inference_status Search for a inference status.
|
1486
|
+
# @option opts [Integer] :page Zero-based page index (0..N) (default to 0)
|
1487
|
+
# @option opts [Integer] :size The size of the page to be returned (default to 100)
|
1488
|
+
# @option opts [Array<String>] :sort Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
|
1489
|
+
# @return [Array<(FileListDTO, Integer, Hash)>] FileListDTO data, response status code and response headers
|
1490
|
+
def user_files_with_http_info(opts = {})
|
1491
|
+
if @api_client.config.debugging
|
1492
|
+
@api_client.config.logger.debug 'Calling API: UserApi.user_files ...'
|
1493
|
+
end
|
1494
|
+
allowable_values = ["en", "es", "fr", "de", "jp", "cn", "IT", "RU"]
|
1495
|
+
if @api_client.config.client_side_validation && opts[:'language'] && !allowable_values.include?(opts[:'language'])
|
1496
|
+
fail ArgumentError, "invalid value for \"language\", must be one of #{allowable_values}"
|
1497
|
+
end
|
1498
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
1499
|
+
if @api_client.config.client_side_validation && opts[:'primary_mood_cluster'] && !allowable_values.include?(opts[:'primary_mood_cluster'])
|
1500
|
+
fail ArgumentError, "invalid value for \"primary_mood_cluster\", must be one of #{allowable_values}"
|
1501
|
+
end
|
1502
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
1503
|
+
if @api_client.config.client_side_validation && opts[:'secondary_mood_cluster'] && !allowable_values.include?(opts[:'secondary_mood_cluster'])
|
1504
|
+
fail ArgumentError, "invalid value for \"secondary_mood_cluster\", must be one of #{allowable_values}"
|
1505
|
+
end
|
1506
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
1507
|
+
if @api_client.config.client_side_validation && opts[:'tertiary_mood_cluster'] && !allowable_values.include?(opts[:'tertiary_mood_cluster'])
|
1508
|
+
fail ArgumentError, "invalid value for \"tertiary_mood_cluster\", must be one of #{allowable_values}"
|
1509
|
+
end
|
1510
|
+
allowable_values = ["very sad", "sad", "moderate valence", "positive", "very positive", "varying valence"]
|
1511
|
+
if @api_client.config.client_side_validation && opts[:'valence'] && !allowable_values.include?(opts[:'valence'])
|
1512
|
+
fail ArgumentError, "invalid value for \"valence\", must be one of #{allowable_values}"
|
1513
|
+
end
|
1514
|
+
allowable_values = ["very calm", "calm", "moderate arousal", "energetic", "very energetic", "varying arousal"]
|
1515
|
+
if @api_client.config.client_side_validation && opts[:'arousal'] && !allowable_values.include?(opts[:'arousal'])
|
1516
|
+
fail ArgumentError, "invalid value for \"arousal\", must be one of #{allowable_values}"
|
1517
|
+
end
|
1518
|
+
allowable_values = ["very unpleasant", "unpleasant", "neutral pleasantness", "pleasant", "very pleasant", "varying pleasantness"]
|
1519
|
+
if @api_client.config.client_side_validation && opts[:'pleasantness'] && !allowable_values.include?(opts[:'pleasantness'])
|
1520
|
+
fail ArgumentError, "invalid value for \"pleasantness\", must be one of #{allowable_values}"
|
1521
|
+
end
|
1522
|
+
allowable_values = ["very unengaging", "unengaging", "neutral engagement", "engaging", "very engaging", "varying engagement"]
|
1523
|
+
if @api_client.config.client_side_validation && opts[:'engagement'] && !allowable_values.include?(opts[:'engagement'])
|
1524
|
+
fail ArgumentError, "invalid value for \"engagement\", must be one of #{allowable_values}"
|
1525
|
+
end
|
1526
|
+
allowable_values = ["instrumental", "female vocals", "male vocals", "mixed vocals", "diverse gender vocals"]
|
1527
|
+
if @api_client.config.client_side_validation && opts[:'vocals'] && !allowable_values.include?(opts[:'vocals'])
|
1528
|
+
fail ArgumentError, "invalid value for \"vocals\", must be one of #{allowable_values}"
|
1529
|
+
end
|
1530
|
+
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"]
|
1531
|
+
if @api_client.config.client_side_validation && opts[:'dominant_instrument'] && !allowable_values.include?(opts[:'dominant_instrument'])
|
1532
|
+
fail ArgumentError, "invalid value for \"dominant_instrument\", must be one of #{allowable_values}"
|
1533
|
+
end
|
1534
|
+
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"]
|
1535
|
+
if @api_client.config.client_side_validation && opts[:'secondary_instrument'] && !allowable_values.include?(opts[:'secondary_instrument'])
|
1536
|
+
fail ArgumentError, "invalid value for \"secondary_instrument\", must be one of #{allowable_values}"
|
1537
|
+
end
|
1538
|
+
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"]
|
1539
|
+
if @api_client.config.client_side_validation && opts[:'tertiary_instrument'] && !allowable_values.include?(opts[:'tertiary_instrument'])
|
1540
|
+
fail ArgumentError, "invalid value for \"tertiary_instrument\", must be one of #{allowable_values}"
|
1541
|
+
end
|
1542
|
+
allowable_values = ["very quiet", "quiet", "moderate", "loud", "very loud", "dynamic"]
|
1543
|
+
if @api_client.config.client_side_validation && opts[:'energy'] && !allowable_values.include?(opts[:'energy'])
|
1544
|
+
fail ArgumentError, "invalid value for \"energy\", must be one of #{allowable_values}"
|
1545
|
+
end
|
1546
|
+
allowable_values = ["acoustic", "electric", "electronic", "mixed sound generation"]
|
1547
|
+
if @api_client.config.client_side_validation && opts[:'sound_generation'] && !allowable_values.include?(opts[:'sound_generation'])
|
1548
|
+
fail ArgumentError, "invalid value for \"sound_generation\", must be one of #{allowable_values}"
|
1549
|
+
end
|
1550
|
+
allowable_values = ["very slow", "slow", "mid-tempo", "fast", "very fast", "varying tempo"]
|
1551
|
+
if @api_client.config.client_side_validation && opts[:'tempo'] && !allowable_values.include?(opts[:'tempo'])
|
1552
|
+
fail ArgumentError, "invalid value for \"tempo\", must be one of #{allowable_values}"
|
1553
|
+
end
|
1554
|
+
allowable_values = ["major key", "minor key", "neutral key"]
|
1555
|
+
if @api_client.config.client_side_validation && opts[:'scale'] && !allowable_values.include?(opts[:'scale'])
|
1556
|
+
fail ArgumentError, "invalid value for \"scale\", must be one of #{allowable_values}"
|
1557
|
+
end
|
1558
|
+
allowable_values = ["common time", "triple meter", "complex time signature", "binary rhythm", "ternary rhythm"]
|
1559
|
+
if @api_client.config.client_side_validation && opts[:'rhythm'] && !allowable_values.include?(opts[:'rhythm'])
|
1560
|
+
fail ArgumentError, "invalid value for \"rhythm\", must be one of #{allowable_values}"
|
1561
|
+
end
|
1562
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
1563
|
+
if @api_client.config.client_side_validation && opts[:'primary_sound_character'] && !allowable_values.include?(opts[:'primary_sound_character'])
|
1564
|
+
fail ArgumentError, "invalid value for \"primary_sound_character\", must be one of #{allowable_values}"
|
1565
|
+
end
|
1566
|
+
allowable_values = ["very warm", "warm", "moderate timbre", "bright", "very bright"]
|
1567
|
+
if @api_client.config.client_side_validation && opts[:'timbre'] && !allowable_values.include?(opts[:'timbre'])
|
1568
|
+
fail ArgumentError, "invalid value for \"timbre\", must be one of #{allowable_values}"
|
1569
|
+
end
|
1570
|
+
allowable_values = ["very clear", "clear", "moderate roughness", "distorted", "very distorted"]
|
1571
|
+
if @api_client.config.client_side_validation && opts[:'roughness'] && !allowable_values.include?(opts[:'roughness'])
|
1572
|
+
fail ArgumentError, "invalid value for \"roughness\", must be one of #{allowable_values}"
|
1573
|
+
end
|
1574
|
+
allowable_values = ["monotonous", "moderate melodiousness", "melodious", "atonal"]
|
1575
|
+
if @api_client.config.client_side_validation && opts[:'tonality'] && !allowable_values.include?(opts[:'tonality'])
|
1576
|
+
fail ArgumentError, "invalid value for \"tonality\", must be one of #{allowable_values}"
|
1577
|
+
end
|
1578
|
+
allowable_values = ["very dissonant", "dissonant", "moderate harmonies", "harmonious", "very harmonious"]
|
1579
|
+
if @api_client.config.client_side_validation && opts[:'harmony'] && !allowable_values.include?(opts[:'harmony'])
|
1580
|
+
fail ArgumentError, "invalid value for \"harmony\", must be one of #{allowable_values}"
|
1581
|
+
end
|
1582
|
+
allowable_values = ["very thin", "thin", "moderate texture", "full", "very full"]
|
1583
|
+
if @api_client.config.client_side_validation && opts[:'texture'] && !allowable_values.include?(opts[:'texture'])
|
1584
|
+
fail ArgumentError, "invalid value for \"texture\", must be one of #{allowable_values}"
|
1585
|
+
end
|
1586
|
+
allowable_values = ["very steady", "steady", "moderate rhythm feel", "groovy", "very groovy"]
|
1587
|
+
if @api_client.config.client_side_validation && opts[:'groovyness'] && !allowable_values.include?(opts[:'groovyness'])
|
1588
|
+
fail ArgumentError, "invalid value for \"groovyness\", must be one of #{allowable_values}"
|
1589
|
+
end
|
1590
|
+
allowable_values = ["very compact", "compact", "moderate space", "wide", "very wide"]
|
1591
|
+
if @api_client.config.client_side_validation && opts[:'space'] && !allowable_values.include?(opts[:'space'])
|
1592
|
+
fail ArgumentError, "invalid value for \"space\", must be one of #{allowable_values}"
|
1593
|
+
end
|
1594
|
+
allowable_values = ["low production quality", "medium production quality", "high production quality"]
|
1595
|
+
if @api_client.config.client_side_validation && opts[:'production_rating'] && !allowable_values.include?(opts[:'production_rating'])
|
1596
|
+
fail ArgumentError, "invalid value for \"production_rating\", must be one of #{allowable_values}"
|
1597
|
+
end
|
1598
|
+
allowable_values = ["low performance quality", "medium performance quality", "high performance quality"]
|
1599
|
+
if @api_client.config.client_side_validation && opts[:'performance_rating'] && !allowable_values.include?(opts[:'performance_rating'])
|
1600
|
+
fail ArgumentError, "invalid value for \"performance_rating\", must be one of #{allowable_values}"
|
1601
|
+
end
|
1602
|
+
allowable_values = ["low song quality", "medium song quality", "high song quality"]
|
1603
|
+
if @api_client.config.client_side_validation && opts[:'song_rating'] && !allowable_values.include?(opts[:'song_rating'])
|
1604
|
+
fail ArgumentError, "invalid value for \"song_rating\", must be one of #{allowable_values}"
|
1605
|
+
end
|
1606
|
+
allowable_values = ["Generation Z", "Younger Generation Y", "Older Generation Y", "Generation X", "Younger Generation B", "Older Generation B"]
|
1607
|
+
if @api_client.config.client_side_validation && opts[:'audience_age'] && !allowable_values.include?(opts[:'audience_age'])
|
1608
|
+
fail ArgumentError, "invalid value for \"audience_age\", must be one of #{allowable_values}"
|
1609
|
+
end
|
1610
|
+
allowable_values = ["Australia and New Zealand", "Central America and the Carribean", "Central and Southern Asia", "Eastern Asia", "Eastern Europe", "Northern Africa and Western Asia", "Northern America", "Oceania", "South America", "South-Eastern Asia", "Southern Europe", "Sub-Saharan Africa", "Western and Northern Europe"]
|
1611
|
+
if @api_client.config.client_side_validation && opts[:'audience_region'] && !allowable_values.include?(opts[:'audience_region'])
|
1612
|
+
fail ArgumentError, "invalid value for \"audience_region\", must be one of #{allowable_values}"
|
1613
|
+
end
|
1614
|
+
allowable_values = ["male", "female"]
|
1615
|
+
if @api_client.config.client_side_validation && opts[:'audience_gender'] && !allowable_values.include?(opts[:'audience_gender'])
|
1616
|
+
fail ArgumentError, "invalid value for \"audience_gender\", must be one of #{allowable_values}"
|
1617
|
+
end
|
1618
|
+
allowable_values = ["pre-1950s", "1950s", "1960s", "1970s", "1980s", "1990s", "2000s", "2010s", "2020s"]
|
1619
|
+
if @api_client.config.client_side_validation && opts[:'origin_decade'] && !allowable_values.include?(opts[:'origin_decade'])
|
1620
|
+
fail ArgumentError, "invalid value for \"origin_decade\", must be one of #{allowable_values}"
|
1621
|
+
end
|
1622
|
+
allowable_values = ["curateable", "uncurateable"]
|
1623
|
+
if @api_client.config.client_side_validation && opts[:'curateability'] && !allowable_values.include?(opts[:'curateability'])
|
1624
|
+
fail ArgumentError, "invalid value for \"curateability\", must be one of #{allowable_values}"
|
1625
|
+
end
|
1626
|
+
allowable_values = ["background", "sport", "focus", "christmas", "film", "summer", "adverts", "party", "relax"]
|
1627
|
+
if @api_client.config.client_side_validation && opts[:'use_case'] && !allowable_values.include?(opts[:'use_case'])
|
1628
|
+
fail ArgumentError, "invalid value for \"use_case\", must be one of #{allowable_values}"
|
1629
|
+
end
|
1630
|
+
allowable_values = ["Spotify", "TikTok", "Unfitting", "YouTube"]
|
1631
|
+
if @api_client.config.client_side_validation && opts[:'channel_suitability'] && !allowable_values.include?(opts[:'channel_suitability'])
|
1632
|
+
fail ArgumentError, "invalid value for \"channel_suitability\", must be one of #{allowable_values}"
|
1633
|
+
end
|
1634
|
+
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 0
|
1635
|
+
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling UserApi.user_files, must be greater than or equal to 0.'
|
1636
|
+
end
|
1637
|
+
|
1638
|
+
if @api_client.config.client_side_validation && !opts[:'size'].nil? && opts[:'size'] < 1
|
1639
|
+
fail ArgumentError, 'invalid value for "opts[:"size"]" when calling UserApi.user_files, must be greater than or equal to 1.'
|
1640
|
+
end
|
1641
|
+
|
1642
|
+
# resource path
|
1643
|
+
local_var_path = '/api/v1/user/files'
|
1644
|
+
|
1645
|
+
# query parameters
|
1646
|
+
query_params = opts[:query_params] || {}
|
1647
|
+
query_params[:'ISRC'] = opts[:'isrc'] if !opts[:'isrc'].nil?
|
1648
|
+
query_params[:'contributor'] = opts[:'contributor'] if !opts[:'contributor'].nil?
|
1649
|
+
query_params[:'mainArtist'] = opts[:'main_artist'] if !opts[:'main_artist'].nil?
|
1650
|
+
query_params[:'composer'] = opts[:'composer'] if !opts[:'composer'].nil?
|
1651
|
+
query_params[:'title'] = opts[:'title'] if !opts[:'title'].nil?
|
1652
|
+
query_params[:'language'] = opts[:'language'] if !opts[:'language'].nil?
|
1653
|
+
query_params[:'genreNames'] = @api_client.build_collection_param(opts[:'genre_names'], :multi) if !opts[:'genre_names'].nil?
|
1654
|
+
query_params[:'tagNames'] = @api_client.build_collection_param(opts[:'tag_names'], :multi) if !opts[:'tag_names'].nil?
|
1655
|
+
query_params[:'releaseDate'] = opts[:'release_date'] if !opts[:'release_date'].nil?
|
1656
|
+
query_params[:'primaryMoodCluster'] = opts[:'primary_mood_cluster'] if !opts[:'primary_mood_cluster'].nil?
|
1657
|
+
query_params[:'secondaryMoodCluster'] = opts[:'secondary_mood_cluster'] if !opts[:'secondary_mood_cluster'].nil?
|
1658
|
+
query_params[:'tertiaryMoodCluster'] = opts[:'tertiary_mood_cluster'] if !opts[:'tertiary_mood_cluster'].nil?
|
1659
|
+
query_params[:'valence'] = opts[:'valence'] if !opts[:'valence'].nil?
|
1660
|
+
query_params[:'arousal'] = opts[:'arousal'] if !opts[:'arousal'].nil?
|
1661
|
+
query_params[:'pleasantness'] = opts[:'pleasantness'] if !opts[:'pleasantness'].nil?
|
1662
|
+
query_params[:'engagement'] = opts[:'engagement'] if !opts[:'engagement'].nil?
|
1663
|
+
query_params[:'vocals'] = opts[:'vocals'] if !opts[:'vocals'].nil?
|
1664
|
+
query_params[:'dominantInstrument'] = opts[:'dominant_instrument'] if !opts[:'dominant_instrument'].nil?
|
1665
|
+
query_params[:'secondaryInstrument'] = opts[:'secondary_instrument'] if !opts[:'secondary_instrument'].nil?
|
1666
|
+
query_params[:'tertiaryInstrument'] = opts[:'tertiary_instrument'] if !opts[:'tertiary_instrument'].nil?
|
1667
|
+
query_params[:'energy'] = opts[:'energy'] if !opts[:'energy'].nil?
|
1668
|
+
query_params[:'soundGeneration'] = opts[:'sound_generation'] if !opts[:'sound_generation'].nil?
|
1669
|
+
query_params[:'tempo'] = opts[:'tempo'] if !opts[:'tempo'].nil?
|
1670
|
+
query_params[:'scale'] = opts[:'scale'] if !opts[:'scale'].nil?
|
1671
|
+
query_params[:'rhythm'] = opts[:'rhythm'] if !opts[:'rhythm'].nil?
|
1672
|
+
query_params[:'primarySoundCharacter'] = opts[:'primary_sound_character'] if !opts[:'primary_sound_character'].nil?
|
1673
|
+
query_params[:'timbre'] = opts[:'timbre'] if !opts[:'timbre'].nil?
|
1674
|
+
query_params[:'roughness'] = opts[:'roughness'] if !opts[:'roughness'].nil?
|
1675
|
+
query_params[:'tonality'] = opts[:'tonality'] if !opts[:'tonality'].nil?
|
1676
|
+
query_params[:'harmony'] = opts[:'harmony'] if !opts[:'harmony'].nil?
|
1677
|
+
query_params[:'texture'] = opts[:'texture'] if !opts[:'texture'].nil?
|
1678
|
+
query_params[:'groovyness'] = opts[:'groovyness'] if !opts[:'groovyness'].nil?
|
1679
|
+
query_params[:'space'] = opts[:'space'] if !opts[:'space'].nil?
|
1680
|
+
query_params[:'productionRating'] = opts[:'production_rating'] if !opts[:'production_rating'].nil?
|
1681
|
+
query_params[:'performanceRating'] = opts[:'performance_rating'] if !opts[:'performance_rating'].nil?
|
1682
|
+
query_params[:'songRating'] = opts[:'song_rating'] if !opts[:'song_rating'].nil?
|
1683
|
+
query_params[:'audienceAge'] = opts[:'audience_age'] if !opts[:'audience_age'].nil?
|
1684
|
+
query_params[:'audienceRegion'] = opts[:'audience_region'] if !opts[:'audience_region'].nil?
|
1685
|
+
query_params[:'audienceGender'] = opts[:'audience_gender'] if !opts[:'audience_gender'].nil?
|
1686
|
+
query_params[:'originDecade'] = opts[:'origin_decade'] if !opts[:'origin_decade'].nil?
|
1687
|
+
query_params[:'curateability'] = opts[:'curateability'] if !opts[:'curateability'].nil?
|
1688
|
+
query_params[:'useCase'] = opts[:'use_case'] if !opts[:'use_case'].nil?
|
1689
|
+
query_params[:'channelSuitability'] = opts[:'channel_suitability'] if !opts[:'channel_suitability'].nil?
|
1690
|
+
query_params[:'similarToRecording'] = opts[:'similar_to_recording'] if !opts[:'similar_to_recording'].nil?
|
1691
|
+
query_params[:'songtradrTrackId'] = opts[:'songtradr_track_id'] if !opts[:'songtradr_track_id'].nil?
|
1692
|
+
query_params[:'usageName'] = opts[:'usage_name'] if !opts[:'usage_name'].nil?
|
1693
|
+
query_params[:'bpmMin'] = opts[:'bpm_min'] if !opts[:'bpm_min'].nil?
|
1694
|
+
query_params[:'bpmMax'] = opts[:'bpm_max'] if !opts[:'bpm_max'].nil?
|
1695
|
+
query_params[:'name'] = opts[:'name'] if !opts[:'name'].nil?
|
1696
|
+
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
1697
|
+
query_params[:'extension'] = opts[:'extension'] if !opts[:'extension'].nil?
|
1698
|
+
query_params[:'uploadEndTime'] = opts[:'upload_end_time'] if !opts[:'upload_end_time'].nil?
|
1699
|
+
query_params[:'minUploadEndTime'] = opts[:'min_upload_end_time'] if !opts[:'min_upload_end_time'].nil?
|
1700
|
+
query_params[:'maxUploadEndTime'] = opts[:'max_upload_end_time'] if !opts[:'max_upload_end_time'].nil?
|
1701
|
+
query_params[:'fingerprintStatus'] = opts[:'fingerprint_status'] if !opts[:'fingerprint_status'].nil?
|
1702
|
+
query_params[:'inferenceStatus'] = opts[:'inference_status'] if !opts[:'inference_status'].nil?
|
1703
|
+
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
1704
|
+
query_params[:'size'] = opts[:'size'] if !opts[:'size'].nil?
|
1705
|
+
query_params[:'sort'] = @api_client.build_collection_param(opts[:'sort'], :multi) if !opts[:'sort'].nil?
|
1706
|
+
|
1707
|
+
# header parameters
|
1708
|
+
header_params = opts[:header_params] || {}
|
1709
|
+
# HTTP header 'Accept' (if needed)
|
1710
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1711
|
+
|
1712
|
+
# form parameters
|
1713
|
+
form_params = opts[:form_params] || {}
|
1714
|
+
|
1715
|
+
# http body (model)
|
1716
|
+
post_body = opts[:debug_body]
|
1717
|
+
|
1718
|
+
# return_type
|
1719
|
+
return_type = opts[:debug_return_type] || 'FileListDTO'
|
1720
|
+
|
1721
|
+
# auth_names
|
1722
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
1723
|
+
|
1724
|
+
new_options = opts.merge(
|
1725
|
+
:operation => :"UserApi.user_files",
|
1726
|
+
:header_params => header_params,
|
1727
|
+
:query_params => query_params,
|
1728
|
+
:form_params => form_params,
|
1729
|
+
:body => post_body,
|
1730
|
+
:auth_names => auth_names,
|
1731
|
+
:return_type => return_type
|
1732
|
+
)
|
1733
|
+
|
1734
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
1735
|
+
if @api_client.config.debugging
|
1736
|
+
@api_client.config.logger.debug "API called: UserApi#user_files\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1737
|
+
end
|
1738
|
+
return data, status_code, headers
|
1739
|
+
end
|
1740
|
+
|
1741
|
+
# Download links for your files
|
1742
|
+
# @param [Hash] opts the optional parameters
|
1743
|
+
# @option opts [String] :isrc
|
1744
|
+
# @option opts [String] :contributor
|
1745
|
+
# @option opts [String] :main_artist
|
1746
|
+
# @option opts [String] :composer
|
1747
|
+
# @option opts [String] :title
|
1748
|
+
# @option opts [String] :language
|
1749
|
+
# @option opts [Array<String>] :genre_names
|
1750
|
+
# @option opts [Array<String>] :tag_names
|
1751
|
+
# @option opts [Time] :release_date
|
1752
|
+
# @option opts [String] :primary_mood_cluster
|
1753
|
+
# @option opts [String] :secondary_mood_cluster
|
1754
|
+
# @option opts [String] :tertiary_mood_cluster
|
1755
|
+
# @option opts [String] :valence
|
1756
|
+
# @option opts [String] :arousal
|
1757
|
+
# @option opts [String] :pleasantness
|
1758
|
+
# @option opts [String] :engagement
|
1759
|
+
# @option opts [String] :vocals
|
1760
|
+
# @option opts [String] :dominant_instrument
|
1761
|
+
# @option opts [String] :secondary_instrument
|
1762
|
+
# @option opts [String] :tertiary_instrument
|
1763
|
+
# @option opts [String] :energy
|
1764
|
+
# @option opts [String] :sound_generation
|
1765
|
+
# @option opts [String] :tempo
|
1766
|
+
# @option opts [String] :scale
|
1767
|
+
# @option opts [String] :rhythm
|
1768
|
+
# @option opts [String] :primary_sound_character
|
1769
|
+
# @option opts [String] :timbre
|
1770
|
+
# @option opts [String] :roughness
|
1771
|
+
# @option opts [String] :tonality
|
1772
|
+
# @option opts [String] :harmony
|
1773
|
+
# @option opts [String] :texture
|
1774
|
+
# @option opts [String] :groovyness
|
1775
|
+
# @option opts [String] :space
|
1776
|
+
# @option opts [String] :production_rating
|
1777
|
+
# @option opts [String] :performance_rating
|
1778
|
+
# @option opts [String] :song_rating
|
1779
|
+
# @option opts [String] :audience_age
|
1780
|
+
# @option opts [String] :audience_region
|
1781
|
+
# @option opts [String] :audience_gender
|
1782
|
+
# @option opts [String] :songtradr_track_id
|
1783
|
+
# @option opts [String] :usage_name
|
1784
|
+
# @option opts [Integer] :bpm_min
|
1785
|
+
# @option opts [Integer] :bpm_max
|
1786
|
+
# @option opts [String] :name
|
1787
|
+
# @option opts [String] :folder
|
1788
|
+
# @option opts [String] :extension
|
1789
|
+
# @option opts [Time] :upload_end_time
|
1790
|
+
# @option opts [Time] :min_upload_end_time
|
1791
|
+
# @option opts [Time] :max_upload_end_time
|
1792
|
+
# @option opts [String] :fingerprint_status
|
1793
|
+
# @option opts [String] :inference_status
|
1794
|
+
# @option opts [Integer] :page Zero-based page index (0..N) (default to 0)
|
1795
|
+
# @option opts [Integer] :size The size of the page to be returned (default to 100)
|
1796
|
+
# @option opts [Array<String>] :sort Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
|
1797
|
+
# @return [Array<FileMinimalWithUrlDTO>]
|
1798
|
+
def user_files_download(opts = {})
|
1799
|
+
data, _status_code, _headers = user_files_download_with_http_info(opts)
|
1800
|
+
data
|
1801
|
+
end
|
1802
|
+
|
1803
|
+
# Download links for your files
|
1804
|
+
# @param [Hash] opts the optional parameters
|
1805
|
+
# @option opts [String] :isrc
|
1806
|
+
# @option opts [String] :contributor
|
1807
|
+
# @option opts [String] :main_artist
|
1808
|
+
# @option opts [String] :composer
|
1809
|
+
# @option opts [String] :title
|
1810
|
+
# @option opts [String] :language
|
1811
|
+
# @option opts [Array<String>] :genre_names
|
1812
|
+
# @option opts [Array<String>] :tag_names
|
1813
|
+
# @option opts [Time] :release_date
|
1814
|
+
# @option opts [String] :primary_mood_cluster
|
1815
|
+
# @option opts [String] :secondary_mood_cluster
|
1816
|
+
# @option opts [String] :tertiary_mood_cluster
|
1817
|
+
# @option opts [String] :valence
|
1818
|
+
# @option opts [String] :arousal
|
1819
|
+
# @option opts [String] :pleasantness
|
1820
|
+
# @option opts [String] :engagement
|
1821
|
+
# @option opts [String] :vocals
|
1822
|
+
# @option opts [String] :dominant_instrument
|
1823
|
+
# @option opts [String] :secondary_instrument
|
1824
|
+
# @option opts [String] :tertiary_instrument
|
1825
|
+
# @option opts [String] :energy
|
1826
|
+
# @option opts [String] :sound_generation
|
1827
|
+
# @option opts [String] :tempo
|
1828
|
+
# @option opts [String] :scale
|
1829
|
+
# @option opts [String] :rhythm
|
1830
|
+
# @option opts [String] :primary_sound_character
|
1831
|
+
# @option opts [String] :timbre
|
1832
|
+
# @option opts [String] :roughness
|
1833
|
+
# @option opts [String] :tonality
|
1834
|
+
# @option opts [String] :harmony
|
1835
|
+
# @option opts [String] :texture
|
1836
|
+
# @option opts [String] :groovyness
|
1837
|
+
# @option opts [String] :space
|
1838
|
+
# @option opts [String] :production_rating
|
1839
|
+
# @option opts [String] :performance_rating
|
1840
|
+
# @option opts [String] :song_rating
|
1841
|
+
# @option opts [String] :audience_age
|
1842
|
+
# @option opts [String] :audience_region
|
1843
|
+
# @option opts [String] :audience_gender
|
1844
|
+
# @option opts [String] :songtradr_track_id
|
1845
|
+
# @option opts [String] :usage_name
|
1846
|
+
# @option opts [Integer] :bpm_min
|
1847
|
+
# @option opts [Integer] :bpm_max
|
1848
|
+
# @option opts [String] :name
|
1849
|
+
# @option opts [String] :folder
|
1850
|
+
# @option opts [String] :extension
|
1851
|
+
# @option opts [Time] :upload_end_time
|
1852
|
+
# @option opts [Time] :min_upload_end_time
|
1853
|
+
# @option opts [Time] :max_upload_end_time
|
1854
|
+
# @option opts [String] :fingerprint_status
|
1855
|
+
# @option opts [String] :inference_status
|
1856
|
+
# @option opts [Integer] :page Zero-based page index (0..N) (default to 0)
|
1857
|
+
# @option opts [Integer] :size The size of the page to be returned (default to 100)
|
1858
|
+
# @option opts [Array<String>] :sort Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
|
1859
|
+
# @return [Array<(Array<FileMinimalWithUrlDTO>, Integer, Hash)>] Array<FileMinimalWithUrlDTO> data, response status code and response headers
|
1860
|
+
def user_files_download_with_http_info(opts = {})
|
1861
|
+
if @api_client.config.debugging
|
1862
|
+
@api_client.config.logger.debug 'Calling API: UserApi.user_files_download ...'
|
1863
|
+
end
|
1864
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
1865
|
+
if @api_client.config.client_side_validation && opts[:'primary_mood_cluster'] && !allowable_values.include?(opts[:'primary_mood_cluster'])
|
1866
|
+
fail ArgumentError, "invalid value for \"primary_mood_cluster\", must be one of #{allowable_values}"
|
1867
|
+
end
|
1868
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
1869
|
+
if @api_client.config.client_side_validation && opts[:'secondary_mood_cluster'] && !allowable_values.include?(opts[:'secondary_mood_cluster'])
|
1870
|
+
fail ArgumentError, "invalid value for \"secondary_mood_cluster\", must be one of #{allowable_values}"
|
1871
|
+
end
|
1872
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
1873
|
+
if @api_client.config.client_side_validation && opts[:'tertiary_mood_cluster'] && !allowable_values.include?(opts[:'tertiary_mood_cluster'])
|
1874
|
+
fail ArgumentError, "invalid value for \"tertiary_mood_cluster\", must be one of #{allowable_values}"
|
1875
|
+
end
|
1876
|
+
allowable_values = ["very sad", "sad", "moderate valence", "positive", "very positive", "varying valence"]
|
1877
|
+
if @api_client.config.client_side_validation && opts[:'valence'] && !allowable_values.include?(opts[:'valence'])
|
1878
|
+
fail ArgumentError, "invalid value for \"valence\", must be one of #{allowable_values}"
|
1879
|
+
end
|
1880
|
+
allowable_values = ["very calm", "calm", "moderate arousal", "energetic", "very energetic", "varying arousal"]
|
1881
|
+
if @api_client.config.client_side_validation && opts[:'arousal'] && !allowable_values.include?(opts[:'arousal'])
|
1882
|
+
fail ArgumentError, "invalid value for \"arousal\", must be one of #{allowable_values}"
|
1883
|
+
end
|
1884
|
+
allowable_values = ["very unpleasant", "unpleasant", "neutral pleasantness", "pleasant", "very pleasant", "varying pleasantness"]
|
1885
|
+
if @api_client.config.client_side_validation && opts[:'pleasantness'] && !allowable_values.include?(opts[:'pleasantness'])
|
1886
|
+
fail ArgumentError, "invalid value for \"pleasantness\", must be one of #{allowable_values}"
|
1887
|
+
end
|
1888
|
+
allowable_values = ["very unengaging", "unengaging", "neutral engagement", "engaging", "very engaging", "varying engagement"]
|
1889
|
+
if @api_client.config.client_side_validation && opts[:'engagement'] && !allowable_values.include?(opts[:'engagement'])
|
1890
|
+
fail ArgumentError, "invalid value for \"engagement\", must be one of #{allowable_values}"
|
1891
|
+
end
|
1892
|
+
allowable_values = ["instrumental", "female vocals", "male vocals", "mixed vocals", "diverse gender vocals"]
|
1893
|
+
if @api_client.config.client_side_validation && opts[:'vocals'] && !allowable_values.include?(opts[:'vocals'])
|
1894
|
+
fail ArgumentError, "invalid value for \"vocals\", must be one of #{allowable_values}"
|
1895
|
+
end
|
1896
|
+
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"]
|
1897
|
+
if @api_client.config.client_side_validation && opts[:'dominant_instrument'] && !allowable_values.include?(opts[:'dominant_instrument'])
|
1898
|
+
fail ArgumentError, "invalid value for \"dominant_instrument\", must be one of #{allowable_values}"
|
1899
|
+
end
|
1900
|
+
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"]
|
1901
|
+
if @api_client.config.client_side_validation && opts[:'secondary_instrument'] && !allowable_values.include?(opts[:'secondary_instrument'])
|
1902
|
+
fail ArgumentError, "invalid value for \"secondary_instrument\", must be one of #{allowable_values}"
|
1903
|
+
end
|
1904
|
+
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"]
|
1905
|
+
if @api_client.config.client_side_validation && opts[:'tertiary_instrument'] && !allowable_values.include?(opts[:'tertiary_instrument'])
|
1906
|
+
fail ArgumentError, "invalid value for \"tertiary_instrument\", must be one of #{allowable_values}"
|
1907
|
+
end
|
1908
|
+
allowable_values = ["very quiet", "quiet", "moderate", "loud", "very loud", "dynamic"]
|
1909
|
+
if @api_client.config.client_side_validation && opts[:'energy'] && !allowable_values.include?(opts[:'energy'])
|
1910
|
+
fail ArgumentError, "invalid value for \"energy\", must be one of #{allowable_values}"
|
1911
|
+
end
|
1912
|
+
allowable_values = ["acoustic", "electric", "electronic", "mixed sound generation"]
|
1913
|
+
if @api_client.config.client_side_validation && opts[:'sound_generation'] && !allowable_values.include?(opts[:'sound_generation'])
|
1914
|
+
fail ArgumentError, "invalid value for \"sound_generation\", must be one of #{allowable_values}"
|
1915
|
+
end
|
1916
|
+
allowable_values = ["very slow", "slow", "mid-tempo", "fast", "very fast", "varying tempo"]
|
1917
|
+
if @api_client.config.client_side_validation && opts[:'tempo'] && !allowable_values.include?(opts[:'tempo'])
|
1918
|
+
fail ArgumentError, "invalid value for \"tempo\", must be one of #{allowable_values}"
|
1919
|
+
end
|
1920
|
+
allowable_values = ["major key", "minor key", "neutral key"]
|
1921
|
+
if @api_client.config.client_side_validation && opts[:'scale'] && !allowable_values.include?(opts[:'scale'])
|
1922
|
+
fail ArgumentError, "invalid value for \"scale\", must be one of #{allowable_values}"
|
1923
|
+
end
|
1924
|
+
allowable_values = ["common time", "triple meter", "complex time signature", "binary rhythm", "ternary rhythm"]
|
1925
|
+
if @api_client.config.client_side_validation && opts[:'rhythm'] && !allowable_values.include?(opts[:'rhythm'])
|
1926
|
+
fail ArgumentError, "invalid value for \"rhythm\", must be one of #{allowable_values}"
|
1927
|
+
end
|
1928
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
1929
|
+
if @api_client.config.client_side_validation && opts[:'primary_sound_character'] && !allowable_values.include?(opts[:'primary_sound_character'])
|
1930
|
+
fail ArgumentError, "invalid value for \"primary_sound_character\", must be one of #{allowable_values}"
|
1931
|
+
end
|
1932
|
+
allowable_values = ["very warm", "warm", "moderate timbre", "bright", "very bright"]
|
1933
|
+
if @api_client.config.client_side_validation && opts[:'timbre'] && !allowable_values.include?(opts[:'timbre'])
|
1934
|
+
fail ArgumentError, "invalid value for \"timbre\", must be one of #{allowable_values}"
|
1935
|
+
end
|
1936
|
+
allowable_values = ["very clear", "clear", "moderate roughness", "distorted", "very distorted"]
|
1937
|
+
if @api_client.config.client_side_validation && opts[:'roughness'] && !allowable_values.include?(opts[:'roughness'])
|
1938
|
+
fail ArgumentError, "invalid value for \"roughness\", must be one of #{allowable_values}"
|
1939
|
+
end
|
1940
|
+
allowable_values = ["monotonous", "moderate melodiousness", "melodious", "atonal"]
|
1941
|
+
if @api_client.config.client_side_validation && opts[:'tonality'] && !allowable_values.include?(opts[:'tonality'])
|
1942
|
+
fail ArgumentError, "invalid value for \"tonality\", must be one of #{allowable_values}"
|
1943
|
+
end
|
1944
|
+
allowable_values = ["very dissonant", "dissonant", "moderate harmonies", "harmonious", "very harmonious"]
|
1945
|
+
if @api_client.config.client_side_validation && opts[:'harmony'] && !allowable_values.include?(opts[:'harmony'])
|
1946
|
+
fail ArgumentError, "invalid value for \"harmony\", must be one of #{allowable_values}"
|
1947
|
+
end
|
1948
|
+
allowable_values = ["very thin", "thin", "moderate texture", "full", "very full"]
|
1949
|
+
if @api_client.config.client_side_validation && opts[:'texture'] && !allowable_values.include?(opts[:'texture'])
|
1950
|
+
fail ArgumentError, "invalid value for \"texture\", must be one of #{allowable_values}"
|
1951
|
+
end
|
1952
|
+
allowable_values = ["very steady", "steady", "moderate rhythm feel", "groovy", "very groovy"]
|
1953
|
+
if @api_client.config.client_side_validation && opts[:'groovyness'] && !allowable_values.include?(opts[:'groovyness'])
|
1954
|
+
fail ArgumentError, "invalid value for \"groovyness\", must be one of #{allowable_values}"
|
1955
|
+
end
|
1956
|
+
allowable_values = ["very compact", "compact", "moderate space", "wide", "very wide"]
|
1957
|
+
if @api_client.config.client_side_validation && opts[:'space'] && !allowable_values.include?(opts[:'space'])
|
1958
|
+
fail ArgumentError, "invalid value for \"space\", must be one of #{allowable_values}"
|
1959
|
+
end
|
1960
|
+
allowable_values = ["low production quality", "medium production quality", "high production quality"]
|
1961
|
+
if @api_client.config.client_side_validation && opts[:'production_rating'] && !allowable_values.include?(opts[:'production_rating'])
|
1962
|
+
fail ArgumentError, "invalid value for \"production_rating\", must be one of #{allowable_values}"
|
1963
|
+
end
|
1964
|
+
allowable_values = ["low performance quality", "medium performance quality", "high performance quality"]
|
1965
|
+
if @api_client.config.client_side_validation && opts[:'performance_rating'] && !allowable_values.include?(opts[:'performance_rating'])
|
1966
|
+
fail ArgumentError, "invalid value for \"performance_rating\", must be one of #{allowable_values}"
|
1967
|
+
end
|
1968
|
+
allowable_values = ["low song quality", "medium song quality", "high song quality"]
|
1969
|
+
if @api_client.config.client_side_validation && opts[:'song_rating'] && !allowable_values.include?(opts[:'song_rating'])
|
1970
|
+
fail ArgumentError, "invalid value for \"song_rating\", must be one of #{allowable_values}"
|
1971
|
+
end
|
1972
|
+
allowable_values = ["Generation Z", "Younger Generation Y", "Older Generation Y", "Generation X", "Younger Generation B", "Older Generation B"]
|
1973
|
+
if @api_client.config.client_side_validation && opts[:'audience_age'] && !allowable_values.include?(opts[:'audience_age'])
|
1974
|
+
fail ArgumentError, "invalid value for \"audience_age\", must be one of #{allowable_values}"
|
1975
|
+
end
|
1976
|
+
allowable_values = ["Australia and New Zealand", "Central America and the Carribean", "Central and Southern Asia", "Eastern Asia", "Eastern Europe", "Northern Africa and Western Asia", "Northern America", "Oceania", "South America", "South-Eastern Asia", "Southern Europe", "Sub-Saharan Africa", "Western and Northern Europe"]
|
1977
|
+
if @api_client.config.client_side_validation && opts[:'audience_region'] && !allowable_values.include?(opts[:'audience_region'])
|
1978
|
+
fail ArgumentError, "invalid value for \"audience_region\", must be one of #{allowable_values}"
|
1979
|
+
end
|
1980
|
+
allowable_values = ["male", "female"]
|
1981
|
+
if @api_client.config.client_side_validation && opts[:'audience_gender'] && !allowable_values.include?(opts[:'audience_gender'])
|
1982
|
+
fail ArgumentError, "invalid value for \"audience_gender\", must be one of #{allowable_values}"
|
1983
|
+
end
|
1984
|
+
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 0
|
1985
|
+
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling UserApi.user_files_download, must be greater than or equal to 0.'
|
1986
|
+
end
|
1987
|
+
|
1988
|
+
if @api_client.config.client_side_validation && !opts[:'size'].nil? && opts[:'size'] < 1
|
1989
|
+
fail ArgumentError, 'invalid value for "opts[:"size"]" when calling UserApi.user_files_download, must be greater than or equal to 1.'
|
1990
|
+
end
|
1991
|
+
|
1992
|
+
# resource path
|
1993
|
+
local_var_path = '/api/v1/user/filesDownload'
|
1994
|
+
|
1995
|
+
# query parameters
|
1996
|
+
query_params = opts[:query_params] || {}
|
1997
|
+
query_params[:'isrc'] = opts[:'isrc'] if !opts[:'isrc'].nil?
|
1998
|
+
query_params[:'contributor'] = opts[:'contributor'] if !opts[:'contributor'].nil?
|
1999
|
+
query_params[:'mainArtist'] = opts[:'main_artist'] if !opts[:'main_artist'].nil?
|
2000
|
+
query_params[:'composer'] = opts[:'composer'] if !opts[:'composer'].nil?
|
2001
|
+
query_params[:'title'] = opts[:'title'] if !opts[:'title'].nil?
|
2002
|
+
query_params[:'language'] = opts[:'language'] if !opts[:'language'].nil?
|
2003
|
+
query_params[:'genreNames'] = @api_client.build_collection_param(opts[:'genre_names'], :multi) if !opts[:'genre_names'].nil?
|
2004
|
+
query_params[:'tagNames'] = @api_client.build_collection_param(opts[:'tag_names'], :multi) if !opts[:'tag_names'].nil?
|
2005
|
+
query_params[:'releaseDate'] = opts[:'release_date'] if !opts[:'release_date'].nil?
|
2006
|
+
query_params[:'primaryMoodCluster'] = opts[:'primary_mood_cluster'] if !opts[:'primary_mood_cluster'].nil?
|
2007
|
+
query_params[:'secondaryMoodCluster'] = opts[:'secondary_mood_cluster'] if !opts[:'secondary_mood_cluster'].nil?
|
2008
|
+
query_params[:'tertiaryMoodCluster'] = opts[:'tertiary_mood_cluster'] if !opts[:'tertiary_mood_cluster'].nil?
|
2009
|
+
query_params[:'valence'] = opts[:'valence'] if !opts[:'valence'].nil?
|
2010
|
+
query_params[:'arousal'] = opts[:'arousal'] if !opts[:'arousal'].nil?
|
2011
|
+
query_params[:'pleasantness'] = opts[:'pleasantness'] if !opts[:'pleasantness'].nil?
|
2012
|
+
query_params[:'engagement'] = opts[:'engagement'] if !opts[:'engagement'].nil?
|
2013
|
+
query_params[:'vocals'] = opts[:'vocals'] if !opts[:'vocals'].nil?
|
2014
|
+
query_params[:'dominantInstrument'] = opts[:'dominant_instrument'] if !opts[:'dominant_instrument'].nil?
|
2015
|
+
query_params[:'secondaryInstrument'] = opts[:'secondary_instrument'] if !opts[:'secondary_instrument'].nil?
|
2016
|
+
query_params[:'tertiaryInstrument'] = opts[:'tertiary_instrument'] if !opts[:'tertiary_instrument'].nil?
|
2017
|
+
query_params[:'energy'] = opts[:'energy'] if !opts[:'energy'].nil?
|
2018
|
+
query_params[:'soundGeneration'] = opts[:'sound_generation'] if !opts[:'sound_generation'].nil?
|
2019
|
+
query_params[:'tempo'] = opts[:'tempo'] if !opts[:'tempo'].nil?
|
2020
|
+
query_params[:'scale'] = opts[:'scale'] if !opts[:'scale'].nil?
|
2021
|
+
query_params[:'rhythm'] = opts[:'rhythm'] if !opts[:'rhythm'].nil?
|
2022
|
+
query_params[:'primarySoundCharacter'] = opts[:'primary_sound_character'] if !opts[:'primary_sound_character'].nil?
|
2023
|
+
query_params[:'timbre'] = opts[:'timbre'] if !opts[:'timbre'].nil?
|
2024
|
+
query_params[:'roughness'] = opts[:'roughness'] if !opts[:'roughness'].nil?
|
2025
|
+
query_params[:'tonality'] = opts[:'tonality'] if !opts[:'tonality'].nil?
|
2026
|
+
query_params[:'harmony'] = opts[:'harmony'] if !opts[:'harmony'].nil?
|
2027
|
+
query_params[:'texture'] = opts[:'texture'] if !opts[:'texture'].nil?
|
2028
|
+
query_params[:'groovyness'] = opts[:'groovyness'] if !opts[:'groovyness'].nil?
|
2029
|
+
query_params[:'space'] = opts[:'space'] if !opts[:'space'].nil?
|
2030
|
+
query_params[:'productionRating'] = opts[:'production_rating'] if !opts[:'production_rating'].nil?
|
2031
|
+
query_params[:'performanceRating'] = opts[:'performance_rating'] if !opts[:'performance_rating'].nil?
|
2032
|
+
query_params[:'songRating'] = opts[:'song_rating'] if !opts[:'song_rating'].nil?
|
2033
|
+
query_params[:'audienceAge'] = opts[:'audience_age'] if !opts[:'audience_age'].nil?
|
2034
|
+
query_params[:'audienceRegion'] = opts[:'audience_region'] if !opts[:'audience_region'].nil?
|
2035
|
+
query_params[:'audienceGender'] = opts[:'audience_gender'] if !opts[:'audience_gender'].nil?
|
2036
|
+
query_params[:'songtradrTrackId'] = opts[:'songtradr_track_id'] if !opts[:'songtradr_track_id'].nil?
|
2037
|
+
query_params[:'usageName'] = opts[:'usage_name'] if !opts[:'usage_name'].nil?
|
2038
|
+
query_params[:'bpmMin'] = opts[:'bpm_min'] if !opts[:'bpm_min'].nil?
|
2039
|
+
query_params[:'bpmMax'] = opts[:'bpm_max'] if !opts[:'bpm_max'].nil?
|
2040
|
+
query_params[:'name'] = opts[:'name'] if !opts[:'name'].nil?
|
2041
|
+
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
2042
|
+
query_params[:'extension'] = opts[:'extension'] if !opts[:'extension'].nil?
|
2043
|
+
query_params[:'uploadEndTime'] = opts[:'upload_end_time'] if !opts[:'upload_end_time'].nil?
|
2044
|
+
query_params[:'minUploadEndTime'] = opts[:'min_upload_end_time'] if !opts[:'min_upload_end_time'].nil?
|
2045
|
+
query_params[:'maxUploadEndTime'] = opts[:'max_upload_end_time'] if !opts[:'max_upload_end_time'].nil?
|
2046
|
+
query_params[:'fingerprintStatus'] = opts[:'fingerprint_status'] if !opts[:'fingerprint_status'].nil?
|
2047
|
+
query_params[:'inferenceStatus'] = opts[:'inference_status'] if !opts[:'inference_status'].nil?
|
2048
|
+
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
2049
|
+
query_params[:'size'] = opts[:'size'] if !opts[:'size'].nil?
|
2050
|
+
query_params[:'sort'] = @api_client.build_collection_param(opts[:'sort'], :multi) if !opts[:'sort'].nil?
|
2051
|
+
|
2052
|
+
# header parameters
|
2053
|
+
header_params = opts[:header_params] || {}
|
2054
|
+
# HTTP header 'Accept' (if needed)
|
2055
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
2056
|
+
|
2057
|
+
# form parameters
|
2058
|
+
form_params = opts[:form_params] || {}
|
2059
|
+
|
2060
|
+
# http body (model)
|
2061
|
+
post_body = opts[:debug_body]
|
2062
|
+
|
2063
|
+
# return_type
|
2064
|
+
return_type = opts[:debug_return_type] || 'Array<FileMinimalWithUrlDTO>'
|
2065
|
+
|
2066
|
+
# auth_names
|
2067
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
2068
|
+
|
2069
|
+
new_options = opts.merge(
|
2070
|
+
:operation => :"UserApi.user_files_download",
|
2071
|
+
:header_params => header_params,
|
2072
|
+
:query_params => query_params,
|
2073
|
+
:form_params => form_params,
|
2074
|
+
:body => post_body,
|
2075
|
+
:auth_names => auth_names,
|
2076
|
+
:return_type => return_type
|
2077
|
+
)
|
2078
|
+
|
2079
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
2080
|
+
if @api_client.config.debugging
|
2081
|
+
@api_client.config.logger.debug "API called: UserApi#user_files_download\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2082
|
+
end
|
2083
|
+
return data, status_code, headers
|
2084
|
+
end
|
2085
|
+
|
2086
|
+
# Status details for files.
|
2087
|
+
# @param object_keys [String] Comma-separated list of objectKeys of the files.
|
2088
|
+
# @param [Hash] opts the optional parameters
|
2089
|
+
# @return [Array<FileSmallDTO>]
|
2090
|
+
def user_files_status(object_keys, opts = {})
|
2091
|
+
data, _status_code, _headers = user_files_status_with_http_info(object_keys, opts)
|
2092
|
+
data
|
2093
|
+
end
|
2094
|
+
|
2095
|
+
# Status details for files.
|
2096
|
+
# @param object_keys [String] Comma-separated list of objectKeys of the files.
|
2097
|
+
# @param [Hash] opts the optional parameters
|
2098
|
+
# @return [Array<(Array<FileSmallDTO>, Integer, Hash)>] Array<FileSmallDTO> data, response status code and response headers
|
2099
|
+
def user_files_status_with_http_info(object_keys, opts = {})
|
2100
|
+
if @api_client.config.debugging
|
2101
|
+
@api_client.config.logger.debug 'Calling API: UserApi.user_files_status ...'
|
2102
|
+
end
|
2103
|
+
# verify the required parameter 'object_keys' is set
|
2104
|
+
if @api_client.config.client_side_validation && object_keys.nil?
|
2105
|
+
fail ArgumentError, "Missing the required parameter 'object_keys' when calling UserApi.user_files_status"
|
2106
|
+
end
|
2107
|
+
# resource path
|
2108
|
+
local_var_path = '/api/v1/user/filesStatus'
|
2109
|
+
|
2110
|
+
# query parameters
|
2111
|
+
query_params = opts[:query_params] || {}
|
2112
|
+
query_params[:'objectKeys'] = object_keys
|
2113
|
+
|
2114
|
+
# header parameters
|
2115
|
+
header_params = opts[:header_params] || {}
|
2116
|
+
# HTTP header 'Accept' (if needed)
|
2117
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
2118
|
+
|
2119
|
+
# form parameters
|
2120
|
+
form_params = opts[:form_params] || {}
|
2121
|
+
|
2122
|
+
# http body (model)
|
2123
|
+
post_body = opts[:debug_body]
|
2124
|
+
|
2125
|
+
# return_type
|
2126
|
+
return_type = opts[:debug_return_type] || 'Array<FileSmallDTO>'
|
2127
|
+
|
2128
|
+
# auth_names
|
2129
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
2130
|
+
|
2131
|
+
new_options = opts.merge(
|
2132
|
+
:operation => :"UserApi.user_files_status",
|
2133
|
+
:header_params => header_params,
|
2134
|
+
:query_params => query_params,
|
2135
|
+
:form_params => form_params,
|
2136
|
+
:body => post_body,
|
2137
|
+
:auth_names => auth_names,
|
2138
|
+
:return_type => return_type
|
2139
|
+
)
|
2140
|
+
|
2141
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
2142
|
+
if @api_client.config.debugging
|
2143
|
+
@api_client.config.logger.debug "API called: UserApi#user_files_status\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2144
|
+
end
|
2145
|
+
return data, status_code, headers
|
2146
|
+
end
|
2147
|
+
|
2148
|
+
# Summary fo your files.
|
2149
|
+
# @param [Hash] opts the optional parameters
|
2150
|
+
# @option opts [String] :isrc Search for a ISRC
|
2151
|
+
# @option opts [String] :contributor Search for a name that was involved as any contributor.
|
2152
|
+
# @option opts [String] :main_artist Search for a main artist.
|
2153
|
+
# @option opts [String] :composer Search for a composer.
|
2154
|
+
# @option opts [String] :title Search for a title.
|
2155
|
+
# @option opts [String] :language Search for a language of the lyrics.
|
2156
|
+
# @option opts [Array<String>] :genre_names
|
2157
|
+
# @option opts [Array<String>] :tag_names
|
2158
|
+
# @option opts [Time] :release_date
|
2159
|
+
# @option opts [String] :primary_mood_cluster
|
2160
|
+
# @option opts [String] :secondary_mood_cluster
|
2161
|
+
# @option opts [String] :tertiary_mood_cluster
|
2162
|
+
# @option opts [String] :valence
|
2163
|
+
# @option opts [String] :arousal
|
2164
|
+
# @option opts [String] :pleasantness
|
2165
|
+
# @option opts [String] :engagement
|
2166
|
+
# @option opts [String] :vocals
|
2167
|
+
# @option opts [String] :dominant_instrument
|
2168
|
+
# @option opts [String] :secondary_instrument
|
2169
|
+
# @option opts [String] :tertiary_instrument
|
2170
|
+
# @option opts [String] :energy
|
2171
|
+
# @option opts [String] :sound_generation
|
2172
|
+
# @option opts [String] :tempo
|
2173
|
+
# @option opts [String] :scale
|
2174
|
+
# @option opts [String] :rhythm
|
2175
|
+
# @option opts [String] :primary_sound_character
|
2176
|
+
# @option opts [String] :timbre
|
2177
|
+
# @option opts [String] :roughness
|
2178
|
+
# @option opts [String] :tonality
|
2179
|
+
# @option opts [String] :harmony
|
2180
|
+
# @option opts [String] :texture
|
2181
|
+
# @option opts [String] :groovyness
|
2182
|
+
# @option opts [String] :space
|
2183
|
+
# @option opts [String] :production_rating
|
2184
|
+
# @option opts [String] :performance_rating
|
2185
|
+
# @option opts [String] :song_rating
|
2186
|
+
# @option opts [String] :audience_age
|
2187
|
+
# @option opts [String] :audience_region
|
2188
|
+
# @option opts [String] :audience_gender
|
2189
|
+
# @option opts [String] :origin_decade
|
2190
|
+
# @option opts [String] :curateability
|
2191
|
+
# @option opts [String] :use_case
|
2192
|
+
# @option opts [String] :channel_suitability
|
2193
|
+
# @option opts [String] :similar_to_recording
|
2194
|
+
# @option opts [String] :songtradr_track_id
|
2195
|
+
# @option opts [String] :usage_name
|
2196
|
+
# @option opts [Integer] :bpm_min Search for a minimal bpm.
|
2197
|
+
# @option opts [Integer] :bpm_max Search for a maximal bpm.
|
2198
|
+
# @option opts [String] :name Search for a file name.
|
2199
|
+
# @option opts [String] :folder Search for a folder.
|
2200
|
+
# @option opts [String] :extension Search for a file extension.
|
2201
|
+
# @option opts [Time] :upload_end_time
|
2202
|
+
# @option opts [Time] :min_upload_end_time
|
2203
|
+
# @option opts [Time] :max_upload_end_time
|
2204
|
+
# @option opts [String] :fingerprint_status Search for a fingerprint status.
|
2205
|
+
# @option opts [String] :inference_status Search for a inference status.
|
2206
|
+
# @return [FilesSummaryDTO]
|
2207
|
+
def user_files_summary(opts = {})
|
2208
|
+
data, _status_code, _headers = user_files_summary_with_http_info(opts)
|
2209
|
+
data
|
2210
|
+
end
|
2211
|
+
|
2212
|
+
# Summary fo your files.
|
2213
|
+
# @param [Hash] opts the optional parameters
|
2214
|
+
# @option opts [String] :isrc Search for a ISRC
|
2215
|
+
# @option opts [String] :contributor Search for a name that was involved as any contributor.
|
2216
|
+
# @option opts [String] :main_artist Search for a main artist.
|
2217
|
+
# @option opts [String] :composer Search for a composer.
|
2218
|
+
# @option opts [String] :title Search for a title.
|
2219
|
+
# @option opts [String] :language Search for a language of the lyrics.
|
2220
|
+
# @option opts [Array<String>] :genre_names
|
2221
|
+
# @option opts [Array<String>] :tag_names
|
2222
|
+
# @option opts [Time] :release_date
|
2223
|
+
# @option opts [String] :primary_mood_cluster
|
2224
|
+
# @option opts [String] :secondary_mood_cluster
|
2225
|
+
# @option opts [String] :tertiary_mood_cluster
|
2226
|
+
# @option opts [String] :valence
|
2227
|
+
# @option opts [String] :arousal
|
2228
|
+
# @option opts [String] :pleasantness
|
2229
|
+
# @option opts [String] :engagement
|
2230
|
+
# @option opts [String] :vocals
|
2231
|
+
# @option opts [String] :dominant_instrument
|
2232
|
+
# @option opts [String] :secondary_instrument
|
2233
|
+
# @option opts [String] :tertiary_instrument
|
2234
|
+
# @option opts [String] :energy
|
2235
|
+
# @option opts [String] :sound_generation
|
2236
|
+
# @option opts [String] :tempo
|
2237
|
+
# @option opts [String] :scale
|
2238
|
+
# @option opts [String] :rhythm
|
2239
|
+
# @option opts [String] :primary_sound_character
|
2240
|
+
# @option opts [String] :timbre
|
2241
|
+
# @option opts [String] :roughness
|
2242
|
+
# @option opts [String] :tonality
|
2243
|
+
# @option opts [String] :harmony
|
2244
|
+
# @option opts [String] :texture
|
2245
|
+
# @option opts [String] :groovyness
|
2246
|
+
# @option opts [String] :space
|
2247
|
+
# @option opts [String] :production_rating
|
2248
|
+
# @option opts [String] :performance_rating
|
2249
|
+
# @option opts [String] :song_rating
|
2250
|
+
# @option opts [String] :audience_age
|
2251
|
+
# @option opts [String] :audience_region
|
2252
|
+
# @option opts [String] :audience_gender
|
2253
|
+
# @option opts [String] :origin_decade
|
2254
|
+
# @option opts [String] :curateability
|
2255
|
+
# @option opts [String] :use_case
|
2256
|
+
# @option opts [String] :channel_suitability
|
2257
|
+
# @option opts [String] :similar_to_recording
|
2258
|
+
# @option opts [String] :songtradr_track_id
|
2259
|
+
# @option opts [String] :usage_name
|
2260
|
+
# @option opts [Integer] :bpm_min Search for a minimal bpm.
|
2261
|
+
# @option opts [Integer] :bpm_max Search for a maximal bpm.
|
2262
|
+
# @option opts [String] :name Search for a file name.
|
2263
|
+
# @option opts [String] :folder Search for a folder.
|
2264
|
+
# @option opts [String] :extension Search for a file extension.
|
2265
|
+
# @option opts [Time] :upload_end_time
|
2266
|
+
# @option opts [Time] :min_upload_end_time
|
2267
|
+
# @option opts [Time] :max_upload_end_time
|
2268
|
+
# @option opts [String] :fingerprint_status Search for a fingerprint status.
|
2269
|
+
# @option opts [String] :inference_status Search for a inference status.
|
2270
|
+
# @return [Array<(FilesSummaryDTO, Integer, Hash)>] FilesSummaryDTO data, response status code and response headers
|
2271
|
+
def user_files_summary_with_http_info(opts = {})
|
2272
|
+
if @api_client.config.debugging
|
2273
|
+
@api_client.config.logger.debug 'Calling API: UserApi.user_files_summary ...'
|
2274
|
+
end
|
2275
|
+
allowable_values = ["en", "es", "fr", "de", "jp", "cn", "IT", "RU"]
|
2276
|
+
if @api_client.config.client_side_validation && opts[:'language'] && !allowable_values.include?(opts[:'language'])
|
2277
|
+
fail ArgumentError, "invalid value for \"language\", must be one of #{allowable_values}"
|
2278
|
+
end
|
2279
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
2280
|
+
if @api_client.config.client_side_validation && opts[:'primary_mood_cluster'] && !allowable_values.include?(opts[:'primary_mood_cluster'])
|
2281
|
+
fail ArgumentError, "invalid value for \"primary_mood_cluster\", must be one of #{allowable_values}"
|
2282
|
+
end
|
2283
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
2284
|
+
if @api_client.config.client_side_validation && opts[:'secondary_mood_cluster'] && !allowable_values.include?(opts[:'secondary_mood_cluster'])
|
2285
|
+
fail ArgumentError, "invalid value for \"secondary_mood_cluster\", must be one of #{allowable_values}"
|
2286
|
+
end
|
2287
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
2288
|
+
if @api_client.config.client_side_validation && opts[:'tertiary_mood_cluster'] && !allowable_values.include?(opts[:'tertiary_mood_cluster'])
|
2289
|
+
fail ArgumentError, "invalid value for \"tertiary_mood_cluster\", must be one of #{allowable_values}"
|
2290
|
+
end
|
2291
|
+
allowable_values = ["very sad", "sad", "moderate valence", "positive", "very positive", "varying valence"]
|
2292
|
+
if @api_client.config.client_side_validation && opts[:'valence'] && !allowable_values.include?(opts[:'valence'])
|
2293
|
+
fail ArgumentError, "invalid value for \"valence\", must be one of #{allowable_values}"
|
2294
|
+
end
|
2295
|
+
allowable_values = ["very calm", "calm", "moderate arousal", "energetic", "very energetic", "varying arousal"]
|
2296
|
+
if @api_client.config.client_side_validation && opts[:'arousal'] && !allowable_values.include?(opts[:'arousal'])
|
2297
|
+
fail ArgumentError, "invalid value for \"arousal\", must be one of #{allowable_values}"
|
2298
|
+
end
|
2299
|
+
allowable_values = ["very unpleasant", "unpleasant", "neutral pleasantness", "pleasant", "very pleasant", "varying pleasantness"]
|
2300
|
+
if @api_client.config.client_side_validation && opts[:'pleasantness'] && !allowable_values.include?(opts[:'pleasantness'])
|
2301
|
+
fail ArgumentError, "invalid value for \"pleasantness\", must be one of #{allowable_values}"
|
2302
|
+
end
|
2303
|
+
allowable_values = ["very unengaging", "unengaging", "neutral engagement", "engaging", "very engaging", "varying engagement"]
|
2304
|
+
if @api_client.config.client_side_validation && opts[:'engagement'] && !allowable_values.include?(opts[:'engagement'])
|
2305
|
+
fail ArgumentError, "invalid value for \"engagement\", must be one of #{allowable_values}"
|
2306
|
+
end
|
2307
|
+
allowable_values = ["instrumental", "female vocals", "male vocals", "mixed vocals", "diverse gender vocals"]
|
2308
|
+
if @api_client.config.client_side_validation && opts[:'vocals'] && !allowable_values.include?(opts[:'vocals'])
|
2309
|
+
fail ArgumentError, "invalid value for \"vocals\", must be one of #{allowable_values}"
|
2310
|
+
end
|
2311
|
+
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"]
|
2312
|
+
if @api_client.config.client_side_validation && opts[:'dominant_instrument'] && !allowable_values.include?(opts[:'dominant_instrument'])
|
2313
|
+
fail ArgumentError, "invalid value for \"dominant_instrument\", must be one of #{allowable_values}"
|
2314
|
+
end
|
2315
|
+
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"]
|
2316
|
+
if @api_client.config.client_side_validation && opts[:'secondary_instrument'] && !allowable_values.include?(opts[:'secondary_instrument'])
|
2317
|
+
fail ArgumentError, "invalid value for \"secondary_instrument\", must be one of #{allowable_values}"
|
2318
|
+
end
|
2319
|
+
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"]
|
2320
|
+
if @api_client.config.client_side_validation && opts[:'tertiary_instrument'] && !allowable_values.include?(opts[:'tertiary_instrument'])
|
2321
|
+
fail ArgumentError, "invalid value for \"tertiary_instrument\", must be one of #{allowable_values}"
|
2322
|
+
end
|
2323
|
+
allowable_values = ["very quiet", "quiet", "moderate", "loud", "very loud", "dynamic"]
|
2324
|
+
if @api_client.config.client_side_validation && opts[:'energy'] && !allowable_values.include?(opts[:'energy'])
|
2325
|
+
fail ArgumentError, "invalid value for \"energy\", must be one of #{allowable_values}"
|
2326
|
+
end
|
2327
|
+
allowable_values = ["acoustic", "electric", "electronic", "mixed sound generation"]
|
2328
|
+
if @api_client.config.client_side_validation && opts[:'sound_generation'] && !allowable_values.include?(opts[:'sound_generation'])
|
2329
|
+
fail ArgumentError, "invalid value for \"sound_generation\", must be one of #{allowable_values}"
|
2330
|
+
end
|
2331
|
+
allowable_values = ["very slow", "slow", "mid-tempo", "fast", "very fast", "varying tempo"]
|
2332
|
+
if @api_client.config.client_side_validation && opts[:'tempo'] && !allowable_values.include?(opts[:'tempo'])
|
2333
|
+
fail ArgumentError, "invalid value for \"tempo\", must be one of #{allowable_values}"
|
2334
|
+
end
|
2335
|
+
allowable_values = ["major key", "minor key", "neutral key"]
|
2336
|
+
if @api_client.config.client_side_validation && opts[:'scale'] && !allowable_values.include?(opts[:'scale'])
|
2337
|
+
fail ArgumentError, "invalid value for \"scale\", must be one of #{allowable_values}"
|
2338
|
+
end
|
2339
|
+
allowable_values = ["common time", "triple meter", "complex time signature", "binary rhythm", "ternary rhythm"]
|
2340
|
+
if @api_client.config.client_side_validation && opts[:'rhythm'] && !allowable_values.include?(opts[:'rhythm'])
|
2341
|
+
fail ArgumentError, "invalid value for \"rhythm\", must be one of #{allowable_values}"
|
2342
|
+
end
|
2343
|
+
allowable_values = ["aggressive", "amusing", "anxious", "calm", "devotional", "dreamy", "energetic", "enigmatic", "epic", "erotic", "positive", "sad", "scary", "wild"]
|
2344
|
+
if @api_client.config.client_side_validation && opts[:'primary_sound_character'] && !allowable_values.include?(opts[:'primary_sound_character'])
|
2345
|
+
fail ArgumentError, "invalid value for \"primary_sound_character\", must be one of #{allowable_values}"
|
2346
|
+
end
|
2347
|
+
allowable_values = ["very warm", "warm", "moderate timbre", "bright", "very bright"]
|
2348
|
+
if @api_client.config.client_side_validation && opts[:'timbre'] && !allowable_values.include?(opts[:'timbre'])
|
2349
|
+
fail ArgumentError, "invalid value for \"timbre\", must be one of #{allowable_values}"
|
2350
|
+
end
|
2351
|
+
allowable_values = ["very clear", "clear", "moderate roughness", "distorted", "very distorted"]
|
2352
|
+
if @api_client.config.client_side_validation && opts[:'roughness'] && !allowable_values.include?(opts[:'roughness'])
|
2353
|
+
fail ArgumentError, "invalid value for \"roughness\", must be one of #{allowable_values}"
|
2354
|
+
end
|
2355
|
+
allowable_values = ["monotonous", "moderate melodiousness", "melodious", "atonal"]
|
2356
|
+
if @api_client.config.client_side_validation && opts[:'tonality'] && !allowable_values.include?(opts[:'tonality'])
|
2357
|
+
fail ArgumentError, "invalid value for \"tonality\", must be one of #{allowable_values}"
|
2358
|
+
end
|
2359
|
+
allowable_values = ["very dissonant", "dissonant", "moderate harmonies", "harmonious", "very harmonious"]
|
2360
|
+
if @api_client.config.client_side_validation && opts[:'harmony'] && !allowable_values.include?(opts[:'harmony'])
|
2361
|
+
fail ArgumentError, "invalid value for \"harmony\", must be one of #{allowable_values}"
|
2362
|
+
end
|
2363
|
+
allowable_values = ["very thin", "thin", "moderate texture", "full", "very full"]
|
2364
|
+
if @api_client.config.client_side_validation && opts[:'texture'] && !allowable_values.include?(opts[:'texture'])
|
2365
|
+
fail ArgumentError, "invalid value for \"texture\", must be one of #{allowable_values}"
|
2366
|
+
end
|
2367
|
+
allowable_values = ["very steady", "steady", "moderate rhythm feel", "groovy", "very groovy"]
|
2368
|
+
if @api_client.config.client_side_validation && opts[:'groovyness'] && !allowable_values.include?(opts[:'groovyness'])
|
2369
|
+
fail ArgumentError, "invalid value for \"groovyness\", must be one of #{allowable_values}"
|
2370
|
+
end
|
2371
|
+
allowable_values = ["very compact", "compact", "moderate space", "wide", "very wide"]
|
2372
|
+
if @api_client.config.client_side_validation && opts[:'space'] && !allowable_values.include?(opts[:'space'])
|
2373
|
+
fail ArgumentError, "invalid value for \"space\", must be one of #{allowable_values}"
|
2374
|
+
end
|
2375
|
+
allowable_values = ["low production quality", "medium production quality", "high production quality"]
|
2376
|
+
if @api_client.config.client_side_validation && opts[:'production_rating'] && !allowable_values.include?(opts[:'production_rating'])
|
2377
|
+
fail ArgumentError, "invalid value for \"production_rating\", must be one of #{allowable_values}"
|
2378
|
+
end
|
2379
|
+
allowable_values = ["low performance quality", "medium performance quality", "high performance quality"]
|
2380
|
+
if @api_client.config.client_side_validation && opts[:'performance_rating'] && !allowable_values.include?(opts[:'performance_rating'])
|
2381
|
+
fail ArgumentError, "invalid value for \"performance_rating\", must be one of #{allowable_values}"
|
2382
|
+
end
|
2383
|
+
allowable_values = ["low song quality", "medium song quality", "high song quality"]
|
2384
|
+
if @api_client.config.client_side_validation && opts[:'song_rating'] && !allowable_values.include?(opts[:'song_rating'])
|
2385
|
+
fail ArgumentError, "invalid value for \"song_rating\", must be one of #{allowable_values}"
|
2386
|
+
end
|
2387
|
+
allowable_values = ["Generation Z", "Younger Generation Y", "Older Generation Y", "Generation X", "Younger Generation B", "Older Generation B"]
|
2388
|
+
if @api_client.config.client_side_validation && opts[:'audience_age'] && !allowable_values.include?(opts[:'audience_age'])
|
2389
|
+
fail ArgumentError, "invalid value for \"audience_age\", must be one of #{allowable_values}"
|
2390
|
+
end
|
2391
|
+
allowable_values = ["Australia and New Zealand", "Central America and the Carribean", "Central and Southern Asia", "Eastern Asia", "Eastern Europe", "Northern Africa and Western Asia", "Northern America", "Oceania", "South America", "South-Eastern Asia", "Southern Europe", "Sub-Saharan Africa", "Western and Northern Europe"]
|
2392
|
+
if @api_client.config.client_side_validation && opts[:'audience_region'] && !allowable_values.include?(opts[:'audience_region'])
|
2393
|
+
fail ArgumentError, "invalid value for \"audience_region\", must be one of #{allowable_values}"
|
2394
|
+
end
|
2395
|
+
allowable_values = ["male", "female"]
|
2396
|
+
if @api_client.config.client_side_validation && opts[:'audience_gender'] && !allowable_values.include?(opts[:'audience_gender'])
|
2397
|
+
fail ArgumentError, "invalid value for \"audience_gender\", must be one of #{allowable_values}"
|
2398
|
+
end
|
2399
|
+
allowable_values = ["pre-1950s", "1950s", "1960s", "1970s", "1980s", "1990s", "2000s", "2010s", "2020s"]
|
2400
|
+
if @api_client.config.client_side_validation && opts[:'origin_decade'] && !allowable_values.include?(opts[:'origin_decade'])
|
2401
|
+
fail ArgumentError, "invalid value for \"origin_decade\", must be one of #{allowable_values}"
|
2402
|
+
end
|
2403
|
+
allowable_values = ["curateable", "uncurateable"]
|
2404
|
+
if @api_client.config.client_side_validation && opts[:'curateability'] && !allowable_values.include?(opts[:'curateability'])
|
2405
|
+
fail ArgumentError, "invalid value for \"curateability\", must be one of #{allowable_values}"
|
2406
|
+
end
|
2407
|
+
allowable_values = ["background", "sport", "focus", "christmas", "film", "summer", "adverts", "party", "relax"]
|
2408
|
+
if @api_client.config.client_side_validation && opts[:'use_case'] && !allowable_values.include?(opts[:'use_case'])
|
2409
|
+
fail ArgumentError, "invalid value for \"use_case\", must be one of #{allowable_values}"
|
2410
|
+
end
|
2411
|
+
allowable_values = ["Spotify", "TikTok", "Unfitting", "YouTube"]
|
2412
|
+
if @api_client.config.client_side_validation && opts[:'channel_suitability'] && !allowable_values.include?(opts[:'channel_suitability'])
|
2413
|
+
fail ArgumentError, "invalid value for \"channel_suitability\", must be one of #{allowable_values}"
|
2414
|
+
end
|
2415
|
+
# resource path
|
2416
|
+
local_var_path = '/api/v1/user/filesSummary'
|
2417
|
+
|
2418
|
+
# query parameters
|
2419
|
+
query_params = opts[:query_params] || {}
|
2420
|
+
query_params[:'ISRC'] = opts[:'isrc'] if !opts[:'isrc'].nil?
|
2421
|
+
query_params[:'contributor'] = opts[:'contributor'] if !opts[:'contributor'].nil?
|
2422
|
+
query_params[:'mainArtist'] = opts[:'main_artist'] if !opts[:'main_artist'].nil?
|
2423
|
+
query_params[:'composer'] = opts[:'composer'] if !opts[:'composer'].nil?
|
2424
|
+
query_params[:'title'] = opts[:'title'] if !opts[:'title'].nil?
|
2425
|
+
query_params[:'language'] = opts[:'language'] if !opts[:'language'].nil?
|
2426
|
+
query_params[:'genreNames'] = @api_client.build_collection_param(opts[:'genre_names'], :multi) if !opts[:'genre_names'].nil?
|
2427
|
+
query_params[:'tagNames'] = @api_client.build_collection_param(opts[:'tag_names'], :multi) if !opts[:'tag_names'].nil?
|
2428
|
+
query_params[:'releaseDate'] = opts[:'release_date'] if !opts[:'release_date'].nil?
|
2429
|
+
query_params[:'primaryMoodCluster'] = opts[:'primary_mood_cluster'] if !opts[:'primary_mood_cluster'].nil?
|
2430
|
+
query_params[:'secondaryMoodCluster'] = opts[:'secondary_mood_cluster'] if !opts[:'secondary_mood_cluster'].nil?
|
2431
|
+
query_params[:'tertiaryMoodCluster'] = opts[:'tertiary_mood_cluster'] if !opts[:'tertiary_mood_cluster'].nil?
|
2432
|
+
query_params[:'valence'] = opts[:'valence'] if !opts[:'valence'].nil?
|
2433
|
+
query_params[:'arousal'] = opts[:'arousal'] if !opts[:'arousal'].nil?
|
2434
|
+
query_params[:'pleasantness'] = opts[:'pleasantness'] if !opts[:'pleasantness'].nil?
|
2435
|
+
query_params[:'engagement'] = opts[:'engagement'] if !opts[:'engagement'].nil?
|
2436
|
+
query_params[:'vocals'] = opts[:'vocals'] if !opts[:'vocals'].nil?
|
2437
|
+
query_params[:'dominantInstrument'] = opts[:'dominant_instrument'] if !opts[:'dominant_instrument'].nil?
|
2438
|
+
query_params[:'secondaryInstrument'] = opts[:'secondary_instrument'] if !opts[:'secondary_instrument'].nil?
|
2439
|
+
query_params[:'tertiaryInstrument'] = opts[:'tertiary_instrument'] if !opts[:'tertiary_instrument'].nil?
|
2440
|
+
query_params[:'energy'] = opts[:'energy'] if !opts[:'energy'].nil?
|
2441
|
+
query_params[:'soundGeneration'] = opts[:'sound_generation'] if !opts[:'sound_generation'].nil?
|
2442
|
+
query_params[:'tempo'] = opts[:'tempo'] if !opts[:'tempo'].nil?
|
2443
|
+
query_params[:'scale'] = opts[:'scale'] if !opts[:'scale'].nil?
|
2444
|
+
query_params[:'rhythm'] = opts[:'rhythm'] if !opts[:'rhythm'].nil?
|
2445
|
+
query_params[:'primarySoundCharacter'] = opts[:'primary_sound_character'] if !opts[:'primary_sound_character'].nil?
|
2446
|
+
query_params[:'timbre'] = opts[:'timbre'] if !opts[:'timbre'].nil?
|
2447
|
+
query_params[:'roughness'] = opts[:'roughness'] if !opts[:'roughness'].nil?
|
2448
|
+
query_params[:'tonality'] = opts[:'tonality'] if !opts[:'tonality'].nil?
|
2449
|
+
query_params[:'harmony'] = opts[:'harmony'] if !opts[:'harmony'].nil?
|
2450
|
+
query_params[:'texture'] = opts[:'texture'] if !opts[:'texture'].nil?
|
2451
|
+
query_params[:'groovyness'] = opts[:'groovyness'] if !opts[:'groovyness'].nil?
|
2452
|
+
query_params[:'space'] = opts[:'space'] if !opts[:'space'].nil?
|
2453
|
+
query_params[:'productionRating'] = opts[:'production_rating'] if !opts[:'production_rating'].nil?
|
2454
|
+
query_params[:'performanceRating'] = opts[:'performance_rating'] if !opts[:'performance_rating'].nil?
|
2455
|
+
query_params[:'songRating'] = opts[:'song_rating'] if !opts[:'song_rating'].nil?
|
2456
|
+
query_params[:'audienceAge'] = opts[:'audience_age'] if !opts[:'audience_age'].nil?
|
2457
|
+
query_params[:'audienceRegion'] = opts[:'audience_region'] if !opts[:'audience_region'].nil?
|
2458
|
+
query_params[:'audienceGender'] = opts[:'audience_gender'] if !opts[:'audience_gender'].nil?
|
2459
|
+
query_params[:'originDecade'] = opts[:'origin_decade'] if !opts[:'origin_decade'].nil?
|
2460
|
+
query_params[:'curateability'] = opts[:'curateability'] if !opts[:'curateability'].nil?
|
2461
|
+
query_params[:'useCase'] = opts[:'use_case'] if !opts[:'use_case'].nil?
|
2462
|
+
query_params[:'channelSuitability'] = opts[:'channel_suitability'] if !opts[:'channel_suitability'].nil?
|
2463
|
+
query_params[:'similarToRecording'] = opts[:'similar_to_recording'] if !opts[:'similar_to_recording'].nil?
|
2464
|
+
query_params[:'songtradrTrackId'] = opts[:'songtradr_track_id'] if !opts[:'songtradr_track_id'].nil?
|
2465
|
+
query_params[:'usageName'] = opts[:'usage_name'] if !opts[:'usage_name'].nil?
|
2466
|
+
query_params[:'bpmMin'] = opts[:'bpm_min'] if !opts[:'bpm_min'].nil?
|
2467
|
+
query_params[:'bpmMax'] = opts[:'bpm_max'] if !opts[:'bpm_max'].nil?
|
2468
|
+
query_params[:'name'] = opts[:'name'] if !opts[:'name'].nil?
|
2469
|
+
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
2470
|
+
query_params[:'extension'] = opts[:'extension'] if !opts[:'extension'].nil?
|
2471
|
+
query_params[:'uploadEndTime'] = opts[:'upload_end_time'] if !opts[:'upload_end_time'].nil?
|
2472
|
+
query_params[:'minUploadEndTime'] = opts[:'min_upload_end_time'] if !opts[:'min_upload_end_time'].nil?
|
2473
|
+
query_params[:'maxUploadEndTime'] = opts[:'max_upload_end_time'] if !opts[:'max_upload_end_time'].nil?
|
2474
|
+
query_params[:'fingerprintStatus'] = opts[:'fingerprint_status'] if !opts[:'fingerprint_status'].nil?
|
2475
|
+
query_params[:'inferenceStatus'] = opts[:'inference_status'] if !opts[:'inference_status'].nil?
|
2476
|
+
|
2477
|
+
# header parameters
|
2478
|
+
header_params = opts[:header_params] || {}
|
2479
|
+
# HTTP header 'Accept' (if needed)
|
2480
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
2481
|
+
|
2482
|
+
# form parameters
|
2483
|
+
form_params = opts[:form_params] || {}
|
2484
|
+
|
2485
|
+
# http body (model)
|
2486
|
+
post_body = opts[:debug_body]
|
2487
|
+
|
2488
|
+
# return_type
|
2489
|
+
return_type = opts[:debug_return_type] || 'FilesSummaryDTO'
|
2490
|
+
|
2491
|
+
# auth_names
|
2492
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
2493
|
+
|
2494
|
+
new_options = opts.merge(
|
2495
|
+
:operation => :"UserApi.user_files_summary",
|
2496
|
+
:header_params => header_params,
|
2497
|
+
:query_params => query_params,
|
2498
|
+
:form_params => form_params,
|
2499
|
+
:body => post_body,
|
2500
|
+
:auth_names => auth_names,
|
2501
|
+
:return_type => return_type
|
2502
|
+
)
|
2503
|
+
|
2504
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
2505
|
+
if @api_client.config.debugging
|
2506
|
+
@api_client.config.logger.debug "API called: UserApi#user_files_summary\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2507
|
+
end
|
2508
|
+
return data, status_code, headers
|
2509
|
+
end
|
2510
|
+
|
2511
|
+
# Your Folders
|
2512
|
+
# @param [Hash] opts the optional parameters
|
2513
|
+
# @option opts [Integer] :page Zero-based page index (0..N) (default to 0)
|
2514
|
+
# @option opts [Integer] :size The size of the page to be returned (default to 20)
|
2515
|
+
# @option opts [Array<String>] :sort Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
|
2516
|
+
# @return [Array<String>]
|
2517
|
+
def user_folders(opts = {})
|
2518
|
+
data, _status_code, _headers = user_folders_with_http_info(opts)
|
2519
|
+
data
|
2520
|
+
end
|
2521
|
+
|
2522
|
+
# Your Folders
|
2523
|
+
# @param [Hash] opts the optional parameters
|
2524
|
+
# @option opts [Integer] :page Zero-based page index (0..N) (default to 0)
|
2525
|
+
# @option opts [Integer] :size The size of the page to be returned (default to 20)
|
2526
|
+
# @option opts [Array<String>] :sort Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
|
2527
|
+
# @return [Array<(Array<String>, Integer, Hash)>] Array<String> data, response status code and response headers
|
2528
|
+
def user_folders_with_http_info(opts = {})
|
2529
|
+
if @api_client.config.debugging
|
2530
|
+
@api_client.config.logger.debug 'Calling API: UserApi.user_folders ...'
|
2531
|
+
end
|
2532
|
+
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 0
|
2533
|
+
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling UserApi.user_folders, must be greater than or equal to 0.'
|
2534
|
+
end
|
2535
|
+
|
2536
|
+
if @api_client.config.client_side_validation && !opts[:'size'].nil? && opts[:'size'] < 1
|
2537
|
+
fail ArgumentError, 'invalid value for "opts[:"size"]" when calling UserApi.user_folders, must be greater than or equal to 1.'
|
2538
|
+
end
|
2539
|
+
|
2540
|
+
# resource path
|
2541
|
+
local_var_path = '/api/v1/user/folders'
|
2542
|
+
|
2543
|
+
# query parameters
|
2544
|
+
query_params = opts[:query_params] || {}
|
2545
|
+
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
2546
|
+
query_params[:'size'] = opts[:'size'] if !opts[:'size'].nil?
|
2547
|
+
query_params[:'sort'] = @api_client.build_collection_param(opts[:'sort'], :multi) if !opts[:'sort'].nil?
|
2548
|
+
|
2549
|
+
# header parameters
|
2550
|
+
header_params = opts[:header_params] || {}
|
2551
|
+
# HTTP header 'Accept' (if needed)
|
2552
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
2553
|
+
|
2554
|
+
# form parameters
|
2555
|
+
form_params = opts[:form_params] || {}
|
2556
|
+
|
2557
|
+
# http body (model)
|
2558
|
+
post_body = opts[:debug_body]
|
2559
|
+
|
2560
|
+
# return_type
|
2561
|
+
return_type = opts[:debug_return_type] || 'Array<String>'
|
2562
|
+
|
2563
|
+
# auth_names
|
2564
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
2565
|
+
|
2566
|
+
new_options = opts.merge(
|
2567
|
+
:operation => :"UserApi.user_folders",
|
2568
|
+
:header_params => header_params,
|
2569
|
+
:query_params => query_params,
|
2570
|
+
:form_params => form_params,
|
2571
|
+
:body => post_body,
|
2572
|
+
:auth_names => auth_names,
|
2573
|
+
:return_type => return_type
|
2574
|
+
)
|
2575
|
+
|
2576
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
2577
|
+
if @api_client.config.debugging
|
2578
|
+
@api_client.config.logger.debug "API called: UserApi#user_folders\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2579
|
+
end
|
2580
|
+
return data, status_code, headers
|
2581
|
+
end
|
2582
|
+
|
2583
|
+
# @param username [String]
|
2584
|
+
# @param [Hash] opts the optional parameters
|
2585
|
+
# @return [Array<String>]
|
2586
|
+
def user_referrers(username, opts = {})
|
2587
|
+
data, _status_code, _headers = user_referrers_with_http_info(username, opts)
|
2588
|
+
data
|
2589
|
+
end
|
2590
|
+
|
2591
|
+
# @param username [String]
|
2592
|
+
# @param [Hash] opts the optional parameters
|
2593
|
+
# @return [Array<(Array<String>, Integer, Hash)>] Array<String> data, response status code and response headers
|
2594
|
+
def user_referrers_with_http_info(username, opts = {})
|
2595
|
+
if @api_client.config.debugging
|
2596
|
+
@api_client.config.logger.debug 'Calling API: UserApi.user_referrers ...'
|
2597
|
+
end
|
2598
|
+
# verify the required parameter 'username' is set
|
2599
|
+
if @api_client.config.client_side_validation && username.nil?
|
2600
|
+
fail ArgumentError, "Missing the required parameter 'username' when calling UserApi.user_referrers"
|
2601
|
+
end
|
2602
|
+
# resource path
|
2603
|
+
local_var_path = '/api/v1/user/referrers/{username}'.sub('{' + 'username' + '}', CGI.escape(username.to_s))
|
2604
|
+
|
2605
|
+
# query parameters
|
2606
|
+
query_params = opts[:query_params] || {}
|
2607
|
+
|
2608
|
+
# header parameters
|
2609
|
+
header_params = opts[:header_params] || {}
|
2610
|
+
# HTTP header 'Accept' (if needed)
|
2611
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
2612
|
+
|
2613
|
+
# form parameters
|
2614
|
+
form_params = opts[:form_params] || {}
|
2615
|
+
|
2616
|
+
# http body (model)
|
2617
|
+
post_body = opts[:debug_body]
|
2618
|
+
|
2619
|
+
# return_type
|
2620
|
+
return_type = opts[:debug_return_type] || 'Array<String>'
|
2621
|
+
|
2622
|
+
# auth_names
|
2623
|
+
auth_names = opts[:debug_auth_names] || ['bearer-jwt']
|
2624
|
+
|
2625
|
+
new_options = opts.merge(
|
2626
|
+
:operation => :"UserApi.user_referrers",
|
2627
|
+
:header_params => header_params,
|
2628
|
+
:query_params => query_params,
|
2629
|
+
:form_params => form_params,
|
2630
|
+
:body => post_body,
|
2631
|
+
:auth_names => auth_names,
|
2632
|
+
:return_type => return_type
|
2633
|
+
)
|
2634
|
+
|
2635
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
2636
|
+
if @api_client.config.debugging
|
2637
|
+
@api_client.config.logger.debug "API called: UserApi#user_referrers\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
2638
|
+
end
|
2639
|
+
return data, status_code, headers
|
2640
|
+
end
|
2641
|
+
end
|
2642
|
+
end
|