phrase 1.0.1 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +50 -387
- data/docs/AccountsApi.md +2 -4
- data/docs/AuthorizationsApi.md +10 -14
- data/docs/BitbucketSyncApi.md +3 -6
- data/docs/BlacklistedKeysApi.md +10 -14
- data/docs/BranchesApi.md +12 -18
- data/docs/CommentsApi.md +13 -20
- data/docs/DistributionsApi.md +10 -14
- data/docs/FormatsApi.md +1 -2
- data/docs/GitLabSyncApi.md +7 -14
- data/docs/{GlossaryApi.md → GlossariesApi.md} +26 -30
- data/docs/GlossaryTermTranslationsApi.md +8 -10
- data/docs/GlossaryTermsApi.md +10 -14
- data/docs/InvitationsApi.md +11 -16
- data/docs/JobLocalesApi.md +12 -18
- data/docs/JobsApi.md +15 -24
- data/docs/KeysApi.md +18 -26
- data/docs/KeysSearchParameters.md +1 -1
- data/docs/KeysTagParameters.md +1 -1
- data/docs/KeysUntagParameters.md +1 -1
- data/docs/LocalesApi.md +13 -18
- data/docs/MembersApi.md +4 -8
- data/docs/OrdersApi.md +10 -14
- data/docs/ProjectCreateParameters.md +3 -1
- data/docs/ProjectsApi.md +10 -14
- data/docs/ReleasesApi.md +11 -16
- data/docs/ScreenshotMarkersApi.md +10 -14
- data/docs/ScreenshotsApi.md +10 -14
- data/docs/SpacesApi.md +13 -20
- data/docs/StyleGuidesApi.md +10 -14
- data/docs/TagsApi.md +9 -12
- data/docs/Team.md +29 -0
- data/docs/TeamCreateParameters.md +17 -0
- data/docs/TeamDetail.md +29 -0
- data/docs/TeamUpdateParameters.md +17 -0
- data/docs/TeamsApi.md +721 -0
- data/docs/TeamsProjectsCreateParameters.md +17 -0
- data/docs/TeamsSpacesCreateParameters.md +17 -0
- data/docs/TeamsUsersCreateParameters.md +17 -0
- data/docs/TranslationsApi.md +28 -44
- data/docs/TranslationsExcludeParameters.md +1 -1
- data/docs/TranslationsIncludeParameters.md +1 -1
- data/docs/TranslationsReviewParameters.md +1 -1
- data/docs/TranslationsSearchParameters.md +1 -1
- data/docs/TranslationsUnverifyParameters.md +1 -1
- data/docs/TranslationsVerifyParameters.md +1 -1
- data/docs/UploadCreateParameters.md +2 -2
- data/docs/UploadsApi.md +12 -10
- data/docs/UsersApi.md +1 -2
- data/docs/VersionsHistoryApi.md +2 -4
- data/docs/WebhooksApi.md +11 -16
- data/git_push.sh +2 -2
- data/lib/phrase.rb +9 -1
- data/lib/phrase/api/authorizations_api.rb +10 -8
- data/lib/phrase/api/bitbucket_sync_api.rb +3 -3
- data/lib/phrase/api/blacklisted_keys_api.rb +10 -8
- data/lib/phrase/api/branches_api.rb +16 -14
- data/lib/phrase/api/comments_api.rb +19 -17
- data/lib/phrase/api/distributions_api.rb +10 -8
- data/lib/phrase/api/git_lab_sync_api.rb +3 -3
- data/lib/phrase/api/{glossary_api.rb → glossaries_api.rb} +31 -29
- data/lib/phrase/api/glossary_term_translations_api.rb +10 -8
- data/lib/phrase/api/glossary_terms_api.rb +10 -8
- data/lib/phrase/api/invitations_api.rb +10 -8
- data/lib/phrase/api/job_locales_api.rb +10 -8
- data/lib/phrase/api/jobs_api.rb +13 -11
- data/lib/phrase/api/keys_api.rb +14 -12
- data/lib/phrase/api/locales_api.rb +15 -13
- data/lib/phrase/api/members_api.rb +3 -3
- data/lib/phrase/api/orders_api.rb +10 -8
- data/lib/phrase/api/projects_api.rb +10 -8
- data/lib/phrase/api/releases_api.rb +10 -8
- data/lib/phrase/api/screenshot_markers_api.rb +10 -8
- data/lib/phrase/api/screenshots_api.rb +10 -8
- data/lib/phrase/api/spaces_api.rb +16 -14
- data/lib/phrase/api/style_guides_api.rb +10 -8
- data/lib/phrase/api/tags_api.rb +10 -8
- data/lib/phrase/api/teams_api.rb +840 -0
- data/lib/phrase/api/translations_api.rb +13 -11
- data/lib/phrase/api/uploads_api.rb +13 -5
- data/lib/phrase/api/webhooks_api.rb +13 -11
- data/lib/phrase/models/keys_search_parameters.rb +1 -1
- data/lib/phrase/models/keys_tag_parameters.rb +1 -1
- data/lib/phrase/models/keys_untag_parameters.rb +1 -1
- data/lib/phrase/models/project_create_parameters.rb +14 -4
- data/lib/phrase/models/team.rb +254 -0
- data/lib/phrase/models/team_create_parameters.rb +195 -0
- data/lib/phrase/models/team_detail.rb +254 -0
- data/lib/phrase/models/team_update_parameters.rb +195 -0
- data/lib/phrase/models/teams_projects_create_parameters.rb +195 -0
- data/lib/phrase/models/teams_spaces_create_parameters.rb +195 -0
- data/lib/phrase/models/teams_users_create_parameters.rb +195 -0
- data/lib/phrase/models/translations_exclude_parameters.rb +1 -1
- data/lib/phrase/models/translations_include_parameters.rb +1 -1
- data/lib/phrase/models/translations_review_parameters.rb +1 -1
- data/lib/phrase/models/translations_search_parameters.rb +1 -1
- data/lib/phrase/models/translations_unverify_parameters.rb +1 -1
- data/lib/phrase/models/translations_verify_parameters.rb +1 -1
- data/lib/phrase/models/upload_create_parameters.rb +4 -8
- data/lib/phrase/version.rb +1 -1
- data/spec/api/authorizations_api_spec.rb +1 -1
- data/spec/api/blacklisted_keys_api_spec.rb +1 -1
- data/spec/api/branches_api_spec.rb +1 -1
- data/spec/api/comments_api_spec.rb +1 -1
- data/spec/api/distributions_api_spec.rb +1 -1
- data/spec/api/{glossary_api_spec.rb → glossaries_api_spec.rb} +7 -7
- data/spec/api/glossary_term_translations_api_spec.rb +1 -1
- data/spec/api/glossary_terms_api_spec.rb +1 -1
- data/spec/api/invitations_api_spec.rb +1 -1
- data/spec/api/job_locales_api_spec.rb +1 -1
- data/spec/api/jobs_api_spec.rb +1 -1
- data/spec/api/keys_api_spec.rb +3 -3
- data/spec/api/locales_api_spec.rb +2 -2
- data/spec/api/orders_api_spec.rb +1 -1
- data/spec/api/projects_api_spec.rb +1 -1
- data/spec/api/releases_api_spec.rb +1 -1
- data/spec/api/screenshot_markers_api_spec.rb +1 -1
- data/spec/api/screenshots_api_spec.rb +1 -1
- data/spec/api/spaces_api_spec.rb +1 -1
- data/spec/api/style_guides_api_spec.rb +1 -1
- data/spec/api/tags_api_spec.rb +1 -1
- data/spec/api/teams_api_spec.rb +185 -0
- data/spec/api/translations_api_spec.rb +4 -4
- data/spec/api/uploads_api_spec.rb +3 -1
- data/spec/api/webhooks_api_spec.rb +1 -1
- data/spec/models/project_create_parameters_spec.rb +6 -0
- data/spec/models/team_create_parameters_spec.rb +29 -0
- data/spec/models/team_detail_spec.rb +65 -0
- data/spec/models/team_spec.rb +65 -0
- data/spec/models/team_update_parameters_spec.rb +29 -0
- data/spec/models/teams_projects_create_parameters_spec.rb +29 -0
- data/spec/models/teams_spaces_create_parameters_spec.rb +29 -0
- data/spec/models/teams_users_create_parameters_spec.rb +29 -0
- metadata +183 -151
|
@@ -103,8 +103,8 @@ module Phrase
|
|
|
103
103
|
# @option opts [String] :branch specify the branch to use
|
|
104
104
|
# @return [nil]
|
|
105
105
|
def job_locale_delete(project_id, job_id, id, opts = {})
|
|
106
|
-
job_locale_delete_with_http_info(project_id, job_id, id, opts)
|
|
107
|
-
|
|
106
|
+
data, _status_code, _headers = job_locale_delete_with_http_info(project_id, job_id, id, opts)
|
|
107
|
+
data
|
|
108
108
|
end
|
|
109
109
|
|
|
110
110
|
# Delete a job locale
|
|
@@ -115,7 +115,7 @@ module Phrase
|
|
|
115
115
|
# @param [Hash] opts the optional parameters
|
|
116
116
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
117
117
|
# @option opts [String] :branch specify the branch to use
|
|
118
|
-
# @return [Array<(Response
|
|
118
|
+
# @return [Array<(Response, Integer, Hash)>] Response<(nil, response status code and response headers
|
|
119
119
|
def job_locale_delete_with_http_info(project_id, job_id, id, opts = {})
|
|
120
120
|
if @api_client.config.debugging
|
|
121
121
|
@api_client.config.logger.debug 'Calling API: JobLocalesApi.job_locale_delete ...'
|
|
@@ -432,10 +432,10 @@ module Phrase
|
|
|
432
432
|
# @param job_locales_create_parameters [JobLocalesCreateParameters]
|
|
433
433
|
# @param [Hash] opts the optional parameters
|
|
434
434
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
435
|
-
# @return [
|
|
435
|
+
# @return [JobLocale]
|
|
436
436
|
def job_locales_create(project_id, job_id, job_locales_create_parameters, opts = {})
|
|
437
|
-
job_locales_create_with_http_info(project_id, job_id, job_locales_create_parameters, opts)
|
|
438
|
-
|
|
437
|
+
data, _status_code, _headers = job_locales_create_with_http_info(project_id, job_id, job_locales_create_parameters, opts)
|
|
438
|
+
data
|
|
439
439
|
end
|
|
440
440
|
|
|
441
441
|
# Create a job locale
|
|
@@ -445,7 +445,7 @@ module Phrase
|
|
|
445
445
|
# @param job_locales_create_parameters [JobLocalesCreateParameters]
|
|
446
446
|
# @param [Hash] opts the optional parameters
|
|
447
447
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
448
|
-
# @return [Array<(Response<(
|
|
448
|
+
# @return [Array<(Response<(JobLocale)>, Integer, Hash)>] Response<(JobLocale)> data, response status code and response headers
|
|
449
449
|
def job_locales_create_with_http_info(project_id, job_id, job_locales_create_parameters, opts = {})
|
|
450
450
|
if @api_client.config.debugging
|
|
451
451
|
@api_client.config.logger.debug 'Calling API: JobLocalesApi.job_locales_create ...'
|
|
@@ -470,6 +470,8 @@ module Phrase
|
|
|
470
470
|
|
|
471
471
|
# header parameters
|
|
472
472
|
header_params = opts[:header_params] || {}
|
|
473
|
+
# HTTP header 'Accept' (if needed)
|
|
474
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
473
475
|
# HTTP header 'Content-Type'
|
|
474
476
|
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
|
475
477
|
header_params[:'X-PhraseApp-OTP'] = opts[:'x_phrase_app_otp'] if !opts[:'x_phrase_app_otp'].nil?
|
|
@@ -481,7 +483,7 @@ module Phrase
|
|
|
481
483
|
post_body = opts[:body] || @api_client.object_to_http_body(job_locales_create_parameters)
|
|
482
484
|
|
|
483
485
|
# return_type
|
|
484
|
-
return_type = opts[:return_type]
|
|
486
|
+
return_type = opts[:return_type] || 'JobLocale'
|
|
485
487
|
|
|
486
488
|
# auth_names
|
|
487
489
|
auth_names = opts[:auth_names] || ['Basic', 'Token']
|
data/lib/phrase/api/jobs_api.rb
CHANGED
|
@@ -93,10 +93,10 @@ module Phrase
|
|
|
93
93
|
# @param job_create_parameters [JobCreateParameters]
|
|
94
94
|
# @param [Hash] opts the optional parameters
|
|
95
95
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
96
|
-
# @return [
|
|
96
|
+
# @return [JobDetails]
|
|
97
97
|
def job_create(project_id, job_create_parameters, opts = {})
|
|
98
|
-
job_create_with_http_info(project_id, job_create_parameters, opts)
|
|
99
|
-
|
|
98
|
+
data, _status_code, _headers = job_create_with_http_info(project_id, job_create_parameters, opts)
|
|
99
|
+
data
|
|
100
100
|
end
|
|
101
101
|
|
|
102
102
|
# Create a job
|
|
@@ -105,7 +105,7 @@ module Phrase
|
|
|
105
105
|
# @param job_create_parameters [JobCreateParameters]
|
|
106
106
|
# @param [Hash] opts the optional parameters
|
|
107
107
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
108
|
-
# @return [Array<(Response<(
|
|
108
|
+
# @return [Array<(Response<(JobDetails)>, Integer, Hash)>] Response<(JobDetails)> data, response status code and response headers
|
|
109
109
|
def job_create_with_http_info(project_id, job_create_parameters, opts = {})
|
|
110
110
|
if @api_client.config.debugging
|
|
111
111
|
@api_client.config.logger.debug 'Calling API: JobsApi.job_create ...'
|
|
@@ -126,6 +126,8 @@ module Phrase
|
|
|
126
126
|
|
|
127
127
|
# header parameters
|
|
128
128
|
header_params = opts[:header_params] || {}
|
|
129
|
+
# HTTP header 'Accept' (if needed)
|
|
130
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
129
131
|
# HTTP header 'Content-Type'
|
|
130
132
|
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
|
131
133
|
header_params[:'X-PhraseApp-OTP'] = opts[:'x_phrase_app_otp'] if !opts[:'x_phrase_app_otp'].nil?
|
|
@@ -137,7 +139,7 @@ module Phrase
|
|
|
137
139
|
post_body = opts[:body] || @api_client.object_to_http_body(job_create_parameters)
|
|
138
140
|
|
|
139
141
|
# return_type
|
|
140
|
-
return_type = opts[:return_type]
|
|
142
|
+
return_type = opts[:return_type] || 'JobDetails'
|
|
141
143
|
|
|
142
144
|
# auth_names
|
|
143
145
|
auth_names = opts[:auth_names] || ['Basic', 'Token']
|
|
@@ -168,8 +170,8 @@ module Phrase
|
|
|
168
170
|
# @option opts [String] :branch specify the branch to use
|
|
169
171
|
# @return [nil]
|
|
170
172
|
def job_delete(project_id, id, opts = {})
|
|
171
|
-
job_delete_with_http_info(project_id, id, opts)
|
|
172
|
-
|
|
173
|
+
data, _status_code, _headers = job_delete_with_http_info(project_id, id, opts)
|
|
174
|
+
data
|
|
173
175
|
end
|
|
174
176
|
|
|
175
177
|
# Delete a job
|
|
@@ -179,7 +181,7 @@ module Phrase
|
|
|
179
181
|
# @param [Hash] opts the optional parameters
|
|
180
182
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
181
183
|
# @option opts [String] :branch specify the branch to use
|
|
182
|
-
# @return [Array<(Response
|
|
184
|
+
# @return [Array<(Response, Integer, Hash)>] Response<(nil, response status code and response headers
|
|
183
185
|
def job_delete_with_http_info(project_id, id, opts = {})
|
|
184
186
|
if @api_client.config.debugging
|
|
185
187
|
@api_client.config.logger.debug 'Calling API: JobsApi.job_delete ...'
|
|
@@ -322,8 +324,8 @@ module Phrase
|
|
|
322
324
|
# @option opts [Array<String>] :translation_key_ids ids of keys that should added to the job
|
|
323
325
|
# @return [nil]
|
|
324
326
|
def job_keys_delete(project_id, id, opts = {})
|
|
325
|
-
job_keys_delete_with_http_info(project_id, id, opts)
|
|
326
|
-
|
|
327
|
+
data, _status_code, _headers = job_keys_delete_with_http_info(project_id, id, opts)
|
|
328
|
+
data
|
|
327
329
|
end
|
|
328
330
|
|
|
329
331
|
# Remove keys from job
|
|
@@ -334,7 +336,7 @@ module Phrase
|
|
|
334
336
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
335
337
|
# @option opts [String] :branch specify the branch to use
|
|
336
338
|
# @option opts [Array<String>] :translation_key_ids ids of keys that should added to the job
|
|
337
|
-
# @return [Array<(Response
|
|
339
|
+
# @return [Array<(Response, Integer, Hash)>] Response<(nil, response status code and response headers
|
|
338
340
|
def job_keys_delete_with_http_info(project_id, id, opts = {})
|
|
339
341
|
if @api_client.config.debugging
|
|
340
342
|
@api_client.config.logger.debug 'Calling API: JobsApi.job_keys_delete ...'
|
data/lib/phrase/api/keys_api.rb
CHANGED
|
@@ -13,10 +13,10 @@ module Phrase
|
|
|
13
13
|
# @param key_create_parameters [KeyCreateParameters]
|
|
14
14
|
# @param [Hash] opts the optional parameters
|
|
15
15
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
16
|
-
# @return [
|
|
16
|
+
# @return [TranslationKeyDetails]
|
|
17
17
|
def key_create(project_id, key_create_parameters, opts = {})
|
|
18
|
-
key_create_with_http_info(project_id, key_create_parameters, opts)
|
|
19
|
-
|
|
18
|
+
data, _status_code, _headers = key_create_with_http_info(project_id, key_create_parameters, opts)
|
|
19
|
+
data
|
|
20
20
|
end
|
|
21
21
|
|
|
22
22
|
# Create a key
|
|
@@ -25,7 +25,7 @@ module Phrase
|
|
|
25
25
|
# @param key_create_parameters [KeyCreateParameters]
|
|
26
26
|
# @param [Hash] opts the optional parameters
|
|
27
27
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
28
|
-
# @return [Array<(Response<(
|
|
28
|
+
# @return [Array<(Response<(TranslationKeyDetails)>, Integer, Hash)>] Response<(TranslationKeyDetails)> data, response status code and response headers
|
|
29
29
|
def key_create_with_http_info(project_id, key_create_parameters, opts = {})
|
|
30
30
|
if @api_client.config.debugging
|
|
31
31
|
@api_client.config.logger.debug 'Calling API: KeysApi.key_create ...'
|
|
@@ -46,6 +46,8 @@ module Phrase
|
|
|
46
46
|
|
|
47
47
|
# header parameters
|
|
48
48
|
header_params = opts[:header_params] || {}
|
|
49
|
+
# HTTP header 'Accept' (if needed)
|
|
50
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
49
51
|
# HTTP header 'Content-Type'
|
|
50
52
|
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
|
51
53
|
header_params[:'X-PhraseApp-OTP'] = opts[:'x_phrase_app_otp'] if !opts[:'x_phrase_app_otp'].nil?
|
|
@@ -57,7 +59,7 @@ module Phrase
|
|
|
57
59
|
post_body = opts[:body] || @api_client.object_to_http_body(key_create_parameters)
|
|
58
60
|
|
|
59
61
|
# return_type
|
|
60
|
-
return_type = opts[:return_type]
|
|
62
|
+
return_type = opts[:return_type] || 'TranslationKeyDetails'
|
|
61
63
|
|
|
62
64
|
# auth_names
|
|
63
65
|
auth_names = opts[:auth_names] || ['Basic', 'Token']
|
|
@@ -88,8 +90,8 @@ module Phrase
|
|
|
88
90
|
# @option opts [String] :branch specify the branch to use
|
|
89
91
|
# @return [nil]
|
|
90
92
|
def key_delete(project_id, id, opts = {})
|
|
91
|
-
key_delete_with_http_info(project_id, id, opts)
|
|
92
|
-
|
|
93
|
+
data, _status_code, _headers = key_delete_with_http_info(project_id, id, opts)
|
|
94
|
+
data
|
|
93
95
|
end
|
|
94
96
|
|
|
95
97
|
# Delete a key
|
|
@@ -99,7 +101,7 @@ module Phrase
|
|
|
99
101
|
# @param [Hash] opts the optional parameters
|
|
100
102
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
101
103
|
# @option opts [String] :branch specify the branch to use
|
|
102
|
-
# @return [Array<(Response
|
|
104
|
+
# @return [Array<(Response, Integer, Hash)>] Response<(nil, response status code and response headers
|
|
103
105
|
def key_delete_with_http_info(project_id, id, opts = {})
|
|
104
106
|
if @api_client.config.debugging
|
|
105
107
|
@api_client.config.logger.debug 'Calling API: KeysApi.key_delete ...'
|
|
@@ -313,7 +315,7 @@ module Phrase
|
|
|
313
315
|
# @param [Hash] opts the optional parameters
|
|
314
316
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
315
317
|
# @option opts [String] :branch specify the branch to use
|
|
316
|
-
# @option opts [String] :q
|
|
318
|
+
# @option opts [String] :q Specify a query to do broad search for keys by name (including wildcards).<br><br> The following qualifiers are also supported in the search term:<br> <ul> <li><code>ids:key_id,...</code> for queries on a comma-separated list of ids</li> <li><code>name:key_name</code> for text queries on exact key names - whitespaces need to be prefixed with a backspace (\\\"\\\\\\\")</li> <li><code>tags:tag_name</code> to filter for keys with certain tags</li> <li><code>translated:{true|false}</code> for translation status (also requires <code>locale_id</code> to be specified)</li> <li><code>updated_at:{>=|<=}2013-02-21T00:00:00Z</code> for date range queries</li> <li><code>unmentioned_in_upload:upload_id</code> to filter keys unmentioned within upload</li> </ul> Find more examples <a href=\"#overview--usage-examples\">here</a>.
|
|
317
319
|
# @option opts [String] :locale_id Locale used to determine the translation state of a key when filtering for untranslated or translated keys.
|
|
318
320
|
# @return [AffectedResources]
|
|
319
321
|
def keys_delete(project_id, opts = {})
|
|
@@ -327,7 +329,7 @@ module Phrase
|
|
|
327
329
|
# @param [Hash] opts the optional parameters
|
|
328
330
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
329
331
|
# @option opts [String] :branch specify the branch to use
|
|
330
|
-
# @option opts [String] :q
|
|
332
|
+
# @option opts [String] :q Specify a query to do broad search for keys by name (including wildcards).<br><br> The following qualifiers are also supported in the search term:<br> <ul> <li><code>ids:key_id,...</code> for queries on a comma-separated list of ids</li> <li><code>name:key_name</code> for text queries on exact key names - whitespaces need to be prefixed with a backspace (\\\"\\\\\\\")</li> <li><code>tags:tag_name</code> to filter for keys with certain tags</li> <li><code>translated:{true|false}</code> for translation status (also requires <code>locale_id</code> to be specified)</li> <li><code>updated_at:{>=|<=}2013-02-21T00:00:00Z</code> for date range queries</li> <li><code>unmentioned_in_upload:upload_id</code> to filter keys unmentioned within upload</li> </ul> Find more examples <a href=\"#overview--usage-examples\">here</a>.
|
|
331
333
|
# @option opts [String] :locale_id Locale used to determine the translation state of a key when filtering for untranslated or translated keys.
|
|
332
334
|
# @return [Array<(Response<(AffectedResources)>, Integer, Hash)>] Response<(AffectedResources)> data, response status code and response headers
|
|
333
335
|
def keys_delete_with_http_info(project_id, opts = {})
|
|
@@ -392,7 +394,7 @@ module Phrase
|
|
|
392
394
|
# @option opts [String] :branch specify the branch to use
|
|
393
395
|
# @option opts [String] :sort Sort by field. Can be one of: name, created_at, updated_at.
|
|
394
396
|
# @option opts [String] :order Order direction. Can be one of: asc, desc.
|
|
395
|
-
# @option opts [String] :q
|
|
397
|
+
# @option opts [String] :q Specify a query to do broad search for keys by name (including wildcards).<br><br> The following qualifiers are also supported in the search term:<br> <ul> <li><code>ids:key_id,...</code> for queries on a comma-separated list of ids</li> <li><code>name:key_name</code> for text queries on exact key names - whitespaces need to be prefixed with a backspace (\\\"\\\\\\\")</li> <li><code>tags:tag_name</code> to filter for keys with certain tags</li> <li><code>translated:{true|false}</code> for translation status (also requires <code>locale_id</code> to be specified)</li> <li><code>updated_at:{>=|<=}2013-02-21T00:00:00Z</code> for date range queries</li> <li><code>unmentioned_in_upload:upload_id</code> to filter keys unmentioned within upload</li> </ul> Find more examples <a href=\"#overview--usage-examples\">here</a>.
|
|
396
398
|
# @option opts [String] :locale_id Locale used to determine the translation state of a key when filtering for untranslated or translated keys.
|
|
397
399
|
# @return [Array<TranslationKey>]
|
|
398
400
|
def keys_list(project_id, opts = {})
|
|
@@ -410,7 +412,7 @@ module Phrase
|
|
|
410
412
|
# @option opts [String] :branch specify the branch to use
|
|
411
413
|
# @option opts [String] :sort Sort by field. Can be one of: name, created_at, updated_at.
|
|
412
414
|
# @option opts [String] :order Order direction. Can be one of: asc, desc.
|
|
413
|
-
# @option opts [String] :q
|
|
415
|
+
# @option opts [String] :q Specify a query to do broad search for keys by name (including wildcards).<br><br> The following qualifiers are also supported in the search term:<br> <ul> <li><code>ids:key_id,...</code> for queries on a comma-separated list of ids</li> <li><code>name:key_name</code> for text queries on exact key names - whitespaces need to be prefixed with a backspace (\\\"\\\\\\\")</li> <li><code>tags:tag_name</code> to filter for keys with certain tags</li> <li><code>translated:{true|false}</code> for translation status (also requires <code>locale_id</code> to be specified)</li> <li><code>updated_at:{>=|<=}2013-02-21T00:00:00Z</code> for date range queries</li> <li><code>unmentioned_in_upload:upload_id</code> to filter keys unmentioned within upload</li> </ul> Find more examples <a href=\"#overview--usage-examples\">here</a>.
|
|
414
416
|
# @option opts [String] :locale_id Locale used to determine the translation state of a key when filtering for untranslated or translated keys.
|
|
415
417
|
# @return [Array<(Response<(Array<TranslationKey>)>, Integer, Hash)>] Response<(Array<TranslationKey>)> data, response status code and response headers
|
|
416
418
|
def keys_list_with_http_info(project_id, opts = {})
|
|
@@ -13,10 +13,10 @@ module Phrase
|
|
|
13
13
|
# @param locale_create_parameters [LocaleCreateParameters]
|
|
14
14
|
# @param [Hash] opts the optional parameters
|
|
15
15
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
16
|
-
# @return [
|
|
16
|
+
# @return [LocaleDetails]
|
|
17
17
|
def locale_create(project_id, locale_create_parameters, opts = {})
|
|
18
|
-
locale_create_with_http_info(project_id, locale_create_parameters, opts)
|
|
19
|
-
|
|
18
|
+
data, _status_code, _headers = locale_create_with_http_info(project_id, locale_create_parameters, opts)
|
|
19
|
+
data
|
|
20
20
|
end
|
|
21
21
|
|
|
22
22
|
# Create a locale
|
|
@@ -25,7 +25,7 @@ module Phrase
|
|
|
25
25
|
# @param locale_create_parameters [LocaleCreateParameters]
|
|
26
26
|
# @param [Hash] opts the optional parameters
|
|
27
27
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
28
|
-
# @return [Array<(Response<(
|
|
28
|
+
# @return [Array<(Response<(LocaleDetails)>, Integer, Hash)>] Response<(LocaleDetails)> data, response status code and response headers
|
|
29
29
|
def locale_create_with_http_info(project_id, locale_create_parameters, opts = {})
|
|
30
30
|
if @api_client.config.debugging
|
|
31
31
|
@api_client.config.logger.debug 'Calling API: LocalesApi.locale_create ...'
|
|
@@ -46,6 +46,8 @@ module Phrase
|
|
|
46
46
|
|
|
47
47
|
# header parameters
|
|
48
48
|
header_params = opts[:header_params] || {}
|
|
49
|
+
# HTTP header 'Accept' (if needed)
|
|
50
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
49
51
|
# HTTP header 'Content-Type'
|
|
50
52
|
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
|
51
53
|
header_params[:'X-PhraseApp-OTP'] = opts[:'x_phrase_app_otp'] if !opts[:'x_phrase_app_otp'].nil?
|
|
@@ -57,7 +59,7 @@ module Phrase
|
|
|
57
59
|
post_body = opts[:body] || @api_client.object_to_http_body(locale_create_parameters)
|
|
58
60
|
|
|
59
61
|
# return_type
|
|
60
|
-
return_type = opts[:return_type]
|
|
62
|
+
return_type = opts[:return_type] || 'LocaleDetails'
|
|
61
63
|
|
|
62
64
|
# auth_names
|
|
63
65
|
auth_names = opts[:auth_names] || ['Basic', 'Token']
|
|
@@ -88,8 +90,8 @@ module Phrase
|
|
|
88
90
|
# @option opts [String] :branch specify the branch to use
|
|
89
91
|
# @return [nil]
|
|
90
92
|
def locale_delete(project_id, id, opts = {})
|
|
91
|
-
locale_delete_with_http_info(project_id, id, opts)
|
|
92
|
-
|
|
93
|
+
data, _status_code, _headers = locale_delete_with_http_info(project_id, id, opts)
|
|
94
|
+
data
|
|
93
95
|
end
|
|
94
96
|
|
|
95
97
|
# Delete a locale
|
|
@@ -99,7 +101,7 @@ module Phrase
|
|
|
99
101
|
# @param [Hash] opts the optional parameters
|
|
100
102
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
101
103
|
# @option opts [String] :branch specify the branch to use
|
|
102
|
-
# @return [Array<(Response
|
|
104
|
+
# @return [Array<(Response, Integer, Hash)>] Response<(nil, response status code and response headers
|
|
103
105
|
def locale_delete_with_http_info(project_id, id, opts = {})
|
|
104
106
|
if @api_client.config.debugging
|
|
105
107
|
@api_client.config.logger.debug 'Calling API: LocalesApi.locale_delete ...'
|
|
@@ -166,7 +168,7 @@ module Phrase
|
|
|
166
168
|
# @option opts [Boolean] :include_translated_keys Include translated keys in the locale file. Use in combination with include_empty_translations to obtain only untranslated keys.
|
|
167
169
|
# @option opts [Boolean] :keep_notranslate_tags Indicates whether [NOTRANSLATE] tags should be kept.
|
|
168
170
|
# @option opts [Boolean] :convert_emoji This option is obsolete. Projects that were created on or after Nov 29th 2019 or that did not contain emoji by then will not require this flag any longer since emoji are now supported natively.
|
|
169
|
-
# @option opts [
|
|
171
|
+
# @option opts [Object] :format_options Additional formatting and render options. See the <a href=\"https://help.phrase.com/help/supported-platforms-and-formats\">format guide</a> for a list of options available for each format. Specify format options like this: <code>...&format_options[foo]=bar</code>
|
|
170
172
|
# @option opts [String] :encoding Enforces a specific encoding on the file contents. Valid options are \"UTF-8\", \"UTF-16\" and \"ISO-8859-1\".
|
|
171
173
|
# @option opts [Boolean] :skip_unverified_translations Indicates whether the locale file should skip all unverified translations. This parameter is deprecated and should be replaced with <code>include_unverified_translations</code>.
|
|
172
174
|
# @option opts [Boolean] :include_unverified_translations if set to false unverified translations are excluded
|
|
@@ -174,8 +176,8 @@ module Phrase
|
|
|
174
176
|
# @option opts [String] :fallback_locale_id If a key has no translation in the locale being downloaded the translation in the fallback locale will be used. Provide the public ID of the locale that should be used as the fallback. Requires include_empty_translations to be set to <code>true</code>.
|
|
175
177
|
# @return [nil]
|
|
176
178
|
def locale_download(project_id, id, opts = {})
|
|
177
|
-
locale_download_with_http_info(project_id, id, opts)
|
|
178
|
-
|
|
179
|
+
data, _status_code, _headers = locale_download_with_http_info(project_id, id, opts)
|
|
180
|
+
data
|
|
179
181
|
end
|
|
180
182
|
|
|
181
183
|
# Download a locale
|
|
@@ -192,13 +194,13 @@ module Phrase
|
|
|
192
194
|
# @option opts [Boolean] :include_translated_keys Include translated keys in the locale file. Use in combination with include_empty_translations to obtain only untranslated keys.
|
|
193
195
|
# @option opts [Boolean] :keep_notranslate_tags Indicates whether [NOTRANSLATE] tags should be kept.
|
|
194
196
|
# @option opts [Boolean] :convert_emoji This option is obsolete. Projects that were created on or after Nov 29th 2019 or that did not contain emoji by then will not require this flag any longer since emoji are now supported natively.
|
|
195
|
-
# @option opts [
|
|
197
|
+
# @option opts [Object] :format_options Additional formatting and render options. See the <a href=\"https://help.phrase.com/help/supported-platforms-and-formats\">format guide</a> for a list of options available for each format. Specify format options like this: <code>...&format_options[foo]=bar</code>
|
|
196
198
|
# @option opts [String] :encoding Enforces a specific encoding on the file contents. Valid options are \"UTF-8\", \"UTF-16\" and \"ISO-8859-1\".
|
|
197
199
|
# @option opts [Boolean] :skip_unverified_translations Indicates whether the locale file should skip all unverified translations. This parameter is deprecated and should be replaced with <code>include_unverified_translations</code>.
|
|
198
200
|
# @option opts [Boolean] :include_unverified_translations if set to false unverified translations are excluded
|
|
199
201
|
# @option opts [Boolean] :use_last_reviewed_version If set to true the last reviewed version of a translation is used. This is only available if the review workflow (currently in beta) is enabled for the project.
|
|
200
202
|
# @option opts [String] :fallback_locale_id If a key has no translation in the locale being downloaded the translation in the fallback locale will be used. Provide the public ID of the locale that should be used as the fallback. Requires include_empty_translations to be set to <code>true</code>.
|
|
201
|
-
# @return [Array<(Response
|
|
203
|
+
# @return [Array<(Response, Integer, Hash)>] Response<(nil, response status code and response headers
|
|
202
204
|
def locale_download_with_http_info(project_id, id, opts = {})
|
|
203
205
|
if @api_client.config.debugging
|
|
204
206
|
@api_client.config.logger.debug 'Calling API: LocalesApi.locale_download ...'
|
|
@@ -15,8 +15,8 @@ module Phrase
|
|
|
15
15
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
16
16
|
# @return [nil]
|
|
17
17
|
def member_delete(account_id, id, opts = {})
|
|
18
|
-
member_delete_with_http_info(account_id, id, opts)
|
|
19
|
-
|
|
18
|
+
data, _status_code, _headers = member_delete_with_http_info(account_id, id, opts)
|
|
19
|
+
data
|
|
20
20
|
end
|
|
21
21
|
|
|
22
22
|
# Remove a user from the account
|
|
@@ -25,7 +25,7 @@ module Phrase
|
|
|
25
25
|
# @param id [String] ID
|
|
26
26
|
# @param [Hash] opts the optional parameters
|
|
27
27
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
28
|
-
# @return [Array<(Response
|
|
28
|
+
# @return [Array<(Response, Integer, Hash)>] Response<(nil, response status code and response headers
|
|
29
29
|
def member_delete_with_http_info(account_id, id, opts = {})
|
|
30
30
|
if @api_client.config.debugging
|
|
31
31
|
@api_client.config.logger.debug 'Calling API: MembersApi.member_delete ...'
|
|
@@ -93,10 +93,10 @@ module Phrase
|
|
|
93
93
|
# @param order_create_parameters [OrderCreateParameters]
|
|
94
94
|
# @param [Hash] opts the optional parameters
|
|
95
95
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
96
|
-
# @return [
|
|
96
|
+
# @return [TranslationOrder]
|
|
97
97
|
def order_create(project_id, order_create_parameters, opts = {})
|
|
98
|
-
order_create_with_http_info(project_id, order_create_parameters, opts)
|
|
99
|
-
|
|
98
|
+
data, _status_code, _headers = order_create_with_http_info(project_id, order_create_parameters, opts)
|
|
99
|
+
data
|
|
100
100
|
end
|
|
101
101
|
|
|
102
102
|
# Create a new order
|
|
@@ -105,7 +105,7 @@ module Phrase
|
|
|
105
105
|
# @param order_create_parameters [OrderCreateParameters]
|
|
106
106
|
# @param [Hash] opts the optional parameters
|
|
107
107
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
108
|
-
# @return [Array<(Response<(
|
|
108
|
+
# @return [Array<(Response<(TranslationOrder)>, Integer, Hash)>] Response<(TranslationOrder)> data, response status code and response headers
|
|
109
109
|
def order_create_with_http_info(project_id, order_create_parameters, opts = {})
|
|
110
110
|
if @api_client.config.debugging
|
|
111
111
|
@api_client.config.logger.debug 'Calling API: OrdersApi.order_create ...'
|
|
@@ -126,6 +126,8 @@ module Phrase
|
|
|
126
126
|
|
|
127
127
|
# header parameters
|
|
128
128
|
header_params = opts[:header_params] || {}
|
|
129
|
+
# HTTP header 'Accept' (if needed)
|
|
130
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
129
131
|
# HTTP header 'Content-Type'
|
|
130
132
|
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
|
131
133
|
header_params[:'X-PhraseApp-OTP'] = opts[:'x_phrase_app_otp'] if !opts[:'x_phrase_app_otp'].nil?
|
|
@@ -137,7 +139,7 @@ module Phrase
|
|
|
137
139
|
post_body = opts[:body] || @api_client.object_to_http_body(order_create_parameters)
|
|
138
140
|
|
|
139
141
|
# return_type
|
|
140
|
-
return_type = opts[:return_type]
|
|
142
|
+
return_type = opts[:return_type] || 'TranslationOrder'
|
|
141
143
|
|
|
142
144
|
# auth_names
|
|
143
145
|
auth_names = opts[:auth_names] || ['Basic', 'Token']
|
|
@@ -168,8 +170,8 @@ module Phrase
|
|
|
168
170
|
# @option opts [String] :branch specify the branch to use
|
|
169
171
|
# @return [nil]
|
|
170
172
|
def order_delete(project_id, id, opts = {})
|
|
171
|
-
order_delete_with_http_info(project_id, id, opts)
|
|
172
|
-
|
|
173
|
+
data, _status_code, _headers = order_delete_with_http_info(project_id, id, opts)
|
|
174
|
+
data
|
|
173
175
|
end
|
|
174
176
|
|
|
175
177
|
# Cancel an order
|
|
@@ -179,7 +181,7 @@ module Phrase
|
|
|
179
181
|
# @param [Hash] opts the optional parameters
|
|
180
182
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
181
183
|
# @option opts [String] :branch specify the branch to use
|
|
182
|
-
# @return [Array<(Response
|
|
184
|
+
# @return [Array<(Response, Integer, Hash)>] Response<(nil, response status code and response headers
|
|
183
185
|
def order_delete_with_http_info(project_id, id, opts = {})
|
|
184
186
|
if @api_client.config.debugging
|
|
185
187
|
@api_client.config.logger.debug 'Calling API: OrdersApi.order_delete ...'
|
|
@@ -12,10 +12,10 @@ module Phrase
|
|
|
12
12
|
# @param project_create_parameters [ProjectCreateParameters]
|
|
13
13
|
# @param [Hash] opts the optional parameters
|
|
14
14
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
15
|
-
# @return [
|
|
15
|
+
# @return [ProjectDetails]
|
|
16
16
|
def project_create(project_create_parameters, opts = {})
|
|
17
|
-
project_create_with_http_info(project_create_parameters, opts)
|
|
18
|
-
|
|
17
|
+
data, _status_code, _headers = project_create_with_http_info(project_create_parameters, opts)
|
|
18
|
+
data
|
|
19
19
|
end
|
|
20
20
|
|
|
21
21
|
# Create a project
|
|
@@ -23,7 +23,7 @@ module Phrase
|
|
|
23
23
|
# @param project_create_parameters [ProjectCreateParameters]
|
|
24
24
|
# @param [Hash] opts the optional parameters
|
|
25
25
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
26
|
-
# @return [Array<(Response<(
|
|
26
|
+
# @return [Array<(Response<(ProjectDetails)>, Integer, Hash)>] Response<(ProjectDetails)> data, response status code and response headers
|
|
27
27
|
def project_create_with_http_info(project_create_parameters, opts = {})
|
|
28
28
|
if @api_client.config.debugging
|
|
29
29
|
@api_client.config.logger.debug 'Calling API: ProjectsApi.project_create ...'
|
|
@@ -40,6 +40,8 @@ module Phrase
|
|
|
40
40
|
|
|
41
41
|
# header parameters
|
|
42
42
|
header_params = opts[:header_params] || {}
|
|
43
|
+
# HTTP header 'Accept' (if needed)
|
|
44
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
43
45
|
# HTTP header 'Content-Type'
|
|
44
46
|
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
|
45
47
|
header_params[:'X-PhraseApp-OTP'] = opts[:'x_phrase_app_otp'] if !opts[:'x_phrase_app_otp'].nil?
|
|
@@ -51,7 +53,7 @@ module Phrase
|
|
|
51
53
|
post_body = opts[:body] || @api_client.object_to_http_body(project_create_parameters)
|
|
52
54
|
|
|
53
55
|
# return_type
|
|
54
|
-
return_type = opts[:return_type]
|
|
56
|
+
return_type = opts[:return_type] || 'ProjectDetails'
|
|
55
57
|
|
|
56
58
|
# auth_names
|
|
57
59
|
auth_names = opts[:auth_names] || ['Basic', 'Token']
|
|
@@ -80,8 +82,8 @@ module Phrase
|
|
|
80
82
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
81
83
|
# @return [nil]
|
|
82
84
|
def project_delete(id, opts = {})
|
|
83
|
-
project_delete_with_http_info(id, opts)
|
|
84
|
-
|
|
85
|
+
data, _status_code, _headers = project_delete_with_http_info(id, opts)
|
|
86
|
+
data
|
|
85
87
|
end
|
|
86
88
|
|
|
87
89
|
# Delete a project
|
|
@@ -89,7 +91,7 @@ module Phrase
|
|
|
89
91
|
# @param id [String] ID
|
|
90
92
|
# @param [Hash] opts the optional parameters
|
|
91
93
|
# @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
|
|
92
|
-
# @return [Array<(Response
|
|
94
|
+
# @return [Array<(Response, Integer, Hash)>] Response<(nil, response status code and response headers
|
|
93
95
|
def project_delete_with_http_info(id, opts = {})
|
|
94
96
|
if @api_client.config.debugging
|
|
95
97
|
@api_client.config.logger.debug 'Calling API: ProjectsApi.project_delete ...'
|