phrase 3.5.0 → 3.7.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +25 -0
  3. data/README.md +4 -3
  4. data/docs/CommentCreateParameters.md +5 -3
  5. data/docs/CommentCreateParameters1.md +19 -0
  6. data/docs/CommentRepliesApi.md +6 -8
  7. data/docs/CommentsApi.md +2 -6
  8. data/docs/FormatsApi.md +3 -9
  9. data/docs/JobsApi.md +2 -2
  10. data/docs/KeyCreateParameters.md +3 -1
  11. data/docs/KeyUpdateParameters.md +1 -1
  12. data/docs/LocalesApi.md +4 -0
  13. data/docs/ProjectCreateParameters.md +3 -9
  14. data/docs/ProjectUpdateParameters.md +3 -9
  15. data/docs/ScreenshotUpdateParameters.md +1 -1
  16. data/docs/UploadsApi.md +5 -3
  17. data/lib/phrase/api/comment_replies_api.rb +12 -10
  18. data/lib/phrase/api/comments_api.rb +0 -6
  19. data/lib/phrase/api/formats_api.rb +0 -3
  20. data/lib/phrase/api/jobs_api.rb +2 -2
  21. data/lib/phrase/api/locales_api.rb +6 -0
  22. data/lib/phrase/api/uploads_api.rb +5 -2
  23. data/lib/phrase/models/comment_create_parameters.rb +25 -8
  24. data/lib/phrase/models/comment_create_parameters1.rb +212 -0
  25. data/lib/phrase/models/key_create_parameters.rb +11 -1
  26. data/lib/phrase/models/project_create_parameters.rb +5 -35
  27. data/lib/phrase/models/project_update_parameters.rb +5 -35
  28. data/lib/phrase/version.rb +1 -1
  29. data/lib/phrase.rb +1 -0
  30. data/spec/api/comment_replies_api_spec.rb +1 -2
  31. data/spec/api/comments_api_spec.rb +0 -2
  32. data/spec/api/formats_api_spec.rb +0 -1
  33. data/spec/api/jobs_api_spec.rb +1 -1
  34. data/spec/models/comment_create_parameters1_spec.rb +35 -0
  35. data/spec/models/comment_create_parameters_spec.rb +7 -1
  36. data/spec/models/key_create_parameters_spec.rb +6 -0
  37. data/spec/models/project_create_parameters_spec.rb +0 -18
  38. data/spec/models/project_update_parameters_spec.rb +0 -18
  39. metadata +250 -246
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7192d11119d30292391cff61b97e50e69f4dafbd850bcc2db2d5b62c7e9f8776
4
- data.tar.gz: 20a0a9ccc7309595138bbd41d50544b8e4951e0c03ecd31e4e3ab3bf72daf28c
3
+ metadata.gz: c3f5c696d27e08c101a167dddb80b511ae88507f70a8c1b9391211093ecbe8d1
4
+ data.tar.gz: 8cd98e44aee6743df2811f7f647c8a3f8c3eb4ff75d5f6789e9d22a1a43ae701
5
5
  SHA512:
6
- metadata.gz: 1cb278af6c89ea39591b743c8585e1d3c96d7daa96a4cc2eb78226965315428659c2153d089b86319536a40a9a4b59f5d22cad918935d7b102cdd01b174e6186
7
- data.tar.gz: 3533e003d3ca6fc5a0a0e815da450680d3fe93ffde8d465198d89ed81c987467fc005a23b62b480049c6332d8015394615347cb38fc776e79efbba08da77fcfc
6
+ metadata.gz: ed36f256d74a41f434e893d24d6f6d0b6180255318a75f7b649ec210707b39ea6da91524cce29d47ffdcb14378c3ac4b70253383273e5ab43c8ed53f1db7a241
7
+ data.tar.gz: 55579b6ed6a2cb30a9628a79f2fc2c34d1c95c353083cbd8ad4fc667ae295b30cbe0ed3700333a8ca34741c6b9ea101e22a52fa98c9d0dee668050245fab6f10
data/CHANGELOG.md CHANGED
@@ -1,5 +1,30 @@
1
1
  # Changelog
2
2
 
