phrase 4.24.0 → 4.25.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (63) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +16 -0
  3. data/README.md +7 -3
  4. data/docs/BranchComparison.md +23 -0
  5. data/docs/BranchComparisonChange.md +19 -0
  6. data/docs/BranchComparisonDiff.md +21 -0
  7. data/docs/BranchComparisonDiffConflictsValue.md +19 -0
  8. data/docs/BranchesApi.md +5 -4
  9. data/docs/Format.md +20 -20
  10. data/docs/FormatsApi.md +1 -1
  11. data/docs/Job.md +3 -1
  12. data/docs/JobDetails.md +2 -0
  13. data/docs/KeyCreateParameters.md +1 -1
  14. data/docs/KeyUpdateParameters.md +1 -1
  15. data/docs/Locale.md +2 -0
  16. data/docs/LocaleCreateParameters.md +3 -1
  17. data/docs/LocaleDetails.md +2 -0
  18. data/docs/LocaleDownloadCreateParameters.md +4 -0
  19. data/docs/LocaleUpdateParameters.md +3 -1
  20. data/docs/LocalesApi.md +2 -2
  21. data/docs/ProjectCreateParameters.md +1 -1
  22. data/docs/ProjectUpdateParameters.md +1 -1
  23. data/docs/RepoSync.md +2 -0
  24. data/docs/RepoSyncCreateParameters.md +2 -0
  25. data/docs/ScreenshotUpdateParameters.md +1 -1
  26. data/docs/ScreenshotsApi.md +9 -9
  27. data/lib/phrase/api/branches_api.rb +5 -3
  28. data/lib/phrase/api/formats_api.rb +2 -2
  29. data/lib/phrase/api/locales_api.rb +2 -2
  30. data/lib/phrase/api/screenshots_api.rb +16 -12
  31. data/lib/phrase/models/branch_comparison.rb +224 -0
  32. data/lib/phrase/models/branch_comparison_change.rb +212 -0
  33. data/lib/phrase/models/branch_comparison_diff.rb +223 -0
  34. data/lib/phrase/models/branch_comparison_diff_conflicts_value.rb +209 -0
  35. data/lib/phrase/models/format.rb +60 -0
  36. data/lib/phrase/models/job.rb +16 -5
  37. data/lib/phrase/models/job_details.rb +12 -1
  38. data/lib/phrase/models/locale.rb +10 -1
  39. data/lib/phrase/models/locale_create_parameters.rb +14 -4
  40. data/lib/phrase/models/locale_details.rb +10 -1
  41. data/lib/phrase/models/locale_download_create_parameters.rb +21 -1
  42. data/lib/phrase/models/locale_update_parameters.rb +14 -4
  43. data/lib/phrase/models/repo_sync.rb +29 -1
  44. data/lib/phrase/models/repo_sync_create_parameters.rb +27 -1
  45. data/lib/phrase/version.rb +1 -1
  46. data/lib/phrase.rb +4 -0
  47. data/spec/api/branches_api_spec.rb +1 -1
  48. data/spec/api/formats_api_spec.rb +1 -1
  49. data/spec/api/screenshots_api_spec.rb +4 -4
  50. data/spec/models/branch_comparison_change_spec.rb +35 -0
  51. data/spec/models/branch_comparison_diff_conflicts_value_spec.rb +35 -0
  52. data/spec/models/branch_comparison_diff_spec.rb +41 -0
  53. data/spec/models/branch_comparison_spec.rb +47 -0
  54. data/spec/models/job_details_spec.rb +6 -0
  55. data/spec/models/job_spec.rb +6 -0
  56. data/spec/models/locale_create_parameters_spec.rb +6 -0
  57. data/spec/models/locale_details_spec.rb +6 -0
  58. data/spec/models/locale_download_create_parameters_spec.rb +12 -0
  59. data/spec/models/locale_spec.rb +6 -0
  60. data/spec/models/locale_update_parameters_spec.rb +6 -0
  61. data/spec/models/repo_sync_create_parameters_spec.rb +6 -0
  62. data/spec/models/repo_sync_spec.rb +6 -0
  63. metadata +18 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8d213192723604fbb4ef7a90d6a9f29acc732851fef5f2aca3fd4ca40b12c15d
4
- data.tar.gz: 187feac87a11747ede044a04da9d66304dc683e66d6055c83091a570a2342e77
3
+ metadata.gz: e6cad43dbdeb14af43039a96509f173dcd8c3358bbaab868cb16cf04cb4fc05f
4
+ data.tar.gz: 3721a11b575861aad15b88d6dd410dd826405f57178286542dc37149de357b73
5
5
  SHA512:
6
- metadata.gz: 1c2184c4658be521ee20da21c7e10545aa9be346d993e2f35424188686e2584ade0e47d950f84f7c5116ea3098b177c829c8598281851ca9e03b78a716c6777d
7
- data.tar.gz: 633b174f29f95e59035fdc6a7beb8fbc789cc9b79ddd314c4dcbd640e2a2a198d950281d0e05265812126f3871f35a6e4d6572150727211fa718c51c2718b123
6
+ metadata.gz: 427e8f756767ed00efba125b3f5e168b51ec77b041e8aaa41d9af0a0a19a553a433941f5bc1988f2ab069c95170b8491fca8b4c5639c0590e94fe0eead400807
7
+ data.tar.gz: 1e52d069831312b3b82526499e19f6297e9e231e9b3106e6eb301277d667788d88753632cc8b76972be9bb219a0f34370224a14b054c60cfd413eba6bf09f1f8
data/CHANGELOG.md CHANGED
@@ -1,5 +1,21 @@
1
1
  # Changelog
