crowdin-api 1.14.0 → 1.15.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/.rubocop.yml +4 -0
- data/.rubocop_todo.yml +1 -0
- data/AGENTS.md +63 -0
- data/CLAUDE.md +1 -0
- data/Gemfile.lock +1 -1
- data/README.md +1 -1
- data/lib/crowdin-api/api_resources/advisor.rb +86 -0
- data/lib/crowdin-api/api_resources/ai.rb +974 -0
- data/lib/crowdin-api/api_resources/applications.rb +247 -10
- data/lib/crowdin-api/api_resources/bundles.rb +45 -29
- data/lib/crowdin-api/api_resources/clients.rb +23 -0
- data/lib/crowdin-api/api_resources/custom_spellcheckers.rb +36 -0
- data/lib/crowdin-api/api_resources/dictionaries.rb +5 -5
- data/lib/crowdin-api/api_resources/distributions.rb +15 -15
- data/lib/crowdin-api/api_resources/external_qa_checks.rb +36 -0
- data/lib/crowdin-api/api_resources/fields.rb +78 -0
- data/lib/crowdin-api/api_resources/glossaries.rb +62 -50
- data/lib/crowdin-api/api_resources/integrations.rb +201 -0
- data/lib/crowdin-api/api_resources/labels.rb +32 -0
- data/lib/crowdin-api/api_resources/languages.rb +16 -0
- data/lib/crowdin-api/api_resources/machine_translation_engines.rb +17 -0
- data/lib/crowdin-api/api_resources/notifications.rb +15 -6
- data/lib/crowdin-api/api_resources/organization.rb +33 -0
- data/lib/crowdin-api/api_resources/organization_webhooks.rb +71 -0
- data/lib/crowdin-api/api_resources/placeholders.rb +182 -0
- data/lib/crowdin-api/api_resources/projects.rb +137 -41
- data/lib/crowdin-api/api_resources/reports.rb +310 -26
- data/lib/crowdin-api/api_resources/screenshots.rb +48 -0
- data/lib/crowdin-api/api_resources/security_logs.rb +63 -0
- data/lib/crowdin-api/api_resources/source_files.rb +370 -65
- data/lib/crowdin-api/api_resources/source_strings.rb +62 -0
- data/lib/crowdin-api/api_resources/storages.rb +11 -11
- data/lib/crowdin-api/api_resources/string_comments.rb +46 -0
- data/lib/crowdin-api/api_resources/string_corrections.rb +21 -6
- data/lib/crowdin-api/api_resources/string_translations.rb +96 -0
- data/lib/crowdin-api/api_resources/style_guides.rb +71 -0
- data/lib/crowdin-api/api_resources/tasks.rb +140 -10
- data/lib/crowdin-api/api_resources/teams.rb +99 -0
- data/lib/crowdin-api/api_resources/translation_memory.rb +138 -0
- data/lib/crowdin-api/api_resources/translation_status.rb +65 -0
- data/lib/crowdin-api/api_resources/translations.rb +122 -2
- data/lib/crowdin-api/api_resources/users.rb +136 -6
- data/lib/crowdin-api/api_resources/vendors.rb +2 -0
- data/lib/crowdin-api/api_resources/webhooks.rb +16 -0
- data/lib/crowdin-api/api_resources/workflows.rb +24 -0
- data/lib/crowdin-api/client/version.rb +1 -1
- data/lib/crowdin-api/core/request.rb +1 -1
- data/lib/crowdin-api.rb +3 -1
- data/spec/api_resources/advisor_spec.rb +45 -0
- data/spec/api_resources/ai_spec.rb +863 -0
- data/spec/api_resources/applications_spec.rb +138 -0
- data/spec/api_resources/bundles_spec.rb +8 -0
- data/spec/api_resources/clients_spec.rb +13 -0
- data/spec/api_resources/custom_spellcheckers_spec.rb +21 -0
- data/spec/api_resources/external_qa_checks_spec.rb +21 -0
- data/spec/api_resources/fields_spec.rb +45 -0
- data/spec/api_resources/glossaries_spec.rb +18 -0
- data/spec/api_resources/integrations_spec.rb +117 -0
- data/spec/api_resources/organization_spec.rb +21 -0
- data/spec/api_resources/organization_webhooks_spec.rb +45 -0
- data/spec/api_resources/placeholders_spec.rb +103 -0
- data/spec/api_resources/projects_spec.rb +58 -0
- data/spec/api_resources/reports_spec.rb +221 -0
- data/spec/api_resources/security_logs_spec.rb +39 -0
- data/spec/api_resources/source_files_spec.rb +182 -0
- data/spec/api_resources/source_strings_spec.rb +26 -0
- data/spec/api_resources/string_comments_spec.rb +18 -0
- data/spec/api_resources/string_corrections_spec.rb +25 -19
- data/spec/api_resources/string_translations_spec.rb +26 -0
- data/spec/api_resources/style_guides_spec.rb +45 -0
- data/spec/api_resources/tasks_spec.rb +60 -0
- data/spec/api_resources/teams_spec.rb +42 -0
- data/spec/api_resources/translation_memory_spec.rb +58 -0
- data/spec/api_resources/translation_status_spec.rb +26 -0
- data/spec/api_resources/translations_spec.rb +42 -0
- data/spec/api_resources/users_spec.rb +84 -0
- data/spec/api_resources/workflows_spec.rb +10 -0
- metadata +27 -1
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Crowdin
|
|
4
|
+
module ApiResources
|
|
5
|
+
module Fields
|
|
6
|
+
# -- For Enterprise mode only --
|
|
7
|
+
|
|
8
|
+
# @param query [Hash] Request Query Parameters
|
|
9
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.fields.getMany Enterprise API Documentation}
|
|
10
|
+
def list_fields(query = {})
|
|
11
|
+
enterprise_mode? || raise_only_for_enterprise_mode_error
|
|
12
|
+
|
|
13
|
+
request = Web::Request.new(
|
|
14
|
+
connection,
|
|
15
|
+
:get,
|
|
16
|
+
"#{config.target_api_url}/fields",
|
|
17
|
+
{ params: query }
|
|
18
|
+
)
|
|
19
|
+
Web::SendRequest.new(request).perform
|
|
20
|
+
end
|
|
21
|
+
|
|
22
|
+
# @param body [Hash] Request Body
|
|
23
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.fields.post Enterprise API Documentation}
|
|
24
|
+
def add_field(body = {})
|
|
25
|
+
enterprise_mode? || raise_only_for_enterprise_mode_error
|
|
26
|
+
|
|
27
|
+
request = Web::Request.new(
|
|
28
|
+
connection,
|
|
29
|
+
:post,
|
|
30
|
+
"#{config.target_api_url}/fields",
|
|
31
|
+
{ params: body }
|
|
32
|
+
)
|
|
33
|
+
Web::SendRequest.new(request).perform
|
|
34
|
+
end
|
|
35
|
+
|
|
36
|
+
# @param field_id [Integer] Field Identifier
|
|
37
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.fields.delete Enterprise API Documentation}
|
|
38
|
+
def delete_field(field_id)
|
|
39
|
+
enterprise_mode? || raise_only_for_enterprise_mode_error
|
|
40
|
+
|
|
41
|
+
request = Web::Request.new(
|
|
42
|
+
connection,
|
|
43
|
+
:delete,
|
|
44
|
+
"#{config.target_api_url}/fields/#{field_id}"
|
|
45
|
+
)
|
|
46
|
+
Web::SendRequest.new(request).perform
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
# @param field_id [Integer] Field Identifier
|
|
50
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.fields.get Enterprise API Documentation}
|
|
51
|
+
def get_field(field_id)
|
|
52
|
+
enterprise_mode? || raise_only_for_enterprise_mode_error
|
|
53
|
+
|
|
54
|
+
request = Web::Request.new(
|
|
55
|
+
connection,
|
|
56
|
+
:get,
|
|
57
|
+
"#{config.target_api_url}/fields/#{field_id}"
|
|
58
|
+
)
|
|
59
|
+
Web::SendRequest.new(request).perform
|
|
60
|
+
end
|
|
61
|
+
|
|
62
|
+
# @param field_id [Integer] Field Identifier
|
|
63
|
+
# @param body [Array] Request Body
|
|
64
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.fields.patch Enterprise API Documentation}
|
|
65
|
+
def edit_field(field_id, body = [])
|
|
66
|
+
enterprise_mode? || raise_only_for_enterprise_mode_error
|
|
67
|
+
|
|
68
|
+
request = Web::Request.new(
|
|
69
|
+
connection,
|
|
70
|
+
:patch,
|
|
71
|
+
"#{config.target_api_url}/fields/#{field_id}",
|
|
72
|
+
{ params: body }
|
|
73
|
+
)
|
|
74
|
+
Web::SendRequest.new(request).perform
|
|
75
|
+
end
|
|
76
|
+
end
|
|
77
|
+
end
|
|
78
|
+
end
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
module Crowdin
|
|
4
4
|
module ApiResources
|
|
5
5
|
module Glossaries
|
|
6
|
-
# @param query [Hash] Request
|
|
7
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
8
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
6
|
+
# @param query [Hash] Request Query Parameters
|
|
7
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.getMany API Documentation}
|
|
8
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.getMany Enterprise API Documentation}
|
|
9
9
|
def list_glossaries(query = {})
|
|
10
10
|
request = Web::Request.new(
|
|
11
11
|
connection,
|
|
@@ -17,8 +17,8 @@ module Crowdin
|
|
|
17
17
|
end
|
|
18
18
|
|
|
19
19
|
# @param query [Hash] Request Body
|
|
20
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
21
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
20
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.post API Documentation}
|
|
21
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.post Enterprise API Documentation}
|
|
22
22
|
def add_glossary(query = {})
|
|
23
23
|
request = Web::Request.new(
|
|
24
24
|
connection,
|
|
@@ -30,9 +30,9 @@ module Crowdin
|
|
|
30
30
|
end
|
|
31
31
|
|
|
32
32
|
# @param glossary_id [Integer] Glossary Identifier
|
|
33
|
-
# @param query [Hash] Request
|
|
34
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
35
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
33
|
+
# @param query [Hash] Request Query Parameters
|
|
34
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.get API Documentation}
|
|
35
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.get Enterprise API Documentation}
|
|
36
36
|
def get_glossary(glossary_id = nil, query = {})
|
|
37
37
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
38
38
|
|
|
@@ -46,8 +46,8 @@ module Crowdin
|
|
|
46
46
|
end
|
|
47
47
|
|
|
48
48
|
# @param glossary_id [Integer] Glossary Identifier
|
|
49
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
50
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
49
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.delete API Documentation}
|
|
50
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.delete Enterprise API Documentation}
|
|
51
51
|
def delete_glossary(glossary_id = nil)
|
|
52
52
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
53
53
|
|
|
@@ -61,8 +61,8 @@ module Crowdin
|
|
|
61
61
|
|
|
62
62
|
# @param glossary_id [Integer] Glossary Identifier
|
|
63
63
|
# @param query [Hash] Request Body
|
|
64
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
65
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
64
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.patch API Documentation}
|
|
65
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.patch Enterprise API Documentation}
|
|
66
66
|
def edit_glossary(glossary_id = nil, query = {})
|
|
67
67
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
68
68
|
|
|
@@ -77,9 +77,9 @@ module Crowdin
|
|
|
77
77
|
|
|
78
78
|
# @param query [Hash] Request Body
|
|
79
79
|
# @param glossary_id [Integer] Glossary Identifier
|
|
80
|
-
# @param destination [String] File
|
|
81
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
82
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
80
|
+
# @param destination [String] Destination of File
|
|
81
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.exports.post API Documentation}
|
|
82
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.exports.post Enterprise API Documentation}
|
|
83
83
|
def export_glossary(query = {}, glossary_id = nil, destination = nil)
|
|
84
84
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
85
85
|
|
|
@@ -94,8 +94,8 @@ module Crowdin
|
|
|
94
94
|
|
|
95
95
|
# @param glossary_id [Integer] Glossary Identifier
|
|
96
96
|
# @param export_id [String] Export Identifier, consists of 36 characters
|
|
97
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
98
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
97
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.exports.get API Documentation}
|
|
98
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.exports.get Enterprise API Documentation}
|
|
99
99
|
def check_glossary_export_status(glossary_id = nil, export_id = nil)
|
|
100
100
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
101
101
|
export_id || raise_parameter_is_required_error(:export_id)
|
|
@@ -110,9 +110,9 @@ module Crowdin
|
|
|
110
110
|
|
|
111
111
|
# @param glossary_id [Integer] Glossary Identifier
|
|
112
112
|
# @param export_id [String] Export Identifier, consists of 36 characters
|
|
113
|
-
# @param destination [String] File
|
|
114
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
115
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
113
|
+
# @param destination [String] Destination of File
|
|
114
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.exports.download.download API Documentation}
|
|
115
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.exports.download.download Enterprise API Documentation}
|
|
116
116
|
def download_glossary(glossary_id = nil, export_id = nil, destination = nil)
|
|
117
117
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
118
118
|
export_id || raise_parameter_is_required_error(:export_id)
|
|
@@ -127,8 +127,8 @@ module Crowdin
|
|
|
127
127
|
|
|
128
128
|
# @param glossary_id [Integer] Glossary Identifier
|
|
129
129
|
# @param query [Hash] Request Body
|
|
130
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
131
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
130
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.imports.post API Documentation}
|
|
131
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.imports.post Enterprise API Documentation}
|
|
132
132
|
def import_glossary(glossary_id = nil, query = {})
|
|
133
133
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
134
134
|
|
|
@@ -143,8 +143,8 @@ module Crowdin
|
|
|
143
143
|
|
|
144
144
|
# @param glossary_id [Integer] Glossary Identifier
|
|
145
145
|
# @param import_id [String] Import Identifier, consists of 36 characters
|
|
146
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
147
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
146
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.imports.get API Documentation}
|
|
147
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.imports.get Enterprise API Documentation}
|
|
148
148
|
def check_glossary_import_status(glossary_id = nil, import_id = nil)
|
|
149
149
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
150
150
|
import_id || raise_parameter_is_required_error(:import_id)
|
|
@@ -158,9 +158,9 @@ module Crowdin
|
|
|
158
158
|
end
|
|
159
159
|
|
|
160
160
|
# @param glossary_id [Integer] Glossary Identifier
|
|
161
|
-
# @param query [Hash] Request
|
|
162
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
163
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
161
|
+
# @param query [Hash] Request Query Parameters
|
|
162
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.terms.getMany API Documentation}
|
|
163
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.terms.getMany Enterprise API Documentation}
|
|
164
164
|
def list_terms(glossary_id = nil, query = {})
|
|
165
165
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
166
166
|
|
|
@@ -175,8 +175,8 @@ module Crowdin
|
|
|
175
175
|
|
|
176
176
|
# @param glossary_id [Integer] Glossary Identifier
|
|
177
177
|
# @param query [Hash] Request Body
|
|
178
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
179
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
178
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.terms.post API Documentation}
|
|
179
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.terms.post Enterprise API Documentation}
|
|
180
180
|
def add_term(glossary_id = nil, query = {})
|
|
181
181
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
182
182
|
|
|
@@ -190,9 +190,9 @@ module Crowdin
|
|
|
190
190
|
end
|
|
191
191
|
|
|
192
192
|
# @param glossary_id [Integer] Glossary Identifier
|
|
193
|
-
# @param query [Hash] Request
|
|
194
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
195
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
193
|
+
# @param query [Hash] Request Query Parameters
|
|
194
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.terms.deleteMany API Documentation}
|
|
195
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.terms.deleteMany Enterprise API Documentation}
|
|
196
196
|
def clear_glossary(glossary_id = nil, query = {})
|
|
197
197
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
198
198
|
|
|
@@ -211,8 +211,8 @@ module Crowdin
|
|
|
211
211
|
|
|
212
212
|
# @param glossary_id [Integer] Glossary Identifier
|
|
213
213
|
# @param term_id [Integer] Term Identifier
|
|
214
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
215
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
214
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.terms.get API Documentation}
|
|
215
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.terms.get Enterprise API Documentation}
|
|
216
216
|
def get_term(glossary_id = nil, term_id = nil)
|
|
217
217
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
218
218
|
term_id || raise_parameter_is_required_error(:term_id)
|
|
@@ -227,8 +227,8 @@ module Crowdin
|
|
|
227
227
|
|
|
228
228
|
# @param glossary_id [Integer] Glossary Identifier
|
|
229
229
|
# @param term_id [Integer] Term Identifier
|
|
230
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
231
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
230
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.terms.delete API Documentation}
|
|
231
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.terms.delete Enterprise API Documentation}
|
|
232
232
|
def delete_term(glossary_id = nil, term_id = nil)
|
|
233
233
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
234
234
|
term_id || raise_parameter_is_required_error(:term_id)
|
|
@@ -244,8 +244,8 @@ module Crowdin
|
|
|
244
244
|
# @param glossary_id [Integer] Glossary Identifier
|
|
245
245
|
# @param term_id [Integer] Term Identifier
|
|
246
246
|
# @param query [Hash] Request Body
|
|
247
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
248
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
247
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.terms.patch API Documentation}
|
|
248
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.terms.patch Enterprise API Documentation}
|
|
249
249
|
def edit_term(glossary_id = nil, term_id = nil, query = {})
|
|
250
250
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
251
251
|
term_id || raise_parameter_is_required_error(:term_id)
|
|
@@ -260,9 +260,9 @@ module Crowdin
|
|
|
260
260
|
end
|
|
261
261
|
|
|
262
262
|
# @param glossary_id [Integer] Glossary Identifier
|
|
263
|
-
# @param query [Hash] Request
|
|
264
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
265
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
263
|
+
# @param query [Hash] Request Query Parameters
|
|
264
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.concepts.getMany API Documentation}
|
|
265
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.concepts.getMany Enterprise API Documentation}
|
|
266
266
|
def list_concepts(glossary_id = nil, query = {})
|
|
267
267
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
268
268
|
|
|
@@ -277,8 +277,8 @@ module Crowdin
|
|
|
277
277
|
|
|
278
278
|
# @param glossary_id [Integer] Glossary Identifier
|
|
279
279
|
# @param concept_id [Integer] Concept Identifier
|
|
280
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
281
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
280
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.concepts.get API Documentation}
|
|
281
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.concepts.get Enterprise API Documentation}
|
|
282
282
|
def get_concept(glossary_id = nil, concept_id = nil)
|
|
283
283
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
284
284
|
concept_id || raise_parameter_is_required_error(:concept_id)
|
|
@@ -294,8 +294,8 @@ module Crowdin
|
|
|
294
294
|
# @param glossary_id [Integer] Glossary Identifier
|
|
295
295
|
# @param concept_id [Integer] Concept Identifier
|
|
296
296
|
# @param query [Hash] Request Body
|
|
297
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
298
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
297
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.concepts.put API Documentation}
|
|
298
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.concepts.put Enterprise API Documentation}
|
|
299
299
|
def update_concept(glossary_id = nil, concept_id = nil, query = {})
|
|
300
300
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
301
301
|
concept_id || raise_parameter_is_required_error(:concept_id)
|
|
@@ -311,8 +311,8 @@ module Crowdin
|
|
|
311
311
|
|
|
312
312
|
# @param glossary_id [Integer] Glossary Identifier
|
|
313
313
|
# @param concept_id [Integer] Concept Identifier
|
|
314
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
315
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
314
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.concepts.delete API Documentation}
|
|
315
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.concepts.delete Enterprise API Documentation}
|
|
316
316
|
def delete_concept(glossary_id = nil, concept_id = nil)
|
|
317
317
|
glossary_id || raise_parameter_is_required_error(:glossary_id)
|
|
318
318
|
concept_id || raise_parameter_is_required_error(:concept_id)
|
|
@@ -325,10 +325,9 @@ module Crowdin
|
|
|
325
325
|
Web::SendRequest.new(request).perform
|
|
326
326
|
end
|
|
327
327
|
|
|
328
|
-
# @param project_id [Integer] Project Identifier
|
|
329
328
|
# @param query [Hash] Request Body
|
|
330
|
-
# * {https://support.crowdin.com/developer/api/v2/#
|
|
331
|
-
# * {https://support.crowdin.com/developer/enterprise/api/v2/#
|
|
329
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.projects.glossaries.concordance.post API Documentation}
|
|
330
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.projects.glossaries.concordance.post Enterprise API Documentation}
|
|
332
331
|
def search_glossaries_concordance(project_id = nil, query = {})
|
|
333
332
|
project_id || raise_project_id_is_required_error
|
|
334
333
|
|
|
@@ -344,6 +343,19 @@ module Crowdin
|
|
|
344
343
|
)
|
|
345
344
|
Web::SendRequest.new(request).perform
|
|
346
345
|
end
|
|
346
|
+
|
|
347
|
+
# @param body [Hash] Request Body
|
|
348
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.glossaries.concordance.post API Documentation}
|
|
349
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.glossaries.concordance.post Enterprise API Documentation}
|
|
350
|
+
def concordance_search_in_glossaries(body = {})
|
|
351
|
+
request = Web::Request.new(
|
|
352
|
+
connection,
|
|
353
|
+
:post,
|
|
354
|
+
"#{config.target_api_url}/glossaries/concordance",
|
|
355
|
+
{ params: body }
|
|
356
|
+
)
|
|
357
|
+
Web::SendRequest.new(request).perform
|
|
358
|
+
end
|
|
347
359
|
end
|
|
348
360
|
end
|
|
349
361
|
end
|
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Crowdin
|
|
4
|
+
module ApiResources
|
|
5
|
+
module Integrations
|
|
6
|
+
# @param application_identifier [String] Identifier of the application
|
|
7
|
+
# @param query [Hash] Request Query Parameters
|
|
8
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.job.list API Documentation}
|
|
9
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.job.list Enterprise API Documentation}
|
|
10
|
+
def list_jobs(application_identifier, query = {})
|
|
11
|
+
request = Web::Request.new(
|
|
12
|
+
connection,
|
|
13
|
+
:get,
|
|
14
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/all-jobs",
|
|
15
|
+
{ params: query }
|
|
16
|
+
)
|
|
17
|
+
Web::SendRequest.new(request).perform
|
|
18
|
+
end
|
|
19
|
+
|
|
20
|
+
# @param application_identifier [String] Identifier of the application
|
|
21
|
+
# @param query [Hash] Request Query Parameters
|
|
22
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.crowdin.files API Documentation}
|
|
23
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.crowdin.files Enterprise API Documentation}
|
|
24
|
+
def list_crowdin_files(application_identifier, query = {})
|
|
25
|
+
request = Web::Request.new(
|
|
26
|
+
connection,
|
|
27
|
+
:get,
|
|
28
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/crowdin-files",
|
|
29
|
+
{ params: query }
|
|
30
|
+
)
|
|
31
|
+
Web::SendRequest.new(request).perform
|
|
32
|
+
end
|
|
33
|
+
|
|
34
|
+
# @param application_identifier [String] Identifier of the application
|
|
35
|
+
# @param body [Hash] Request Body
|
|
36
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.crowdin.update API Documentation}
|
|
37
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.crowdin.update Enterprise API Documentation}
|
|
38
|
+
def update_crowdin_files(application_identifier, body = {})
|
|
39
|
+
request = Web::Request.new(
|
|
40
|
+
connection,
|
|
41
|
+
:post,
|
|
42
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/crowdin-update",
|
|
43
|
+
{ params: body }
|
|
44
|
+
)
|
|
45
|
+
Web::SendRequest.new(request).perform
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# @param application_identifier [String] Identifier of the application
|
|
49
|
+
# @param query [Hash] Request Query Parameters
|
|
50
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.file.progress API Documentation}
|
|
51
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.file.progress Enterprise API Documentation}
|
|
52
|
+
def get_integration_file_progress(application_identifier, query = {})
|
|
53
|
+
request = Web::Request.new(
|
|
54
|
+
connection,
|
|
55
|
+
:get,
|
|
56
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/file-progress",
|
|
57
|
+
{ params: query }
|
|
58
|
+
)
|
|
59
|
+
Web::SendRequest.new(request).perform
|
|
60
|
+
end
|
|
61
|
+
|
|
62
|
+
# @param application_identifier [String] Identifier of the application
|
|
63
|
+
# @param query [Hash] Request Query Parameters
|
|
64
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.integration.files API Documentation}
|
|
65
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.integration.files Enterprise API Documentation}
|
|
66
|
+
def list_integration_files(application_identifier, query = {})
|
|
67
|
+
request = Web::Request.new(
|
|
68
|
+
connection,
|
|
69
|
+
:get,
|
|
70
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/integration-files",
|
|
71
|
+
{ params: query }
|
|
72
|
+
)
|
|
73
|
+
Web::SendRequest.new(request).perform
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
# @param application_identifier [String] Identifier of the application
|
|
77
|
+
# @param body [Hash] Request Body
|
|
78
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.integration.update API Documentation}
|
|
79
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.integration.update Enterprise API Documentation}
|
|
80
|
+
def update_integration_files(application_identifier, body = {})
|
|
81
|
+
request = Web::Request.new(
|
|
82
|
+
connection,
|
|
83
|
+
:post,
|
|
84
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/integration-update",
|
|
85
|
+
{ params: body }
|
|
86
|
+
)
|
|
87
|
+
Web::SendRequest.new(request).perform
|
|
88
|
+
end
|
|
89
|
+
|
|
90
|
+
# @param application_identifier [String] Identifier of the application
|
|
91
|
+
# @param query [Hash] Request Query Parameters
|
|
92
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.job.info API Documentation}
|
|
93
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.job.info Enterprise API Documentation}
|
|
94
|
+
def get_job_info(application_identifier, query = {})
|
|
95
|
+
request = Web::Request.new(
|
|
96
|
+
connection,
|
|
97
|
+
:get,
|
|
98
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/job-info",
|
|
99
|
+
{ params: query }
|
|
100
|
+
)
|
|
101
|
+
Web::SendRequest.new(request).perform
|
|
102
|
+
end
|
|
103
|
+
|
|
104
|
+
# @param application_identifier [String] Identifier of the application
|
|
105
|
+
# @param query [Hash] Request Query Parameters
|
|
106
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.job.cancel API Documentation}
|
|
107
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.job.cancel Enterprise API Documentation}
|
|
108
|
+
def cancel_job(application_identifier, query = {})
|
|
109
|
+
request = Web::Request.new(
|
|
110
|
+
connection,
|
|
111
|
+
:delete,
|
|
112
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/jobs",
|
|
113
|
+
{ params: query }
|
|
114
|
+
)
|
|
115
|
+
Web::SendRequest.new(request).perform
|
|
116
|
+
end
|
|
117
|
+
|
|
118
|
+
# @param application_identifier [String] Identifier of the application
|
|
119
|
+
# @param body [Hash] Request Body
|
|
120
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.integration.login API Documentation}
|
|
121
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.integration.login Enterprise API Documentation}
|
|
122
|
+
def integration_login(application_identifier, body = {})
|
|
123
|
+
request = Web::Request.new(
|
|
124
|
+
connection,
|
|
125
|
+
:post,
|
|
126
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/login",
|
|
127
|
+
{ params: body }
|
|
128
|
+
)
|
|
129
|
+
Web::SendRequest.new(request).perform
|
|
130
|
+
end
|
|
131
|
+
|
|
132
|
+
# @param application_identifier [String] Identifier of the application
|
|
133
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.integration.fields API Documentation}
|
|
134
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.integration.fields Enterprise API Documentation}
|
|
135
|
+
def integration_login_form_fields(application_identifier)
|
|
136
|
+
request = Web::Request.new(
|
|
137
|
+
connection,
|
|
138
|
+
:get,
|
|
139
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/login-fields"
|
|
140
|
+
)
|
|
141
|
+
Web::SendRequest.new(request).perform
|
|
142
|
+
end
|
|
143
|
+
|
|
144
|
+
# @param application_identifier [String] Identifier of the application
|
|
145
|
+
# @param query [Hash] Request Query Parameters
|
|
146
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.settings.get API Documentation}
|
|
147
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.settings.get Enterprise API Documentation}
|
|
148
|
+
def get_application_settings(application_identifier, query = {})
|
|
149
|
+
request = Web::Request.new(
|
|
150
|
+
connection,
|
|
151
|
+
:get,
|
|
152
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/settings",
|
|
153
|
+
{ params: query }
|
|
154
|
+
)
|
|
155
|
+
Web::SendRequest.new(request).perform
|
|
156
|
+
end
|
|
157
|
+
|
|
158
|
+
# @param application_identifier [String] Identifier of the application
|
|
159
|
+
# @param body [Hash] Request Body
|
|
160
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.settings.update API Documentation}
|
|
161
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.settings.update Enterprise API Documentation}
|
|
162
|
+
def update_application_settings(application_identifier, body = {})
|
|
163
|
+
request = Web::Request.new(
|
|
164
|
+
connection,
|
|
165
|
+
:post,
|
|
166
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/settings",
|
|
167
|
+
{ params: body }
|
|
168
|
+
)
|
|
169
|
+
Web::SendRequest.new(request).perform
|
|
170
|
+
end
|
|
171
|
+
|
|
172
|
+
# @param application_identifier [String] Identifier of the application
|
|
173
|
+
# @param query [Hash] Request Query Parameters
|
|
174
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.sync.settings.get API Documentation}
|
|
175
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.sync.settings.get Enterprise API Documentation}
|
|
176
|
+
def get_sync_settings(application_identifier, query = {})
|
|
177
|
+
request = Web::Request.new(
|
|
178
|
+
connection,
|
|
179
|
+
:get,
|
|
180
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/sync-settings",
|
|
181
|
+
{ params: query }
|
|
182
|
+
)
|
|
183
|
+
Web::SendRequest.new(request).perform
|
|
184
|
+
end
|
|
185
|
+
|
|
186
|
+
# @param application_identifier [String] Identifier of the application
|
|
187
|
+
# @param body [Hash] Request Body
|
|
188
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.applications.integrations.sync.settings.update API Documentation}
|
|
189
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.applications.integrations.sync.settings.update Enterprise API Documentation}
|
|
190
|
+
def update_sync_settings(application_identifier, body = {})
|
|
191
|
+
request = Web::Request.new(
|
|
192
|
+
connection,
|
|
193
|
+
:post,
|
|
194
|
+
"#{config.target_api_url}/applications/#{application_identifier}/api/sync-settings",
|
|
195
|
+
{ params: body }
|
|
196
|
+
)
|
|
197
|
+
Web::SendRequest.new(request).perform
|
|
198
|
+
end
|
|
199
|
+
end
|
|
200
|
+
end
|
|
201
|
+
end
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
module Crowdin
|
|
4
4
|
module ApiResources
|
|
5
5
|
module Labels
|
|
6
|
+
# @param query [Hash] Request Query Parameters
|
|
7
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.projects.labels.getMany API Documentation}
|
|
8
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.projects.labels.getMany Enterprise API Documentation}
|
|
6
9
|
def list_labels(query = {}, project_id = config.project_id)
|
|
7
10
|
project_id || raise_project_id_is_required_error
|
|
8
11
|
|
|
@@ -15,6 +18,9 @@ module Crowdin
|
|
|
15
18
|
Web::SendRequest.new(request).perform
|
|
16
19
|
end
|
|
17
20
|
|
|
21
|
+
# @param query [Hash] Request Body
|
|
22
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.projects.labels.post API Documentation}
|
|
23
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.projects.labels.post Enterprise API Documentation}
|
|
18
24
|
def add_label(query = {}, project_id = config.project_id)
|
|
19
25
|
project_id || raise_project_id_is_required_error
|
|
20
26
|
|
|
@@ -27,6 +33,9 @@ module Crowdin
|
|
|
27
33
|
Web::SendRequest.new(request).perform
|
|
28
34
|
end
|
|
29
35
|
|
|
36
|
+
# @param label_id [Integer] Label Identifier
|
|
37
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.projects.labels.get API Documentation}
|
|
38
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.projects.labels.get Enterprise API Documentation}
|
|
30
39
|
def get_label(label_id = nil, project_id = config.project_id)
|
|
31
40
|
label_id || raise_parameter_is_required_error(:label_id)
|
|
32
41
|
project_id || raise_project_id_is_required_error
|
|
@@ -39,6 +48,9 @@ module Crowdin
|
|
|
39
48
|
Web::SendRequest.new(request).perform
|
|
40
49
|
end
|
|
41
50
|
|
|
51
|
+
# @param label_id [Integer] Label Identifier
|
|
52
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.projects.labels.delete API Documentation}
|
|
53
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.projects.labels.delete Enterprise API Documentation}
|
|
42
54
|
def delete_label(label_id = nil, project_id = config.project_id)
|
|
43
55
|
label_id || raise_parameter_is_required_error(:label_id)
|
|
44
56
|
project_id || raise_project_id_is_required_error
|
|
@@ -51,6 +63,10 @@ module Crowdin
|
|
|
51
63
|
Web::SendRequest.new(request).perform
|
|
52
64
|
end
|
|
53
65
|
|
|
66
|
+
# @param label_id [Integer] Label Identifier
|
|
67
|
+
# @param query [Hash] Request Body
|
|
68
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.projects.labels.patch API Documentation}
|
|
69
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.projects.labels.patch Enterprise API Documentation}
|
|
54
70
|
def edit_label(label_id = nil, query = {}, project_id = config.project_id)
|
|
55
71
|
label_id || raise_parameter_is_required_error(:label_id)
|
|
56
72
|
project_id || raise_project_id_is_required_error
|
|
@@ -64,6 +80,10 @@ module Crowdin
|
|
|
64
80
|
Web::SendRequest.new(request).perform
|
|
65
81
|
end
|
|
66
82
|
|
|
83
|
+
# @param label_id [Integer] Label Identifier
|
|
84
|
+
# @param query [Hash] Request Body
|
|
85
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.projects.labels.strings.post API Documentation}
|
|
86
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.projects.labels.strings.post Enterprise API Documentation}
|
|
67
87
|
def assign_label_to_strings(label_id = nil, query = {}, project_id = config.project_id)
|
|
68
88
|
label_id || raise_parameter_is_required_error(:label_id)
|
|
69
89
|
project_id || raise_project_id_is_required_error
|
|
@@ -77,6 +97,10 @@ module Crowdin
|
|
|
77
97
|
Web::SendRequest.new(request).perform
|
|
78
98
|
end
|
|
79
99
|
|
|
100
|
+
# @param label_id [Integer] Label Identifier
|
|
101
|
+
# @param query [Hash] Request Query Parameters
|
|
102
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.projects.labels.strings.deleteMany API Documentation}
|
|
103
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.projects.labels.strings.deleteMany Enterprise API Documentation}
|
|
80
104
|
def unassign_label_from_strings(label_id = nil, query = {}, project_id = config.project_id)
|
|
81
105
|
label_id || raise_parameter_is_required_error(:label_id)
|
|
82
106
|
project_id || raise_project_id_is_required_error
|
|
@@ -94,6 +118,10 @@ module Crowdin
|
|
|
94
118
|
e.message
|
|
95
119
|
end
|
|
96
120
|
|
|
121
|
+
# @param label_id [Integer] Label Identifier
|
|
122
|
+
# @param query [Hash] Request Body
|
|
123
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.projects.labels.screenshots.post API Documentation}
|
|
124
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.projects.labels.screenshots.post Enterprise API Documentation}
|
|
97
125
|
def assign_label_to_screenshots(label_id = nil, query = {}, project_id = config.project_id)
|
|
98
126
|
label_id || raise_parameter_is_required_error(:label_id)
|
|
99
127
|
project_id || raise_project_id_is_required_error
|
|
@@ -107,6 +135,10 @@ module Crowdin
|
|
|
107
135
|
Web::SendRequest.new(request).perform
|
|
108
136
|
end
|
|
109
137
|
|
|
138
|
+
# @param label_id [Integer] Label Identifier
|
|
139
|
+
# @param query [Hash] Request Query Parameters
|
|
140
|
+
# * {https://support.crowdin.com/developer/api/v2/#operation/api.projects.labels.screenshots.deleteMany API Documentation}
|
|
141
|
+
# * {https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.projects.labels.screenshots.deleteMany Enterprise API Documentation}
|
|
110
142
|
def unassign_label_from_screenshots(label_id = nil, query = {}, project_id = config.project_id)
|
|
111
143
|
label_id || raise_parameter_is_required_error(:label_id)
|
|
112
144
|
project_id || raise_project_id_is_required_error
|