@shipeasy/openapi 3.1.0 → 3.3.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 (45) hide show
  1. package/README.md +1 -1
  2. package/dist/{chunk-V4ZESAIF.js → chunk-75Z4SQOM.js} +141 -1
  3. package/dist/chunk-75Z4SQOM.js.map +1 -0
  4. package/dist/{chunk-UV333BIK.js → chunk-ZYK74ZIW.js} +569 -119
  5. package/dist/chunk-ZYK74ZIW.js.map +1 -0
  6. package/dist/{client-yqGYju-M.d.ts → client-DAGqRpF1.d.ts} +2209 -401
  7. package/dist/client.d.ts +1 -1
  8. package/dist/client.js +33 -1
  9. package/dist/custom.d.ts +5 -5
  10. package/dist/custom.js +128 -84
  11. package/dist/custom.js.map +1 -1
  12. package/dist/index.d.ts +2 -2
  13. package/dist/index.js +34 -2
  14. package/dist/index.js.map +1 -1
  15. package/dist/schemas.d.ts +2007 -891
  16. package/dist/schemas.js +179 -1
  17. package/openapi-sdk.json +1769 -0
  18. package/openapi.json +5861 -2597
  19. package/openapi.yaml +2739 -452
  20. package/package.json +6 -4
  21. package/spec/components/responses.yaml +39 -0
  22. package/spec/components/schemas/alert-rules.yaml +405 -7
  23. package/spec/components/schemas/alerts.yaml +9 -7
  24. package/spec/components/schemas/common.yaml +2 -2
  25. package/spec/components/schemas/connectors.yaml +69 -6
  26. package/spec/components/schemas/events.yaml +20 -9
  27. package/spec/components/schemas/gates.yaml +87 -0
  28. package/spec/components/schemas/keys.yaml +32 -2
  29. package/spec/components/schemas/killswitches.yaml +64 -0
  30. package/spec/components/schemas/metrics.yaml +131 -251
  31. package/spec/components/schemas/ops.yaml +555 -22
  32. package/spec/components/schemas/projects.yaml +18 -0
  33. package/spec/components/schemas/tags.yaml +91 -0
  34. package/spec/openapi-sdk.yaml +86 -0
  35. package/spec/openapi.yaml +61 -0
  36. package/spec/paths/alerts.yaml +5 -3
  37. package/spec/paths/gates.yaml +282 -0
  38. package/spec/paths/i18n.yaml +2 -1
  39. package/spec/paths/keys.yaml +79 -0
  40. package/spec/paths/killswitches.yaml +96 -0
  41. package/spec/paths/metrics.yaml +26 -17
  42. package/spec/paths/ops.yaml +566 -10
  43. package/spec/paths/tags.yaml +270 -0
  44. package/dist/chunk-UV333BIK.js.map +0 -1
  45. package/dist/chunk-V4ZESAIF.js.map +0 -1
