@shipeasy/openapi 1.6.0 → 2.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.
Files changed (151) hide show
  1. package/README.md +37 -0
  2. package/dist/chunk-EPLLHLZN.js +1616 -0
  3. package/dist/chunk-EPLLHLZN.js.map +1 -0
  4. package/dist/chunk-SPH5HWCD.js +3326 -0
  5. package/dist/chunk-SPH5HWCD.js.map +1 -0
  6. package/dist/client-pVkoo3Bf.d.ts +11186 -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 +64 -0
  11. package/dist/custom.js +292 -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 +7920 -0
  20. package/dist/schemas.js +1083 -0
  21. package/dist/schemas.js.map +1 -0
  22. package/openapi.json +15297 -3044
  23. package/openapi.yaml +13979 -0
  24. package/package.json +33 -26
  25. package/spec/components/errors.yaml +53 -0
  26. package/spec/components/parameters.yaml +24 -0
  27. package/spec/components/responses.yaml +107 -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 +87 -0
  31. package/spec/components/schemas/configs.yaml +371 -0
  32. package/spec/components/schemas/connectors.yaml +593 -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 +198 -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 +1011 -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 +348 -0
  47. package/spec/paths/alert-rules.yaml +250 -0
  48. package/spec/paths/attributes.yaml +261 -0
  49. package/spec/paths/configs.yaml +744 -0
  50. package/spec/paths/connectors.yaml +748 -0
  51. package/spec/paths/errors.yaml +382 -0
  52. package/spec/paths/events.yaml +366 -0
  53. package/spec/paths/experiments.yaml +777 -0
  54. package/spec/paths/gate-templates.yaml +263 -0
  55. package/spec/paths/gates.yaml +451 -0
  56. package/spec/paths/i18n.yaml +544 -0
  57. package/spec/paths/keys.yaml +181 -0
  58. package/spec/paths/killswitches.yaml +557 -0
  59. package/spec/paths/metrics.yaml +302 -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 +247 -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
