@shipeasy/openapi 2.5.0 → 3.1.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.
@@ -94,14 +94,6 @@ ListI18nKeysResponse:
94
94
  anyOf:
95
95
  - type: string
96
96
  - type: "null"
97
- chunkId:
98
- description: Owning chunk (authoring grouping) id.
99
- type: string
100
- chunkName:
101
- description: Name of the owning chunk (authoring grouping), or `null` when it cannot be resolved.
102
- anyOf:
103
- - type: string
104
- - type: "null"
105
97
  updatedAt:
106
98
  description: ISO-8601 timestamp of the last edit.
107
99
  type: string
@@ -116,8 +108,6 @@ ListI18nKeysResponse:
116
108
  - variables
117
109
  - profileId
118
110
  - profileName
119
- - chunkId
120
- - chunkName
121
111
  - updatedAt
122
112
  - updatedBy
123
113
  additionalProperties: false
@@ -138,12 +128,6 @@ PushI18nKeysRequest:
138
128
  type: string
139
129
  format: uuid
140
130
  description: Target profile id to add keys to.
141
- chunk:
142
- description: Logical grouping the new keys are filed under. Defaults to `default`.
143
- type: string
144
- minLength: 1
145
- maxLength: 64
146
- default: default
147
131
  keys:
148
132
  type: array
149
133
  minItems: 1
@@ -174,12 +158,16 @@ PushI18nKeysRequest:
174
158
  - key
175
159
  - value
176
160
  additionalProperties: false
177
- description: Keys to add. Insert-only — existing keys are reported back as `skipped`.
161
+ description: Keys to add. Insert-only by default — existing keys are reported back as `skipped` (set `force` to overwrite them instead).
162
+ force:
163
+ type: boolean
164
+ default: false
165
+ description: Overwrite keys that already exist with the submitted value instead of skipping them. Overwritten keys come back as `updated`. Off by default so a routine push can never clobber live translations.
178
166
  required:
179
167
  - profile_id
180
168
  - keys
181
169
  additionalProperties: false
182
- description: "Body for `POST /api/admin/i18n/keys`. Insert-only: keys that already exist are never overwritten — use `PUT /keys/{id}` to change a value."
170
+ description: "Body for `POST /api/admin/i18n/keys`. Insert-only by default: keys that already exist are never overwritten — pass `force: true` to overwrite them in bulk, or use `PUT /keys/{id}` to change one value."
183
171
  PushI18nKeysResponse:
184
172
  type: object
185
173
  properties:
@@ -192,23 +180,30 @@ PushI18nKeysResponse:
192
180
  type: array
193
181
  items:
194
182
  type: string
195
- description: Key names that already existed and were left untouched.
183
+ description: Key names that already existed and were left untouched. Always empty when `force` was set — those key names come back under `updated` instead.
184
+ updated:
185
+ type: array
186
+ items:
187
+ type: string
188
+ description: Key names that already existed and were overwritten with the submitted value. Only ever non-empty when the push set `force`.
196
189
  pushed_count:
197
190
  type: number
198
191
  description: Number of keys inserted (== `added.length`).
199
192
  skipped_count:
200
193
  type: number
201
194
  description: Number of keys skipped (== `skipped.length`).
202
- chunk:
203
- description: The chunk the keys were filed under.
204
- type: string
195
+ updated_count:
196
+ type: number
197
+ description: Number of existing keys overwritten (== `updated.length`).
205
198
  required:
206
199
  - added
207
200
  - skipped
201
+ - updated
208
202
  - pushed_count
209
203
  - skipped_count
204
+ - updated_count
210
205
  additionalProperties: false
211
- description: Result of an insert-only key push.
206
+ description: Result of a key push — what was inserted, what was left alone, and (with `force`) what was overwritten.
212
207
  UpdateI18nKeyRequest:
213
208
  type: object
214
209
  properties:
@@ -249,12 +244,6 @@ UpsertI18nKeysRequest:
249
244
  type: string
250
245
  format: uuid
251
246
  description: Target profile id to upsert keys into.
