phrase 1.0.14 → 2.3.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.
- checksums.yaml +4 -4
- data/README.md +48 -9
- data/docs/Account.md +3 -1
- data/docs/AccountDetails.md +5 -1
- data/docs/AccountDetails1.md +3 -1
- data/docs/AccountSearchResult.md +29 -0
- data/docs/Branch.md +5 -1
- data/docs/Comment.md +3 -1
- data/docs/CurrentUser.md +31 -0
- data/docs/JobCreateParameters.md +2 -0
- data/docs/JobDetails.md +2 -0
- data/docs/JobDetails1.md +2 -0
- data/docs/JobLocale.md +5 -1
- data/docs/JobTemplate.md +29 -0
- data/docs/JobTemplateCreateParameters.md +21 -0
- data/docs/JobTemplateLocale.md +23 -0
- data/docs/JobTemplateLocaleUpdateParameters.md +23 -0
- data/docs/JobTemplateLocalesApi.md +347 -0
- data/docs/JobTemplateLocalesCreateParameters.md +23 -0
- data/docs/JobTemplatePreview.md +19 -0
- data/docs/JobTemplateUpdateParameters.md +21 -0
- data/docs/JobTemplateUserPreview.md +23 -0
- data/docs/JobTemplatesApi.md +337 -0
- data/docs/KeysApi.md +137 -9
- data/docs/KeysExcludeParameters.md +23 -0
- data/docs/KeysIncludeParameters.md +23 -0
- data/docs/KeysSearchParameters.md +1 -1
- data/docs/KeysTagParameters.md +1 -1
- data/docs/KeysUntagParameters.md +1 -1
- data/docs/LocalePreview1.md +23 -0
- data/docs/LocalesApi.md +78 -7
- data/docs/MemberSpaces.md +2 -2
- data/docs/MemberUpdateParameters.md +4 -2
- data/docs/Notification.md +41 -0
- data/docs/NotificationGroup.md +23 -0
- data/docs/NotificationGroupDetail.md +27 -0
- data/docs/NotificationGroupsApi.md +194 -0
- data/docs/NotificationsApi.md +194 -0
- data/docs/OrderCreateParameters.md +2 -0
- data/docs/Project.md +2 -0
- data/docs/ProjectCreateParameters.md +35 -1
- data/docs/ProjectDetails.md +2 -0
- data/docs/ProjectsApi.md +7 -1
- data/docs/SearchApi.md +72 -0
- data/docs/SearchInAccountParameters.md +23 -0
- data/docs/Space1.md +25 -0
- data/docs/Subscription.md +19 -0
- data/docs/TranslationOrder.md +2 -0
- data/docs/TranslationsApi.md +25 -25
- data/docs/User.md +0 -2
- data/docs/UsersApi.md +2 -2
- data/lib/phrase.rb +24 -0
- data/lib/phrase/api/job_template_locales_api.rb +417 -0
- data/lib/phrase/api/job_templates_api.rb +387 -0
- data/lib/phrase/api/keys_api.rb +158 -10
- data/lib/phrase/api/locales_api.rb +85 -5
- data/lib/phrase/api/notification_groups_api.rb +202 -0
- data/lib/phrase/api/notifications_api.rb +202 -0
- data/lib/phrase/api/projects_api.rb +9 -0
- data/lib/phrase/api/search_api.rb +84 -0
- data/lib/phrase/api/translations_api.rb +35 -35
- data/lib/phrase/api/users_api.rb +3 -3
- data/lib/phrase/models/account.rb +13 -4
- data/lib/phrase/models/account_details.rb +22 -4
- data/lib/phrase/models/account_details1.rb +10 -1
- data/lib/phrase/models/account_search_result.rb +250 -0
- data/lib/phrase/models/branch.rb +19 -1
- data/lib/phrase/models/comment.rb +15 -4
- data/lib/phrase/models/current_user.rb +257 -0
- data/lib/phrase/models/job_create_parameters.rb +11 -1
- data/lib/phrase/models/job_details.rb +10 -1
- data/lib/phrase/models/job_details1.rb +10 -1
- data/lib/phrase/models/job_locale.rb +22 -4
- data/lib/phrase/models/job_template.rb +248 -0
- data/lib/phrase/models/job_template_create_parameters.rb +220 -0
- data/lib/phrase/models/job_template_locale.rb +223 -0
- data/lib/phrase/models/job_template_locale_update_parameters.rb +234 -0
- data/lib/phrase/models/job_template_locales_create_parameters.rb +234 -0
- data/lib/phrase/models/job_template_preview.rb +203 -0
- data/lib/phrase/models/job_template_update_parameters.rb +220 -0
- data/lib/phrase/models/job_template_user_preview.rb +221 -0
- data/lib/phrase/models/keys_exclude_parameters.rb +225 -0
- data/lib/phrase/models/keys_include_parameters.rb +225 -0
- 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/locale_preview1.rb +221 -0
- data/lib/phrase/models/member_spaces.rb +2 -2
- data/lib/phrase/models/member_update_parameters.rb +12 -2
- data/lib/phrase/models/notification.rb +302 -0
- data/lib/phrase/models/notification_group.rb +221 -0
- data/lib/phrase/models/notification_group_detail.rb +239 -0
- data/lib/phrase/models/order_create_parameters.rb +11 -1
- data/lib/phrase/models/project.rb +10 -1
- data/lib/phrase/models/project_create_parameters.rb +174 -4
- data/lib/phrase/models/project_details.rb +10 -1
- data/lib/phrase/models/search_in_account_parameters.rb +225 -0
- data/lib/phrase/models/space1.rb +230 -0
- data/lib/phrase/models/subscription.rb +203 -0
- data/lib/phrase/models/translation_order.rb +10 -1
- data/lib/phrase/models/user.rb +1 -10
- data/lib/phrase/version.rb +1 -1
- data/spec/api/job_template_locales_api_spec.rb +103 -0
- data/spec/api/job_templates_api_spec.rb +98 -0
- data/spec/api/keys_api_spec.rb +32 -4
- data/spec/api/locales_api_spec.rb +19 -2
- data/spec/api/notification_groups_api_spec.rb +62 -0
- data/spec/api/notifications_api_spec.rb +62 -0
- data/spec/api/projects_api_spec.rb +3 -0
- data/spec/api/search_api_spec.rb +37 -0
- data/spec/api/translations_api_spec.rb +10 -10
- data/spec/api/users_api_spec.rb +1 -1
- data/spec/models/account_details1_spec.rb +6 -0
- data/spec/models/account_details_spec.rb +12 -0
- data/spec/models/account_search_result_spec.rb +65 -0
- data/spec/models/account_spec.rb +6 -0
- data/spec/models/branch_spec.rb +12 -0
- data/spec/models/comment_spec.rb +6 -0
- data/spec/models/current_user_spec.rb +71 -0
- data/spec/models/job_create_parameters_spec.rb +6 -0
- data/spec/models/job_details1_spec.rb +6 -0
- data/spec/models/job_details_spec.rb +6 -0
- data/spec/models/job_locale_spec.rb +12 -0
- data/spec/models/job_template_create_parameters_spec.rb +41 -0
- data/spec/models/job_template_locale_spec.rb +47 -0
- data/spec/models/job_template_locale_update_parameters_spec.rb +47 -0
- data/spec/models/job_template_locales_create_parameters_spec.rb +47 -0
- data/spec/models/job_template_preview_spec.rb +35 -0
- data/spec/models/job_template_spec.rb +65 -0
- data/spec/models/job_template_update_parameters_spec.rb +41 -0
- data/spec/models/job_template_user_preview_spec.rb +47 -0
- data/spec/models/keys_exclude_parameters_spec.rb +47 -0
- data/spec/models/keys_include_parameters_spec.rb +47 -0
- data/spec/models/locale_preview1_spec.rb +47 -0
- data/spec/models/member_update_parameters_spec.rb +6 -0
- data/spec/models/notification_group_detail_spec.rb +59 -0
- data/spec/models/notification_group_spec.rb +47 -0
- data/spec/models/notification_spec.rb +101 -0
- data/spec/models/order_create_parameters_spec.rb +6 -0
- data/spec/models/project_create_parameters_spec.rb +102 -0
- data/spec/models/project_details_spec.rb +6 -0
- data/spec/models/project_spec.rb +6 -0
- data/spec/models/search_in_account_parameters_spec.rb +47 -0
- data/spec/models/space1_spec.rb +53 -0
- data/spec/models/subscription_spec.rb +35 -0
- data/spec/models/translation_order_spec.rb +6 -0
- data/spec/models/user_spec.rb +0 -6
- metadata +263 -167
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Phrase::KeysExcludeParameters
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
Name | Type | Description | Notes
|
|
6
|
+
------------ | ------------- | ------------- | -------------
|
|
7
|
+
**branch** | **String** | specify the branch to use | [optional]
|
|
8
|
+
**q** | **String** | 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 - spaces, commas, and colons need to be escaped with double backslashes</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>. | [optional]
|
|
9
|
+
**target_locale_id** | **String** | Locale used to exlcude or include keys. | [optional]
|
|
10
|
+
**tags** | **String** | Tag or comma-separated list of tags to add to the matching collection of keys | [optional]
|
|
11
|
+
|
|
12
|
+
## Code Sample
|
|
13
|
+
|
|
14
|
+
```ruby
|
|
15
|
+
require 'Phrase'
|
|
16
|
+
|
|
17
|
+
instance = Phrase::KeysExcludeParameters.new(branch: my-feature-branch,
|
|
18
|
+
q: mykey* translated:true,
|
|
19
|
+
target_locale_id: abcd1234abcd1234abcd1234abcd1234,
|
|
20
|
+
tags: landing-page,release-1.2)
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Phrase::KeysIncludeParameters
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
Name | Type | Description | Notes
|
|
6
|
+
------------ | ------------- | ------------- | -------------
|
|
7
|
+
**branch** | **String** | specify the branch to use | [optional]
|
|
8
|
+
**q** | **String** | 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 - spaces, commas, and colons need to be escaped with double backslashes</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>. | [optional]
|
|
9
|
+
**target_locale_id** | **String** | Locale used to exlcude or include keys. | [optional]
|
|
10
|
+
**tags** | **String** | Tag or comma-separated list of tags to add to the matching collection of keys | [optional]
|
|
11
|
+
|
|
12
|
+
## Code Sample
|
|
13
|
+
|
|
14
|
+
```ruby
|
|
15
|
+
require 'Phrase'
|
|
16
|
+
|
|
17
|
+
instance = Phrase::KeysIncludeParameters.new(branch: my-feature-branch,
|
|
18
|
+
q: mykey* translated:true,
|
|
19
|
+
target_locale_id: abcd1234abcd1234abcd1234abcd1234,
|
|
20
|
+
tags: landing-page,release-1.2)
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
|
|
@@ -7,7 +7,7 @@ Name | Type | Description | Notes
|
|
|
7
7
|
**branch** | **String** | specify the branch to use | [optional]
|
|
8
8
|
**sort** | **String** | Sort by field. Can be one of: name, created_at, updated_at. | [optional]
|
|
9
9
|
**order** | **String** | Order direction. Can be one of: asc, desc. | [optional]
|
|
10
|
-
**q** | **String** | 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 -
|
|
10
|
+
**q** | **String** | 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 - spaces, commas, and colons need to be escaped with double backslashes</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>. | [optional]
|
|
11
11
|
**locale_id** | **String** | Locale used to determine the translation state of a key when filtering for untranslated or translated keys. | [optional]
|
|
12
12
|
|
|
13
13
|
## Code Sample
|
data/docs/KeysTagParameters.md
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
Name | Type | Description | Notes
|
|
6
6
|
------------ | ------------- | ------------- | -------------
|
|
7
7
|
**branch** | **String** | specify the branch to use | [optional]
|
|
8
|
-
**q** | **String** | 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 -
|
|
8
|
+
**q** | **String** | 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 - spaces, commas, and colons need to be escaped with double backslashes</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>. | [optional]
|
|
9
9
|
**locale_id** | **String** | Locale used to determine the translation state of a key when filtering for untranslated or translated keys. | [optional]
|
|
10
10
|
**tags** | **String** | Tag or comma-separated list of tags to add to the matching collection of keys | [optional]
|
|
11
11
|
|
data/docs/KeysUntagParameters.md
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
Name | Type | Description | Notes
|
|
6
6
|
------------ | ------------- | ------------- | -------------
|
|
7
7
|
**branch** | **String** | specify the branch to use | [optional]
|
|
8
|
-
**q** | **String** | 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 -
|
|
8
|
+
**q** | **String** | 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 - spaces, commas, and colons need to be escaped with double backslashes</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>. | [optional]
|
|
9
9
|
**locale_id** | **String** | Locale used to determine the translation state of a key when filtering for untranslated or translated keys. | [optional]
|
|
10
10
|
**tags** | **String** | Tag or comma-separated list of tags to remove from the matching collection of keys | [optional]
|
|
11
11
|
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Phrase::LocalePreview1
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
Name | Type | Description | Notes
|
|
6
|
+
------------ | ------------- | ------------- | -------------
|
|
7
|
+
**id** | **String** | | [optional]
|
|
8
|
+
**name** | **String** | | [optional]
|
|
9
|
+
**code** | **String** | | [optional]
|
|
10
|
+
**project** | [**ProjectShort**](ProjectShort.md) | | [optional]
|
|
11
|
+
|
|
12
|
+
## Code Sample
|
|
13
|
+
|
|
14
|
+
```ruby
|
|
15
|
+
require 'Phrase'
|
|
16
|
+
|
|
17
|
+
instance = Phrase::LocalePreview1.new(id: null,
|
|
18
|
+
name: null,
|
|
19
|
+
code: null,
|
|
20
|
+
project: null)
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
|
data/docs/LocalesApi.md
CHANGED
|
@@ -4,6 +4,7 @@ All URIs are relative to *https://api.phrase.com/v2*
|
|
|
4
4
|
|
|
5
5
|
Method | HTTP request | Description
|
|
6
6
|
------------- | ------------- | -------------
|
|
7
|
+
[**account_locales**](LocalesApi.md#account_locales) | **GET** /accounts/{account_id}/locales | List locales used in account
|
|
7
8
|
[**locale_create**](LocalesApi.md#locale_create) | **POST** /projects/{project_id}/locales | Create a locale
|
|
8
9
|
[**locale_delete**](LocalesApi.md#locale_delete) | **DELETE** /projects/{project_id}/locales/{id} | Delete a locale
|
|
9
10
|
[**locale_download**](LocalesApi.md#locale_download) | **GET** /projects/{project_id}/locales/{id}/download | Download a locale
|
|
@@ -13,6 +14,71 @@ Method | HTTP request | Description
|
|
|
13
14
|
|
|
14
15
|
|
|
15
16
|
|
|
17
|
+
## account_locales
|
|
18
|
+
|
|
19
|
+
> Array<LocalePreview1> account_locales(id, opts)
|
|
20
|
+
|
|
21
|
+
List locales used in account
|
|
22
|
+
|
|
23
|
+
List all locales unique by locale code used across all projects within an account.
|
|
24
|
+
|
|
25
|
+
### Example
|
|
26
|
+
|
|
27
|
+
```ruby
|
|
28
|
+
# load the gem
|
|
29
|
+
require 'phrase'
|
|
30
|
+
# setup authorization
|
|
31
|
+
Phrase.configure do |config|
|
|
32
|
+
# Configure HTTP basic authorization: Basic
|
|
33
|
+
config.username = 'YOUR USERNAME'
|
|
34
|
+
config.password = 'YOUR PASSWORD'
|
|
35
|
+
|
|
36
|
+
# Configure API key authorization: Token
|
|
37
|
+
config.api_key['Authorization'] = 'YOUR API KEY'
|
|
38
|
+
config.api_key_prefix['Authorization'] = 'token'
|
|
39
|
+
end
|
|
40
|
+
|
|
41
|
+
api_instance = Phrase::LocalesApi.new
|
|
42
|
+
id = 'id_example' # String | ID
|
|
43
|
+
opts = {
|
|
44
|
+
x_phrase_app_otp: 'x_phrase_app_otp_example', # String | Two-Factor-Authentication token (optional)
|
|
45
|
+
page: 1, # Integer | Page number
|
|
46
|
+
per_page: 25 # Integer | allows you to specify a page size up to 100 items, 25 by default
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
begin
|
|
50
|
+
#List locales used in account
|
|
51
|
+
result = api_instance.account_locales(id, opts)
|
|
52
|
+
pp result
|
|
53
|
+
rescue Phrase::ApiError => e
|
|
54
|
+
puts "Exception when calling LocalesApi->account_locales: #{e}"
|
|
55
|
+
end
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
### Parameters
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
Name | Type | Description | Notes
|
|
62
|
+
------------- | ------------- | ------------- | -------------
|
|
63
|
+
**id** | **String**| ID |
|
|
64
|
+
**x_phrase_app_otp** | **String**| Two-Factor-Authentication token (optional) | [optional]
|
|
65
|
+
**page** | **Integer**| Page number | [optional]
|
|
66
|
+
**per_page** | **Integer**| allows you to specify a page size up to 100 items, 25 by default | [optional]
|
|
67
|
+
|
|
68
|
+
### Return type
|
|
69
|
+
|
|
70
|
+
Response<([**Array<LocalePreview1>**](LocalePreview1.md))>
|
|
71
|
+
|
|
72
|
+
### Authorization
|
|
73
|
+
|
|
74
|
+
[Basic](../README.md#Basic), [Token](../README.md#Token)
|
|
75
|
+
|
|
76
|
+
### HTTP request headers
|
|
77
|
+
|
|
78
|
+
- **Content-Type**: Not defined
|
|
79
|
+
- **Accept**: application/json
|
|
80
|
+
|
|
81
|
+
|
|
16
82
|
## locale_create
|
|
17
83
|
|
|
18
84
|
> LocaleDetails locale_create(project_id, locale_create_parameters, opts)
|
|
@@ -142,7 +208,7 @@ Response<(nil (empty response body))>
|
|
|
142
208
|
|
|
143
209
|
## locale_download
|
|
144
210
|
|
|
145
|
-
> locale_download(project_id, id, opts)
|
|
211
|
+
> File locale_download(project_id, id, opts)
|
|
146
212
|
|
|
147
213
|
Download a locale
|
|
148
214
|
|
|
@@ -170,7 +236,7 @@ id = 'id_example' # String | ID
|
|
|
170
236
|
opts = {
|
|
171
237
|
x_phrase_app_otp: 'x_phrase_app_otp_example', # String | Two-Factor-Authentication token (optional)
|
|
172
238
|
branch: 'my-feature-branch', # String | specify the branch to use
|
|
173
|
-
file_format: 'yml', # String | File format name. See the format guide for all supported file formats.
|
|
239
|
+
file_format: 'yml', # String | File format name. See the <a href=\"https://help.phrase.com/help/supported-platforms-and-formats\">format guide</a> for all supported file formats.
|
|
174
240
|
tags: 'feature1,feature2', # String | Limit results to keys tagged with a list of comma separated tag names.
|
|
175
241
|
tag: 'feature', # String | Limit download to tagged keys. This parameter is deprecated. Please use the \"tags\" parameter instead
|
|
176
242
|
include_empty_translations: true, # Boolean | Indicates whether keys without translations should be included in the output as well.
|
|
@@ -183,12 +249,14 @@ opts = {
|
|
|
183
249
|
skip_unverified_translations: true, # Boolean | Indicates whether the locale file should skip all unverified translations. This parameter is deprecated and should be replaced with <code>include_unverified_translations</code>.
|
|
184
250
|
include_unverified_translations: true, # Boolean | if set to false unverified translations are excluded
|
|
185
251
|
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 (currently in beta) is enabled for the project.
|
|
186
|
-
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 public ID of the locale that should be used as the fallback. Requires include_empty_translations to be set to <code>true</code>.
|
|
252
|
+
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 public ID of the locale that should be used as the fallback. Requires include_empty_translations to be set to <code>true</code>.
|
|
253
|
+
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.
|
|
187
254
|
}
|
|
188
255
|
|
|
189
256
|
begin
|
|
190
257
|
#Download a locale
|
|
191
|
-
api_instance.locale_download(project_id, id, opts)
|
|
258
|
+
result = api_instance.locale_download(project_id, id, opts)
|
|
259
|
+
pp result
|
|
192
260
|
rescue Phrase::ApiError => e
|
|
193
261
|
puts "Exception when calling LocalesApi->locale_download: #{e}"
|
|
194
262
|
end
|
|
@@ -203,7 +271,7 @@ Name | Type | Description | Notes
|
|
|
203
271
|
**id** | **String**| ID |
|
|
204
272
|
**x_phrase_app_otp** | **String**| Two-Factor-Authentication token (optional) | [optional]
|
|
205
273
|
**branch** | **String**| specify the branch to use | [optional]
|
|
206
|
-
**file_format** | **String**| File format name. See the format guide for all supported file formats. | [optional]
|
|
274
|
+
**file_format** | **String**| File format name. See the <a href=\"https://help.phrase.com/help/supported-platforms-and-formats\">format guide</a> for all supported file formats. | [optional]
|
|
207
275
|
**tags** | **String**| Limit results to keys tagged with a list of comma separated tag names. | [optional]
|
|
208
276
|
**tag** | **String**| Limit download to tagged keys. This parameter is deprecated. Please use the \"tags\" parameter instead | [optional]
|
|
209
277
|
**include_empty_translations** | **Boolean**| Indicates whether keys without translations should be included in the output as well. | [optional]
|
|
@@ -217,10 +285,11 @@ Name | Type | Description | Notes
|
|
|
217
285
|
**include_unverified_translations** | **Boolean**| if set to false unverified translations are excluded | [optional]
|
|
218
286
|
**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 (currently in beta) is enabled for the project. | [optional]
|
|
219
287
|
**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 public ID of the locale that should be used as the fallback. Requires include_empty_translations to be set to <code>true</code>. | [optional]
|
|
288
|
+
**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 <code>tag</code> parameter indicating a specific job. | [optional]
|
|
220
289
|
|
|
221
290
|
### Return type
|
|
222
291
|
|
|
223
|
-
Response<(
|
|
292
|
+
Response<(**File**)>
|
|
224
293
|
|
|
225
294
|
### Authorization
|
|
226
295
|
|
|
@@ -229,7 +298,7 @@ Response<(nil (empty response body))>
|
|
|
229
298
|
### HTTP request headers
|
|
230
299
|
|
|
231
300
|
- **Content-Type**: Not defined
|
|
232
|
-
- **Accept**:
|
|
301
|
+
- **Accept**: *
|
|
233
302
|
|
|
234
303
|
|
|
235
304
|
## locale_show
|
|
@@ -392,6 +461,7 @@ opts = {
|
|
|
392
461
|
x_phrase_app_otp: 'x_phrase_app_otp_example', # String | Two-Factor-Authentication token (optional)
|
|
393
462
|
page: 1, # Integer | Page number
|
|
394
463
|
per_page: 25, # Integer | allows you to specify a page size up to 100 items, 25 by default
|
|
464
|
+
sort_by: 'sort_by_example', # String | Sort locales. Valid options are \"name_asc\", \"name_desc\", \"default_asc\", \"default_desc\".
|
|
395
465
|
branch: 'my-feature-branch' # String | specify the branch to use
|
|
396
466
|
}
|
|
397
467
|
|
|
@@ -413,6 +483,7 @@ Name | Type | Description | Notes
|
|
|
413
483
|
**x_phrase_app_otp** | **String**| Two-Factor-Authentication token (optional) | [optional]
|
|
414
484
|
**page** | **Integer**| Page number | [optional]
|
|
415
485
|
**per_page** | **Integer**| allows you to specify a page size up to 100 items, 25 by default | [optional]
|
|
486
|
+
**sort_by** | **String**| Sort locales. Valid options are \"name_asc\", \"name_desc\", \"default_asc\", \"default_desc\". | [optional]
|
|
416
487
|
**branch** | **String**| specify the branch to use | [optional]
|
|
417
488
|
|
|
418
489
|
### Return type
|
data/docs/MemberSpaces.md
CHANGED
|
@@ -6,8 +6,8 @@ Name | Type | Description | Notes
|
|
|
6
6
|
------------ | ------------- | ------------- | -------------
|
|
7
7
|
**id** | **String** | | [optional]
|
|
8
8
|
**name** | **String** | | [optional]
|
|
9
|
-
**created_at** |
|
|
10
|
-
**updated_at** |
|
|
9
|
+
**created_at** | **DateTime** | | [optional]
|
|
10
|
+
**updated_at** | **DateTime** | | [optional]
|
|
11
11
|
**projects_count** | **Integer** | | [optional]
|
|
12
12
|
|
|
13
13
|
## Code Sample
|
|
@@ -4,7 +4,8 @@
|
|
|
4
4
|
|
|
5
5
|
Name | Type | Description | Notes
|
|
6
6
|
------------ | ------------- | ------------- | -------------
|
|
7
|
-
**
|
|
7
|
+
**strategy** | **String** | Update strategy, can be any of set, add, remove. If provided, it will set, add or remove given spaces, projects and locale ids from users access list. | [optional]
|
|
8
|
+
**role** | **String** | Member role, can be any of of Admin, ProjectManager, Developer, Designer, Translator | [optional]
|
|
8
9
|
**project_ids** | **String** | List of project ids the user has access to. | [optional]
|
|
9
10
|
**locale_ids** | **String** | List of locale ids the user has access to. | [optional]
|
|
10
11
|
**default_locale_codes** | **Array<String>** | List of default locales for the user. | [optional]
|
|
@@ -16,7 +17,8 @@ Name | Type | Description | Notes
|
|
|
16
17
|
```ruby
|
|
17
18
|
require 'Phrase'
|
|
18
19
|
|
|
19
|
-
instance = Phrase::MemberUpdateParameters.new(
|
|
20
|
+
instance = Phrase::MemberUpdateParameters.new(strategy: set,
|
|
21
|
+
role: Developer,
|
|
20
22
|
project_ids: abcd1234abcd1234abcd1234,abcd1234abcd1234abcd1235,
|
|
21
23
|
locale_ids: abcd1234abcd1234abcd1234,abcd1234abcd1234abcd1235,
|
|
22
24
|
default_locale_codes: ["en","fi"],
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
# Phrase::Notification
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
Name | Type | Description | Notes
|
|
6
|
+
------------ | ------------- | ------------- | -------------
|
|
7
|
+
**id** | **String** | | [optional]
|
|
8
|
+
**event_name** | **String** | | [optional]
|
|
9
|
+
**created_at** | **DateTime** | | [optional]
|
|
10
|
+
**updated_at** | **DateTime** | | [optional]
|
|
11
|
+
**delivered_at** | **DateTime** | | [optional]
|
|
12
|
+
**seen_at** | **DateTime** | | [optional]
|
|
13
|
+
**data** | [**Object**](.md) | | [optional]
|
|
14
|
+
**resource** | [**Object**](.md) | | [optional]
|
|
15
|
+
**locale** | [**Locale**](Locale.md) | | [optional]
|
|
16
|
+
**user** | [**UserPreview**](UserPreview.md) | | [optional]
|
|
17
|
+
**project** | [**Project**](Project.md) | | [optional]
|
|
18
|
+
**account** | [**Account**](Account.md) | | [optional]
|
|
19
|
+
**group** | [**NotificationGroup**](NotificationGroup.md) | | [optional]
|
|
20
|
+
|
|
21
|
+
## Code Sample
|
|
22
|
+
|
|
23
|
+
```ruby
|
|
24
|
+
require 'Phrase'
|
|
25
|
+
|
|
26
|
+
instance = Phrase::Notification.new(id: null,
|
|
27
|
+
event_name: null,
|
|
28
|
+
created_at: null,
|
|
29
|
+
updated_at: null,
|
|
30
|
+
delivered_at: null,
|
|
31
|
+
seen_at: null,
|
|
32
|
+
data: null,
|
|
33
|
+
resource: null,
|
|
34
|
+
locale: null,
|
|
35
|
+
user: null,
|
|
36
|
+
project: null,
|
|
37
|
+
account: null,
|
|
38
|
+
group: null)
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Phrase::NotificationGroup
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
Name | Type | Description | Notes
|
|
6
|
+
------------ | ------------- | ------------- | -------------
|
|
7
|
+
**id** | **String** | | [optional]
|
|
8
|
+
**event_name** | **String** | | [optional]
|
|
9
|
+
**created_at** | **DateTime** | | [optional]
|
|
10
|
+
**updated_at** | **DateTime** | | [optional]
|
|
11
|
+
|
|
12
|
+
## Code Sample
|
|
13
|
+
|
|
14
|
+
```ruby
|
|
15
|
+
require 'Phrase'
|
|
16
|
+
|
|
17
|
+
instance = Phrase::NotificationGroup.new(id: null,
|
|
18
|
+
event_name: null,
|
|
19
|
+
created_at: null,
|
|
20
|
+
updated_at: null)
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# Phrase::NotificationGroupDetail
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
Name | Type | Description | Notes
|
|
6
|
+
------------ | ------------- | ------------- | -------------
|
|
7
|
+
**id** | **String** | | [optional]
|
|
8
|
+
**event_name** | **String** | | [optional]
|
|
9
|
+
**created_at** | **DateTime** | | [optional]
|
|
10
|
+
**updated_at** | **DateTime** | | [optional]
|
|
11
|
+
**notifications_count** | **Integer** | | [optional]
|
|
12
|
+
**latest_notification** | **Object** | | [optional]
|
|
13
|
+
|
|
14
|
+
## Code Sample
|
|
15
|
+
|
|
16
|
+
```ruby
|
|
17
|
+
require 'Phrase'
|
|
18
|
+
|
|
19
|
+
instance = Phrase::NotificationGroupDetail.new(id: null,
|
|
20
|
+
event_name: null,
|
|
21
|
+
created_at: null,
|
|
22
|
+
updated_at: null,
|
|
23
|
+
notifications_count: null,
|
|
24
|
+
latest_notification: null)
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
|
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
# Phrase::NotificationGroupsApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *https://api.phrase.com/v2*
|
|
4
|
+
|
|
5
|
+
Method | HTTP request | Description
|
|
6
|
+
------------- | ------------- | -------------
|
|
7
|
+
[**notification_groups_list**](NotificationGroupsApi.md#notification_groups_list) | **GET** /notification_groups | List notification groups
|
|
8
|
+
[**notification_groups_mark_all_as_read**](NotificationGroupsApi.md#notification_groups_mark_all_as_read) | **PATCH** /notification_groups/mark_all_as_read | Mark all notification groups as read
|
|
9
|
+
[**notification_groups_mark_as_read**](NotificationGroupsApi.md#notification_groups_mark_as_read) | **PATCH** /notification_groups/{id}/mark_as_read | Mark a notification group as read
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
## notification_groups_list
|
|
14
|
+
|
|
15
|
+
> Array<Object> notification_groups_list(opts)
|
|
16
|
+
|
|
17
|
+
List notification groups
|
|
18
|
+
|
|
19
|
+
List all notification groups from the current user
|
|
20
|
+
|
|
21
|
+
### Example
|
|
22
|
+
|
|
23
|
+
```ruby
|
|
24
|
+
# load the gem
|
|
25
|
+
require 'phrase'
|
|
26
|
+
# setup authorization
|
|
27
|
+
Phrase.configure do |config|
|
|
28
|
+
# Configure HTTP basic authorization: Basic
|
|
29
|
+
config.username = 'YOUR USERNAME'
|
|
30
|
+
config.password = 'YOUR PASSWORD'
|
|
31
|
+
|
|
32
|
+
# Configure API key authorization: Token
|
|
33
|
+
config.api_key['Authorization'] = 'YOUR API KEY'
|
|
34
|
+
config.api_key_prefix['Authorization'] = 'token'
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
api_instance = Phrase::NotificationGroupsApi.new
|
|
38
|
+
opts = {
|
|
39
|
+
x_phrase_app_otp: 'x_phrase_app_otp_example', # String | Two-Factor-Authentication token (optional)
|
|
40
|
+
page: 1, # Integer | Page number
|
|
41
|
+
per_page: 25 # Integer | allows you to specify a page size up to 100 items, 25 by default
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
begin
|
|
45
|
+
#List notification groups
|
|
46
|
+
result = api_instance.notification_groups_list(opts)
|
|
47
|
+
pp result
|
|
48
|
+
rescue Phrase::ApiError => e
|
|
49
|
+
puts "Exception when calling NotificationGroupsApi->notification_groups_list: #{e}"
|
|
50
|
+
end
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
### Parameters
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
Name | Type | Description | Notes
|
|
57
|
+
------------- | ------------- | ------------- | -------------
|
|
58
|
+
**x_phrase_app_otp** | **String**| Two-Factor-Authentication token (optional) | [optional]
|
|
59
|
+
**page** | **Integer**| Page number | [optional]
|
|
60
|
+
**per_page** | **Integer**| allows you to specify a page size up to 100 items, 25 by default | [optional]
|
|
61
|
+
|
|
62
|
+
### Return type
|
|
63
|
+
|
|
64
|
+
Response<(**Array<Object>**)>
|
|
65
|
+
|
|
66
|
+
### Authorization
|
|
67
|
+
|
|
68
|
+
[Basic](../README.md#Basic), [Token](../README.md#Token)
|
|
69
|
+
|
|
70
|
+
### HTTP request headers
|
|
71
|
+
|
|
72
|
+
- **Content-Type**: Not defined
|
|
73
|
+
- **Accept**: application/json
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
## notification_groups_mark_all_as_read
|
|
77
|
+
|
|
78
|
+
> Array<Object> notification_groups_mark_all_as_read(opts)
|
|
79
|
+
|
|
80
|
+
Mark all notification groups as read
|
|
81
|
+
|
|
82
|
+
Mark all notification groups of the current user as read
|
|
83
|
+
|
|
84
|
+
### Example
|
|
85
|
+
|
|
86
|
+
```ruby
|
|
87
|
+
# load the gem
|
|
88
|
+
require 'phrase'
|
|
89
|
+
# setup authorization
|
|
90
|
+
Phrase.configure do |config|
|
|
91
|
+
# Configure HTTP basic authorization: Basic
|
|
92
|
+
config.username = 'YOUR USERNAME'
|
|
93
|
+
config.password = 'YOUR PASSWORD'
|
|
94
|
+
|
|
95
|
+
# Configure API key authorization: Token
|
|
96
|
+
config.api_key['Authorization'] = 'YOUR API KEY'
|
|
97
|
+
config.api_key_prefix['Authorization'] = 'token'
|
|
98
|
+
end
|
|
99
|
+
|
|
100
|
+
api_instance = Phrase::NotificationGroupsApi.new
|
|
101
|
+
opts = {
|
|
102
|
+
x_phrase_app_otp: 'x_phrase_app_otp_example' # String | Two-Factor-Authentication token (optional)
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
begin
|
|
106
|
+
#Mark all notification groups as read
|
|
107
|
+
result = api_instance.notification_groups_mark_all_as_read(opts)
|
|
108
|
+
pp result
|
|
109
|
+
rescue Phrase::ApiError => e
|
|
110
|
+
puts "Exception when calling NotificationGroupsApi->notification_groups_mark_all_as_read: #{e}"
|
|
111
|
+
end
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
### Parameters
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+
Name | Type | Description | Notes
|
|
118
|
+
------------- | ------------- | ------------- | -------------
|
|
119
|
+
**x_phrase_app_otp** | **String**| Two-Factor-Authentication token (optional) | [optional]
|
|
120
|
+
|
|
121
|
+
### Return type
|
|
122
|
+
|
|
123
|
+
Response<(**Array<Object>**)>
|
|
124
|
+
|
|
125
|
+
### Authorization
|
|
126
|
+
|
|
127
|
+
[Basic](../README.md#Basic), [Token](../README.md#Token)
|
|
128
|
+
|
|
129
|
+
### HTTP request headers
|
|
130
|
+
|
|
131
|
+
- **Content-Type**: Not defined
|
|
132
|
+
- **Accept**: application/json
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
## notification_groups_mark_as_read
|
|
136
|
+
|
|
137
|
+
> NotificationGroupDetail notification_groups_mark_as_read(id, opts)
|
|
138
|
+
|
|
139
|
+
Mark a notification group as read
|
|
140
|
+
|
|
141
|
+
Mark a notifications group of the current user as read
|
|
142
|
+
|
|
143
|
+
### Example
|
|
144
|
+
|
|
145
|
+
```ruby
|
|
146
|
+
# load the gem
|
|
147
|
+
require 'phrase'
|
|
148
|
+
# setup authorization
|
|
149
|
+
Phrase.configure do |config|
|
|
150
|
+
# Configure HTTP basic authorization: Basic
|
|
151
|
+
config.username = 'YOUR USERNAME'
|
|
152
|
+
config.password = 'YOUR PASSWORD'
|
|
153
|
+
|
|
154
|
+
# Configure API key authorization: Token
|
|
155
|
+
config.api_key['Authorization'] = 'YOUR API KEY'
|
|
156
|
+
config.api_key_prefix['Authorization'] = 'token'
|
|
157
|
+
end
|
|
158
|
+
|
|
159
|
+
api_instance = Phrase::NotificationGroupsApi.new
|
|
160
|
+
id = 'id_example' # String | ID
|
|
161
|
+
opts = {
|
|
162
|
+
x_phrase_app_otp: 'x_phrase_app_otp_example' # String | Two-Factor-Authentication token (optional)
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
begin
|
|
166
|
+
#Mark a notification group as read
|
|
167
|
+
result = api_instance.notification_groups_mark_as_read(id, opts)
|
|
168
|
+
pp result
|
|
169
|
+
rescue Phrase::ApiError => e
|
|
170
|
+
puts "Exception when calling NotificationGroupsApi->notification_groups_mark_as_read: #{e}"
|
|
171
|
+
end
|
|
172
|
+
```
|
|
173
|
+
|
|
174
|
+
### Parameters
|
|
175
|
+
|
|
176
|
+
|
|
177
|
+
Name | Type | Description | Notes
|
|
178
|
+
------------- | ------------- | ------------- | -------------
|
|
179
|
+
**id** | **String**| ID |
|
|
180
|
+
**x_phrase_app_otp** | **String**| Two-Factor-Authentication token (optional) | [optional]
|
|
181
|
+
|
|
182
|
+
### Return type
|
|
183
|
+
|
|
184
|
+
Response<([**NotificationGroupDetail**](NotificationGroupDetail.md))>
|
|
185
|
+
|
|
186
|
+
### Authorization
|
|
187
|
+
|
|
188
|
+
[Basic](../README.md#Basic), [Token](../README.md#Token)
|
|
189
|
+
|
|
190
|
+
### HTTP request headers
|
|
191
|
+
|
|
192
|
+
- **Content-Type**: Not defined
|
|
193
|
+
- **Accept**: application/json
|
|
194
|
+
|