@@ -1,221 +0,0 @@
1
- // src/schemas/experiments.ts
2
- import { z as z3 } from "zod";
3
-
4
- // src/schemas/folder.ts
5
- import { z } from "zod";
6
- var folderSchema = z.string().max(256).regex(/^[a-zA-Z0-9_-]+$/, "Folder must be alphanumeric, `_` or `-` (no `/`).").nullable().optional().describe(
7
- "Optional folder name used to group items in the dashboard. Part of the SDK lookup key: an item in folder `checkout` named `new-cart` is referenced as `checkout/new-cart` from the SDK."
8
- );
9
-
10
- // src/schemas/metric-name.ts
11
- import { z as z2 } from "zod";
12
- var metricNameSchema = z2.string().regex(/^[a-z0-9](?:[a-z0-9_-]*[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9_-]*[a-z0-9])?)?$/).max(128);
13
-
14
- // src/schemas/experiments.ts
15
- var experimentInlineMetricSchema = z3.object({
16
- name: metricNameSchema.optional(),
17
- query: z3.string().min(1).max(4096).describe("Metric DSL string, e.g. `count_users(checkout_completed)`.")
18
- });
19
- var experimentNameSchema = z3.string().regex(/^[a-z0-9](?:[a-z0-9_-]*[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9_-]*[a-z0-9])?)?$/).max(128).describe(
20
- "Stable experiment key. Single segment or `folder.name` (a-z, 0-9, `_`/`-`; max 128 chars). Used by SDKs as `Shipeasy.getExperiment(user, '<name>')`. Immutable after create."
21
- );
22
- var experimentGroupSchema = z3.object({
23
- name: z3.string().min(1).max(64).describe("Group label (e.g. `control`, `treatment_a`). Max 64 chars."),
24
- weight: z3.number().int().min(0).max(1e4).describe(
25
- "Allocation weight in basis points (0\u201310000). The sum across all groups must equal exactly **10000** (100%)."
26
- ),
27
- params: z3.record(z3.string(), z3.unknown()).default({}).describe(
28
- "Per-group parameter values delivered to the SDK when a caller is hashed into this group. Keys must match the experiment's `params` schema."
29
- )
30
- }).describe("One variant in the experiment. Weights across all groups must sum to 10000.");
31
- var paramSchemaSchema = z3.record(z3.string(), z3.enum(["string", "bool", "number"])).describe(
32
- "Map of param-name \u2192 scalar type. Defines the shape of `groups[].params`. Example: `{ headline: 'string', show_cta: 'bool' }`."
33
- );
34
- var bucketBySchema = z3.string().min(1).max(128).regex(
35
- /^[a-zA-Z_][a-zA-Z0-9_]*$/,
36
- "Must be a user-attribute name (letters, digits, underscore; not starting with a digit)."
37
- ).describe(
38
- "User-attribute name used as the bucketing key \u2014 e.g. `user_id` (default), `session_id`, `device_id`, or a custom attribute like `company_id` to keep a whole org on one variant. Defaults to `user_id` when omitted."
39
- );
40
- var experimentCreateSchema = z3.object({
41
- name: experimentNameSchema,
42
- description: z3.string().max(2e3).nullable().default(null).describe("Free-form description. Max 2000 chars, markdown rendered in the dashboard."),
43
- hypothesis: z3.string().max(4e3).nullable().default(null).describe("Hypothesis statement shown in the editor. Display-only."),
44
- tag: z3.string().max(64).nullable().default(null).describe("Short tag chip rendered next to the name. Display-only."),
45
- owner_email: z3.string().max(254).nullable().default(null).describe("Owner email. Display-only."),
46
- audience: z3.string().max(256).nullable().default(null).describe("Audience label shown in the editor. Display-only."),
47
- bucket_by: bucketBySchema.nullable().default(null),
48
- folder: folderSchema,
49
- universe: z3.string().min(1).describe(
50
- "Name of an existing universe in the project. Returns `422` if the universe doesn't exist."
51
- ),
52
- targeting_gate: z3.string().nullable().default(null).describe(
53
- "Optional gate name. Only callers that pass the gate are enrolled in the experiment."
54
- ),
55
- allocation_pct: z3.number().int().min(0).max(1e4).default(0).describe(
56
- "Share of the (gated) audience allocated to the experiment, in basis points (0\u201310000 = 0%\u2013100%). `0` = unallocated. Immutable while the experiment is running."
57
- ),
58
- salt: z3.string().min(1).max(64).optional().describe("Hash salt for bucketing. Auto-generated if omitted. Immutable while running."),
59
- params: paramSchemaSchema.default({}),
60
- groups: z3.array(experimentGroupSchema).min(2).describe(
61
- "Two or more variants. Weights must sum to exactly 10000 (100%). Immutable while running."
62
- ),
63
- significance_threshold: z3.number().min(1e-4).max(0.5).default(0.05).describe(
64
- "p-value cutoff used by the analysis pass. Defaults to `0.05`. Values other than 0.05 require Pro plan or higher."
65
- ),
66
- min_runtime_days: z3.number().int().min(0).max(365).default(0).describe("Minimum days the experiment must run before results are considered conclusive."),
67
- min_sample_size: z3.number().int().min(1).default(100).describe("Minimum exposures per group before results are considered conclusive."),
68
- sequential_testing: z3.boolean().default(false).describe(
69
- "Enable sequential testing (always-valid p-values). Requires Premium plan or higher."
70
- ),
71
- goal_metric: experimentInlineMetricSchema.optional().describe(
72
- "Single goal metric defined inline as a DSL query. The underlying event is auto-created if missing."
73
- ),
74
- guardrail_metrics: z3.array(experimentInlineMetricSchema).max(10).default([]).describe(
75
- "Up to 10 guardrail metrics defined inline. Each is upserted (event + metric) and attached with role=guardrail."
76
- )
77
- }).refine(
78
- (e) => e.groups.reduce((s, g) => s + g.weight, 0) === 1e4,
79
- "groups weights must sum to exactly 10000"
80
- ).describe(
81
- "Body for `POST /api/admin/experiments`. `name`, `universe`, and `groups` (\u22652, weights sum to 10000) required."
82
- );
83
- var experimentUpdateSchema = z3.object({
84
- name: experimentNameSchema.optional(),
85
- description: z3.string().max(2e3).nullable().optional(),
86
- hypothesis: z3.string().max(4e3).nullable().optional(),
87
- tag: z3.string().max(64).nullable().optional(),
88
- owner_email: z3.string().max(254).nullable().optional(),
89
- audience: z3.string().max(256).nullable().optional(),
90
- bucket_by: bucketBySchema.nullable().optional(),
91
- folder: folderSchema,
92
- targeting_gate: z3.string().nullable().optional(),
93
- allocation_pct: z3.number().int().min(0).max(1e4).optional().describe("Basis-points allocation (0\u201310000). Immutable while the experiment is running."),
94
- salt: z3.string().min(1).max(64).optional().describe("Hash salt. Immutable while running."),
95
- universe: z3.string().optional().describe(
96
- "New universe name. Immutable while running. Returns `422` if the universe doesn't exist."
97
- ),
98
- params: paramSchemaSchema.optional(),
99
- groups: z3.array(experimentGroupSchema).min(2).optional().describe("Replacement groups. Weights must sum to 10000. Immutable while running."),
100
- significance_threshold: z3.number().min(1e-4).max(0.5).optional(),
101
- min_runtime_days: z3.number().int().min(0).max(365).optional(),
102
- min_sample_size: z3.number().int().min(1).optional(),
103
- sequential_testing: z3.boolean().optional(),
104
- goal_metric: experimentInlineMetricSchema.optional().describe("Replaces the goal metric (event auto-upserted)."),
105
- guardrail_metrics: z3.array(experimentInlineMetricSchema).max(10).optional().describe("Replaces the guardrail set wholesale (event auto-upserted per entry).")
106
- }).describe(
107
- "Body for `PATCH /api/admin/experiments/{id}`. Partial \u2014 only supplied fields change. `allocation_pct`, `groups`, `salt`, `universe`, `params` are immutable while the experiment is running (stop first)."
108
- );
109
- var experimentStatusUpdateSchema = z3.object({
110
- status: z3.enum(["draft", "running", "stopped", "archived"]).describe(
111
- "Target status. Allowed transitions: `draft \u2192 running`, `running \u2192 stopped`, `stopped \u2192 archived`, `draft \u2192 archived`, and `archived \u2192 draft` (restore \u2014 only if the experiment never started). Restarting an archived experiment directly is not allowed; restore it to draft first, then start."
112
- )
113
- }).describe("Body for `POST /api/admin/experiments/{id}/status`.");
114
- var experimentMetricsUpdateSchema = z3.object({
115
- metrics: z3.array(
116
- z3.object({
117
- metric_id: z3.string().describe("Existing metric id in the project."),
118
- role: z3.enum(["goal", "guardrail", "secondary"]).describe(
119
- "Metric role. `goal` drives the decision, `guardrail` blocks ship if degraded, `secondary` is informational."
120
- )
121
- })
122
- ).describe("Replacement metrics list \u2014 replaces the current attachments wholesale.")
123
- }).describe(
124
- "Body for `POST /api/admin/experiments/{id}/metrics`. Replaces the experiment's metric attachments wholesale. Returns `422` if any `metric_id` is unknown."
125
- );
126
- var experimentResponseSchema = z3.object({
127
- id: z3.string().describe("Stable opaque experiment id (`exp_\u2026`)."),
128
- name: experimentNameSchema,
129
- description: z3.string().nullable(),
130
- hypothesis: z3.string().nullable(),
131
- tag: z3.string().nullable(),
132
- ownerEmail: z3.string().nullable(),
133
- audience: z3.string().nullable(),
134
- bucketBy: bucketBySchema.nullable(),
135
- folder: z3.string().nullable(),
136
- status: z3.enum(["draft", "running", "stopped", "archived"]),
137
- universe: z3.string().describe("Universe name this experiment draws from."),
138
- targetingGate: z3.string().nullable(),
139
- allocationPct: z3.number().int().describe("Allocation in basis points (0\u201310000)."),
140
- salt: z3.string(),
141
- params: z3.record(z3.string(), z3.enum(["string", "bool", "number"])),
142
- groups: z3.array(experimentGroupSchema),
143
- significanceThreshold: z3.number(),
144
- minRuntimeDays: z3.number().int(),
145
- minSampleSize: z3.number().int(),
146
- sequentialTesting: z3.boolean(),
147
- startedAt: z3.string().nullable().describe("ISO-8601 timestamp the experiment last transitioned to `running`, or `null`."),
148
- stoppedAt: z3.string().nullable().optional(),
149
- updatedAt: z3.string()
150
- });
151
- var experimentCreateResponseSchema = z3.object({
152
- id: z3.string().describe("Newly assigned experiment id."),
153
- name: experimentNameSchema
154
- });
155
- var experimentUpdateResponseSchema = z3.object({
156
- id: z3.string().describe("Experiment id that was updated.")
157
- });
158
- var experimentDeleteResponseSchema = z3.object({ ok: z3.literal(true) });
159
- var experimentStatusResponseSchema = z3.object({
160
- id: z3.string(),
161
- status: z3.enum(["draft", "running", "stopped", "archived"])
162
- });
163
- var experimentMetricsResponseSchema = z3.object({
164
- id: z3.string(),
165
- metrics: z3.array(
166
- z3.object({
167
- metric_id: z3.string(),
168
- role: z3.enum(["goal", "guardrail", "secondary"])
169
- })
170
- )
171
- });
172
- var experimentResultRowSchema = z3.object({
173
- metric: z3.string(),
174
- group_name: z3.string(),
175
- ds: z3.string().describe("Date slice (`YYYY-MM-DD`)."),
176
- n: z3.number().nullable(),
177
- mean: z3.number().nullable(),
178
- delta_pct: z3.number().nullable(),
179
- p_value: z3.number().nullable(),
180
- srm_detected: z3.number().nullable().describe("`1` if sample-ratio mismatch detected, else `0`.")
181
- });
182
- var experimentResultsResponseSchema = z3.object({
183
- experiment: z3.object({
184
- id: z3.string(),
185
- name: experimentNameSchema,
186
- status: z3.enum(["draft", "running", "stopped", "archived"])
187
- }),
188
- results: z3.array(experimentResultRowSchema)
189
- });
190
- var experimentTimeseriesResponseSchema = z3.object({
191
- experiment: z3.object({
192
- id: z3.string(),
193
- name: experimentNameSchema,
194
- status: z3.enum(["draft", "running", "stopped", "archived"])
195
- }),
196
- series: z3.array(experimentResultRowSchema)
197
- });
198
- var experimentReanalyzeResponseSchema = z3.object({
199
- id: z3.string(),
200
- queued: z3.literal(true)
201
- });
202
- export {
203
- bucketBySchema,
204
- experimentCreateResponseSchema,
205
- experimentCreateSchema,
206
- experimentDeleteResponseSchema,
207
- experimentGroupSchema,
208
- experimentInlineMetricSchema,
209
- experimentMetricsResponseSchema,
210
- experimentMetricsUpdateSchema,
211
- experimentNameSchema,
212
- experimentReanalyzeResponseSchema,
213
- experimentResponseSchema,
214
- experimentResultsResponseSchema,
215
- experimentStatusResponseSchema,
216
- experimentStatusUpdateSchema,
217
- experimentTimeseriesResponseSchema,
218
- experimentUpdateResponseSchema,
219
- experimentUpdateSchema,
220
- paramSchemaSchema
221
- };
@@ -1,10 +0,0 @@
1
- import { z } from 'zod';
2
-
3
- /** Folder name validation shared across every entity that supports folders.
4
- * Flat string — no `/` allowed because `/` is the folder/name separator in
5
- * SDK lookup keys (see KV blob format 3). Empty string is coerced to null
6
- * at the boundary so the DB stores a single canonical "no folder" value. */
7
- declare const folderSchema: z.ZodOptional<z.ZodNullable<z.ZodString>>;
8
- type FolderInput = z.infer<typeof folderSchema>;
9
-
10
- export { type FolderInput, folderSchema };
@@ -1,8 +0,0 @@
1
- // src/schemas/folder.ts
2
- import { z } from "zod";
3
- var folderSchema = z.string().max(256).regex(/^[a-zA-Z0-9_-]+$/, "Folder must be alphanumeric, `_` or `-` (no `/`).").nullable().optional().describe(
4
- "Optional folder name used to group items in the dashboard. Part of the SDK lookup key: an item in folder `checkout` named `new-cart` is referenced as `checkout/new-cart` from the SDK."
5
- );
6
- export {
7
- folderSchema
8
- };
@@ -1,386 +0,0 @@
1
- import { z } from 'zod';
2
-
3
- declare const gateRuleSchema: z.ZodObject<{
4
- attr: z.ZodString;
5
- op: z.ZodEnum<{
6
- eq: "eq";
7
- neq: "neq";
8
- in: "in";
9
- not_in: "not_in";
10
- gt: "gt";
11
- gte: "gte";
12
- lt: "lt";
13
- lte: "lte";
14
- contains: "contains";
15
- regex: "regex";
16
- semver_gt: "semver_gt";
17
- semver_gte: "semver_gte";
18
- semver_lt: "semver_lt";
19
- semver_lte: "semver_lte";
20
- gate_pass: "gate_pass";
21
- exp_in: "exp_in";
22
- }>;
23
- value: z.ZodUnknown;
24
- }, z.core.$strip>;
25
- declare const gateNameSchema: z.ZodString;
26
- declare const rampSchema: z.ZodObject<{
27
- from: z.ZodNumber;
28
- to: z.ZodNumber;
29
- startAt: z.ZodNumber;
30
- durationMs: z.ZodNumber;
31
- }, z.core.$strip>;
32
- declare const stackedGateEntrySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
33
- id: z.ZodString;
34
- type: z.ZodLiteral<"condition">;
35
- name: z.ZodOptional<z.ZodString>;
36
- fromTemplate: z.ZodOptional<z.ZodNullable<z.ZodString>>;
37
- pass: z.ZodOptional<z.ZodEnum<{
38
- all: "all";
39
- any: "any";
40
- }>>;
41
- rules: z.ZodDefault<z.ZodArray<z.ZodObject<{
42
- attr: z.ZodString;
43
- op: z.ZodEnum<{
44
- eq: "eq";
45
- neq: "neq";
46
- in: "in";
47
- not_in: "not_in";
48
- gt: "gt";
49
- gte: "gte";
50
- lt: "lt";
51
- lte: "lte";
52
- contains: "contains";
53
- regex: "regex";
54
- semver_gt: "semver_gt";
55
- semver_gte: "semver_gte";
56
- semver_lt: "semver_lt";
57
- semver_lte: "semver_lte";
58
- gate_pass: "gate_pass";
59
- exp_in: "exp_in";
60
- }>;
61
- value: z.ZodUnknown;
62
- }, z.core.$strip>>>;
63
- rolloutPct: z.ZodOptional<z.ZodNumber>;
64
- bucketBy: z.ZodOptional<z.ZodString>;
65
- salt: z.ZodOptional<z.ZodString>;
66
- ramp: z.ZodOptional<z.ZodObject<{
67
- from: z.ZodNumber;
68
- to: z.ZodNumber;
69
- startAt: z.ZodNumber;
70
- durationMs: z.ZodNumber;
71
- }, z.core.$strip>>;
72
- locked: z.ZodOptional<z.ZodBoolean>;
73
- }, z.core.$strip>, z.ZodObject<{
74
- id: z.ZodString;
75
- type: z.ZodLiteral<"rollout">;
76
- name: z.ZodOptional<z.ZodString>;
77
- fromTemplate: z.ZodOptional<z.ZodNullable<z.ZodString>>;
78
- rolloutPct: z.ZodNumber;
79
- bucketBy: z.ZodOptional<z.ZodString>;
80
- salt: z.ZodOptional<z.ZodString>;
81
- ramp: z.ZodOptional<z.ZodObject<{
82
- from: z.ZodNumber;
83
- to: z.ZodNumber;
84
- startAt: z.ZodNumber;
85
- durationMs: z.ZodNumber;
86
- }, z.core.$strip>>;
87
- locked: z.ZodOptional<z.ZodBoolean>;
88
- }, z.core.$strip>], "type">;
89
- declare const gateMetadataPatchSchema: z.ZodObject<{
90
- title: z.ZodOptional<z.ZodString>;
91
- description: z.ZodOptional<z.ZodString>;
92
- folder: z.ZodOptional<z.ZodNullable<z.ZodString>>;
93
- group: z.ZodOptional<z.ZodString>;
94
- owner_email: z.ZodOptional<z.ZodString>;
95
- }, z.core.$strip>;
96
- declare const gateCreateSchema: z.ZodObject<{
97
- title: z.ZodOptional<z.ZodString>;
98
- description: z.ZodOptional<z.ZodString>;
99
- folder: z.ZodOptional<z.ZodNullable<z.ZodString>>;
100
- group: z.ZodOptional<z.ZodString>;
101
- owner_email: z.ZodOptional<z.ZodString>;
102
- name: z.ZodString;
103
- enabled: z.ZodDefault<z.ZodBoolean>;
104
- rollout_pct: z.ZodDefault<z.ZodNumber>;
105
- rollout_percent: z.ZodOptional<z.ZodNumber>;
106
- rules: z.ZodDefault<z.ZodArray<z.ZodObject<{
107
- attr: z.ZodString;
108
- op: z.ZodEnum<{
109
- eq: "eq";
110
- neq: "neq";
111
- in: "in";
112
- not_in: "not_in";
113
- gt: "gt";
114
- gte: "gte";
115
- lt: "lt";
116
- lte: "lte";
117
- contains: "contains";
118
- regex: "regex";
119
- semver_gt: "semver_gt";
120
- semver_gte: "semver_gte";
121
- semver_lt: "semver_lt";
122
- semver_lte: "semver_lte";
123
- gate_pass: "gate_pass";
124
- exp_in: "exp_in";
125
- }>;
126
- value: z.ZodUnknown;
127
- }, z.core.$strip>>>;
128
- salt: z.ZodOptional<z.ZodString>;
129
- stack: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
130
- id: z.ZodString;
131
- type: z.ZodLiteral<"condition">;
132
- name: z.ZodOptional<z.ZodString>;
133
- fromTemplate: z.ZodOptional<z.ZodNullable<z.ZodString>>;
134
- pass: z.ZodOptional<z.ZodEnum<{
135
- all: "all";
136
- any: "any";
137
- }>>;
138
- rules: z.ZodDefault<z.ZodArray<z.ZodObject<{
139
- attr: z.ZodString;
140
- op: z.ZodEnum<{
141
- eq: "eq";
142
- neq: "neq";
143
- in: "in";
144
- not_in: "not_in";
145
- gt: "gt";
146
- gte: "gte";
147
- lt: "lt";
148
- lte: "lte";
149
- contains: "contains";
150
- regex: "regex";
151
- semver_gt: "semver_gt";
152
- semver_gte: "semver_gte";
153
- semver_lt: "semver_lt";
154
- semver_lte: "semver_lte";
155
- gate_pass: "gate_pass";
156
- exp_in: "exp_in";
157
- }>;
158
- value: z.ZodUnknown;
159
- }, z.core.$strip>>>;
160
- rolloutPct: z.ZodOptional<z.ZodNumber>;
161
- bucketBy: z.ZodOptional<z.ZodString>;
162
- salt: z.ZodOptional<z.ZodString>;
163
- ramp: z.ZodOptional<z.ZodObject<{
164
- from: z.ZodNumber;
165
- to: z.ZodNumber;
166
- startAt: z.ZodNumber;
167
- durationMs: z.ZodNumber;
168
- }, z.core.$strip>>;
169
- locked: z.ZodOptional<z.ZodBoolean>;
170
- }, z.core.$strip>, z.ZodObject<{
171
- id: z.ZodString;
172
- type: z.ZodLiteral<"rollout">;
173
- name: z.ZodOptional<z.ZodString>;
174
- fromTemplate: z.ZodOptional<z.ZodNullable<z.ZodString>>;
175
- rolloutPct: z.ZodNumber;
176
- bucketBy: z.ZodOptional<z.ZodString>;
177
- salt: z.ZodOptional<z.ZodString>;
178
- ramp: z.ZodOptional<z.ZodObject<{
179
- from: z.ZodNumber;
180
- to: z.ZodNumber;
181
- startAt: z.ZodNumber;
182
- durationMs: z.ZodNumber;
183
- }, z.core.$strip>>;
184
- locked: z.ZodOptional<z.ZodBoolean>;
185
- }, z.core.$strip>], "type">>>>;
186
- }, z.core.$strip>;
187
- declare const gateUpdateSchema: z.ZodObject<{
188
- title: z.ZodOptional<z.ZodString>;
189
- description: z.ZodOptional<z.ZodString>;
190
- folder: z.ZodOptional<z.ZodNullable<z.ZodString>>;
191
- group: z.ZodOptional<z.ZodString>;
192
- owner_email: z.ZodOptional<z.ZodString>;
193
- rollout_pct: z.ZodOptional<z.ZodNumber>;
194
- rollout_percent: z.ZodOptional<z.ZodNumber>;
195
- rules: z.ZodOptional<z.ZodArray<z.ZodObject<{
196
- attr: z.ZodString;
197
- op: z.ZodEnum<{
198
- eq: "eq";
199
- neq: "neq";
200
- in: "in";
201
- not_in: "not_in";
202
- gt: "gt";
203
- gte: "gte";
204
- lt: "lt";
205
- lte: "lte";
206
- contains: "contains";
207
- regex: "regex";
208
- semver_gt: "semver_gt";
209
- semver_gte: "semver_gte";
210
- semver_lt: "semver_lt";
211
- semver_lte: "semver_lte";
212
- gate_pass: "gate_pass";
213
- exp_in: "exp_in";
214
- }>;
215
- value: z.ZodUnknown;
216
- }, z.core.$strip>>>;
217
- enabled: z.ZodOptional<z.ZodBoolean>;
218
- stack: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
219
- id: z.ZodString;
220
- type: z.ZodLiteral<"condition">;
221
- name: z.ZodOptional<z.ZodString>;
222
- fromTemplate: z.ZodOptional<z.ZodNullable<z.ZodString>>;
223
- pass: z.ZodOptional<z.ZodEnum<{
224
- all: "all";
225
- any: "any";
226
- }>>;
227
- rules: z.ZodDefault<z.ZodArray<z.ZodObject<{
228
- attr: z.ZodString;
229
- op: z.ZodEnum<{
230
- eq: "eq";
231
- neq: "neq";
232
- in: "in";
233
- not_in: "not_in";
234
- gt: "gt";
235
- gte: "gte";
236
- lt: "lt";
237
- lte: "lte";
238
- contains: "contains";
239
- regex: "regex";
240
- semver_gt: "semver_gt";
241
- semver_gte: "semver_gte";
242
- semver_lt: "semver_lt";
243
- semver_lte: "semver_lte";
244
- gate_pass: "gate_pass";
245
- exp_in: "exp_in";
246
- }>;
247
- value: z.ZodUnknown;
248
- }, z.core.$strip>>>;
249
- rolloutPct: z.ZodOptional<z.ZodNumber>;
250
- bucketBy: z.ZodOptional<z.ZodString>;
251
- salt: z.ZodOptional<z.ZodString>;
252
- ramp: z.ZodOptional<z.ZodObject<{
253
- from: z.ZodNumber;
254
- to: z.ZodNumber;
255
- startAt: z.ZodNumber;
256
- durationMs: z.ZodNumber;
257
- }, z.core.$strip>>;
258
- locked: z.ZodOptional<z.ZodBoolean>;
259
- }, z.core.$strip>, z.ZodObject<{
260
- id: z.ZodString;
261
- type: z.ZodLiteral<"rollout">;
262
- name: z.ZodOptional<z.ZodString>;
263
- fromTemplate: z.ZodOptional<z.ZodNullable<z.ZodString>>;
264
- rolloutPct: z.ZodNumber;
265
- bucketBy: z.ZodOptional<z.ZodString>;
266
- salt: z.ZodOptional<z.ZodString>;
267
- ramp: z.ZodOptional<z.ZodObject<{
268
- from: z.ZodNumber;
269
- to: z.ZodNumber;
270
- startAt: z.ZodNumber;
271
- durationMs: z.ZodNumber;
272
- }, z.core.$strip>>;
273
- locked: z.ZodOptional<z.ZodBoolean>;
274
- }, z.core.$strip>], "type">>>>;
275
- }, z.core.$strip>;
276
- type GateCreateInput = z.input<typeof gateCreateSchema>;
277
- type GateUpdateInput = z.input<typeof gateUpdateSchema>;
278
- type StackedGateEntryInput = z.input<typeof stackedGateEntrySchema>;
279
- declare const gateResponseSchema: z.ZodObject<{
280
- id: z.ZodString;
281
- name: z.ZodString;
282
- enabled: z.ZodUnion<readonly [z.ZodBoolean, z.ZodNumber]>;
283
- rolloutPct: z.ZodNumber;
284
- rules: z.ZodOptional<z.ZodArray<z.ZodObject<{
285
- attr: z.ZodString;
286
- op: z.ZodEnum<{
287
- eq: "eq";
288
- neq: "neq";
289
- in: "in";
290
- not_in: "not_in";
291
- gt: "gt";
292
- gte: "gte";
293
- lt: "lt";
294
- lte: "lte";
295
- contains: "contains";
296
- regex: "regex";
297
- semver_gt: "semver_gt";
298
- semver_gte: "semver_gte";
299
- semver_lt: "semver_lt";
300
- semver_lte: "semver_lte";
301
- gate_pass: "gate_pass";
302
- exp_in: "exp_in";
303
- }>;
304
- value: z.ZodUnknown;
305
- }, z.core.$strip>>>;
306
- salt: z.ZodOptional<z.ZodString>;
307
- title: z.ZodOptional<z.ZodNullable<z.ZodString>>;
308
- description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
309
- folder: z.ZodOptional<z.ZodNullable<z.ZodString>>;
310
- groupName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
311
- ownerEmail: z.ZodOptional<z.ZodNullable<z.ZodString>>;
312
- stack: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
313
- id: z.ZodString;
314
- type: z.ZodLiteral<"condition">;
315
- name: z.ZodOptional<z.ZodString>;
316
- fromTemplate: z.ZodOptional<z.ZodNullable<z.ZodString>>;
317
- pass: z.ZodOptional<z.ZodEnum<{
318
- all: "all";
319
- any: "any";
320
- }>>;
321
- rules: z.ZodDefault<z.ZodArray<z.ZodObject<{
322
- attr: z.ZodString;
323
- op: z.ZodEnum<{
324
- eq: "eq";
325
- neq: "neq";
326
- in: "in";
327
- not_in: "not_in";
328
- gt: "gt";
329
- gte: "gte";
330
- lt: "lt";
331
- lte: "lte";
332
- contains: "contains";
333
- regex: "regex";
334
- semver_gt: "semver_gt";
335
- semver_gte: "semver_gte";
336
- semver_lt: "semver_lt";
337
- semver_lte: "semver_lte";
338
- gate_pass: "gate_pass";
339
- exp_in: "exp_in";
340
- }>;
341
- value: z.ZodUnknown;
342
- }, z.core.$strip>>>;
343
- rolloutPct: z.ZodOptional<z.ZodNumber>;
344
- bucketBy: z.ZodOptional<z.ZodString>;
345
- salt: z.ZodOptional<z.ZodString>;
346
- ramp: z.ZodOptional<z.ZodObject<{
347
- from: z.ZodNumber;
348
- to: z.ZodNumber;
349
- startAt: z.ZodNumber;
350
- durationMs: z.ZodNumber;
351
- }, z.core.$strip>>;
352
- locked: z.ZodOptional<z.ZodBoolean>;
353
- }, z.core.$strip>, z.ZodObject<{
354
- id: z.ZodString;
355
- type: z.ZodLiteral<"rollout">;
356
- name: z.ZodOptional<z.ZodString>;
357
- fromTemplate: z.ZodOptional<z.ZodNullable<z.ZodString>>;
358
- rolloutPct: z.ZodNumber;
359
- bucketBy: z.ZodOptional<z.ZodString>;
360
- salt: z.ZodOptional<z.ZodString>;
361
- ramp: z.ZodOptional<z.ZodObject<{
362
- from: z.ZodNumber;
363
- to: z.ZodNumber;
364
- startAt: z.ZodNumber;
365
- durationMs: z.ZodNumber;
366
- }, z.core.$strip>>;
367
- locked: z.ZodOptional<z.ZodBoolean>;
368
- }, z.core.$strip>], "type">>>>;
369
- updatedAt: z.ZodString;
370
- }, z.core.$strip>;
371
- declare const gateCreateResponseSchema: z.ZodObject<{
372
- id: z.ZodString;
373
- name: z.ZodString;
374
- }, z.core.$strip>;
375
- declare const gateUpdateResponseSchema: z.ZodObject<{
376
- id: z.ZodString;
377
- }, z.core.$strip>;
378
- declare const gateDeleteResponseSchema: z.ZodObject<{
379
- ok: z.ZodLiteral<true>;
380
- }, z.core.$strip>;
381
- declare const gateToggleResponseSchema: z.ZodObject<{
382
- id: z.ZodString;
383
- enabled: z.ZodBoolean;
384
- }, z.core.$strip>;
385
-
386
- export { type GateCreateInput, type GateUpdateInput, type StackedGateEntryInput, gateCreateResponseSchema, gateCreateSchema, gateDeleteResponseSchema, gateMetadataPatchSchema, gateNameSchema, gateResponseSchema, gateRuleSchema, gateToggleResponseSchema, gateUpdateResponseSchema, gateUpdateSchema, rampSchema, stackedGateEntrySchema };