252
- chunk:
253
- description: Logical grouping the keys are filed under. Defaults to `default`.
254
- type: string
255
- minLength: 1
256
- maxLength: 64
257
- default: default
258
247
  keys:
259
248
  type: array
260
249
  minItems: 1
@@ -297,12 +286,8 @@ UpsertI18nKeysResponse:
297
286
  upserted:
298
287
  type: number
299
288
  description: Number of keys written (inserted or overwritten).
300
- chunk:
301
- type: string
302
- description: The chunk the keys were filed under.
303
289
  required:
304
290
  - upserted
305
- - chunk
306
291
  additionalProperties: false
307
292
  description: Result of a bulk key upsert. The affected profile's KV snapshot is rebuilt (and the CDN purged) before this returns.
308
293
  ListI18nDraftsResponse:
@@ -465,12 +450,9 @@ UpsertI18nDraftKeyResponse:
465
450
  $ref: "./common.yaml#/OkResponse"
466
451
  PublishI18nProfileRequest:
467
452
  type: object
468
- properties:
469
- chunk:
470
- description: Optional chunk label to stamp on the audit log. Publishing is profile-wide regardless — the whole profile is snapshotted into one KV blob.
471
- type: string
453
+ properties: {}
472
454
  additionalProperties: false
473
- description: Body for `POST /api/admin/i18n/profiles/{profileId}/publish`. The `chunk` is an audit label only.
455
+ description: Body for `POST /api/admin/i18n/profiles/{profileId}/publish`. Publishing is profile-wide — the whole profile is snapshotted into one KV blob — so the body takes no options.
474
456
  PublishI18nProfileResponse:
475
457
  type: object
476
458
  properties:
@@ -481,11 +463,6 @@ PublishI18nProfileResponse:
481
463
  profile_id:
482
464
  type: string
483
465
  description: Profile that was published.
484
- chunk:
485
- anyOf:
486
- - type: string
487
- - type: "null"
488
- description: Audit chunk label, or `null` when none was given.
489
466
  published_at:
490
467
  type: string
491
468
  description: ISO-8601 timestamp of the publish.
@@ -514,7 +491,6 @@ PublishI18nProfileResponse:
514
491
  required:
515
492
  - ok
516
493
  - profile_id
517
- - chunk
518
494
  - published_at
519
495
  - version
520
496
  - key_count
@@ -1093,8 +1093,6 @@ OpsItemStatus:
1093
1093
  enum:
1094
1094
  - open
1095
1095
  - pending_approval
1096
- - triage
1097
- - triaged
1098
1096
  - investigating_by_ai
1099
1097
  - in_progress
1100
1098
  - blocked
@@ -1102,7 +1100,7 @@ OpsItemStatus:
1102
1100
  - resolved
1103
1101
  - wont_fix
1104
1102
  description: >-
1105
- Lifecycle status of a queue item. The working flow is `open` → `triaged` →
1103
+ Lifecycle status of a queue item. The working flow is `open` →
1106
1104
  `in_progress` → `ready_for_qa` → `resolved` (or `wont_fix`, terminal from
1107
1105
  any earlier stage). `blocked` marks an item that can't progress until an
1108
1106
  external dependency clears — a working state a human sets and clears.
@@ -1111,18 +1109,17 @@ OpsItemStatus:
1111
1109
  after verification — set it directly from code only when the fix has been
1112
1110
  verified end-to-end. `investigating_by_ai` is a system-owned display state —
1113
1111
  set when the AI agent (Jarvis) picks an item up to investigate, never chosen
