@verbatra/sdk 0.11.0 → 0.12.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.
@@ -0,0 +1,354 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://verbatra.kreitz-webdev.de/schema/v1/doctor-result.json",
4
+ "title": "verbatra doctor result",
5
+ "type": "object",
6
+ "properties": {
7
+ "ok": {
8
+ "type": "boolean"
9
+ },
10
+ "checks": {
11
+ "type": "array",
12
+ "items": {
13
+ "type": "object",
14
+ "properties": {
15
+ "id": {
16
+ "type": "string",
17
+ "enum": [
18
+ "config",
19
+ "format-adapter",
20
+ "provider",
21
+ "api-key",
22
+ "network-policy",
23
+ "source-file",
24
+ "plural-rules",
25
+ "plural-completeness",
26
+ "locale-codes",
27
+ "locale-state",
28
+ "locales",
29
+ "untranslated-literals",
30
+ "data-flow"
31
+ ]
32
+ },
33
+ "title": {
34
+ "type": "string"
35
+ },
36
+ "status": {
37
+ "type": "string",
38
+ "enum": [
39
+ "pass",
40
+ "warn",
41
+ "fail",
42
+ "skipped"
43
+ ]
44
+ },
45
+ "detail": {
46
+ "type": "string"
47
+ },
48
+ "fix": {
49
+ "type": "string"
50
+ }
51
+ },
52
+ "required": [
53
+ "id",
54
+ "title",
55
+ "status",
56
+ "detail"
57
+ ]
58
+ }
59
+ },
60
+ "literals": {
61
+ "type": "object",
62
+ "properties": {
63
+ "scannedFiles": {
64
+ "type": "number"
65
+ },
66
+ "findings": {
67
+ "type": "array",
68
+ "items": {
69
+ "type": "object",
70
+ "properties": {
71
+ "file": {
72
+ "type": "string"
73
+ },
74
+ "line": {
75
+ "type": "number"
76
+ },
77
+ "column": {
78
+ "type": "number"
79
+ },
80
+ "text": {
81
+ "type": "string"
82
+ },
83
+ "truncated": {
84
+ "type": "boolean"
85
+ }
86
+ },
87
+ "required": [
88
+ "file",
89
+ "line",
90
+ "column",
91
+ "text",
92
+ "truncated"
93
+ ]
94
+ }
95
+ },
96
+ "suppressed": {
97
+ "type": "array",
98
+ "items": {
99
+ "type": "object",
100
+ "properties": {
101
+ "file": {
102
+ "type": "string"
103
+ },
104
+ "line": {
105
+ "type": "number"
106
+ },
107
+ "column": {
108
+ "type": "number"
109
+ },
110
+ "text": {
111
+ "type": "string"
112
+ },
113
+ "truncated": {
114
+ "type": "boolean"
115
+ },
116
+ "reason": {
117
+ "type": "string",
118
+ "enum": [
119
+ "directive",
120
+ "ignore-list"
121
+ ]
122
+ }
123
+ },
124
+ "required": [
125
+ "file",
126
+ "line",
127
+ "column",
128
+ "text",
129
+ "truncated",
130
+ "reason"
131
+ ]
132
+ }
133
+ },
134
+ "diagnostics": {
135
+ "type": "array",
136
+ "items": {
137
+ "type": "object",
138
+ "properties": {
139
+ "file": {
140
+ "type": "string"
141
+ },
142
+ "reason": {
143
+ "type": "string",
144
+ "enum": [
145
+ "unreadable",
146
+ "too-large",
147
+ "unparseable",
148
+ "unreadable-directory"
149
+ ]
150
+ }
151
+ },
152
+ "required": [
153
+ "file",
154
+ "reason"
155
+ ]
156
+ }
157
+ }
158
+ },
159
+ "required": [
160
+ "scannedFiles",
161
+ "findings",
162
+ "suppressed",
163
+ "diagnostics"
164
+ ]
165
+ },
166
+ "locales": {
167
+ "type": "object",
168
+ "properties": {
169
+ "provider": {
170
+ "type": "string",
171
+ "enum": [
172
+ "anthropic",
173
+ "openai",
174
+ "gemini",
175
+ "deepl",
176
+ "google-translate",
177
+ "openai-compatible",
178
+ "opencode",
179
+ "libretranslate"
180
+ ]
181
+ },
182
+ "coverage": {
183
+ "type": "string",
184
+ "enum": [
185
+ "listed",
186
+ "open"
187
+ ]
188
+ },
189
+ "tableVersion": {
190
+ "type": "string"
191
+ },
192
+ "tableOrigin": {
193
+ "type": "string",
194
+ "enum": [
195
+ "static",
196
+ "live"
197
+ ]
198
+ },
199
+ "live": {
200
+ "type": "object",
201
+ "properties": {
202
+ "status": {
203
+ "type": "string",
204
+ "enum": [
205
+ "refreshed",
206
+ "skipped",
207
+ "failed"
208
+ ]
209
+ },
210
+ "detail": {
211
+ "type": "string"
212
+ }
213
+ },
214
+ "required": [
215
+ "status",
216
+ "detail"
217
+ ]
218
+ },
219
+ "source": {
220
+ "type": "object",
221
+ "properties": {
222
+ "locale": {
223
+ "type": "string"
224
+ },
225
+ "providerCode": {
226
+ "type": "string"
227
+ },
228
+ "mapped": {
229
+ "type": "boolean"
230
+ },
231
+ "support": {
232
+ "type": "string",
233
+ "enum": [
234
+ "supported",
235
+ "unverified",
236
+ "unsupported"
237
+ ]
238
+ },
239
+ "warnings": {
240
+ "type": "array",
241
+ "items": {
242
+ "type": "object",
243
+ "properties": {
244
+ "code": {
245
+ "type": "string",
246
+ "enum": [
247
+ "LOCALE_UNVERIFIED_BY_PROVIDER",
248
+ "LOCALE_NOT_WELL_TESTED",
249
+ "GLOSSARY_UNSUPPORTED_BY_PROVIDER",
250
+ "FORMALITY_UNSUPPORTED_BY_PROVIDER"
251
+ ]
252
+ },
253
+ "message": {
254
+ "type": "string"
255
+ }
256
+ },
257
+ "required": [
258
+ "code",
259
+ "message"
260
+ ]
261
+ }
262
+ }
263
+ },
264
+ "required": [
265
+ "locale",
266
+ "providerCode",
267
+ "mapped",
268
+ "support",
269
+ "warnings"
270
+ ]
271
+ },
272
+ "locales": {
273
+ "type": "array",
274
+ "items": {
275
+ "type": "object",
276
+ "properties": {
277
+ "locale": {
278
+ "type": "string"
279
+ },
280
+ "providerCode": {
281
+ "type": "string"
282
+ },
283
+ "mapped": {
284
+ "type": "boolean"
285
+ },
286
+ "support": {
287
+ "type": "string",
288
+ "enum": [
289
+ "supported",
290
+ "unverified",
291
+ "unsupported"
292
+ ]
293
+ },
294
+ "warnings": {
295
+ "type": "array",
296
+ "items": {
297
+ "type": "object",
298
+ "properties": {
299
+ "code": {
300
+ "type": "string",
301
+ "enum": [
302
+ "LOCALE_UNVERIFIED_BY_PROVIDER",
303
+ "LOCALE_NOT_WELL_TESTED",
304
+ "GLOSSARY_UNSUPPORTED_BY_PROVIDER",
305
+ "FORMALITY_UNSUPPORTED_BY_PROVIDER"
306
+ ]
307
+ },
308
+ "message": {
309
+ "type": "string"
310
+ }
311
+ },
312
+ "required": [
313
+ "code",
314
+ "message"
315
+ ]
316
+ }
317
+ },
318
+ "glossary": {
319
+ "type": "boolean"
320
+ },
321
+ "formality": {
322
+ "type": "boolean"
323
+ }
324
+ },
325
+ "required": [
326
+ "locale",
327
+ "providerCode",
328
+ "mapped",
329
+ "support",
330
+ "warnings",
331
+ "glossary",
332
+ "formality"
333
+ ]
334
+ }
335
+ }
336
+ },
337
+ "required": [
338
+ "provider",
339
+ "coverage",
340
+ "tableVersion",
341
+ "tableOrigin",
342
+ "source",
343
+ "locales"
344
+ ]
345
+ },
346
+ "dataFlow": {
347
+ "$ref": "https://verbatra.kreitz-webdev.de/schema/v1/data-flow-manifest.json"
348
+ }
349
+ },
350
+ "required": [
351
+ "ok",
352
+ "checks"
353
+ ]
354
+ }
@@ -0,0 +1,53 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://verbatra.kreitz-webdev.de/schema/v1/export-tmx-result.json",
4
+ "title": "verbatra tmx export result",
5
+ "type": "object",
6
+ "properties": {
7
+ "path": {
8
+ "type": "string"
9
+ },
10
+ "units": {
11
+ "type": "number"
12
+ },
13
+ "locales": {
14
+ "type": "array",
15
+ "items": {
16
+ "type": "object",
17
+ "properties": {
18
+ "locale": {
19
+ "type": "string"
20
+ },
21
+ "units": {
22
+ "type": "number"
23
+ }
24
+ },
25
+ "required": [
26
+ "locale",
27
+ "units"
28
+ ]
29
+ }
30
+ },
31
+ "withoutSource": {
32
+ "type": "number"
33
+ },
34
+ "illegalCharactersRemoved": {
35
+ "type": "number"
36
+ },
37
+ "provenanceMarkers": {
38
+ "type": "string",
39
+ "enum": [
40
+ "written",
41
+ "unavailable"
42
+ ]
43
+ }
44
+ },
45
+ "required": [
46
+ "path",
47
+ "units",
48
+ "locales",
49
+ "withoutSource",
50
+ "illegalCharactersRemoved",
51
+ "provenanceMarkers"
52
+ ]
53
+ }
@@ -0,0 +1,40 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://verbatra.kreitz-webdev.de/schema/v1/export-workbook-result.json",
4
+ "title": "verbatra export result",
5
+ "type": "object",
6
+ "properties": {
7
+ "path": {
8
+ "type": "string"
9
+ },
10
+ "locales": {
11
+ "type": "array",
12
+ "items": {
13
+ "type": "object",
14
+ "properties": {
15
+ "locale": {
16
+ "type": "string"
17
+ },
18
+ "rows": {
19
+ "type": "number"
20
+ }
21
+ },
22
+ "required": [
23
+ "locale",
24
+ "rows"
25
+ ]
26
+ }
27
+ },
28
+ "provenanceMarkers": {
29
+ "type": "string",
30
+ "enum": [
31
+ "written",
32
+ "unavailable"
33
+ ]
34
+ }
35
+ },
36
+ "required": [
37
+ "path",
38
+ "locales"
39
+ ]
40
+ }
@@ -0,0 +1,149 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://verbatra.kreitz-webdev.de/schema/v1/extract-result.json",
4
+ "title": "verbatra extract result",
5
+ "type": "object",
6
+ "properties": {
7
+ "sourcePath": {
8
+ "type": "string"
9
+ },
10
+ "scannedFiles": {
11
+ "type": "number"
12
+ },
13
+ "added": {
14
+ "type": "array",
15
+ "items": {
16
+ "type": "object",
17
+ "properties": {
18
+ "key": {
19
+ "type": "string"
20
+ },
21
+ "value": {
22
+ "type": "string"
23
+ },
24
+ "file": {
25
+ "type": "string"
26
+ },
27
+ "line": {
28
+ "type": "number"
29
+ }
30
+ },
31
+ "required": [
32
+ "key",
33
+ "value",
34
+ "file",
35
+ "line"
36
+ ]
37
+ }
38
+ },
39
+ "existingKeys": {
40
+ "type": "number"
41
+ },
42
+ "withoutDefault": {
43
+ "type": "array",
44
+ "items": {
45
+ "type": "string"
46
+ }
47
+ },
48
+ "dynamic": {
49
+ "type": "array",
50
+ "items": {
51
+ "type": "object",
52
+ "properties": {
53
+ "file": {
54
+ "type": "string"
55
+ },
56
+ "line": {
57
+ "type": "number"
58
+ }
59
+ },
60
+ "required": [
61
+ "file",
62
+ "line"
63
+ ]
64
+ }
65
+ },
66
+ "conflicts": {
67
+ "type": "array",
68
+ "items": {
69
+ "type": "object",
70
+ "properties": {
71
+ "key": {
72
+ "type": "string"
73
+ },
74
+ "values": {
75
+ "type": "array",
76
+ "items": {
77
+ "type": "string"
78
+ }
79
+ },
80
+ "locations": {
81
+ "type": "array",
82
+ "items": {
83
+ "type": "object",
84
+ "properties": {
85
+ "file": {
86
+ "type": "string"
87
+ },
88
+ "line": {
89
+ "type": "number"
90
+ }
91
+ },
92
+ "required": [
93
+ "file",
94
+ "line"
95
+ ]
96
+ }
97
+ }
98
+ },
99
+ "required": [
100
+ "key",
101
+ "values",
102
+ "locations"
103
+ ]
104
+ }
105
+ },
106
+ "diagnostics": {
107
+ "type": "array",
108
+ "items": {
109
+ "type": "object",
110
+ "properties": {
111
+ "file": {
112
+ "type": "string"
113
+ },
114
+ "reason": {
115
+ "type": "string",
116
+ "enum": [
117
+ "unreadable",
118
+ "too-large",
119
+ "unparseable",
120
+ "unreadable-directory"
121
+ ]
122
+ }
123
+ },
124
+ "required": [
125
+ "file",
126
+ "reason"
127
+ ]
128
+ }
129
+ },
130
+ "written": {
131
+ "type": "boolean"
132
+ },
133
+ "dryRun": {
134
+ "type": "boolean"
135
+ }
136
+ },
137
+ "required": [
138
+ "sourcePath",
139
+ "scannedFiles",
140
+ "added",
141
+ "existingKeys",
142
+ "withoutDefault",
143
+ "dynamic",
144
+ "conflicts",
145
+ "diagnostics",
146
+ "written",
147
+ "dryRun"
148
+ ]
149
+ }
@@ -0,0 +1,80 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://verbatra.kreitz-webdev.de/schema/v1/generate-types-result.json",
4
+ "title": "verbatra types result",
5
+ "type": "object",
6
+ "properties": {
7
+ "path": {
8
+ "type": "string"
9
+ },
10
+ "sourcePath": {
11
+ "type": "string"
12
+ },
13
+ "keys": {
14
+ "type": "number"
15
+ },
16
+ "withArguments": {
17
+ "type": "number"
18
+ },
19
+ "unresolved": {
20
+ "type": "array",
21
+ "items": {
22
+ "type": "object",
23
+ "properties": {
24
+ "key": {
25
+ "type": "string"
26
+ },
27
+ "reason": {
28
+ "type": "string",
29
+ "enum": [
30
+ "invalid-message-syntax",
31
+ "mixed-argument-styles",
32
+ "argument-index-out-of-range"
33
+ ]
34
+ }
35
+ },
36
+ "required": [
37
+ "key",
38
+ "reason"
39
+ ]
40
+ }
41
+ },
42
+ "excluded": {
43
+ "type": "array",
44
+ "items": {
45
+ "type": "string"
46
+ }
47
+ },
48
+ "plural": {
49
+ "type": "array",
50
+ "items": {
51
+ "type": "string"
52
+ }
53
+ },
54
+ "written": {
55
+ "type": "boolean"
56
+ },
57
+ "stale": {
58
+ "type": "boolean"
59
+ },
60
+ "missing": {
61
+ "type": "boolean"
62
+ },
63
+ "check": {
64
+ "type": "boolean"
65
+ }
66
+ },
67
+ "required": [
68
+ "path",
69
+ "sourcePath",
70
+ "keys",
71
+ "withArguments",
72
+ "unresolved",
73
+ "excluded",
74
+ "plural",
75
+ "written",
76
+ "stale",
77
+ "missing",
78
+ "check"
79
+ ]
80
+ }