3
+ ## [3.7.0](https://github.com/phrase/openapi/compare/ruby-v3.6.0...ruby-v3.7.0) (2024-12-03)
4
+
5
+
6
+ ### Features
7
+
8
+ * **API:** Add Pagination header to POST search endpoints [[#457](https://github.com/phrase/openapi/issues/457)] ([#706](https://github.com/phrase/openapi/issues/706)) ([9a79fa3](https://github.com/phrase/openapi/commit/9a79fa31bb3b9d58272fa2f4e82d72d0d44a93a0))
9
+ * **API:** autotranslate param in key creation [STRINGS-786] ([#713](https://github.com/phrase/openapi/issues/713)) ([581d0ff](https://github.com/phrase/openapi/commit/581d0ff5f1d06757e5ddd9603b78fc8d435d68ee))
10
+
11
+
12
+ ### Bug Fixes
13
+
14
+ * **API:** Comment creation schema fix #STRINGS-866 ([#718](https://github.com/phrase/openapi/issues/718)) ([e201d13](https://github.com/phrase/openapi/commit/e201d1360c89698dd8d3642cc28f89dd0e50a1fb))
15
+
16
+ ## [3.6.0](https://github.com/phrase/openapi/compare/ruby-v3.5.0...ruby-v3.6.0) (2024-10-02)
17
+
18
+
19
+ ### Features
20
+
21
+ * Add translation key prefixes for upload and download ([#687](https://github.com/phrase/openapi/issues/687)) ([9c9c959](https://github.com/phrase/openapi/commit/9c9c959830631bcac8beaf1de30ab31755ac1ee5))
22
+
23
+
24
+ ### Bug Fixes
25
+
26
+ * **API:** Format list is not paginated and authenticated #STRINGS-458 ([#690](https://github.com/phrase/openapi/issues/690)) ([25e90f4](https://github.com/phrase/openapi/commit/25e90f46513e70cf328be80c36ae785cead05851))
27
+
3
28
  ## [3.5.0](https://github.com/phrase/openapi/compare/ruby-v3.4.0...ruby-v3.5.0) (2024-09-09)
4
29
 
5
30
 
data/README.md CHANGED
@@ -7,7 +7,7 @@ Phrase Strings is a translation management platform for software projects. You c
7
7
  ## This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
8
8
 
9
9
  - API version: 2.0.0
10
- - Package version: 3.5.0
10
+ - Package version: 3.7.0
11
11
  - Build package: org.openapitools.codegen.languages.RubyClientCodegen
12
12
  For more information, please visit [https://developers.phrase.com/api/](https://developers.phrase.com/api/)
13
13
 
@@ -56,10 +56,10 @@ gem build phrase.gemspec
56
56
  Then install the gem locally:
57
57
 
58
58
  ```shell
59
- gem install ./phrase-3.5.0.gem
59
+ gem install ./phrase-3.7.0.gem
60
60
  ```
61
61
 
62
- (for development, run `gem install --dev ./phrase-3.5.0.gem` to install the development dependencies)
62
+ (for development, run `gem install --dev ./phrase-3.7.0.gem` to install the development dependencies)
63
63
 
64
64
  ## Getting Started
65
65
 
@@ -436,6 +436,7 @@ Class | Method | HTTP request | Description
436
436
  - [Phrase::BranchUpdateParameters](docs/BranchUpdateParameters.md)
437
437
  - [Phrase::Comment](docs/Comment.md)
438
438
  - [Phrase::CommentCreateParameters](docs/CommentCreateParameters.md)
439
+ - [Phrase::CommentCreateParameters1](docs/CommentCreateParameters1.md)
439
440
  - [Phrase::CommentMarkReadParameters](docs/CommentMarkReadParameters.md)
440
441
  - [Phrase::CommentReaction](docs/CommentReaction.md)
441
442
  - [Phrase::CommentUpdateParameters](docs/CommentUpdateParameters.md)
@@ -4,16 +4,18 @@
4
4
 
5
5
  Name | Type | Description | Notes
6
6
  ------------ | ------------- | ------------- | -------------
7
+ **message** | **String** | Comment message |
7
8
  **branch** | **String** | specify the branch to use | [optional]
8
- **message** | **String** | Comment message | [optional]
9
+ **locale_ids** | **Array<String>** | specify the locales for the comment | [optional]
9
10
 
10
11
  ## Code Sample
11
12
 
12
13
  ```ruby
13
14
  require 'Phrase'
14
15
 
15
- instance = Phrase::CommentCreateParameters.new(branch: my-feature-branch,
16
- message: Some message...)
16
+ instance = Phrase::CommentCreateParameters.new(message: Some message...,
17
+ branch: my-feature-branch,
18
+ locale_ids: ["someId","someOtherId"])
17
19
  ```
18
20
 
19
21
 
@@ -0,0 +1,19 @@
1
+ # Phrase::CommentCreateParameters1
2
+
3
+ ## Properties
4
+
5
+ Name | Type | Description | Notes
6
+ ------------ | ------------- | ------------- | -------------
7
+ **message** | **String** | Reply message body |
8
+ **branch** | **String** | Specify the branch to use | [optional]
9
+
10
+ ## Code Sample
11
+
12
+ ```ruby
13
+ require 'Phrase'
14
+
15
+ instance = Phrase::CommentCreateParameters1.new(message: Some message...,
16
+ branch: my-feature-branch)
17
+ ```
18
+
19
+
@@ -94,7 +94,7 @@ Response<([**Array&lt;Comment&gt;**](Comment.md))>
94
94
 
95
95
  ## reply_create
96
96
 
97
- > Comment reply_create(project_id, key_id, comment_id, opts)
97
+ > Comment reply_create(project_id, key_id, comment_id, comment_create_parameters1, opts)
98
98
 
99
99
  Create a reply
100
100
 
@@ -120,15 +120,14 @@ api_instance = Phrase::CommentRepliesApi.new
120
120
  project_id = 'project_id_example' # String | Project ID
121
121
  key_id = 'key_id_example' # String | Translation Key ID
122
122
  comment_id = 'comment_id_example' # String | Comment ID
123
+ comment_create_parameters1 = Phrase::CommentCreateParameters1.new({message: 'Some message...'}) # CommentCreateParameters1 |
123
124
  opts = {
124
- x_phrase_app_otp: 'x_phrase_app_otp_example', # String | Two-Factor-Authentication token (optional)
125
- branch: 'my-feature-branch', # String | specify the branch to use
126
- message: 'some message...' # String | specify the message for the comment
125
+ x_phrase_app_otp: 'x_phrase_app_otp_example' # String | Two-Factor-Authentication token (optional)
127
126
  }
128
127
 
129
128
  begin
130
129
  #Create a reply
131
- result = api_instance.reply_create(project_id, key_id, comment_id, opts)
130
+ result = api_instance.reply_create(project_id, key_id, comment_id, comment_create_parameters1, opts)
132
131
  pp result
133
132
  rescue Phrase::ApiError => e
134
133
  puts "Exception when calling CommentRepliesApi->reply_create: #{e}"
@@ -143,9 +142,8 @@ Name | Type | Description | Notes
143
142
  **project_id** | **String**| Project ID |
144
143
  **key_id** | **String**| Translation Key ID |
145
144
  **comment_id** | **String**| Comment ID |
145
+ **comment_create_parameters1** | [**CommentCreateParameters1**](CommentCreateParameters1.md)| |
146
146
  **x_phrase_app_otp** | **String**| Two-Factor-Authentication token (optional) | [optional]
147
- **branch** | **String**| specify the branch to use | [optional]
148
- **message** | **String**| specify the message for the comment | [optional]
149
147
 
150
148
  ### Return type
151
149
 
@@ -157,7 +155,7 @@ Response<([**Comment**](Comment.md))>
157
155
 
158
156
  ### HTTP request headers
159
157
 
160
- - **Content-Type**: Not defined
158
+ - **Content-Type**: application/json
161
159
  - **Accept**: application/json
162
160
 
163
161
 
data/docs/CommentsApi.md CHANGED
@@ -42,11 +42,9 @@ end
42
42
  api_instance = Phrase::CommentsApi.new
43
43
  project_id = 'project_id_example' # String | Project ID
44
44
  key_id = 'key_id_example' # String | Translation Key ID
45
- comment_create_parameters = Phrase::CommentCreateParameters.new # CommentCreateParameters |
45
+ comment_create_parameters = Phrase::CommentCreateParameters.new({message: 'Some message...'}) # CommentCreateParameters |
46
46
  opts = {
47
- x_phrase_app_otp: 'x_phrase_app_otp_example', # String | Two-Factor-Authentication token (optional)
48
- message: 'some message...', # String | specify the message for the comment
49
- locale_ids: ['inner_example'] # Array<String> | specify the locales for the comment
47
+ x_phrase_app_otp: 'x_phrase_app_otp_example' # String | Two-Factor-Authentication token (optional)
50
48
  }
51
49
 
52
50
  begin
@@ -67,8 +65,6 @@ Name | Type | Description | Notes
67
65
  **key_id** | **String**| Translation Key ID |
68
66
  **comment_create_parameters** | [**CommentCreateParameters**](CommentCreateParameters.md)| |
69
67
  **x_phrase_app_otp** | **String**| Two-Factor-Authentication token (optional) | [optional]
70
- **message** | **String**| specify the message for the comment | [optional]
71
- **locale_ids** | [**Array&lt;String&gt;**](String.md)| specify the locales for the comment | [optional]
72
68
 
73
69
  ### Return type
74
70
 
data/docs/FormatsApi.md CHANGED
@@ -10,7 +10,7 @@ Method | HTTP request | Description
10
10
 
11
11
  ## formats_list
12
12
 
13
- > Array&lt;Format&gt; formats_list(opts)
13
+ > Array&lt;Format&gt; formats_list
14
14
 
15
15
  List formats
16
16
 
@@ -33,13 +33,10 @@ Phrase.configure do |config|
33
33
  end
34
34
 
35
35
  api_instance = Phrase::FormatsApi.new
36
- opts = {
37
- x_phrase_app_otp: 'x_phrase_app_otp_example' # String | Two-Factor-Authentication token (optional)
38
- }
39
36
 
40
37
  begin
41
38
  #List formats
42
- result = api_instance.formats_list(opts)
39
+ result = api_instance.formats_list
43
40
  pp result
44
41
  rescue Phrase::ApiError => e
45
42
  puts "Exception when calling FormatsApi->formats_list: #{e}"
@@ -48,10 +45,7 @@ end
48
45
 
49
46
  ### Parameters
50
47
 
51
-
52
- Name | Type | Description | Notes
53
- ------------- | ------------- | ------------- | -------------
54
- **x_phrase_app_otp** | **String**| Two-Factor-Authentication token (optional) | [optional]
48
+ This endpoint does not need any parameter.
55
49
 
56
50
  ### Return type
57
51
 
data/docs/JobsApi.md CHANGED
@@ -307,7 +307,7 @@ id = 'id_example' # String | ID
307
307
  opts = {
308
308
  x_phrase_app_otp: 'x_phrase_app_otp_example', # String | Two-Factor-Authentication token (optional)
309
309
  branch: 'my-feature-branch', # String | specify the branch to use
310
- translation_key_ids: ['inner_example'] # Array<String> | ids of keys that should added to the job
310
+ translation_key_ids: ['inner_example'] # Array<String> | ids of keys that should be removed from the job
311
311
  }
312
312
 
313
313
  begin
@@ -327,7 +327,7 @@ Name | Type | Description | Notes
327
327
  **id** | **String**| ID |
328
328
  **x_phrase_app_otp** | **String**| Two-Factor-Authentication token (optional) | [optional]
329
329
  **branch** | **String**| specify the branch to use | [optional]
330
- **translation_key_ids** | [**Array&lt;String&gt;**](String.md)| ids of keys that should added to the job | [optional]
330
+ **translation_key_ids** | [**Array&lt;String&gt;**](String.md)| ids of keys that should be removed from the job | [optional]
331
331
 
332
332
  ### Return type
333
333
 
@@ -16,6 +16,7 @@ Name | Type | Description | Notes
16
16
  **remove_screenshot** | **Boolean** | Indicates whether the screenshot will be deleted. This parameter is deprecated. Please use the Screenshots endpoint instead. | [optional]
17
17
  **unformatted** | **Boolean** | Indicates whether the key should be exported as \&quot;unformatted\&quot;. Supported by Android XML and other formats. | [optional]
18
18
  **default_translation_content** | **String** | Creates a translation in the default locale with the specified content | [optional]
19
+ **autotranslate** | **Boolean** | Indicates whether the key should be autotranslated to other locales based on the copy provided in &#x60;default_translation_content&#x60;. | [optional]
19
20
  **xml_space_preserve** | **Boolean** | Indicates whether the key should be exported with \&quot;xml:space&#x3D;preserve\&quot;. Supported by several XML-based formats. | [optional]
20
21
  **original_file** | **String** | Original file attribute. Used in some formats, e.g. XLIFF. | [optional]
21
22
  **localized_format_string** | **String** | NSStringLocalizedFormatKey attribute. Used in .stringsdict format. | [optional]
@@ -35,10 +36,11 @@ instance = Phrase::KeyCreateParameters.new(branch: my-feature-branch,
35
36
  data_type: number,
36
37
  tags: awesome-feature,needs-proofreading,
37
38
  max_characters_allowed: 140,
38
- screenshot: [B@7bb92a71,
39
+ screenshot: [B@38b65eb9,
39
40
  remove_screenshot: null,
40
41
  unformatted: null,
41
42
  default_translation_content: Default translation content,
43
+ autotranslate: null,
42
44
  xml_space_preserve: null,
43
45
  original_file: null,
44
46
  localized_format_string: null,
@@ -34,7 +34,7 @@ instance = Phrase::KeyUpdateParameters.new(branch: my-feature-branch,
34
34
  data_type: number,
35
35
  tags: awesome-feature,needs-proofreading,
36
36
  max_characters_allowed: 140,
37
- screenshot: [B@3bbb5b2,
37
+ screenshot: [B@3c32105c,
38
38
  remove_screenshot: null,
39
39
  unformatted: null,
40
40
  xml_space_preserve: null,
data/docs/LocalesApi.md CHANGED
@@ -253,6 +253,8 @@ opts = {
253
253
  use_last_reviewed_version: true, # Boolean | If set to true the last reviewed version of a translation is used. This is only available if the review workflow is enabled for the project.
254
254
  fallback_locale_id: 'fallback_locale_id_example', # String | If a key has no translation in the locale being downloaded the translation in the fallback locale will be used. Provide the ID of the locale that should be used as the fallback. Requires include_empty_translations to be set to <code>true</code>.
255
255
  source_locale_id: 'source_locale_id_example', # String | Provides the source language of a corresponding job as the source language of the generated locale file. This parameter will be ignored unless used in combination with a <code>tag</code> parameter indicating a specific job.
256
+ translation_key_prefix: 'prefix_', # String | Download all translation keys, and remove the specified prefix where possible. Warning: this may create duplicate key names if other keys share the same name after the prefix is removed.
257
+ filter_by_prefix: true, # Boolean | Only download translation keys containing the specified prefix, and remove the prefix from the generated file.
256
258
  custom_metadata_filters: { key: 3.56} # Object | Custom metadata filters. Provide the name of the metadata field and the value to filter by. Only keys with matching metadata will be included in the download.
257
259
  }
258
260
 
@@ -291,6 +293,8 @@ Name | Type | Description | Notes
291
293
  **use_last_reviewed_version** | **Boolean**| If set to true the last reviewed version of a translation is used. This is only available if the review workflow is enabled for the project. | [optional]
292
294
  **fallback_locale_id** | **String**| If a key has no translation in the locale being downloaded the translation in the fallback locale will be used. Provide the ID of the locale that should be used as the fallback. Requires include_empty_translations to be set to &lt;code&gt;true&lt;/code&gt;. | [optional]
293
295
  **source_locale_id** | **String**| Provides the source language of a corresponding job as the source language of the generated locale file. This parameter will be ignored unless used in combination with a &lt;code&gt;tag&lt;/code&gt; parameter indicating a specific job. | [optional]
296
+ **translation_key_prefix** | **String**| Download all translation keys, and remove the specified prefix where possible. Warning: this may create duplicate key names if other keys share the same name after the prefix is removed. | [optional]
297
+ **filter_by_prefix** | **Boolean**| Only download translation keys containing the specified prefix, and remove the prefix from the generated file. | [optional]
294
298
  **custom_metadata_filters** | [**Object**](.md)| Custom metadata filters. Provide the name of the metadata field and the value to filter by. Only keys with matching metadata will be included in the download. | [optional]
295
299
 
296
300
  ### Return type
@@ -14,7 +14,7 @@ Name | Type | Description | Notes
14
14
  **point_of_contact** | **String** | (Optional) User ID of the point of contact for the project. | [optional]
15
15
  **source_project_id** | **String** | When a source project ID is given, a clone of that project will be created, including all locales, keys and translations as well as the main project settings if they are not defined otherwise through the params. | [optional]
16
16
  **workflow** | **String** | (Optional) Review Workflow. \&quot;simple\&quot; / \&quot;review\&quot;. &lt;a href&#x3D;\&quot;https://support.phrase.com/hc/en-us/articles/5784094755484\&quot;&gt;Read more&lt;/a&gt; | [optional]
17
- **machine_translation_enabled** | **Boolean** | (Optional) Enable machine translation support in the project. Required for Autopilot and Smart Suggest | [optional]
17
+ **machine_translation_enabled** | **Boolean** | (Optional) Enable machine translation support in the project. Required for Pre-Translation | [optional]
18
18
  **enable_branching** | **Boolean** | (Optional) Enable branching in the project | [optional]
19
19
  **protect_master_branch** | **Boolean** | (Optional) Protect the master branch in project where branching is enabled | [optional]
20
20
  **enable_all_data_type_translation_keys_for_translators** | **Boolean** | (Optional) Otherwise, translators are not allowed to edit translations other than strings | [optional]
@@ -27,9 +27,6 @@ Name | Type | Description | Notes
27
27
  **autotranslate_mark_as_unverified** | **Boolean** | (Optional) Requires autotranslate_enabled to be true | [optional]
28
28
  **autotranslate_use_machine_translation** | **Boolean** | (Optional) Requires autotranslate_enabled to be true | [optional]
29
29
  **autotranslate_use_translation_memory** | **Boolean** | (Optional) Requires autotranslate_enabled to be true | [optional]
30
- **smart_suggest_enabled** | **Boolean** | (Optional) Smart Suggest, requires machine_translation_enabled | [optional]
31
- **smart_suggest_use_glossary** | **Boolean** | (Optional) Requires smart_suggest_enabled to be true | [optional]
32
- **smart_suggest_use_machine_translation** | **Boolean** | (Optional) Requires smart_suggest_enabled to be true | [optional]
33
30
 
34
31
  ## Code Sample
35
32
 
@@ -40,7 +37,7 @@ instance = Phrase::ProjectCreateParameters.new(name: My Android Project,
40
37
  main_format: yml,
41
38
  media: Python,
42
39
  shares_translation_memory: true,
43
- project_image: [B@15cf663c,
40
+ project_image: [B@2bd89b8e,
44
41
  remove_project_image: null,
45
42
  account_id: abcd1234,
46
43
  point_of_contact: abcd1234,
@@ -58,10 +55,7 @@ instance = Phrase::ProjectCreateParameters.new(name: My Android Project,
58
55
  autotranslate_check_new_locales: true,
59
56
  autotranslate_mark_as_unverified: true,
60
57
  autotranslate_use_machine_translation: true,
61
- autotranslate_use_translation_memory: true,
62
- smart_suggest_enabled: true,
63
- smart_suggest_use_glossary: true,
64
- smart_suggest_use_machine_translation: true)
58
+ autotranslate_use_translation_memory: true)
65
59
  ```
66
60
 
67
61
 
@@ -13,7 +13,7 @@ Name | Type | Description | Notes
13
13
  **project_image** | **File** | (Optional) Image to identify the project | [optional]
14
14
  **remove_project_image** | **Boolean** | (Optional) Indicates whether the project image should be deleted. | [optional]
15
15
  **workflow** | **String** | (Optional) Review Workflow. \&quot;simple\&quot; / \&quot;review\&quot;. &lt;a href&#x3D;\&quot;https://support.phrase.com/hc/en-us/articles/5784094755484\&quot;&gt;Read more&lt;/a&gt; | [optional]
16
- **machine_translation_enabled** | **Boolean** | (Optional) Enable machine translation support in the project. Required for Autopilot and Smart Suggest | [optional]
16
+ **machine_translation_enabled** | **Boolean** | (Optional) Enable machine translation support in the project. Required for Pre-Translation | [optional]
17
17
  **enable_branching** | **Boolean** | (Optional) Enable branching in the project | [optional]
18
18
  **protect_master_branch** | **Boolean** | (Optional) Protect the master branch in project where branching is enabled | [optional]
19
19
  **enable_all_data_type_translation_keys_for_translators** | **Boolean** | (Optional) Otherwise, translators are not allowed to edit translations other than strings | [optional]
@@ -26,9 +26,6 @@ Name | Type | Description | Notes
26
26
  **autotranslate_mark_as_unverified** | **Boolean** | (Optional) Requires autotranslate_enabled to be true | [optional]
27
27
  **autotranslate_use_machine_translation** | **Boolean** | (Optional) Requires autotranslate_enabled to be true | [optional]
28
28
  **autotranslate_use_translation_memory** | **Boolean** | (Optional) Requires autotranslate_enabled to be true | [optional]
29
- **smart_suggest_enabled** | **Boolean** | (Optional) Smart Suggest, requires machine_translation_enabled | [optional]
30
- **smart_suggest_use_glossary** | **Boolean** | (Optional) Requires smart_suggest_enabled to be true | [optional]
31
- **smart_suggest_use_machine_translation** | **Boolean** | (Optional) Requires smart_suggest_enabled to be true | [optional]
32
29
 
33
30
  ## Code Sample
34
31
 
@@ -41,7 +38,7 @@ instance = Phrase::ProjectUpdateParameters.new(account_id: abcd1234,
41
38
  main_format: yml,
42
39
  media: Python,
43
40
  shares_translation_memory: true,
44
- project_image: [B@3c288a4e,
41
+ project_image: [B@4c49193a,
45
42
  remove_project_image: false,
46
43
  workflow: review,
47
44
  machine_translation_enabled: true,
@@ -56,10 +53,7 @@ instance = Phrase::ProjectUpdateParameters.new(account_id: abcd1234,
56
53
  autotranslate_check_new_locales: true,
57
54
  autotranslate_mark_as_unverified: true,
58
55
  autotranslate_use_machine_translation: true,
59
- autotranslate_use_translation_memory: true,
60
- smart_suggest_enabled: true,
61
- smart_suggest_use_glossary: true,
62
- smart_suggest_use_machine_translation: true)
56
+ autotranslate_use_translation_memory: true)
63
57
  ```
64
58
 
65
59
 
@@ -17,7 +17,7 @@ require 'Phrase'
17
17
  instance = Phrase::ScreenshotUpdateParameters.new(branch: my-feature-branch,
18
18
  name: A screenshot name,
19
19
  description: A screenshot description,
20
- filename: [B@1529406e)
20
+ filename: [B@575dab37)
21
21
  ```
22
22
 
23
23
 
data/docs/UploadsApi.md CHANGED
@@ -52,10 +52,11 @@ opts = {
52
52
  skip_unverification: true, # Boolean | Indicates whether the upload should unverify updated translations.
53
53
  file_encoding: 'file_encoding_example', # String | Enforces a specific encoding on the file contents. Valid options are \\\"UTF-8\\\", \\\"UTF-16\\\" and \\\"ISO-8859-1\\\".
54
54
  locale_mapping: { ... }, # Object | Mapping between locale names and translation columns. Required in some formats like CSV or XLSX.
55
- format_options: { ... }, # Object | Additional options available for specific formats. See our format guide for complete list.
55
+ format_options: { ... }, # Object | Additional options available for specific formats. See our format guide for the [complete list](https://support.phrase.com/hc/en-us/articles/9652464547740-List-of-Supported-File-Types-Strings).
56
56
  autotranslate: true, # Boolean | If set, translations for the uploaded language will be fetched automatically.
57
57
  mark_reviewed: true, # Boolean | Indicated whether the imported translations should be marked as reviewed. This setting is available if the review workflow is enabled for the project.
58
- tag_only_affected_keys: true # Boolean | Indicates whether only keys affected (created or updated) by the upload should be tagged. The default is `false`
58
+ tag_only_affected_keys: true, # Boolean | Indicates whether only keys affected (created or updated) by the upload should be tagged. The default is `false`
59
+ translation_key_prefix: 'translation_key_prefix_example' # String | This prefix will be added to all uploaded translation key names to prevent collisions. Use a meaningful prefix related to your project or file to keep key names organized.
59
60
  }
60
61
 
61
62
  begin
@@ -88,10 +89,11 @@ Name | Type | Description | Notes
88
89
  **skip_unverification** | **Boolean**| Indicates whether the upload should unverify updated translations. | [optional]
89
90
  **file_encoding** | **String**| Enforces a specific encoding on the file contents. Valid options are \\\&quot;UTF-8\\\&quot;, \\\&quot;UTF-16\\\&quot; and \\\&quot;ISO-8859-1\\\&quot;. | [optional]
90
91
  **locale_mapping** | [**Object**](Object.md)| Mapping between locale names and translation columns. Required in some formats like CSV or XLSX. | [optional]
91
- **format_options** | [**Object**](Object.md)| Additional options available for specific formats. See our format guide for complete list. | [optional]
92
+ **format_options** | [**Object**](Object.md)| Additional options available for specific formats. See our format guide for the [complete list](https://support.phrase.com/hc/en-us/articles/9652464547740-List-of-Supported-File-Types-Strings). | [optional]
92
93
  **autotranslate** | **Boolean**| If set, translations for the uploaded language will be fetched automatically. | [optional]
93
94
  **mark_reviewed** | **Boolean**| Indicated whether the imported translations should be marked as reviewed. This setting is available if the review workflow is enabled for the project. | [optional]
94
95
  **tag_only_affected_keys** | **Boolean**| Indicates whether only keys affected (created or updated) by the upload should be tagged. The default is &#x60;false&#x60; | [optional] [default to false]
96
+ **translation_key_prefix** | **String**| This prefix will be added to all uploaded translation key names to prevent collisions. Use a meaningful prefix related to your project or file to keep key names organized. | [optional]
95
97
 
96
98
  ### Return type
97
99
 
@@ -116,13 +116,12 @@ module Phrase
116
116
  # @param project_id [String] Project ID
117
117
  # @param key_id [String] Translation Key ID
118
118
  # @param comment_id [String] Comment ID
119
+ # @param comment_create_parameters1 [CommentCreateParameters1]
119
120
  # @param [Hash] opts the optional parameters
120
121
  # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
121
- # @option opts [String] :branch specify the branch to use
122
- # @option opts [String] :message specify the message for the comment
123
122
  # @return [Comment]
124
- def reply_create(project_id, key_id, comment_id, opts = {})
125
- data, _status_code, _headers = reply_create_with_http_info(project_id, key_id, comment_id, opts)
123
+ def reply_create(project_id, key_id, comment_id, comment_create_parameters1, opts = {})
124
+ data, _status_code, _headers = reply_create_with_http_info(project_id, key_id, comment_id, comment_create_parameters1, opts)
126
125
  data
127
126
  end
128
127
 
@@ -131,12 +130,11 @@ module Phrase
131
130
  # @param project_id [String] Project ID
132
131
  # @param key_id [String] Translation Key ID
133
132
  # @param comment_id [String] Comment ID
133
+ # @param comment_create_parameters1 [CommentCreateParameters1]
134
134
  # @param [Hash] opts the optional parameters
135
135
  # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
136
- # @option opts [String] :branch specify the branch to use
137
- # @option opts [String] :message specify the message for the comment
138
136
  # @return [Array<(Response<(Comment)>, Integer, Hash)>] Response<(Comment)> data, response status code and response headers
139
- def reply_create_with_http_info(project_id, key_id, comment_id, opts = {})
137
+ def reply_create_with_http_info(project_id, key_id, comment_id, comment_create_parameters1, opts = {})
140
138
  if @api_client.config.debugging
141
139
  @api_client.config.logger.debug 'Calling API: CommentRepliesApi.reply_create ...'
142
140
  end
@@ -152,25 +150,29 @@ module Phrase
152
150
  if @api_client.config.client_side_validation && comment_id.nil?
153
151
  fail ArgumentError, "Missing the required parameter 'comment_id' when calling CommentRepliesApi.reply_create"
154
152
  end
153
+ # verify the required parameter 'comment_create_parameters1' is set
154
+ if @api_client.config.client_side_validation && comment_create_parameters1.nil?
155
+ fail ArgumentError, "Missing the required parameter 'comment_create_parameters1' when calling CommentRepliesApi.reply_create"
156
+ end
155
157
  # resource path
156
158
  local_var_path = '/projects/{project_id}/keys/{key_id}/comments/{comment_id}/replies'.sub('{' + 'project_id' + '}', CGI.escape(project_id.to_s)).sub('{' + 'key_id' + '}', CGI.escape(key_id.to_s)).sub('{' + 'comment_id' + '}', CGI.escape(comment_id.to_s))
157
159
 
158
160
  # query parameters
159
161
  query_params = opts[:query_params] || {}
160
- query_params[:'branch'] = opts[:'branch'] if !opts[:'branch'].nil?
161
- query_params[:'message'] = opts[:'message'] if !opts[:'message'].nil?
162
162
 
163
163
  # header parameters
164
164
  header_params = opts[:header_params] || {}
165
165
  # HTTP header 'Accept' (if needed)
166
166
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
167
+ # HTTP header 'Content-Type'
168
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
167
169
  header_params[:'X-PhraseApp-OTP'] = opts[:'x_phrase_app_otp'] if !opts[:'x_phrase_app_otp'].nil?
168
170
 
169
171
  # form parameters
170
172
  form_params = opts[:form_params] || {}
171
173
 
172
174
  # http body (model)
173
- post_body = opts[:body]
175
+ post_body = opts[:body] || @api_client.object_to_http_body(comment_create_parameters1)
174
176
 
175
177
  # return_type
176
178
  return_type = opts[:return_type] || 'Comment'
@@ -14,8 +14,6 @@ module Phrase
14
14
  # @param comment_create_parameters [CommentCreateParameters]
15
15
  # @param [Hash] opts the optional parameters
16
16
  # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
17
- # @option opts [String] :message specify the message for the comment
18
- # @option opts [Array<String>] :locale_ids specify the locales for the comment
19
17
  # @return [Comment]
20
18
  def comment_create(project_id, key_id, comment_create_parameters, opts = {})
21
19
  data, _status_code, _headers = comment_create_with_http_info(project_id, key_id, comment_create_parameters, opts)
@@ -29,8 +27,6 @@ module Phrase
29
27
  # @param comment_create_parameters [CommentCreateParameters]
30
28
  # @param [Hash] opts the optional parameters
31
29
  # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
32
- # @option opts [String] :message specify the message for the comment
33
- # @option opts [Array<String>] :locale_ids specify the locales for the comment
34
30
  # @return [Array<(Response<(Comment)>, Integer, Hash)>] Response<(Comment)> data, response status code and response headers
35
31
  def comment_create_with_http_info(project_id, key_id, comment_create_parameters, opts = {})
36
32
  if @api_client.config.debugging
@@ -53,8 +49,6 @@ module Phrase
53
49
 
54
50
  # query parameters
55
51
  query_params = opts[:query_params] || {}
56
- query_params[:'message'] = opts[:'message'] if !opts[:'message'].nil?
57
- query_params[:'locale_ids'] = @api_client.build_collection_param(opts[:'locale_ids'], :multi) if !opts[:'locale_ids'].nil?
58
52
 
59
53
  # header parameters
60
54
  header_params = opts[:header_params] || {}
@@ -10,7 +10,6 @@ module Phrase
10
10
  # List formats
11
11
  # Get a handy list of all localization file formats supported in Phrase.
12
12
  # @param [Hash] opts the optional parameters
13
- # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
14
13
  # @return [Array<Format>]
15
14
  def formats_list(opts = {})
16
15
  data, _status_code, _headers = formats_list_with_http_info(opts)
@@ -20,7 +19,6 @@ module Phrase
20
19
  # List formats
21
20
  # Get a handy list of all localization file formats supported in Phrase.
22
21
  # @param [Hash] opts the optional parameters
23
- # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
24
22
  # @return [Array<(Response<(Array<Format>)>, Integer, Hash)>] Response<(Array<Format>)> data, response status code and response headers
25
23
  def formats_list_with_http_info(opts = {})
26
24
  if @api_client.config.debugging
@@ -36,7 +34,6 @@ module Phrase
36
34
  header_params = opts[:header_params] || {}
37
35
  # HTTP header 'Accept' (if needed)
38
36
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
39
- header_params[:'X-PhraseApp-OTP'] = opts[:'x_phrase_app_otp'] if !opts[:'x_phrase_app_otp'].nil?
40
37
 
41
38
  # form parameters
42
39
  form_params = opts[:form_params] || {}
@@ -321,7 +321,7 @@ module Phrase
321
321
  # @param [Hash] opts the optional parameters
322
322
  # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
323
323
  # @option opts [String] :branch specify the branch to use
324
- # @option opts [Array<String>] :translation_key_ids ids of keys that should added to the job
324
+ # @option opts [Array<String>] :translation_key_ids ids of keys that should be removed from the job
325
325
  # @return [nil]
326
326
  def job_keys_delete(project_id, id, opts = {})
327
327
  data, _status_code, _headers = job_keys_delete_with_http_info(project_id, id, opts)
@@ -335,7 +335,7 @@ module Phrase
335
335
  # @param [Hash] opts the optional parameters
336
336
  # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
337
337
  # @option opts [String] :branch specify the branch to use
338
- # @option opts [Array<String>] :translation_key_ids ids of keys that should added to the job
338
+ # @option opts [Array<String>] :translation_key_ids ids of keys that should be removed from the job
339
339
  # @return [Array<(Response, Integer, Hash)>] Response<(nil, response status code and response headers
340
340
  def job_keys_delete_with_http_info(project_id, id, opts = {})
341
341
  if @api_client.config.debugging
@@ -250,6 +250,8 @@ module Phrase
250
250
  # @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 is enabled for the project.
251
251
  # @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 ID of the locale that should be used as the fallback. Requires include_empty_translations to be set to &lt;code&gt;true&lt;/code&gt;.
252
252
  # @option opts [String] :source_locale_id Provides the source language of a corresponding job as the source language of the generated locale file. This parameter will be ignored unless used in combination with a &lt;code&gt;tag&lt;/code&gt; parameter indicating a specific job.
253
+ # @option opts [String] :translation_key_prefix Download all translation keys, and remove the specified prefix where possible. Warning: this may create duplicate key names if other keys share the same name after the prefix is removed.
254
+ # @option opts [Boolean] :filter_by_prefix Only download translation keys containing the specified prefix, and remove the prefix from the generated file.
253
255
  # @option opts [Object] :custom_metadata_filters Custom metadata filters. Provide the name of the metadata field and the value to filter by. Only keys with matching metadata will be included in the download.
254
256
  # @return [File]
255
257
  def locale_download(project_id, id, opts = {})
@@ -281,6 +283,8 @@ module Phrase
281
283
  # @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 is enabled for the project.
282
284
  # @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 ID of the locale that should be used as the fallback. Requires include_empty_translations to be set to &lt;code&gt;true&lt;/code&gt;.
283
285
  # @option opts [String] :source_locale_id Provides the source language of a corresponding job as the source language of the generated locale file. This parameter will be ignored unless used in combination with a &lt;code&gt;tag&lt;/code&gt; parameter indicating a specific job.
286
+ # @option opts [String] :translation_key_prefix Download all translation keys, and remove the specified prefix where possible. Warning: this may create duplicate key names if other keys share the same name after the prefix is removed.
287
+ # @option opts [Boolean] :filter_by_prefix Only download translation keys containing the specified prefix, and remove the prefix from the generated file.
284
288
  # @option opts [Object] :custom_metadata_filters Custom metadata filters. Provide the name of the metadata field and the value to filter by. Only keys with matching metadata will be included in the download.
285
289
  # @return [Array<(Response<(File)>, Integer, Hash)>] Response<(File)> data, response status code and response headers
286
290
  def locale_download_with_http_info(project_id, id, opts = {})
@@ -316,6 +320,8 @@ module Phrase
316
320
  query_params[:'use_last_reviewed_version'] = opts[:'use_last_reviewed_version'] if !opts[:'use_last_reviewed_version'].nil?
317
321
  query_params[:'fallback_locale_id'] = opts[:'fallback_locale_id'] if !opts[:'fallback_locale_id'].nil?
318
322
  query_params[:'source_locale_id'] = opts[:'source_locale_id'] if !opts[:'source_locale_id'].nil?
323
+ query_params[:'translation_key_prefix'] = opts[:'translation_key_prefix'] if !opts[:'translation_key_prefix'].nil?
324
+ query_params[:'filter_by_prefix'] = opts[:'filter_by_prefix'] if !opts[:'filter_by_prefix'].nil?
319
325
  query_params[:'custom_metadata_filters'] = opts[:'custom_metadata_filters'] if !opts[:'custom_metadata_filters'].nil?
320
326
 
321
327
  # header parameters
@@ -26,10 +26,11 @@ module Phrase
26
26
  # @option opts [Boolean] :skip_unverification Indicates whether the upload should unverify updated translations.
27
27
  # @option opts [String] :file_encoding Enforces a specific encoding on the file contents. Valid options are \\\&quot;UTF-8\\\&quot;, \\\&quot;UTF-16\\\&quot; and \\\&quot;ISO-8859-1\\\&quot;.
28
28
  # @option opts [Object] :locale_mapping Mapping between locale names and translation columns. Required in some formats like CSV or XLSX.
29
- # @option opts [Object] :format_options Additional options available for specific formats. See our format guide for complete list.
29
+ # @option opts [Object] :format_options Additional options available for specific formats. See our format guide for the [complete list](https://support.phrase.com/hc/en-us/articles/9652464547740-List-of-Supported-File-Types-Strings).
30
30
  # @option opts [Boolean] :autotranslate If set, translations for the uploaded language will be fetched automatically.
31
31
  # @option opts [Boolean] :mark_reviewed Indicated whether the imported translations should be marked as reviewed. This setting is available if the review workflow is enabled for the project.
32
32
  # @option opts [Boolean] :tag_only_affected_keys Indicates whether only keys affected (created or updated) by the upload should be tagged. The default is &#x60;false&#x60; (default to false)
33
+ # @option opts [String] :translation_key_prefix This prefix will be added to all uploaded translation key names to prevent collisions. Use a meaningful prefix related to your project or file to keep key names organized.
33
34
  # @return [Upload]
34
35
  def upload_create(project_id, file, file_format, locale_id, opts = {})
35
36
  data, _status_code, _headers = upload_create_with_http_info(project_id, file, file_format, locale_id, opts)
@@ -55,10 +56,11 @@ module Phrase
55
56
  # @option opts [Boolean] :skip_unverification Indicates whether the upload should unverify updated translations.
56
57
  # @option opts [String] :file_encoding Enforces a specific encoding on the file contents. Valid options are \\\&quot;UTF-8\\\&quot;, \\\&quot;UTF-16\\\&quot; and \\\&quot;ISO-8859-1\\\&quot;.
57
58
  # @option opts [Object] :locale_mapping Mapping between locale names and translation columns. Required in some formats like CSV or XLSX.
58
- # @option opts [Object] :format_options Additional options available for specific formats. See our format guide for complete list.
59
+ # @option opts [Object] :format_options Additional options available for specific formats. See our format guide for the [complete list](https://support.phrase.com/hc/en-us/articles/9652464547740-List-of-Supported-File-Types-Strings).
59
60
  # @option opts [Boolean] :autotranslate If set, translations for the uploaded language will be fetched automatically.
60
61
  # @option opts [Boolean] :mark_reviewed Indicated whether the imported translations should be marked as reviewed. This setting is available if the review workflow is enabled for the project.
61
62
  # @option opts [Boolean] :tag_only_affected_keys Indicates whether only keys affected (created or updated) by the upload should be tagged. The default is &#x60;false&#x60;
63
+ # @option opts [String] :translation_key_prefix This prefix will be added to all uploaded translation key names to prevent collisions. Use a meaningful prefix related to your project or file to keep key names organized.
62
64
  # @return [Array<(Response<(Upload)>, Integer, Hash)>] Response<(Upload)> data, response status code and response headers
63
65
  def upload_create_with_http_info(project_id, file, file_format, locale_id, opts = {})
64
66
  if @api_client.config.debugging
@@ -114,6 +116,7 @@ module Phrase
114
116
  form_params['autotranslate'] = opts[:'autotranslate'] if !opts[:'autotranslate'].nil?
115
117
  form_params['mark_reviewed'] = opts[:'mark_reviewed'] if !opts[:'mark_reviewed'].nil?
116
118
  form_params['tag_only_affected_keys'] = opts[:'tag_only_affected_keys'] if !opts[:'tag_only_affected_keys'].nil?
119
+ form_params['translation_key_prefix'] = opts[:'translation_key_prefix'] if !opts[:'translation_key_prefix'].nil?
117
120
 
118
121
  # http body (model)
119
122
  post_body = opts[:body]