Repository navigation
Expand file tree
/
Copy patherrors.json
More file actions
300 lines (300 loc) · 10.3 KB
/
Copy patherrors.json
File metadata and controls
300 lines (300 loc) · 10.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
{
"description": "How API answers map to SupertextError codes. `detail` is the response body with tags (`<…>`) removed, trimmed (ASCII whitespace) and cut to 200 characters; null when that leaves nothing. Every vector lists the expected detail. `apiErrorCode` is the body's JSON `error_code` (null if the body isn't a JSON object with a string error_code). invalid_language_pair: HTTP 400 or 404 whose body contains the text INVALID_LANGUAGE_PAIR (JSON or not); sourceLang/targetLang come from the JSON body's source_lang/target_lang when they are strings (else null). unsupported_feature: HTTP 400 whose JSON error_code is FEATURE_ERROR (the pair exists but not with this option, e.g. politeness for en-US); `feature` is the body's feature when it is a string (else null). Every vector lists feature (null when not unsupported_feature). Every HTTP 5xx is service_unavailable. HTTP 429 is first retried (see retry-delay.json); this table applies once the retries are used up.",
"http": [
{
"status": 400,
"body": "{\"error_code\":\"INVALID_LANGUAGE_PAIR\",\"source_lang\":\"en\",\"target_lang\":\"de\"}",
"code": "invalid_language_pair",
"detail": "{\"error_code\":\"INVALID_LANGUAGE_PAIR\",\"source_lang\":\"en\",\"target_lang\":\"de\"}",
"apiErrorCode": "INVALID_LANGUAGE_PAIR",
"sourceLang": "en",
"targetLang": "de",
"feature": null
},
{
"status": 400,
"body": "{\"error_code\":\"INVALID_LANGUAGE_PAIR\"}",
"code": "invalid_language_pair",
"detail": "{\"error_code\":\"INVALID_LANGUAGE_PAIR\"}",
"apiErrorCode": "INVALID_LANGUAGE_PAIR",
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 400,
"body": "INVALID_LANGUAGE_PAIR",
"code": "invalid_language_pair",
"detail": "INVALID_LANGUAGE_PAIR",
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 404,
"body": "{\"error_code\":\"INVALID_LANGUAGE_PAIR\",\"message\":\"This language combination is not supported.\",\"source_lang\":\"en\",\"target_lang\":\"xx-YY\"}",
"code": "invalid_language_pair",
"detail": "{\"error_code\":\"INVALID_LANGUAGE_PAIR\",\"message\":\"This language combination is not supported.\",\"source_lang\":\"en\",\"target_lang\":\"xx-YY\"}",
"apiErrorCode": "INVALID_LANGUAGE_PAIR",
"sourceLang": "en",
"targetLang": "xx-YY",
"feature": null
},
{
"status": 400,
"body": "{\"error_code\":\"FEATURE_ERROR\",\"feature\":\"politeness\",\"message\":\"The feature 'politeness' is not supported for the requested configuration. Please consult the feature-support endpoint at /v1/features.\",\"source_lang\":\"de\",\"target_lang\":\"en-US\"}",
"code": "unsupported_feature",
"detail": "{\"error_code\":\"FEATURE_ERROR\",\"feature\":\"politeness\",\"message\":\"The feature 'politeness' is not supported for the requested configuration. Please consult the feature-support endpoint at /v1/features.\"",
"apiErrorCode": "FEATURE_ERROR",
"sourceLang": "de",
"targetLang": "en-US",
"feature": "politeness"
},
{
"status": 400,
"body": "{\"error_code\":\"FEATURE_ERROR\"}",
"code": "unsupported_feature",
"detail": "{\"error_code\":\"FEATURE_ERROR\"}",
"apiErrorCode": "FEATURE_ERROR",
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 404,
"body": "{\"error_code\":\"FEATURE_ERROR\"}",
"code": "not_found",
"detail": "{\"error_code\":\"FEATURE_ERROR\"}",
"apiErrorCode": "FEATURE_ERROR",
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 400,
"body": "{\"error_code\":\"INVALID_MULTIPART\"}",
"code": "unexpected_status",
"detail": "{\"error_code\":\"INVALID_MULTIPART\"}",
"apiErrorCode": "INVALID_MULTIPART",
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 401,
"body": "",
"code": "authentication_failure",
"detail": null,
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 403,
"body": "<h1>Forbidden</h1>",
"code": "authentication_failure",
"detail": "Forbidden",
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 404,
"body": "{}",
"code": "not_found",
"detail": "{}",
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 413,
"body": "",
"code": "payload_too_large",
"detail": null,
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 415,
"body": "",
"code": "unexpected_status",
"detail": null,
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 429,
"body": "{\"error_code\":\"RATE_LIMIT_EXCEEDED\"}",
"code": "too_many_requests",
"detail": "{\"error_code\":\"RATE_LIMIT_EXCEEDED\"}",
"apiErrorCode": "RATE_LIMIT_EXCEEDED",
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 500,
"body": "",
"code": "service_unavailable",
"detail": null,
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 502,
"body": "",
"code": "service_unavailable",
"detail": null,
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 503,
"body": "",
"code": "service_unavailable",
"detail": null,
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 504,
"body": "",
"code": "service_unavailable",
"detail": null,
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 418,
"body": "",
"code": "unexpected_status",
"detail": null,
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 505,
"body": "",
"code": "service_unavailable",
"detail": null,
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 599,
"body": "",
"code": "service_unavailable",
"detail": null,
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 400,
"body": "{\"error_code\":\"INVALID_LANGUAGE_PAIR\",\"source_lang\":null,\"target_lang\":7}",
"code": "invalid_language_pair",
"detail": "{\"error_code\":\"INVALID_LANGUAGE_PAIR\",\"source_lang\":null,\"target_lang\":7}",
"apiErrorCode": "INVALID_LANGUAGE_PAIR",
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 400,
"body": "[\"INVALID_LANGUAGE_PAIR\"]",
"code": "invalid_language_pair",
"detail": "[\"INVALID_LANGUAGE_PAIR\"]",
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 401,
"body": "{\"error_code\":42}",
"code": "authentication_failure",
"detail": "{\"error_code\":42}",
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
},
{
"status": 500,
"body": " <p>\nxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx</p>",
"code": "service_unavailable",
"detail": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"apiErrorCode": null,
"sourceLang": null,
"targetLang": null,
"feature": null
}
],
"fileStatus": [
{
"status": "translating",
"code": null
},
{
"status": "queued",
"code": null
},
{
"status": "done",
"code": null
},
{
"status": "error",
"code": "translation_error"
},
{
"status": "limit_exceeded",
"code": "quota_exceeded"
},
{
"status": "deleted",
"code": "file_deleted"
}
],
"codes": {
"missing_api_key": "No API key configured. No request was sent.",
"authentication_failure": "HTTP 401/403: the key is wrong, revoked or lacks access.",
"invalid_language_pair": "HTTP 400 or 404 INVALID_LANGUAGE_PAIR: a code Supertext doesn't offer (e.g. de or es-ES as target; the live API answers 404 since October 2026).",
"unsupported_language": "No request was sent: the language has no Supertext code (no mapping and no exact match, spec/languages.json → resolve). Ask the administrator to map it.",
"unsupported_feature": "HTTP 400 FEATURE_ERROR: the language pair exists, but not with this option (e.g. politeness for en-US, rm, sq); `feature` names it.",
"not_found": "HTTP 404: unknown file id (expired after 24 h or already deleted).",
"payload_too_large": "HTTP 413: the document is over the API's size limit.",
"too_many_requests": "HTTP 429 after all retries.",
"service_unavailable": "HTTP 5xx.",
"unexpected_status": "Any other HTTP status.",
"transport_error": "No HTTP answer: DNS, TLS, connection refused, request timeout.",
"no_file_id": "The upload answered without a file_id.",
"translation_error": "File status `error`.",
"quota_exceeded": "File status `limit_exceeded`: the account's translation limit is used up.",
"file_deleted": "File status `deleted` before the download.",
"timeout": "The file wasn't done within the client's timeout.",
"incomplete_response": "The download was empty, or (translateTexts) segments are missing from the translated document."
}
}