@shipeasy/openapi 1.6.0 → 2.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (151) hide show
  1. package/README.md +37 -0
  2. package/dist/chunk-643YSMLU.js +1616 -0
  3. package/dist/chunk-643YSMLU.js.map +1 -0
  4. package/dist/chunk-MRW3DJ57.js +3385 -0
  5. package/dist/chunk-MRW3DJ57.js.map +1 -0
  6. package/dist/client-K0ShmsC7.d.ts +11284 -0
  7. package/dist/client.d.ts +1 -0
  8. package/dist/client.js +215 -0
  9. package/dist/client.js.map +1 -0
  10. package/dist/custom.d.ts +86 -0
  11. package/dist/custom.js +300 -0
  12. package/dist/custom.js.map +1 -0
  13. package/dist/index.d.ts +29 -41
  14. package/dist/index.js +258 -4375
  15. package/dist/index.js.map +1 -0
  16. package/dist/node-context.d.ts +81 -33
  17. package/dist/node-context.js +98 -44
  18. package/dist/node-context.js.map +1 -0
  19. package/dist/schemas.d.ts +7973 -0
  20. package/dist/schemas.js +1099 -0
  21. package/dist/schemas.js.map +1 -0
  22. package/openapi.json +15922 -3232
  23. package/openapi.yaml +14277 -0
  24. package/package.json +33 -26
  25. package/spec/components/errors.yaml +53 -0
  26. package/spec/components/parameters.yaml +32 -0
  27. package/spec/components/responses.yaml +122 -0
  28. package/spec/components/schemas/alert-rules.yaml +175 -0
  29. package/spec/components/schemas/attributes.yaml +157 -0
  30. package/spec/components/schemas/common.yaml +92 -0
  31. package/spec/components/schemas/configs.yaml +371 -0
  32. package/spec/components/schemas/connectors.yaml +587 -0
  33. package/spec/components/schemas/errors-api.yaml +209 -0
  34. package/spec/components/schemas/events.yaml +321 -0
  35. package/spec/components/schemas/experiments.yaml +865 -0
  36. package/spec/components/schemas/gate-templates.yaml +237 -0
  37. package/spec/components/schemas/gates.yaml +890 -0
  38. package/spec/components/schemas/i18n.yaml +478 -0
  39. package/spec/components/schemas/keys.yaml +186 -0
  40. package/spec/components/schemas/killswitches.yaml +309 -0
  41. package/spec/components/schemas/metrics.yaml +547 -0
  42. package/spec/components/schemas/ops.yaml +1013 -0
  43. package/spec/components/schemas/projects.yaml +222 -0
  44. package/spec/components/schemas/search.yaml +46 -0
  45. package/spec/components/schemas/universes.yaml +127 -0
  46. package/spec/openapi.yaml +367 -0
  47. package/spec/paths/alert-rules.yaml +258 -0
  48. package/spec/paths/attributes.yaml +272 -0
  49. package/spec/paths/configs.yaml +758 -0
  50. package/spec/paths/connectors.yaml +782 -0
  51. package/spec/paths/errors.yaml +382 -0
  52. package/spec/paths/events.yaml +380 -0
  53. package/spec/paths/experiments.yaml +803 -0
  54. package/spec/paths/gate-templates.yaml +267 -0
  55. package/spec/paths/gates.yaml +465 -0
  56. package/spec/paths/i18n.yaml +557 -0
  57. package/spec/paths/keys.yaml +182 -0
  58. package/spec/paths/killswitches.yaml +574 -0
  59. package/spec/paths/metrics.yaml +313 -0
  60. package/spec/paths/ops.yaml +446 -0
  61. package/spec/paths/projects.yaml +210 -0
  62. package/spec/paths/search.yaml +62 -0
  63. package/spec/paths/universes.yaml +255 -0
  64. package/dist/operations/attributes.d.ts +0 -33
  65. package/dist/operations/attributes.js +0 -16
  66. package/dist/operations/cli-adapter.d.ts +0 -35
  67. package/dist/operations/cli-adapter.js +0 -91
  68. package/dist/operations/coerce.d.ts +0 -32
  69. package/dist/operations/coerce.js +0 -53
  70. package/dist/operations/configs.d.ts +0 -28
  71. package/dist/operations/configs.js +0 -119
  72. package/dist/operations/docs.d.ts +0 -37
  73. package/dist/operations/docs.js +0 -39
  74. package/dist/operations/events.d.ts +0 -28
  75. package/dist/operations/events.js +0 -121
  76. package/dist/operations/experiments.d.ts +0 -28
  77. package/dist/operations/experiments.js +0 -280
  78. package/dist/operations/gates.d.ts +0 -28
  79. package/dist/operations/gates.js +0 -132
  80. package/dist/operations/i18n.d.ts +0 -28
  81. package/dist/operations/i18n.js +0 -121
  82. package/dist/operations/index.d.ts +0 -63
  83. package/dist/operations/index.js +0 -1751
  84. package/dist/operations/killswitches.d.ts +0 -28
  85. package/dist/operations/killswitches.js +0 -126
  86. package/dist/operations/mcp-adapter.d.ts +0 -35
  87. package/dist/operations/mcp-adapter.js +0 -94
  88. package/dist/operations/metrics.d.ts +0 -30
  89. package/dist/operations/metrics.js +0 -114
  90. package/dist/operations/ops.d.ts +0 -28
  91. package/dist/operations/ops.js +0 -313
  92. package/dist/operations/projects.d.ts +0 -28
  93. package/dist/operations/projects.js +0 -36
  94. package/dist/operations/sdk-docs.d.ts +0 -28
  95. package/dist/operations/sdk-docs.js +0 -160
  96. package/dist/operations/types.d.ts +0 -138
  97. package/dist/operations/types.js +0 -9
  98. package/dist/operations/universes.d.ts +0 -28
  99. package/dist/operations/universes.js +0 -93
  100. package/dist/operations/util.d.ts +0 -33
  101. package/dist/operations/util.js +0 -9
  102. package/dist/resources/alert-rules.d.ts +0 -50
  103. package/dist/resources/alert-rules.js +0 -75
  104. package/dist/resources/attributes.d.ts +0 -19
  105. package/dist/resources/attributes.js +0 -10
  106. package/dist/resources/configs.d.ts +0 -681
  107. package/dist/resources/configs.js +0 -509
  108. package/dist/resources/events.d.ts +0 -61
  109. package/dist/resources/events.js +0 -42
  110. package/dist/resources/experiments.d.ts +0 -849
  111. package/dist/resources/experiments.js +0 -707
  112. package/dist/resources/gates.d.ts +0 -808
  113. package/dist/resources/gates.js +0 -522
  114. package/dist/resources/i18n.d.ts +0 -84
  115. package/dist/resources/i18n.js +0 -60
  116. package/dist/resources/index.d.ts +0 -2767
  117. package/dist/resources/index.js +0 -2563
  118. package/dist/resources/killswitches.d.ts +0 -436
  119. package/dist/resources/killswitches.js +0 -514
  120. package/dist/resources/metrics.d.ts +0 -54
  121. package/dist/resources/metrics.js +0 -40
  122. package/dist/resources/ops.d.ts +0 -88
  123. package/dist/resources/ops.js +0 -36
  124. package/dist/resources/projects.d.ts +0 -54
  125. package/dist/resources/projects.js +0 -14
  126. package/dist/resources/universes.d.ts +0 -185
  127. package/dist/resources/universes.js +0 -234
  128. package/dist/schemas/alert-rules.d.ts +0 -65
  129. package/dist/schemas/alert-rules.js +0 -37
  130. package/dist/schemas/configs.d.ts +0 -154
  131. package/dist/schemas/configs.js +0 -134
  132. package/dist/schemas/constants.d.ts +0 -6
  133. package/dist/schemas/constants.js +0 -7
  134. package/dist/schemas/experiments.d.ts +0 -229
  135. package/dist/schemas/experiments.js +0 -221
  136. package/dist/schemas/folder.d.ts +0 -10
  137. package/dist/schemas/folder.js +0 -8
  138. package/dist/schemas/gates.d.ts +0 -386
  139. package/dist/schemas/gates.js +0 -190
  140. package/dist/schemas/index.d.ts +0 -11
  141. package/dist/schemas/index.js +0 -762
  142. package/dist/schemas/killswitches.d.ts +0 -110
  143. package/dist/schemas/killswitches.js +0 -226
  144. package/dist/schemas/metric-name.d.ts +0 -5
  145. package/dist/schemas/metric-name.js +0 -6
  146. package/dist/schemas/pagination.d.ts +0 -37
  147. package/dist/schemas/pagination.js +0 -44
  148. package/dist/schemas/universes.d.ts +0 -35
  149. package/dist/schemas/universes.js +0 -55
  150. package/dist/transport.d.ts +0 -30
  151. package/dist/transport.js +0 -44