@@ -0,0 +1,270 @@
1
+ /api/admin/tags:
2
+ get:
3
+ operationId: listTags
4
+ summary: List the project's tags
5
+ description: |-
6
+ Returns every tag in the project — the shared roster any item (queue items, flags, configs, kill switches, metrics, tracked errors, alert rules, experiments) can carry. Sorted by name.
7
+
8
+ **Use case:** See which tags already exist before tagging an item, so you reuse `ios` instead of minting `iOS-app`.
9
+ tags:
10
+ - Tags
11
+ parameters:
12
+ - $ref: ../components/parameters.yaml#/ProjectId
13
+ - name: q
14
+ in: query
15
+ required: false
16
+ description: Case-insensitive substring filter on the tag name. Omit to return every tag.
17
+ schema:
18
+ type: string
19
+ maxLength: 64
20
+ responses:
21
+ "200":
22
+ description: List the project's tags
23
+ content:
24
+ application/json:
25
+ schema:
26
+ $ref: ../components/schemas/tags.yaml#/ListTagsResponse
27
+ example:
28
+ - id: tag_01j7w8a1b2c3d4e5f6g7h8i9j0
29
+ name: checkout
30
+ - id: tag_01j7w8a1b2c3d4e5f6g7h8i9j1
31
+ name: ios
32
+ "400":
33
+ $ref: ../components/responses.yaml#/BadRequest
34
+ "401":
35
+ $ref: ../components/responses.yaml#/Unauthorized
36
+ "403":
37
+ $ref: ../components/responses.yaml#/Forbidden
38
+ "404":
39
+ $ref: ../components/responses.yaml#/NotFound
40
+ "409":
41
+ $ref: ../components/responses.yaml#/Conflict
42
+ "422":
43
+ $ref: ../components/responses.yaml#/UnprocessableEntity
44
+ x-error-codes:
45
+ - BAD_REQUEST
46
+ - UNAUTHORIZED
47
+ - FORBIDDEN
48
+ x-cli:
49
+ name: list
50
+ /api/admin/tags/{entityType}/{entityId}:
51
+ get:
52
+ operationId: getEntityTags
53
+ summary: Read an item's tags
54
+ description: |-
55
+ Returns the tags attached to one item. The item is addressed by kind (`entityType`) plus its handle, so the same call reads tags off a queue item, a flag, a config, a kill switch, a metric, a tracked error, an alert rule, or an experiment.
56
+
57
+ **Use case:** Check an item's current tags before editing them.
58
+ tags:
59
+ - Tags
60
+ parameters:
61
+ - $ref: ../components/parameters.yaml#/ProjectId
62
+ - name: entityType
63
+ in: path
64
+ required: true
65
+ description: The kind of item — `ops`, `flag`, `config`, `killswitch`, `metric`, `error`, `alert_rule`, or `experiment`.
66
+ schema:
67
+ $ref: ../components/schemas/tags.yaml#/TaggableEntityType
68
+ - name: entityId
69
+ in: path
70
+ required: true
71
+ description: The item's handle — an ops item's number (e.g. `7`) or id; a flag/config/killswitch/metric/alert rule/experiment's name or id; a tracked error's id.
72
+ schema:
73
+ $ref: ../components/schemas/common.yaml#/ResourceId
74
+ responses:
75
+ "200":
76
+ description: Read an item's tags
77
+ content:
78
+ application/json:
79
+ schema:
80
+ $ref: ../components/schemas/tags.yaml#/EntityTagsResponse
81
+ example:
82
+ entityType: ops
83
+ entityId: fb_01j7w8a1b2c3d4e5f6g7h8i9j0
84
+ tags:
85
+ - checkout
86
+ - ios
87
+ "400":
88
+ $ref: ../components/responses.yaml#/BadRequest
89
+ "401":
90
+ $ref: ../components/responses.yaml#/Unauthorized
91
+ "403":
92
+ $ref: ../components/responses.yaml#/Forbidden
93
+ "404":
94
+ $ref: ../components/responses.yaml#/NotFound
95
+ "409":
96
+ $ref: ../components/responses.yaml#/Conflict
97
+ "422":
98
+ $ref: ../components/responses.yaml#/UnprocessableEntity
99
+ x-error-codes:
100
+ - BAD_REQUEST
101
+ - UNAUTHORIZED
102
+ - FORBIDDEN
103
+ - NOT_FOUND
104
+ x-cli:
105
+ name: get
106
+ positional:
107
+ - entityType
108
+ - entityId
109
+ put:
110
+ operationId: setEntityTags
111
+ summary: Replace an item's tags
112
+ description: |-
113
+ Replaces the item's whole tag set with `tags`: names not yet in the project are created, attached names not in the list are detached, and `[]` clears every tag. Names are deduped case-insensitively, reusing an existing tag's casing (sending `iOS` when `ios` exists attaches `ios`).
114
+
115
+ **Use cases**
116
+
117
+ - **Tag an item** — `{ "tags": ["checkout", "ios"] }`.
118
+ - **Clear tags** — `{ "tags": [] }`.
119
+
120
+ To add or remove a few tags without restating the rest, use the incremental `PATCH` instead.
121
+ tags:
122
+ - Tags
123
+ parameters:
124
+ - $ref: ../components/parameters.yaml#/ProjectId
125
+ - name: entityType
126
+ in: path
127
+ required: true
128
+ description: The kind of item — `ops`, `flag`, `config`, `killswitch`, `metric`, `error`, `alert_rule`, or `experiment`.
129
+ schema:
130
+ $ref: ../components/schemas/tags.yaml#/TaggableEntityType
131
+ - name: entityId
132
+ in: path
133
+ required: true
134
+ description: The item's handle — an ops item's number (e.g. `7`) or id; a flag/config/killswitch/metric/alert rule/experiment's name or id; a tracked error's id.
135
+ schema:
136
+ $ref: ../components/schemas/common.yaml#/ResourceId
137
+ requestBody:
138
+ required: true
139
+ content:
140
+ application/json:
141
+ schema:
142
+ $ref: ../components/schemas/tags.yaml#/SetEntityTagsRequest
143
+ examples:
144
+ tag:
145
+ summary: Set the item's tags
146
+ value:
147
+ tags:
148
+ - checkout
149
+ - ios
150
+ clear:
151
+ summary: Remove every tag
152
+ value:
153
+ tags: []
154
+ responses:
155
+ "200":
156
+ description: Replace an item's tags
157
+ content:
158
+ application/json:
159
+ schema:
160
+ $ref: ../components/schemas/tags.yaml#/EntityTagsResponse
161
+ example:
162
+ entityType: ops
163
+ entityId: fb_01j7w8a1b2c3d4e5f6g7h8i9j0
164
+ tags:
165
+ - checkout
166
+ - ios
167
+ "400":
168
+ $ref: ../components/responses.yaml#/BadRequest
169
+ "401":
170
+ $ref: ../components/responses.yaml#/Unauthorized
171
+ "403":
172
+ $ref: ../components/responses.yaml#/Forbidden
173
+ "404":
174
+ $ref: ../components/responses.yaml#/NotFound
175
+ "409":
176
+ $ref: ../components/responses.yaml#/Conflict
177
+ "422":
178
+ $ref: ../components/responses.yaml#/UnprocessableEntity
179
+ x-error-codes:
180
+ - BAD_REQUEST
181
+ - UNAUTHORIZED
182
+ - FORBIDDEN
183
+ - NOT_FOUND
184
+ - VALIDATION
185
+ x-cli:
186
+ name: set
187
+ positional:
188
+ - entityType
189
+ - entityId
190
+ patch:
191
+ operationId: updateEntityTags
192
+ summary: Add or remove tags on an item
193
+ description: |-
194
+ Edits an item's tags incrementally: attaches every name in `add` (creating project tags as needed) and detaches every name in `remove`, leaving the item's other tags untouched. Matching is case-insensitive; a name in both lists ends up removed.
195
+
196
+ **Use cases**
197
+
198
+ - **Add a tag** — `{ "add": ["regression"] }`.
199
+ - **Swap a tag** — `{ "add": ["p1"], "remove": ["p2"] }`.
200
+ tags:
201
+ - Tags
202
+ parameters:
203
+ - $ref: ../components/parameters.yaml#/ProjectId
204
+ - name: entityType
205
+ in: path
206
+ required: true
207
+ description: The kind of item — `ops`, `flag`, `config`, `killswitch`, `metric`, `error`, `alert_rule`, or `experiment`.
208
+ schema:
209
+ $ref: ../components/schemas/tags.yaml#/TaggableEntityType
210
+ - name: entityId
211
+ in: path
212
+ required: true
213
+ description: The item's handle — an ops item's number (e.g. `7`) or id; a flag/config/killswitch/metric/alert rule/experiment's name or id; a tracked error's id.
214
+ schema:
215
+ $ref: ../components/schemas/common.yaml#/ResourceId
216
+ requestBody:
217
+ required: true
218
+ content:
219
+ application/json:
220
+ schema:
221
+ $ref: ../components/schemas/tags.yaml#/UpdateEntityTagsRequest
222
+ examples:
223
+ add:
224
+ summary: Attach one tag
225
+ value:
226
+ add:
227
+ - regression
228
+ swap:
229
+ summary: Replace one tag with another
230
+ value:
231
+ add:
232
+ - p1
233
+ remove:
234
+ - p2
235
+ responses:
236
+ "200":
237
+ description: Add or remove tags on an item
238
+ content:
239
+ application/json:
240
+ schema:
241
+ $ref: ../components/schemas/tags.yaml#/EntityTagsResponse
242
+ example:
243
+ entityType: ops
244
+ entityId: fb_01j7w8a1b2c3d4e5f6g7h8i9j0
245
+ tags:
246
+ - checkout
247
+ - ios
248
+ "400":
249
+ $ref: ../components/responses.yaml#/BadRequest
250
+ "401":
251
+ $ref: ../components/responses.yaml#/Unauthorized
252
+ "403":
253
+ $ref: ../components/responses.yaml#/Forbidden
254
+ "404":
255
+ $ref: ../components/responses.yaml#/NotFound
256
+ "409":
257
+ $ref: ../components/responses.yaml#/Conflict
258
+ "422":
259
+ $ref: ../components/responses.yaml#/UnprocessableEntity
260
+ x-error-codes:
261
+ - BAD_REQUEST
262
+ - UNAUTHORIZED
263
+ - FORBIDDEN
264
+ - NOT_FOUND
265
+ - VALIDATION
266
+ x-cli:
267
+ name: update
268
+ positional:
269
+ - entityType
270
+ - entityId