1114
- by a human — so it is shown but not offered as a manual choice. Two
1115
- human-gated holding states park an item OUT of the work queue until a human
1116
- promotes it to `open` in the dashboard, so `GET /api/admin/ops` excludes
1117
- them under `status=all`/default and returns them only when requested as an
1118
- exact `status`: `pending_approval` is the pre-open approval gate for
1119
- untriaged inbound (e.g. connector requests filed from a customer's
1120
- connectors panel) so it never gets auto-implemented — approving = flipping
1121
- the status to `open`; `triage` is the onboarding-help bucket —
1122
- questions/errors submitted to the "Stuck in onboarding?" assistant are
1123
- funnelled into the platform project as `triage` rows so the team can see
1124
- where people get stuck and follow up, keeping onboarding chatter out of the
1125
- work queue until a human moves real items to `open`.
1112
+ by a human — so it is shown but not offered as a manual choice.
1113
+ `pending_approval` is the one human-gated holding state: it parks an item
1114
+ OUT of the work queue until a human promotes it to `open` in the dashboard,
1115
+ so `GET /api/admin/ops` excludes it under `status=all`/default and returns
1116
+ it only when requested as an exact `status`. It covers untriaged inbound
1117
+ that must never be auto-implemented — connector requests filed from a
1118
+ customer's connectors panel, and questions funnelled in from the "Stuck in
1119
+ onboarding?" assistant — where approving means flipping the status to
1120
+ `open`. Two earlier values were removed in favour of this single gate:
1121
+ `triage` (the onboarding-help bucket, now `pending_approval`) and `triaged`
1122
+ (a redundant "looked at but not started" step, now plain `open`).
1126
1123
  OpsItemPriority:
1127
1124
  type: string
1128
1125
  enum:
@@ -1138,14 +1135,13 @@ OpsInvestigationState:
1138
1135
  type: string
1139
1136
  enum:
1140
1137
  - pr_ready
1138
+ - pr_merged
1141
1139
  - investigated
1142
1140
  - detected
1143
1141
  - question
1144
1142
  - ready_for_qa
1145
1143
  - pending_approval
1146
- - needs_triage
1147
1144
  - working
1148
- - triaged_low
1149
1145
  - backlog
1150
1146
  description: >-
1151
1147
  Where automation has taken an item in the investigation lifecycle — the
@@ -1154,11 +1150,14 @@ OpsInvestigationState:
1154
1150
  happen**, never authored on its own: linking a PR sets `pr_ready`, moving to
1155
1151
  `in_progress` sets `working`, `ready_for_qa` sets `ready_for_qa`, a
1156
1152
  system/assistant reply sets `question`, resolving clears it, and creation
1157
- seeds `needs_triage`/`backlog` (by priority) or `investigated`/`detected`
1158
- for auto-filed error/alert tickets. `triaged_low` marks a low-signal item AI
1159
- has looked at but that nothing is moving. Absent on rows filed before the
1160
- field existed — consumers should treat a missing value as "derive from the
1161
- other fields".
1153
+ seeds `backlog` or `investigated`/`detected` for auto-filed error/alert
1154
+ tickets. `backlog` is the single "nothing has happened yet" state — how
1155
+ urgent that is reads off `priority`, not off a separate state, and its one
1156
+ action is to hand the item to an agent. `pr_merged` is derived client-side
1157
+ by scanning the linked pull request on GitHub, so it is accepted on write
1158
+ but not currently emitted by the API. Absent on rows filed before the field
1159
+ existed — consumers should treat a missing value as "derive from the other
1160
+ fields".
1162
1161
  OpsItemPriorityOrNull:
1163
1162
  anyOf:
1164
1163
  - $ref: "#/OpsItemPriority"
package/spec/openapi.yaml CHANGED
@@ -228,14 +228,14 @@ tags:
228
228
  - name: i18n
229
229
  description: |-
230
230
  String Manager (i18n): the worker-safe REST surface — locale profiles, the
231
- insert-only key push, single-key overwrite, chunk publish, and the read-only
231
+ insert-only key push, single-key overwrite, profile publish, and the read-only
232
232
  key/draft listings.
233
233
 
234
234
  The fs/AST parts (scan, validate, install-loader, codemod) are NOT part of
235
235
  this API — they stay in the fs-having CLI/MCP.
236
236
  - name: Profiles
237
237
  parent: i18n
238
- description: Locale profiles (e.g. `en:prod`) — create, list, and publish a profile's chunks to the CDN.
238
+ description: Locale profiles (e.g. `en:prod`) — create, list, and publish a profile to the CDN.
239
239
  - name: Keys
240
240
  parent: i18n
241
241
  description: Translation keys — the insert-only push, single-key overwrite, and key listing.