@@ -0,0 +1,557 @@
1
+ /api/admin/i18n/profiles:
2
+ get:
3
+ operationId: listI18nProfiles
4
+ summary: List i18n profiles
5
+ description: |-
6
+ Returns every locale profile in the project (e.g. `en:prod`, `fr:prod`).
7
+
8
+ **Use case:** Discover which locale profiles exist before pushing keys or publishing a chunk.
9
+ tags:
10
+ - Profiles
11
+ parameters:
12
+ - $ref: ../components/parameters.yaml#/ProjectId
13
+ responses:
14
+ "200":
15
+ description: List i18n profiles
16
+ content:
17
+ application/json:
18
+ schema:
19
+ $ref: ../components/schemas/i18n.yaml#/ListI18nProfilesResponse
20
+ example:
21
+ - id: i18n_01j7w8a1b2c3
22
+ name: en:prod
23
+ locales:
24
+ - en
25
+ default_locale: en
26
+ "400":
27
+ $ref: ../components/responses.yaml#/BadRequest
28
+ "401":
29
+ $ref: ../components/responses.yaml#/Unauthorized
30
+ "403":
31
+ $ref: ../components/responses.yaml#/Forbidden
32
+ "404":
33
+ $ref: ../components/responses.yaml#/NotFound
34
+ "409":
35
+ $ref: ../components/responses.yaml#/Conflict
36
+ "422":
37
+ $ref: ../components/responses.yaml#/UnprocessableEntity
38
+ x-error-codes:
39
+ - BAD_REQUEST
40
+ - UNAUTHORIZED
41
+ - FORBIDDEN
42
+ x-cli:
43
+ name: list
44
+ post:
45
+ operationId: createI18nProfile
46
+ summary: Create an i18n profile
47
+ description: |-
48
+ Create a locale profile. `name` is the stable handle (e.g. `fr:prod`).
49
+
50
+ **Use case:** Stand up a new locale before seeding its keys.
51
+ tags:
52
+ - Profiles
53
+ parameters:
54
+ - $ref: ../components/parameters.yaml#/ProjectId
55
+ requestBody:
56
+ required: true
57
+ content:
58
+ application/json:
59
+ schema:
60
+ $ref: ../components/schemas/i18n.yaml#/CreateI18nProfileRequest
61
+ example:
62
+ name: fr:prod
63
+ locales:
64
+ - fr
65
+ default_locale: fr
66
+ responses:
67
+ "201":
68
+ description: Create an i18n profile
69
+ content:
70
+ application/json:
71
+ schema:
72
+ $ref: ../components/schemas/i18n.yaml#/CreateI18nProfileResponse
73
+ example:
74
+ id: i18n_01j7w8a1b2c4
75
+ name: fr:prod
76
+ links:
77
+ PublishI18nProfile:
78
+ operationId: publishI18nProfile
79
+ parameters: { profileId: $response.body#/id }
80
+ "400":
81
+ $ref: ../components/responses.yaml#/BadRequest
82
+ "401":
83
+ $ref: ../components/responses.yaml#/Unauthorized
84
+ "403":
85
+ $ref: ../components/responses.yaml#/Forbidden
86
+ "404":
87
+ $ref: ../components/responses.yaml#/NotFound
88
+ "409":
89
+ $ref: ../components/responses.yaml#/Conflict
90
+ "422":
91
+ $ref: ../components/responses.yaml#/UnprocessableEntity
92
+ x-error-codes:
93
+ - BAD_REQUEST
94
+ - UNAUTHORIZED
95
+ - FORBIDDEN
96
+ - ALREADY_EXISTS
97
+ - VALIDATION
98
+ x-cli:
99
+ name: create
100
+ /api/admin/i18n/keys:
101
+ get:
102
+ operationId: listI18nKeys
103
+ summary: List i18n keys
104
+ description: |-
105
+ List keys for a profile, optionally filtered to a name `prefix`.
106
+
107
+ **Use case:** Read the current keys (and values) for a profile — e.g. to diff before a push.
108
+ tags:
109
+ - Keys
110
+ parameters:
111
+ - $ref: ../components/parameters.yaml#/ProjectId
112
+ - name: profile_id
113
+ in: query
114
+ required: false
115
+ description: Profile id to list keys for.
116
+ schema:
117
+ type: string
118
+ - name: prefix
119
+ in: query
120
+ required: false
121
+ description: Only keys whose name starts with this.
122
+ schema:
123
+ type: string
124
+ - name: q
125
+ in: query
126
+ required: false
127
+ description: Free-text search — matches keys whose name, value, OR description contains this substring (case-insensitive). Use it to find the key behind a piece of on-screen copy.
128
+ schema:
129
+ type: string
130
+ maxLength: 100
131
+ - name: limit
132
+ in: query
133
+ required: false
134
+ description: Max keys to return (1–500).
135
+ schema:
136
+ type: integer
137
+ minimum: 1
138
+ maximum: 500
139
+ - name: offset
140
+ in: query
141
+ required: false
142
+ description: Number of keys to skip before returning `limit` rows (offset pagination).
143
+ schema:
144
+ type: integer
145
+ minimum: 0
146
+ default: 0
147
+ responses:
148
+ "200":
149
+ description: List i18n keys
150
+ content:
151
+ application/json:
152
+ schema:
153
+ $ref: ../components/schemas/i18n.yaml#/ListI18nKeysResponse
154
+ example:
155
+ keys:
156
+ - id: key_01j7
157
+ key: checkout.cta
158
+ value: Buy now
159
+ "400":
160
+ $ref: ../components/responses.yaml#/BadRequest
161
+ "401":
162
+ $ref: ../components/responses.yaml#/Unauthorized
163
+ "403":
164
+ $ref: ../components/responses.yaml#/Forbidden
165
+ "404":
166
+ $ref: ../components/responses.yaml#/NotFound
167
+ "409":
168
+ $ref: ../components/responses.yaml#/Conflict
169
+ "422":
170
+ $ref: ../components/responses.yaml#/UnprocessableEntity
171
+ x-error-codes:
172
+ - BAD_REQUEST
173
+ - UNAUTHORIZED
174
+ - FORBIDDEN
175
+ x-cli:
176
+ name: list
177
+ post:
178
+ operationId: pushI18nKeys
179
+ summary: Push new i18n keys (insert-only)
180
+ description: |-
181
+ Add NEW keys to a profile. Insert-only — existing keys are left untouched (overwrite one with `updateI18nKey`).
182
+
183
+ **Use case:** Seed newly-extracted keys without clobbering translations already in the profile.
184
+ tags:
185
+ - Keys
186
+ parameters:
187
+ - $ref: ../components/parameters.yaml#/ProjectId
188
+ requestBody:
189
+ required: true
190
+ content:
191
+ application/json:
192
+ schema:
193
+ $ref: ../components/schemas/i18n.yaml#/PushI18nKeysRequest
194
+ example:
195
+ profile_id: i18n_01j7w8a1b2c3
196
+ keys:
197
+ - key: checkout.cta
198
+ value: Buy now
199
+ responses:
200
+ "201":
201
+ description: Push new i18n keys (insert-only)
202
+ content:
203
+ application/json:
204
+ schema:
205
+ $ref: ../components/schemas/i18n.yaml#/PushI18nKeysResponse
206
+ example:
207
+ added:
208
+ - checkout.cta
209
+ skipped: []
210
+ pushed_count: 1
211
+ skipped_count: 0
212
+ "400":
213
+ $ref: ../components/responses.yaml#/BadRequest
214
+ "401":
215
+ $ref: ../components/responses.yaml#/Unauthorized
216
+ "403":
217
+ $ref: ../components/responses.yaml#/Forbidden
218
+ "404":
219
+ $ref: ../components/responses.yaml#/NotFound
220
+ "409":
221
+ $ref: ../components/responses.yaml#/Conflict
222
+ "422":
223
+ $ref: ../components/responses.yaml#/UnprocessableEntity
224
+ x-error-codes:
225
+ - BAD_REQUEST
226
+ - UNAUTHORIZED
227
+ - FORBIDDEN
228
+ - ALREADY_EXISTS
229
+ - VALIDATION
230
+ x-cli:
231
+ name: push
232
+ /api/admin/i18n/keys/{id}:
233
+ put:
234
+ operationId: updateI18nKey
235
+ summary: Update one i18n key
236
+ description: |-
237
+ Overwrite a single existing key's value — the only overwrite path.
238
+
239
+ The change goes live on its own: the profile's KV snapshot is rebuilt and the CDN purged as part of this call, so no separate profile publish is needed.
240
+
241
+ **Use case:** Correct or re-translate a single string in place.
242
+ tags:
243
+ - Keys
244
+ parameters:
245
+ - $ref: ../components/parameters.yaml#/ProjectId
246
+ - name: id
247
+ in: path
248
+ required: true
249
+ description: The key's id.
250
+ schema:
251
+ $ref: ../components/schemas/common.yaml#/ResourceId
252
+ requestBody:
253
+ required: true
254
+ content:
255
+ application/json:
256
+ schema:
257
+ $ref: ../components/schemas/i18n.yaml#/UpdateI18nKeyRequest
258
+ example:
259
+ value: Buy it now
260
+ responses:
261
+ "200":
262
+ description: Update one i18n key
263
+ content:
264
+ application/json:
265
+ schema:
266
+ $ref: ../components/schemas/i18n.yaml#/UpdateI18nKeyResponse
267
+ example:
268
+ id: key_01j7
269
+ "400":
270
+ $ref: ../components/responses.yaml#/BadRequest
271
+ "401":
272
+ $ref: ../components/responses.yaml#/Unauthorized
273
+ "403":
274
+ $ref: ../components/responses.yaml#/Forbidden
275
+ "404":
276
+ $ref: ../components/responses.yaml#/NotFound
277
+ "409":
278
+ $ref: ../components/responses.yaml#/Conflict
279
+ "422":
280
+ $ref: ../components/responses.yaml#/UnprocessableEntity
281
+ x-error-codes:
282
+ - BAD_REQUEST
283
+ - UNAUTHORIZED
284
+ - FORBIDDEN
285
+ - NOT_FOUND
286
+ - VALIDATION
287
+ x-cli:
288
+ name: update
289
+ positional:
290
+ - id
291
+ /api/admin/i18n/drafts:
292
+ get:
293
+ operationId: listI18nDrafts
294
+ summary: List translation drafts
295
+ description: |-
296
+ List staged translation drafts awaiting review/publish.
297
+
298
+ **Use case:** Review machine-translation drafts before publishing them to a locale.
299
+ tags:
300
+ - Drafts
301
+ parameters:
302
+ - $ref: ../components/parameters.yaml#/ProjectId
303
+ responses:
304
+ "200":
305
+ description: List translation drafts
306
+ content:
307
+ application/json:
308
+ schema:
309
+ $ref: ../components/schemas/i18n.yaml#/ListI18nDraftsResponse
310
+ example:
311
+ - id: draft_01j7
312
+ "400":
313
+ $ref: ../components/responses.yaml#/BadRequest
314
+ "401":
315
+ $ref: ../components/responses.yaml#/Unauthorized
316
+ "403":
317
+ $ref: ../components/responses.yaml#/Forbidden
318
+ "404":
319
+ $ref: ../components/responses.yaml#/NotFound
320
+ "409":
321
+ $ref: ../components/responses.yaml#/Conflict
322
+ "422":
323
+ $ref: ../components/responses.yaml#/UnprocessableEntity
324
+ x-error-codes:
325
+ - BAD_REQUEST
326
+ - UNAUTHORIZED
327
+ - FORBIDDEN
328
+ x-cli:
329
+ name: list
330
+ post:
331
+ operationId: createI18nDraft
332
+ summary: Create a translation draft
333
+ description: |-
334
+ Stage a new translation draft against a target profile, optionally seeding its keys from a source profile.
335
+
336
+ **Use case:** Open a machine-translation draft for review before publishing it to a locale.
337
+ tags:
338
+ - Drafts
339
+ parameters:
340
+ - $ref: ../components/parameters.yaml#/ProjectId
341
+ requestBody:
342
+ required: true
343
+ content:
344
+ application/json:
345
+ schema:
346
+ $ref: ../components/schemas/i18n.yaml#/CreateI18nDraftRequest
347
+ example:
348
+ name: fr:prod
349
+ profile_id: 3f1a6c2e-1b2c-4d5e-8f90-0a1b2c3d4e5f
350
+ responses:
351
+ "200":
352
+ description: Create a translation draft
353
+ content:
354
+ application/json:
355
+ schema:
356
+ $ref: ../components/schemas/i18n.yaml#/CreateI18nDraftResponse
357
+ example:
358
+ id: draft_01j7
359
+ name: fr:prod
360
+ profileId: 3f1a6c2e-1b2c-4d5e-8f90-0a1b2c3d4e5f
361
+ status: open
362
+ "400":
363
+ $ref: ../components/responses.yaml#/BadRequest
364
+ "401":
365
+ $ref: ../components/responses.yaml#/Unauthorized
366
+ "403":
367
+ $ref: ../components/responses.yaml#/Forbidden
368
+ "404":
369
+ $ref: ../components/responses.yaml#/NotFound
370
+ "409":
371
+ $ref: ../components/responses.yaml#/Conflict
372
+ "422":
373
+ $ref: ../components/responses.yaml#/UnprocessableEntity
374
+ x-error-codes:
375
+ - BAD_REQUEST
376
+ - UNAUTHORIZED
377
+ - FORBIDDEN
378
+ - NOT_FOUND
379
+ - VALIDATION
380
+ x-cli:
381
+ name: create
382
+ /api/admin/i18n/drafts/{draftId}:
383
+ patch:
384
+ operationId: updateI18nDraft
385
+ summary: Update a translation draft
386
+ description: |-
387
+ Transition a draft's lifecycle state (`open` / `merged` / `abandoned`).
388
+
389
+ **Use case:** Mark a reviewed draft as merged, or abandon one that should not ship.
390
+ tags:
391
+ - Drafts
392
+ parameters:
393
+ - $ref: ../components/parameters.yaml#/ProjectId
394
+ - name: draftId
395
+ in: path
396
+ required: true
397
+ description: The draft id to update.
398
+ schema:
399
+ $ref: ../components/schemas/common.yaml#/ResourceId
400
+ requestBody:
401
+ required: true
402
+ content:
403
+ application/json:
404
+ schema:
405
+ $ref: ../components/schemas/i18n.yaml#/UpdateI18nDraftRequest
406
+ example:
407
+ status: merged
408
+ responses:
409
+ "200":
410
+ description: Update a translation draft
411
+ content:
412
+ application/json:
413
+ schema:
414
+ $ref: ../components/schemas/i18n.yaml#/UpdateI18nDraftResponse
415
+ example:
416
+ id: draft_01j7
417
+ status: merged
418
+ "400":
419
+ $ref: ../components/responses.yaml#/BadRequest
420
+ "401":
421
+ $ref: ../components/responses.yaml#/Unauthorized
422
+ "403":
423
+ $ref: ../components/responses.yaml#/Forbidden
424
+ "404":
425
+ $ref: ../components/responses.yaml#/NotFound
426
+ "409":
427
+ $ref: ../components/responses.yaml#/Conflict
428
+ "422":
429
+ $ref: ../components/responses.yaml#/UnprocessableEntity
430
+ x-error-codes:
431
+ - BAD_REQUEST
432
+ - UNAUTHORIZED
433
+ - FORBIDDEN
434
+ - NOT_FOUND
435
+ - VALIDATION
436
+ x-cli:
437
+ name: update
438
+ positional:
439
+ - draftId
440
+ /api/admin/i18n/profiles/{profileId}/publish:
441
+ post:
442
+ operationId: publishI18nProfile
443
+ summary: Publish a profile live
444
+ description: |-
445
+ Publish a profile to the CDN — rebuild its KV snapshot + purge the edge. Publishing is PROFILE-WIDE: the whole profile is snapshotted into one KV blob, so the optional `chunk` in the body is an audit label only (it does not scope what ships).
446
+
447
+ **Use case:** Ship the latest translations live after pushing/updating keys.
448
+ tags:
449
+ - Profiles
450
+ parameters:
451
+ - $ref: ../components/parameters.yaml#/ProjectId
452
+ - name: profileId
453
+ in: path
454
+ required: true
455
+ description: The profile id to publish.
456
+ schema:
457
+ $ref: ../components/schemas/common.yaml#/ResourceId
458
+ requestBody:
459
+ required: true
460
+ content:
461
+ application/json:
462
+ schema:
463
+ $ref: ../components/schemas/i18n.yaml#/PublishI18nProfileRequest
464
+ example:
465
+ chunk: default
466
+ responses:
467
+ "200":
468
+ description: Publish a profile chunk
469
+ content:
470
+ application/json:
471
+ schema:
472
+ $ref: ../components/schemas/i18n.yaml#/PublishI18nProfileResponse
473
+ example:
474
+ ok: true
475
+ "400":
476
+ $ref: ../components/responses.yaml#/BadRequest
477
+ "401":
478
+ $ref: ../components/responses.yaml#/Unauthorized
479
+ "403":
480
+ $ref: ../components/responses.yaml#/Forbidden
481
+ "404":
482
+ $ref: ../components/responses.yaml#/NotFound
483
+ "409":
484
+ $ref: ../components/responses.yaml#/Conflict
485
+ "422":
486
+ $ref: ../components/responses.yaml#/UnprocessableEntity
487
+ x-error-codes:
488
+ - BAD_REQUEST
489
+ - UNAUTHORIZED
490
+ - FORBIDDEN
491
+ - NOT_FOUND
492
+ - VALIDATION
493
+ x-cli:
494
+ name: publish
495
+ positional:
496
+ - profileId
497
+ /api/admin/i18n/set:
498
+ post:
499
+ operationId: setI18nLabel
500
+ summary: Set a key's value and publish it live
501
+ description: |-
502
+ Upsert a single key's value into a profile and immediately publish the whole profile (KV rebuild + CDN purge) so the new value is live in one call. The key is inserted when new and overwritten when it already exists. `profile` is a profile name — omit it to target the project's default-marked profile, or pass a name to target another locale.
503
+
504
+ **Use case:** Correct or replace one live string and ship it without a separate `push` + `publish`.
505
+ tags:
506
+ - Keys
507
+ parameters:
508
+ - $ref: ../components/parameters.yaml#/ProjectId
509
+ requestBody:
510
+ required: true
511
+ content:
512
+ application/json:
513
+ schema:
514
+ $ref: ../components/schemas/i18n.yaml#/SetI18nLabelRequest
515
+ example:
516
+ key: home.cta
517
+ value: Get started
518
+ responses:
519
+ "200":
520
+ description: Set a key's value and publish it live
521
+ content:
522
+ application/json:
523
+ schema:
524
+ $ref: ../components/schemas/i18n.yaml#/SetI18nLabelResponse
525
+ example:
526
+ ok: true
527
+ profile: en:prod
528
+ key: home.cta
529
+ value: Get started
530
+ version: "7"
531
+ key_count: 42
532
+ changed: true
533
+ purged: purged
534
+ kv_verified: true
535
+ "400":
536
+ $ref: ../components/responses.yaml#/BadRequest
537
+ "401":
538
+ $ref: ../components/responses.yaml#/Unauthorized
539
+ "403":
540
+ $ref: ../components/responses.yaml#/Forbidden
541
+ "404":
542
+ $ref: ../components/responses.yaml#/NotFound
543
+ "409":
544
+ $ref: ../components/responses.yaml#/Conflict
545
+ "422":
546
+ $ref: ../components/responses.yaml#/UnprocessableEntity
547
+ x-error-codes:
548
+ - BAD_REQUEST
549
+ - UNAUTHORIZED
550
+ - FORBIDDEN
551
+ - NOT_FOUND
552
+ - VALIDATION
553
+ x-cli:
554
+ name: set
555
+ positional:
556
+ - key
557
+ - value