2
2
 
3
+ ## [4.25.0](https://github.com/phrase/strings-openapi/compare/ruby-v4.24.0...ruby-v4.25.0) (2026-06-25)
4
+
5
+
6
+ ### Features
7
+
8
+ * **API:** Add language_ai_profile to locales ([#1207](https://github.com/phrase/strings-openapi/issues/1207)) ([1dbfc65](https://github.com/phrase/strings-openapi/commit/1dbfc65767a9feead5ec18b35f306b728d7b2779))
9
+ * **API:** add name field to repo sync schema and create endpoint ([#1203](https://github.com/phrase/strings-openapi/issues/1203)) ([ed5dabd](https://github.com/phrase/strings-openapi/commit/ed5dabdc5483e98ac3742466272e9de2f7949a56))
10
+ * **API:** Add translation_key_prefix and filter_by_prefix to async locale download ([#1210](https://github.com/phrase/strings-openapi/issues/1210)) ([9c0dd12](https://github.com/phrase/strings-openapi/commit/9c0dd12d938626d49ee828b6eedf6692d4669414))
11
+ * **API:** document branch compare output ([#1151](https://github.com/phrase/strings-openapi/issues/1151)) ([f082775](https://github.com/phrase/strings-openapi/commit/f0827755e1c6d6c3f66f10db5e6c26dc5003a679))
12
+ * **API:** include review_due_date in job responses ([#1205](https://github.com/phrase/strings-openapi/issues/1205)) ([649d5ab](https://github.com/phrase/strings-openapi/commit/649d5ab6001f46f8c785d8d73cb13ac2062d179b))
13
+
14
+
15
+ ### Bug Fixes
16
+
17
+ * **API:** improve get /formats documentation ([#1196](https://github.com/phrase/strings-openapi/issues/1196)) ([46fd53b](https://github.com/phrase/strings-openapi/commit/46fd53bda361a5b928147ab965515c29dbf887d3))
18
+
3
19
  ## [4.24.0](https://github.com/phrase/strings-openapi/compare/ruby-v4.23.0...ruby-v4.24.0) (2026-06-11)
4
20
 
5
21
 
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: 4.24.0
10
+ - Package version: 4.25.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-4.24.0.gem
59
+ gem install ./phrase-4.25.0.gem
60
60
  ```
61
61
 
62
- (for development, run `gem install --dev ./phrase-4.24.0.gem` to install the development dependencies)
62
+ (for development, run `gem install --dev ./phrase-4.25.0.gem` to install the development dependencies)
63
63
 
64
64
  ## Getting Started
65
65
 
@@ -437,6 +437,10 @@ Class | Method | HTTP request | Description
437
437
  - [Phrase::BlacklistedKeyCreateParameters](docs/BlacklistedKeyCreateParameters.md)
438
438
  - [Phrase::BlacklistedKeyUpdateParameters](docs/BlacklistedKeyUpdateParameters.md)
439
439
  - [Phrase::Branch](docs/Branch.md)
440
+ - [Phrase::BranchComparison](docs/BranchComparison.md)
441
+ - [Phrase::BranchComparisonChange](docs/BranchComparisonChange.md)
442
+ - [Phrase::BranchComparisonDiff](docs/BranchComparisonDiff.md)
443
+ - [Phrase::BranchComparisonDiffConflictsValue](docs/BranchComparisonDiffConflictsValue.md)
440
444
  - [Phrase::BranchCreateComparisonParameters](docs/BranchCreateComparisonParameters.md)
441
445
  - [Phrase::BranchCreateParameters](docs/BranchCreateParameters.md)
442
446
  - [Phrase::BranchMergeParameters](docs/BranchMergeParameters.md)
@@ -0,0 +1,23 @@
1
+ # Phrase::BranchComparison
2
+
3
+ ## Properties
4
+
5
+ Name | Type | Description | Notes
6
+ ------------ | ------------- | ------------- | -------------
7
+ **translation_keys** | [**BranchComparisonDiff**](BranchComparisonDiff.md) | | [optional]
8
+ **translations** | [**BranchComparisonDiff**](BranchComparisonDiff.md) | | [optional]
9
+ **locales** | [**BranchComparisonDiff**](BranchComparisonDiff.md) | | [optional]
10
+ **tags** | [**BranchComparisonDiff**](BranchComparisonDiff.md) | | [optional]
11
+
12
+ ## Code Sample
13
+
14
+ ```ruby
15
+ require 'Phrase'
16
+
17
+ instance = Phrase::BranchComparison.new(translation_keys: null,
18
+ translations: null,
19
+ locales: null,
20
+ tags: null)
21
+ ```
22
+
23
+
@@ -0,0 +1,19 @@
1
+ # Phrase::BranchComparisonChange
2
+
3
+ ## Properties
4
+
5
+ Name | Type | Description | Notes
6
+ ------------ | ------------- | ------------- | -------------
7
+ **from** | **Hash<String, Object>** | | [optional]
8
+ **to** | **Hash<String, Object>** | | [optional]
9
+
10
+ ## Code Sample
11
+
12
+ ```ruby
13
+ require 'Phrase'
14
+
15
+ instance = Phrase::BranchComparisonChange.new(from: null,
16
+ to: null)
17
+ ```
18
+
19
+
@@ -0,0 +1,21 @@
1
+ # Phrase::BranchComparisonDiff
2
+
3
+ ## Properties
4
+
5
+ Name | Type | Description | Notes
6
+ ------------ | ------------- | ------------- | -------------
7
+ **base_changes** | [**Array<BranchComparisonChange>**](BranchComparisonChange.md) | Changes made to this resource type in the base branch since the branch was created. | [optional]
8
+ **head_changes** | [**Array<BranchComparisonChange>**](BranchComparisonChange.md) | Changes made to this resource type in the feature branch. | [optional]
9
+ **conflicts** | [**Hash<String, BranchComparisonDiffConflictsValue>**](BranchComparisonDiffConflictsValue.md) | Conflicting changes present in both branches, keyed by conflict type. Possible conflict type keys: `changed_in_head_changed_in_base`, `added_in_head_added_in_base`, `changed_in_head_deleted_in_base`, `deleted_in_head_changed_in_base`. Each value contains `base` and `head` arrays of changed attribute objects. | [optional]
10
+
11
+ ## Code Sample
12
+
13
+ ```ruby
14
+ require 'Phrase'
15
+
16
+ instance = Phrase::BranchComparisonDiff.new(base_changes: null,
17
+ head_changes: null,
18
+ conflicts: null)
19
+ ```
20
+
21
+
@@ -0,0 +1,19 @@
1
+ # Phrase::BranchComparisonDiffConflictsValue
2
+
3
+ ## Properties
4
+
5
+ Name | Type | Description | Notes
6
+ ------------ | ------------- | ------------- | -------------
7
+ **base** | **Array<Hash<String, Object>>** | | [optional]
8
+ **head** | **Array<Hash<String, Object>>** | | [optional]
9
+
10
+ ## Code Sample
11
+
12
+ ```ruby
13
+ require 'Phrase'
14
+
15
+ instance = Phrase::BranchComparisonDiffConflictsValue.new(base: null,
16
+ head: null)
17
+ ```
18
+
19
+
data/docs/BranchesApi.md CHANGED
@@ -18,7 +18,7 @@ Method | HTTP request | Description
18
18
 
19
19
  ## branch_compare
20
20
 
21
- > branch_compare(project_id, name, opts)
21
+ > BranchComparison branch_compare(project_id, name, opts)
22
22
 
23
23
  Compare branches
24
24
 
@@ -49,7 +49,8 @@ opts = {
49
49
 
50
50
  begin
51
51
  #Compare branches
52
- api_instance.branch_compare(project_id, name, opts)
52
+ result = api_instance.branch_compare(project_id, name, opts)
53
+ pp result
53
54
  rescue Phrase::ApiError => e
54
55
  puts "Exception when calling BranchesApi->branch_compare: #{e}"
55
56
  end
@@ -66,7 +67,7 @@ Name | Type | Description | Notes
66
67
 
67
68
  ### Return type
68
69
 
69
- Response<(nil (empty response body))>
70
+ Response<([**BranchComparison**](BranchComparison.md))>
70
71
 
71
72
  ### Authorization
72
73
 
@@ -75,7 +76,7 @@ Response<(nil (empty response body))>
75
76
  ### HTTP request headers
76
77
 
77
78
  - **Content-Type**: Not defined
78
- - **Accept**: Not defined
79
+ - **Accept**: application/json
79
80
 
80
81
 
81
82
  ## branch_comparison_create
data/docs/Format.md CHANGED
@@ -4,32 +4,32 @@
4
4
 
5
5
  Name | Type | Description | Notes
6
6
  ------------ | ------------- | ------------- | -------------
7
- **name** | **String** | | [optional]
8
- **api_name** | **String** | | [optional]
9
- **description** | **String** | | [optional]
10
- **extension** | **String** | | [optional]
11
- **default_encoding** | **String** | | [optional]
12
- **importable** | **Boolean** | | [optional]
13
- **exportable** | **Boolean** | | [optional]
14
- **default_file** | **String** | | [optional]
15
- **renders_default_locale** | **Boolean** | | [optional]
16
- **includes_locale_information** | **Boolean** | | [optional]
7
+ **name** | **String** | Human-readable display name of the format. |
8
+ **api_name** | **String** | Identifier used to reference this format in API requests, such as the file_format parameter on the uploads and downloads endpoints. |
9
+ **description** | **String** | Human-readable summary of the format and its typical use case. |
10
+ **extension** | **String** | Default file extension associated with this format. |
11
+ **default_encoding** | **String** | Default character encoding used when reading or writing files in this format. |
12
+ **importable** | **Boolean** | Whether locale files can be imported using this format. |
13
+ **exportable** | **Boolean** | Whether locale files can be exported using this format. |
14
+ **default_file** | **String** | Conventional file path pattern for this format. Contains locale_name as a placeholder for the locale identifier. |
15
+ **renders_default_locale** | **Boolean** | When true, exported files contain the default locale&#39;s content for any key that has no translation in the target locale. |
16
+ **includes_locale_information** | **Boolean** | When true, files in this format embed locale information so Phrase can detect the locale automatically on import. |
17
17
 
18
18
  ## Code Sample
19
19
 
20
20
  ```ruby
21
21
  require 'Phrase'
22
22
 
23
- instance = Phrase::Format.new(name: null,
24
- api_name: null,
25
- description: null,
26
- extension: null,
27
- default_encoding: null,
28
- importable: null,
29
- exportable: null,
30
- default_file: null,
31
- renders_default_locale: null,
32
- includes_locale_information: null)
23
+ instance = Phrase::Format.new(name: Ruby/Rails YAML,
24
+ api_name: yml,
25
+ description: YAML file format for use with Ruby/Rails applications,
26
+ extension: yml,
27
+ default_encoding: UTF-8,
28
+ importable: true,
29
+ exportable: true,
30
+ default_file: ./config/locales/&lt;locale_name&gt;.yml,
31
+ renders_default_locale: false,
32
+ includes_locale_information: false)
33
33
  ```
34
34
 
35
35
 
data/docs/FormatsApi.md CHANGED
@@ -14,7 +14,7 @@ Method | HTTP request | Description
14
14
 
15
15
  List formats
16
16
 
17
- Get a handy list of all localization file formats supported in Phrase.
17
+ Returns all file formats that Phrase Strings supports. Use the api_name value from each format as the file_format parameter when uploading or downloading locale files. Not every format supports both directions: check the importable and exportable fields before using a format in a workflow. This endpoint does not require authentication and is not subject to rate limiting.
18
18
 
19
19
  ### Example
20
20
 
data/docs/Job.md CHANGED
@@ -16,6 +16,7 @@ Name | Type | Description | Notes
16
16
  **updated_at** | **Time** | | [optional]
17
17
  **automation_id** | **String** | The ID of the automation that created this job, or null if the job was created manually. | [optional]
18
18
  **job_template_id** | **String** | The ID of the job template this job was created from, or null if no template was used. | [optional]
19
+ **review_due_date** | **Time** | The review due date for this job. Returns &#x60;null&#x60; when the project does not have review workflow enabled. | [optional]
19
20
 
20
21
  ## Code Sample
21
22
 
@@ -33,7 +34,8 @@ instance = Phrase::Job.new(id: null,
33
34
  created_at: null,
34
35
  updated_at: null,
35
36
  automation_id: null,
36
- job_template_id: null)
37
+ job_template_id: null,
38
+ review_due_date: 2015-03-25T11:43:52Z)
37
39
  ```
38
40
 
39
41
 
data/docs/JobDetails.md CHANGED
@@ -16,6 +16,7 @@ Name | Type | Description | Notes
16
16
  **updated_at** | **Time** | | [optional]
17
17
  **automation_id** | **String** | The ID of the automation that created this job, or null if the job was created manually. | [optional]
18
18
  **job_template_id** | **String** | The ID of the job template this job was created from, or null if no template was used. | [optional]
19
+ **review_due_date** | **Time** | The review due date for this job. Returns &#x60;null&#x60; when the project does not have review workflow enabled. | [optional]
19
20
  **owner** | [**UserPreview**](UserPreview.md) | | [optional]
20
21
  **job_tag_name** | **String** | | [optional]
21
22
  **source_translations_updated_at** | **Time** | | [optional]
@@ -42,6 +43,7 @@ instance = Phrase::JobDetails.new(id: null,
42
43
  updated_at: null,
43
44
  automation_id: null,
44
45
  job_template_id: null,
46
+ review_due_date: 2015-03-25T11:43:52Z,
45
47
  owner: null,
46
48
  job_tag_name: null,
47
49
  source_translations_updated_at: null,
@@ -40,7 +40,7 @@ instance = Phrase::KeyCreateParameters.new(branch: my-feature-branch,
40
40
  data_type: number,
41
41
  tags: awesome-feature,needs-proofreading,
42
42
  max_characters_allowed: 140,
43
- screenshot: [B@5db553f9,
43
+ screenshot: [B@6d448772,
44
44
  remove_screenshot: null,
45
45
  unformatted: null,
46
46
  default_translation_content: Default translation content,
@@ -38,7 +38,7 @@ instance = Phrase::KeyUpdateParameters.new(branch: my-feature-branch,
38
38
  data_type: number,
39
39
  tags: awesome-feature,needs-proofreading,
40
40
  max_characters_allowed: 140,
41
- screenshot: [B@264e6ac3,
41
+ screenshot: [B@614a32ef,
42
42
  remove_screenshot: null,
43
43
  unformatted: null,
44
44
  xml_space_preserve: null,
data/docs/Locale.md CHANGED
@@ -14,6 +14,7 @@ Name | Type | Description | Notes
14
14
  **ordinal_plural_forms** | **Array&lt;String&gt;** | | [optional]
15
15
  **source_locale** | [**LocalePreview**](LocalePreview.md) | | [optional]
16
16
  **fallback_locale** | [**LocalePreview**](LocalePreview.md) | | [optional]
17
+ **language_ai_profile** | **String** | | [optional]
17
18
  **created_at** | **Time** | | [optional]
18
19
  **updated_at** | **Time** | | [optional]
19
20
 
@@ -32,6 +33,7 @@ instance = Phrase::Locale.new(id: null,
32
33
  ordinal_plural_forms: null,
33
34
  source_locale: null,
34
35
  fallback_locale: null,
36
+ language_ai_profile: null,
35
37
  created_at: null,
36
38
  updated_at: null)
37
39
  ```
@@ -15,6 +15,7 @@ Name | Type | Description | Notes
15
15
  **unverify_new_translations** | **Boolean** | Indicates that new translations for this locale should be marked as unverified. Part of the [Advanced Workflows](https://support.phrase.com/hc/en-us/articles/5784094755484) feature. | [optional]
16
16
  **unverify_updated_translations** | **Boolean** | Indicates that updated translations for this locale should be marked as unverified. Part of the [Advanced Workflows](https://support.phrase.com/hc/en-us/articles/5784094755484) feature. | [optional]
17
17
  **autotranslate** | **Boolean** | If set, translations for this locale will be fetched automatically, right after creation. | [optional]
18
+ **language_ai_profile** | **String** | Identifier of the Language AI profile to use for this locale. | [optional]
18
19
 
19
20
  ## Code Sample
20
21
 
@@ -31,7 +32,8 @@ instance = Phrase::LocaleCreateParameters.new(branch: my-feature-branch,
31
32
  fallback_locale_id: abcd1234abcd1234abcd1234abcd1234,
32
33
  unverify_new_translations: null,
33
34
  unverify_updated_translations: null,
34
- autotranslate: null)
35
+ autotranslate: null,
36
+ language_ai_profile: abcd1234abcd1234abcd1234abcd1234)
35
37
  ```
36
38
 
37
39
 
@@ -14,6 +14,7 @@ Name | Type | Description | Notes
14
14
  **ordinal_plural_forms** | **Array&lt;String&gt;** | | [optional]
15
15
  **source_locale** | [**LocalePreview**](LocalePreview.md) | | [optional]
16
16
  **fallback_locale** | [**LocalePreview**](LocalePreview.md) | | [optional]
17
+ **language_ai_profile** | **String** | | [optional]
17
18
  **created_at** | **Time** | | [optional]
18
19
  **updated_at** | **Time** | | [optional]
19
20
  **statistics** | [**LocaleStatistics**](LocaleStatistics.md) | | [optional]
@@ -33,6 +34,7 @@ instance = Phrase::LocaleDetails.new(id: null,
33
34
  ordinal_plural_forms: null,
34
35
  source_locale: null,
35
36
  fallback_locale: null,
37
+ language_ai_profile: null,
36
38
  created_at: null,
37
39
  updated_at: null,
38
40
  statistics: null)
@@ -21,6 +21,8 @@ Name | Type | Description | Notes
21
21
  **fallback_for_unverified_translations** | **Boolean** | If set to &#x60;true&#x60;, translations in a non-final state are replaced by the fallback locale&#39;s translation at export time. In the simple workflow, \&quot;non-final\&quot; means &#x60;unverified&#x60;. In the review workflow, it additionally includes &#x60;translated&#x60; (awaiting review). No stored translations are modified. Requires &#x60;fallback_locale_id&#x60; or &#x60;use_locale_fallback&#x60; to be set; a &#x60;422&#x60; validation error is returned otherwise. | [optional]
22
22
  **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 &#x60;tag&#x60; parameter indicating a specific job. | [optional]
23
23
  **custom_metadata_filters** | **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. | [optional]
24
+ **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]
25
+ **filter_by_prefix** | **Boolean** | Only download translation keys containing the prefix specified by &#x60;translation_key_prefix&#x60;, and remove that prefix from the generated file. Requires &#x60;translation_key_prefix&#x60; to be set. | [optional]
24
26
  **updated_since** | **String** | Only include translations and keys that have been updated since the given date. The date must be in ISO 8601 format (e.g., &#x60;2023-01-01T00:00:00Z&#x60;). | [optional]
25
27
 
26
28
  ## Code Sample
@@ -45,6 +47,8 @@ instance = Phrase::LocaleDownloadCreateParameters.new(file_format: yml,
45
47
  fallback_for_unverified_translations: false,
46
48
  source_locale_id: abcd1234abcd1234abcd1234abcd1234,
47
49
  custom_metadata_filters: null,
50
+ translation_key_prefix: prefix_,
51
+ filter_by_prefix: null,
48
52
  updated_since: 2023-01-01T00:00:00Z)
49
53
  ```
50
54
 
@@ -15,6 +15,7 @@ Name | Type | Description | Notes
15
15
  **unverify_new_translations** | **Boolean** | Indicates that new translations for this locale should be marked as unverified. Part of the [Advanced Workflows](https://support.phrase.com/hc/en-us/articles/5784094755484) feature. | [optional]
16
16
  **unverify_updated_translations** | **Boolean** | Indicates that updated translations for this locale should be marked as unverified. Part of the [Advanced Workflows](https://support.phrase.com/hc/en-us/articles/5784094755484) feature. | [optional]
17
17
  **autotranslate** | **Boolean** | If set, translations for this locale will be fetched automatically, right after creation. | [optional]
18
+ **language_ai_profile** | **String** | Identifier of the Language AI profile to use for this locale. | [optional]
18
19
 
19
20
  ## Code Sample
20
21
 
@@ -31,7 +32,8 @@ instance = Phrase::LocaleUpdateParameters.new(branch: my-feature-branch,
31
32
  fallback_locale_id: abcd1234abcd1234abcd1234abcd1234,
32
33
  unverify_new_translations: null,
33
34
  unverify_updated_translations: null,
34
- autotranslate: null)
35
+ autotranslate: null,
36
+ language_ai_profile: abcd1234abcd1234abcd1234abcd1234)
35
37
  ```
36
38
 
37
39
 
data/docs/LocalesApi.md CHANGED
@@ -256,7 +256,7 @@ opts = {
256
256
  fallback_for_unverified_translations: true, # Boolean | If set to `true`, translations in a non-final state are replaced by the fallback locale's translation at export time. In the simple workflow, \"non-final\" means `unverified`. In the review workflow, it additionally includes `translated` (awaiting review). No stored translations are modified. Requires `fallback_locale_id` or `use_locale_fallback` to be set; a `422` validation error is returned otherwise.
257
257
  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 `tag` parameter indicating a specific job.
258
258
  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.
259
- filter_by_prefix: true, # Boolean | Only download translation keys containing the specified prefix, and remove the prefix from the generated file.
259
+ filter_by_prefix: true, # Boolean | Only download translation keys containing the prefix specified by `translation_key_prefix`, and remove that prefix from the generated file. Requires `translation_key_prefix` to be set.
260
260
  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.
261
261
  locale_ids: ['inner_example'], # Array<String> | Locale IDs or locale names
262
262
  updated_since: '2023-01-01T00:00:00Z' # String | Only include translations and keys that have been updated since the given date. The date must be in ISO 8601 format (e.g., `2023-01-01T00:00:00Z`).
@@ -300,7 +300,7 @@ Name | Type | Description | Notes
300
300
  **fallback_for_unverified_translations** | **Boolean**| If set to &#x60;true&#x60;, translations in a non-final state are replaced by the fallback locale&#39;s translation at export time. In the simple workflow, \&quot;non-final\&quot; means &#x60;unverified&#x60;. In the review workflow, it additionally includes &#x60;translated&#x60; (awaiting review). No stored translations are modified. Requires &#x60;fallback_locale_id&#x60; or &#x60;use_locale_fallback&#x60; to be set; a &#x60;422&#x60; validation error is returned otherwise. | [optional]
301
301
  **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 &#x60;tag&#x60; parameter indicating a specific job. | [optional]
302
302
  **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]
303
- **filter_by_prefix** | **Boolean**| Only download translation keys containing the specified prefix, and remove the prefix from the generated file. | [optional]
303
+ **filter_by_prefix** | **Boolean**| Only download translation keys containing the prefix specified by &#x60;translation_key_prefix&#x60;, and remove that prefix from the generated file. Requires &#x60;translation_key_prefix&#x60; to be set. | [optional]
304
304
  **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]
305
305
  **locale_ids** | [**Array&lt;String&gt;**](String.md)| Locale IDs or locale names | [optional]
306
306
  **updated_since** | **String**| Only include translations and keys that have been updated since the given date. The date must be in ISO 8601 format (e.g., &#x60;2023-01-01T00:00:00Z&#x60;). | [optional]
@@ -47,7 +47,7 @@ instance = Phrase::ProjectCreateParameters.new(name: My Android Project,
47
47
  main_format: yml,
48
48
  media: Python,
49
49
  shares_translation_memory: true,
50
- project_image: [B@592bc6a7,
50
+ project_image: [B@1e92420f,
51
51
  remove_project_image: null,
52
52
  account_id: abcd1234,
53
53
  point_of_contact: abcd1234,
@@ -48,7 +48,7 @@ instance = Phrase::ProjectUpdateParameters.new(account_id: abcd1234,
48
48
  main_format: yml,
49
49
  media: Python,
50
50
  shares_translation_memory: true,
51
- project_image: [B@519552ae,
51
+ project_image: [B@32dca84b,
52
52
  remove_project_image: false,
53
53
  workflow: review,
54
54
  machine_translation_enabled: true,
data/docs/RepoSync.md CHANGED
@@ -5,6 +5,7 @@
5
5
  Name | Type | Description | Notes
6
6
  ------------ | ------------- | ------------- | -------------
7
7
  **id** | **String** | | [optional]
8
+ **name** | **String** | Optional custom display name for this repo sync. When null or blank, the sync is displayed using the associated project name. | [optional]
8
9
  **project** | [**ProjectShort**](ProjectShort.md) | | [optional]
9
10
  **provider** | **String** | | [optional]
10
11
  **enabled** | **Boolean** | | [optional]
@@ -21,6 +22,7 @@ Name | Type | Description | Notes
21
22
  require 'Phrase'
22
23
 
23
24
  instance = Phrase::RepoSync.new(id: null,
25
+ name: null,
24
26
  project: null,
25
27
  provider: null,
26
28
  enabled: null,
@@ -5,6 +5,7 @@
5
5
  Name | Type | Description | Notes
6
6
  ------------ | ------------- | ------------- | -------------
7
7
  **project_id** | **String** | ID of the project to connect the Repo Sync to. |
8
+ **name** | **String** | Optional custom display name for this repo sync. Defaults to null; when null the project name is used as the display name. | [optional]
8
9
  **git_provider** | **String** | The Git provider to use. | [optional] [default to &#39;github&#39;]
9
10
  **connection_type** | **String** | The authentication method used to connect to the Git provider. Defaults to &#x60;token&#x60; if not specified. Valid values: - &#x60;token&#x60; — Personal access token stored on the Repo Sync. Supported by all providers. - &#x60;github_app&#x60; — Authenticate via the Phrase GitHub App installation on your account. GitHub only. The account must already have the GitHub App installed; if not, the response will include a &#x60;github_app_installation_url&#x60;. - &#x60;self_hosted&#x60; — Token-based auth for self-hosted Git instances. Requires &#x60;custom_api_endpoint&#x60;. |
10
11
  **repo_name** | **String** | Full repository name including the owner, e.g. &#x60;my-org/my-repo&#x60;. |
@@ -20,6 +21,7 @@ Name | Type | Description | Notes
20
21
  require 'Phrase'
21
22
 
22
23
  instance = Phrase::RepoSyncCreateParameters.new(project_id: abcd1234abcd1234abcd1234abcd1234,
24
+ name: null,
23
25
  git_provider: github,
24
26
  connection_type: github_app,
25
27
  repo_name: my-org/my-repo,
@@ -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@5a2cb8e5)
20
+ filename: [B@329ba591)
21
21
  ```
22
22
 
23
23
 
@@ -14,11 +14,11 @@ Method | HTTP request | Description
14
14
 
15
15
  ## screenshot_create
16
16
 
17
- > Screenshot screenshot_create(project_id, opts)
17
+ > Screenshot screenshot_create(project_id, filename, opts)
18
18
 
19
19
  Create a screenshot
20
20
 
21
- Create a new screenshot.
21
+ Creates a screenshot in a project to provide visual context for in-context translation. Attach translation keys to regions of the uploaded image so translators can see where each string appears in your UI. This endpoint accepts a multipart/form-data request with a binary file upload, unlike most Phrase API endpoints that use JSON. Use a multipart form client or the -F flag in curl rather than a JSON body. The screenshot name must be unique within the project (case-insensitive). When name is omitted, it is derived from the uploaded filename. The account must have the Screenshots feature enabled; requests to projects on accounts without it return 403. Creating a screenshot requires a token with the write scope and manage access to the project.
22
22
 
23
23
  ### Example
24
24
 
@@ -38,17 +38,17 @@ end
38
38
 
39
39
  api_instance = Phrase::ScreenshotsApi.new
40
40
  project_id = 'project_id_example' # String | Project ID
41
+ filename = File.new('/path/to/some/file') # File | Image file to upload. Accepted formats are JPEG (jpg/jpeg), GIF, and PNG. Maximum file size is 10 MB. Submitting an unsupported format or a file exceeding the size limit returns 422.
41
42
  opts = {
42
43
  x_phrase_app_otp: 'x_phrase_app_otp_example', # String | Two-Factor-Authentication token (optional)
43
44
  branch: 'branch_example', # String | specify the branch to use
44
- name: 'name_example', # String | Name of the screenshot
45
- description: 'description_example', # String | Description of the screenshot
46
- filename: File.new('/path/to/some/file') # File | Screenshot file
45
+ name: 'name_example', # String | Display name for the screenshot. Must be unique within the project (case-insensitive). When omitted, the name is derived from the uploaded filename.
46
+ description: 'description_example' # String | Optional free-text description of the screenshot.
47
47
  }
48
48
 
49
49
  begin
50
50
  #Create a screenshot
51
- result = api_instance.screenshot_create(project_id, opts)
51
+ result = api_instance.screenshot_create(project_id, filename, opts)
52
52
  pp result
53
53
  rescue Phrase::ApiError => e
54
54
  puts "Exception when calling ScreenshotsApi->screenshot_create: #{e}"
@@ -61,11 +61,11 @@ end
61
61
  Name | Type | Description | Notes
62
62
  ------------- | ------------- | ------------- | -------------
63
63
  **project_id** | **String**| Project ID |
64
+ **filename** | **File**| Image file to upload. Accepted formats are JPEG (jpg/jpeg), GIF, and PNG. Maximum file size is 10 MB. Submitting an unsupported format or a file exceeding the size limit returns 422. |
64
65
  **x_phrase_app_otp** | **String**| Two-Factor-Authentication token (optional) | [optional]
65
66
  **branch** | **String**| specify the branch to use | [optional]
66
- **name** | **String**| Name of the screenshot | [optional]
67
- **description** | **String**| Description of the screenshot | [optional]
68
- **filename** | **File**| Screenshot file | [optional]
67
+ **name** | **String**| Display name for the screenshot. Must be unique within the project (case-insensitive). When omitted, the name is derived from the uploaded filename. | [optional]
68
+ **description** | **String**| Optional free-text description of the screenshot. | [optional]
69
69
 
70
70
  ### Return type
71
71
 
@@ -13,7 +13,7 @@ module Phrase
13
13
  # @param name [String] name
14
14
  # @param [Hash] opts the optional parameters
15
15
  # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
16
- # @return [nil]
16
+ # @return [BranchComparison]
17
17
  def branch_compare(project_id, name, opts = {})
18
18
  data, _status_code, _headers = branch_compare_with_http_info(project_id, name, opts)
19
19
  data
@@ -25,7 +25,7 @@ module Phrase
25
25
  # @param name [String] name
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, Integer, Hash)>] Response<(nil, response status code and response headers
28
+ # @return [Array<(Response<(BranchComparison)>, Integer, Hash)>] Response<(BranchComparison)> data, response status code and response headers
29
29
  def branch_compare_with_http_info(project_id, name, opts = {})
30
30
  if @api_client.config.debugging
31
31
  @api_client.config.logger.debug 'Calling API: BranchesApi.branch_compare ...'
@@ -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
  header_params[:'X-PhraseApp-OTP'] = opts[:'x_phrase_app_otp'] if !opts[:'x_phrase_app_otp'].nil?
50
52
 
51
53
  # form parameters
@@ -55,7 +57,7 @@ module Phrase
55
57
  post_body = opts[:body]
56
58
 
57
59
  # return_type
58
- return_type = opts[:return_type]
60
+ return_type = opts[:return_type] || 'BranchComparison'
59
61
 
60
62
  # auth_names
61
63
  auth_names = opts[:auth_names] || ['Basic', 'Token']
@@ -8,7 +8,7 @@ module Phrase
8
8
  @api_client = api_client
9
9
  end
10
10
  # List formats
11
- # Get a handy list of all localization file formats supported in Phrase.
11
+ # Returns all file formats that Phrase Strings supports. Use the api_name value from each format as the file_format parameter when uploading or downloading locale files. Not every format supports both directions: check the importable and exportable fields before using a format in a workflow. This endpoint does not require authentication and is not subject to rate limiting.
12
12
  # @param [Hash] opts the optional parameters
13
13
  # @return [Array<Format>]
14
14
  def formats_list(opts = {})
@@ -17,7 +17,7 @@ module Phrase
17
17
  end
18
18
 
19
19
  # List formats
20
- # Get a handy list of all localization file formats supported in Phrase.
20
+ # Returns all file formats that Phrase Strings supports. Use the api_name value from each format as the file_format parameter when uploading or downloading locale files. Not every format supports both directions: check the importable and exportable fields before using a format in a workflow. This endpoint does not require authentication and is not subject to rate limiting.
21
21
  # @param [Hash] opts the optional parameters
22
22
  # @return [Array<(Response<(Array<Format>)>, Integer, Hash)>] Response<(Array<Format>)> data, response status code and response headers
23
23
  def formats_list_with_http_info(opts = {})
@@ -255,7 +255,7 @@ module Phrase
255
255
  # @option opts [Boolean] :fallback_for_unverified_translations If set to &#x60;true&#x60;, translations in a non-final state are replaced by the fallback locale&#39;s translation at export time. In the simple workflow, \&quot;non-final\&quot; means &#x60;unverified&#x60;. In the review workflow, it additionally includes &#x60;translated&#x60; (awaiting review). No stored translations are modified. Requires &#x60;fallback_locale_id&#x60; or &#x60;use_locale_fallback&#x60; to be set; a &#x60;422&#x60; validation error is returned otherwise.
256
256
  # @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 &#x60;tag&#x60; parameter indicating a specific job.
257
257
  # @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.
258
- # @option opts [Boolean] :filter_by_prefix Only download translation keys containing the specified prefix, and remove the prefix from the generated file.
258
+ # @option opts [Boolean] :filter_by_prefix Only download translation keys containing the prefix specified by &#x60;translation_key_prefix&#x60;, and remove that prefix from the generated file. Requires &#x60;translation_key_prefix&#x60; to be set.
259
259
  # @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.
260
260
  # @option opts [Array<String>] :locale_ids Locale IDs or locale names
261
261
  # @option opts [String] :updated_since Only include translations and keys that have been updated since the given date. The date must be in ISO 8601 format (e.g., &#x60;2023-01-01T00:00:00Z&#x60;).
@@ -292,7 +292,7 @@ module Phrase
292
292
  # @option opts [Boolean] :fallback_for_unverified_translations If set to &#x60;true&#x60;, translations in a non-final state are replaced by the fallback locale&#39;s translation at export time. In the simple workflow, \&quot;non-final\&quot; means &#x60;unverified&#x60;. In the review workflow, it additionally includes &#x60;translated&#x60; (awaiting review). No stored translations are modified. Requires &#x60;fallback_locale_id&#x60; or &#x60;use_locale_fallback&#x60; to be set; a &#x60;422&#x60; validation error is returned otherwise.
293
293
  # @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 &#x60;tag&#x60; parameter indicating a specific job.
294
294
  # @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.
295
- # @option opts [Boolean] :filter_by_prefix Only download translation keys containing the specified prefix, and remove the prefix from the generated file.
295
+ # @option opts [Boolean] :filter_by_prefix Only download translation keys containing the prefix specified by &#x60;translation_key_prefix&#x60;, and remove that prefix from the generated file. Requires &#x60;translation_key_prefix&#x60; to be set.
296
296
  # @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.
297
297
  # @option opts [Array<String>] :locale_ids Locale IDs or locale names
298
298
  # @option opts [String] :updated_since Only include translations and keys that have been updated since the given date. The date must be in ISO 8601 format (e.g., &#x60;2023-01-01T00:00:00Z&#x60;).