@@ -5,7 +5,7 @@
5
5
  description: |-
6
6
  Returns every locale profile in the project (e.g. `en:prod`, `fr:prod`).
7
7
 
8
- **Use case:** Discover which locale profiles exist before pushing keys or publishing a chunk.
8
+ **Use case:** Discover which locale profiles exist before pushing keys or publishing.
9
9
  tags:
10
10
  - Profiles
11
11
  parameters:
@@ -173,11 +173,13 @@
173
173
  name: list
174
174
  post:
175
175
  operationId: pushI18nKeys
176
- summary: Push new i18n keys (insert-only)
176
+ summary: Push i18n keys (insert-only, or `force` to overwrite)
177
177
  description: |-
178
- Add NEW keys to a profile. Insert-only — existing keys are left untouched (overwrite one with `updateI18nKey`).
178
+ Add NEW keys to a profile. Insert-only by default — existing keys are left untouched and reported back as `skipped`.
179
179
 
180
- **Use case:** Seed newly-extracted keys without clobbering translations already in the profile.
180
+ Pass `force: true` to overwrite the existing ones in bulk with the submitted values: they come back as `updated` instead of `skipped`. Without `force` the only overwrite paths are `updateI18nKey` (one key) and the devtools-only `upsertI18nKeys`.
181
+
182
+ **Use case:** Seed newly-extracted keys without clobbering translations already in the profile — or re-push a whole source-language file with `force` after the copy changed.
181
183
  tags:
182
184
  - Keys
183
185
  parameters:
@@ -195,7 +197,7 @@
195
197
  value: Buy now
196
198
  responses:
197
199
  "201":
198
- description: Push new i18n keys (insert-only)
200
+ description: Push i18n keys (insert-only, or `force` to overwrite)
199
201
  content:
200
202
  application/json:
201
203
  schema:
@@ -204,8 +206,10 @@
204
206
  added:
205
207
  - checkout.cta
206
208
  skipped: []
209
+ updated: []
207
210
  pushed_count: 1
208
211
  skipped_count: 0
212
+ updated_count: 0
209
213
  "400":
210
214
  $ref: ../components/responses.yaml#/BadRequest
211
215
  "401":
@@ -259,7 +263,6 @@
259
263
  $ref: ../components/schemas/i18n.yaml#/UpsertI18nKeysResponse
260
264
  example:
261
265
  upserted: 1
262
- chunk: default
263
266
  "400":
264
267
  $ref: ../components/responses.yaml#/BadRequest
265
268
  "401":
@@ -726,7 +729,7 @@
726
729
  operationId: publishI18nProfile
727
730
  summary: Publish a profile live
728
731
  description: |-
729
- 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).
732
+ 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 body takes no options.
730
733
 
731
734
  **Use case:** Ship the latest translations live after pushing/updating keys.
732
735
  tags:
@@ -740,16 +743,15 @@
740
743
  schema:
741
744
  $ref: ../components/schemas/common.yaml#/ResourceId
742
745
  requestBody:
743
- required: true
746
+ required: false
744
747
  content:
745
748
  application/json:
746
749
  schema:
747
750
  $ref: ../components/schemas/i18n.yaml#/PublishI18nProfileRequest
748
- example:
749
- chunk: default
751
+ example: {}
750
752
  responses:
751
753
  "200":
752
- description: Publish a profile chunk
754
+ description: Publish a profile
753
755
  content:
754
756
  application/json:
755
757
  schema:
@@ -29,9 +29,9 @@
29
29
  in: query
30
30
  required: false
31
31
  description: >-
32
- Filter by lifecycle status, or `all`. The human-gated holding states
33
- (`pending_approval`, `triage`) are excluded from `all`/default and
34
- returned only when requested as the exact status.
32
+ Filter by lifecycle status, or `all`. The human-gated holding state
33
+ (`pending_approval`) is excluded from `all`/default and returned only
34
+ when requested as the exact status.
35
35
  schema:
36
36
  anyOf:
37
37
  - $ref: ../components/schemas/ops.yaml#/OpsItemStatus