@epilot/cli 0.1.46 → 0.1.47

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.
@@ -101,6 +101,189 @@
101
101
  }
102
102
  }
103
103
  },
104
+ "/v2/users/me/settings": {
105
+ "get": {
106
+ "operationId": "listUserSettings",
107
+ "summary": "listUserSettings",
108
+ "description": "List all setting scopes and keys available for the currently logged in user. Does not return setting values.",
109
+ "tags": [
110
+ "User V2"
111
+ ],
112
+ "responses": {
113
+ "200": {
114
+ "description": "List of user setting scopes and keys",
115
+ "content": {
116
+ "application/json": {
117
+ "schema": {
118
+ "$ref": "#/components/schemas/UserSettingsListResponse"
119
+ }
120
+ }
121
+ }
122
+ }
123
+ }
124
+ }
125
+ },
126
+ "/v2/users/me/settings/{scope}": {
127
+ "get": {
128
+ "operationId": "getUserSettingsScope",
129
+ "summary": "getUserSettingsScope",
130
+ "description": "Get all setting values for one scope for the currently logged in user.",
131
+ "tags": [
132
+ "User V2"
133
+ ],
134
+ "parameters": [
135
+ {
136
+ "name": "scope",
137
+ "in": "path",
138
+ "required": true,
139
+ "schema": {
140
+ "$ref": "#/components/schemas/UserSettingScope"
141
+ },
142
+ "description": "User setting scope, for example calendar, navigation, or search"
143
+ }
144
+ ],
145
+ "responses": {
146
+ "200": {
147
+ "description": "User settings for the requested scope",
148
+ "content": {
149
+ "application/json": {
150
+ "schema": {
151
+ "$ref": "#/components/schemas/UserSettingsScopeResponse"
152
+ }
153
+ }
154
+ }
155
+ }
156
+ }
157
+ }
158
+ },
159
+ "/v2/users/me/settings/{scope}/{key}": {
160
+ "get": {
161
+ "operationId": "getUserSetting",
162
+ "summary": "getUserSetting",
163
+ "description": "Get one setting value by scope and key for the currently logged in user.",
164
+ "tags": [
165
+ "User V2"
166
+ ],
167
+ "parameters": [
168
+ {
169
+ "name": "scope",
170
+ "in": "path",
171
+ "required": true,
172
+ "schema": {
173
+ "$ref": "#/components/schemas/UserSettingScope"
174
+ },
175
+ "description": "User setting scope"
176
+ },
177
+ {
178
+ "name": "key",
179
+ "in": "path",
180
+ "required": true,
181
+ "schema": {
182
+ "$ref": "#/components/schemas/UserSettingKey"
183
+ },
184
+ "description": "User setting key"
185
+ }
186
+ ],
187
+ "responses": {
188
+ "200": {
189
+ "description": "User setting",
190
+ "content": {
191
+ "application/json": {
192
+ "schema": {
193
+ "$ref": "#/components/schemas/UserSetting"
194
+ }
195
+ }
196
+ }
197
+ },
198
+ "404": {
199
+ "description": "User setting not found"
200
+ }
201
+ }
202
+ },
203
+ "put": {
204
+ "operationId": "putUserSetting",
205
+ "summary": "putUserSetting",
206
+ "description": "Create or replace one setting value for the currently logged in user.",
207
+ "tags": [
208
+ "User V2"
209
+ ],
210
+ "parameters": [
211
+ {
212
+ "name": "scope",
213
+ "in": "path",
214
+ "required": true,
215
+ "schema": {
216
+ "$ref": "#/components/schemas/UserSettingScope"
217
+ },
218
+ "description": "User setting scope"
219
+ },
220
+ {
221
+ "name": "key",
222
+ "in": "path",
223
+ "required": true,
224
+ "schema": {
225
+ "$ref": "#/components/schemas/UserSettingKey"
226
+ },
227
+ "description": "User setting key"
228
+ }
229
+ ],
230
+ "requestBody": {
231
+ "required": true,
232
+ "content": {
233
+ "application/json": {
234
+ "schema": {
235
+ "$ref": "#/components/schemas/UserSettingValue"
236
+ }
237
+ }
238
+ }
239
+ },
240
+ "responses": {
241
+ "200": {
242
+ "description": "User setting saved successfully",
243
+ "content": {
244
+ "application/json": {
245
+ "schema": {
246
+ "$ref": "#/components/schemas/UserSetting"
247
+ }
248
+ }
249
+ }
250
+ }
251
+ }
252
+ },
253
+ "delete": {
254
+ "operationId": "deleteUserSetting",
255
+ "summary": "deleteUserSetting",
256
+ "description": "Delete one setting value for the currently logged in user.",
257
+ "tags": [
258
+ "User V2"
259
+ ],
260
+ "parameters": [
261
+ {
262
+ "name": "scope",
263
+ "in": "path",
264
+ "required": true,
265
+ "schema": {
266
+ "$ref": "#/components/schemas/UserSettingScope"
267
+ },
268
+ "description": "User setting scope"
269
+ },
270
+ {
271
+ "name": "key",
272
+ "in": "path",
273
+ "required": true,
274
+ "schema": {
275
+ "$ref": "#/components/schemas/UserSettingKey"
276
+ },
277
+ "description": "User setting key"
278
+ }
279
+ ],
280
+ "responses": {
281
+ "204": {
282
+ "description": "User setting deleted successfully"
283
+ }
284
+ }
285
+ }
286
+ },
104
287
  "/v2/users": {
105
288
  "get": {
106
289
  "operationId": "listUsersV2",
@@ -348,6 +531,63 @@
348
531
  }
349
532
  }
350
533
  },
534
+ "/v2/users:sendPasswordReset": {
535
+ "post": {
536
+ "operationId": "sendUserPasswordReset",
537
+ "summary": "sendUserPasswordReset",
538
+ "description": "Send a password reset email to a user in your organization.\nRequires `user:edit` on the target user.\n",
539
+ "tags": [
540
+ "User V2"
541
+ ],
542
+ "requestBody": {
543
+ "required": true,
544
+ "content": {
545
+ "application/json": {
546
+ "schema": {
547
+ "type": "object",
548
+ "required": [
549
+ "email"
550
+ ],
551
+ "properties": {
552
+ "email": {
553
+ "type": "string",
554
+ "description": "Email address of the user to reset",
555
+ "example": "test@example.com"
556
+ }
557
+ }
558
+ }
559
+ }
560
+ }
561
+ },
562
+ "responses": {
563
+ "200": {
564
+ "description": "Password reset triggered",
565
+ "content": {
566
+ "application/json": {
567
+ "schema": {
568
+ "type": "object",
569
+ "required": [
570
+ "success"
571
+ ],
572
+ "properties": {
573
+ "success": {
574
+ "type": "boolean",
575
+ "example": true
576
+ }
577
+ }
578
+ }
579
+ }
580
+ }
581
+ },
582
+ "400": {
583
+ "description": "Invalid email or user not found"
584
+ },
585
+ "403": {
586
+ "description": "Not permitted to reset this user's password"
587
+ }
588
+ }
589
+ }
590
+ },
351
591
  "/v2/users/{id}/groups": {
352
592
  "get": {
353
593
  "operationId": "getGroupsForUser",
@@ -709,6 +949,9 @@
709
949
  "summary": "verifyEmailWithToken",
710
950
  "description": "Update new email using an verification token",
711
951
  "security": [],
952
+ "x-rate-limit": {
953
+ "limit": 10
954
+ },
712
955
  "tags": [
713
956
  "User V2"
714
957
  ],
@@ -736,8 +979,69 @@
736
979
  "200": {
737
980
  "description": "Verified successfully"
738
981
  },
982
+ "400": {
983
+ "description": "No pending email change for this token"
984
+ },
739
985
  "404": {
740
986
  "description": "Token not found"
987
+ },
988
+ "409": {
989
+ "description": "Email address already in use"
990
+ }
991
+ }
992
+ }
993
+ },
994
+ "/v2/users/public/requestPasswordReset": {
995
+ "post": {
996
+ "operationId": "requestPasswordReset",
997
+ "summary": "requestPasswordReset",
998
+ "description": "Request a password reset email for the given email address. Always\nreturns a success response whether or not an account exists with that\nemail.\n",
999
+ "security": [],
1000
+ "x-rate-limit": {
1001
+ "limit": 10
1002
+ },
1003
+ "tags": [
1004
+ "User V2"
1005
+ ],
1006
+ "requestBody": {
1007
+ "required": true,
1008
+ "content": {
1009
+ "application/json": {
1010
+ "schema": {
1011
+ "type": "object",
1012
+ "required": [
1013
+ "email"
1014
+ ],
1015
+ "properties": {
1016
+ "email": {
1017
+ "type": "string",
1018
+ "description": "Email address of the account to reset",
1019
+ "example": "test@example.com"
1020
+ }
1021
+ }
1022
+ }
1023
+ }
1024
+ }
1025
+ },
1026
+ "responses": {
1027
+ "200": {
1028
+ "description": "Request accepted",
1029
+ "content": {
1030
+ "application/json": {
1031
+ "schema": {
1032
+ "type": "object",
1033
+ "required": [
1034
+ "message"
1035
+ ],
1036
+ "properties": {
1037
+ "message": {
1038
+ "type": "string",
1039
+ "example": "If an account exists, a password reset email has been sent."
1040
+ }
1041
+ }
1042
+ }
1043
+ }
1044
+ }
741
1045
  }
742
1046
  }
743
1047
  }
@@ -1687,6 +1991,13 @@
1687
1991
  "nullable": true,
1688
1992
  "format": "email"
1689
1993
  },
1994
+ "draft_email_expires_at": {
1995
+ "description": "Server-set expiry for the pending email change verification link (ISO 8601). Read-only.",
1996
+ "type": "string",
1997
+ "nullable": true,
1998
+ "format": "date-time",
1999
+ "readOnly": true
2000
+ },
1690
2001
  "department": {
1691
2002
  "type": "string",
1692
2003
  "description": "User's department",
@@ -1710,6 +2021,11 @@
1710
2021
  "type": "boolean",
1711
2022
  "example": false
1712
2023
  },
2024
+ "has_passkeys": {
2025
+ "description": "Whether the user has any registered passkeys",
2026
+ "type": "boolean",
2027
+ "example": false
2028
+ },
1713
2029
  "phone_verified": {
1714
2030
  "description": "User's phone number verification status",
1715
2031
  "type": "boolean",
@@ -2048,6 +2364,13 @@
2048
2364
  },
2049
2365
  "image_uri": {
2050
2366
  "$ref": "#/components/schemas/GroupImageUri"
2367
+ },
2368
+ "abbreviation": {
2369
+ "description": "A short abbreviation for the group, up to 2 characters.",
2370
+ "type": "string",
2371
+ "maxLength": 2,
2372
+ "nullable": true,
2373
+ "example": "FN"
2051
2374
  }
2052
2375
  },
2053
2376
  "required": [
@@ -2075,6 +2398,13 @@
2075
2398
  },
2076
2399
  "image_uri": {
2077
2400
  "$ref": "#/components/schemas/GroupImageUri"
2401
+ },
2402
+ "abbreviation": {
2403
+ "description": "A short abbreviation for the group, up to 2 characters.",
2404
+ "type": "string",
2405
+ "maxLength": 2,
2406
+ "nullable": true,
2407
+ "example": "FN"
2078
2408
  }
2079
2409
  }
2080
2410
  },
@@ -2132,6 +2462,13 @@
2132
2462
  },
2133
2463
  "image_uri": {
2134
2464
  "$ref": "#/components/schemas/GroupImageUri"
2465
+ },
2466
+ "abbreviation": {
2467
+ "description": "A short abbreviation for the group, up to 2 characters.",
2468
+ "type": "string",
2469
+ "maxLength": 2,
2470
+ "nullable": true,
2471
+ "example": "FN"
2135
2472
  }
2136
2473
  },
2137
2474
  "required": [
@@ -2377,6 +2714,110 @@
2377
2714
  }
2378
2715
  }
2379
2716
  },
2717
+ "UserSettingScope": {
2718
+ "type": "string",
2719
+ "description": "User setting scope. Values are limited to 64 characters.",
2720
+ "minLength": 1,
2721
+ "maxLength": 64,
2722
+ "example": "calendar"
2723
+ },
2724
+ "UserSettingKey": {
2725
+ "type": "string",
2726
+ "description": "User setting key. Values are limited to 128 characters.",
2727
+ "minLength": 1,
2728
+ "maxLength": 128,
2729
+ "example": "visible_calendars"
2730
+ },
2731
+ "UserSettingValue": {
2732
+ "description": "The JSON value of a user setting. Objects are recommended for extensibility, but any JSON value is accepted up to 64 KiB when serialized as JSON.",
2733
+ "x-maxSerializedBytes": 65536
2734
+ },
2735
+ "UserSetting": {
2736
+ "type": "object",
2737
+ "properties": {
2738
+ "scope": {
2739
+ "$ref": "#/components/schemas/UserSettingScope"
2740
+ },
2741
+ "key": {
2742
+ "$ref": "#/components/schemas/UserSettingKey"
2743
+ },
2744
+ "value": {
2745
+ "$ref": "#/components/schemas/UserSettingValue"
2746
+ },
2747
+ "created_at": {
2748
+ "type": "string",
2749
+ "format": "date-time"
2750
+ },
2751
+ "updated_at": {
2752
+ "type": "string",
2753
+ "format": "date-time"
2754
+ }
2755
+ },
2756
+ "required": [
2757
+ "scope",
2758
+ "key",
2759
+ "value",
2760
+ "created_at",
2761
+ "updated_at"
2762
+ ]
2763
+ },
2764
+ "UserSettingsListResponse": {
2765
+ "type": "object",
2766
+ "properties": {
2767
+ "results": {
2768
+ "type": "array",
2769
+ "items": {
2770
+ "type": "object",
2771
+ "properties": {
2772
+ "scope": {
2773
+ "$ref": "#/components/schemas/UserSettingScope"
2774
+ },
2775
+ "keys": {
2776
+ "type": "array",
2777
+ "items": {
2778
+ "$ref": "#/components/schemas/UserSettingKey"
2779
+ },
2780
+ "example": [
2781
+ "visible_calendars"
2782
+ ]
2783
+ }
2784
+ },
2785
+ "required": [
2786
+ "scope",
2787
+ "keys"
2788
+ ]
2789
+ }
2790
+ }
2791
+ },
2792
+ "required": [
2793
+ "results"
2794
+ ]
2795
+ },
2796
+ "UserSettingsScopeResponse": {
2797
+ "type": "object",
2798
+ "properties": {
2799
+ "scope": {
2800
+ "$ref": "#/components/schemas/UserSettingScope"
2801
+ },
2802
+ "settings": {
2803
+ "type": "object",
2804
+ "additionalProperties": {
2805
+ "$ref": "#/components/schemas/UserSettingValue"
2806
+ },
2807
+ "example": {
2808
+ "visible_calendars": {
2809
+ "calendar_ids": [
2810
+ "holidays"
2811
+ ]
2812
+ }
2813
+ }
2814
+ }
2815
+ },
2816
+ "required": [
2817
+ "scope",
2818
+ "settings"
2819
+ ]
2820
+ },
2380
2821
  "Passkey": {
2381
2822
  "type": "object",
2382
2823
  "properties": {
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  API_LIST
4
- } from "../chunk-YSFRKKRY.js";
4
+ } from "../chunk-VOOQ4GMS.js";
5
5
 
6
6
  // bin/epilot.ts
7
7
  import { runMain } from "citty";
@@ -11,7 +11,7 @@ import { defineCommand } from "citty";
11
11
  var main = defineCommand({
12
12
  meta: {
13
13
  name: "epilot",
14
- version: "0.1.46",
14
+ version: "0.1.47",
15
15
  description: "CLI for epilot APIs"
16
16
  },
17
17
  args: {
@@ -30,8 +30,8 @@ var main = defineCommand({
30
30
  auth: () => import("../auth-CN5EFFDE.js").then((m) => m.default),
31
31
  profile: () => import("../profile-OZJL5ZPT.js").then((m) => m.default),
32
32
  config: () => import("../config-DGZIMLZK.js").then((m) => m.default),
33
- completion: () => import("../completion-QKONIGGO.js").then((m) => m.default),
34
- upgrade: () => import("../upgrade-DE6PWJ2I.js").then((m) => m.default),
33
+ completion: () => import("../completion-EKYW2Z3F.js").then((m) => m.default),
34
+ upgrade: () => import("../upgrade-FCRZPJWQ.js").then((m) => m.default),
35
35
  "access-token": () => import("../access-token-WWE6BDJH.js").then((m) => m.default),
36
36
  address: () => import("../address-EH3C4CVB.js").then((m) => m.default),
37
37
  "address-suggestions": () => import("../address-suggestions-RRSLOBFW.js").then((m) => m.default),
@@ -74,6 +74,7 @@ var main = defineCommand({
74
74
  query: () => import("../query-5QIXDE32.js").then((m) => m.default),
75
75
  sandbox: () => import("../sandbox-Q3XHXMFY.js").then((m) => m.default),
76
76
  sharing: () => import("../sharing-SQJ355YL.js").then((m) => m.default),
77
+ snapshot: () => import("../snapshot-AHEAQ3CU.js").then((m) => m.default),
77
78
  submission: () => import("../submission-WJUI3BYW.js").then((m) => m.default),
78
79
  targeting: () => import("../targeting-6QHPH3GP.js").then((m) => m.default),
79
80
  "template-variables": () => import("../template-variables-WVV7Y6HO.js").then((m) => m.default),
@@ -133,13 +134,13 @@ process.stderr.on("error", (err) => {
133
134
  if (err.code === "EPIPE") process.exit(0);
134
135
  throw err;
135
136
  });
136
- var VERSION = true ? "0.1.46" : (await null).default.version;
137
+ var VERSION = true ? "0.1.47" : (await null).default.version;
137
138
  var reorderedArgv = hoistFlagsAfterSubcommand(process.argv.slice(2));
138
139
  process.argv = [process.argv[0], process.argv[1], ...reorderedArgv];
139
140
  var args = process.argv.slice(2);
140
141
  var completionsIdx = args.indexOf("--_completions");
141
142
  if (completionsIdx >= 0) {
142
- const { handleCompletions } = await import("../completion-QKONIGGO.js");
143
+ const { handleCompletions } = await import("../completion-EKYW2Z3F.js");
143
144
  handleCompletions(args[completionsIdx + 1], args[completionsIdx + 2]);
144
145
  process.exit(0);
145
146
  }
@@ -1168,6 +1168,23 @@ var API_LIST = [
1168
1168
  "acceptOffer"
1169
1169
  ]
1170
1170
  },
1171
+ {
1172
+ apiName: "snapshot",
1173
+ kebabName: "snapshot",
1174
+ title: "Snapshot API",
1175
+ serverUrl: "https://snapshot.sls.epilot.io",
1176
+ operationCount: 8,
1177
+ operationIds: [
1178
+ "listSnapshots",
1179
+ "createSnapshot",
1180
+ "getSnapshot",
1181
+ "deleteSnapshot",
1182
+ "restoreSnapshot",
1183
+ "listSnapshotResources",
1184
+ "getSnapshotResource",
1185
+ "listDependencies"
1186
+ ]
1187
+ },
1171
1188
  {
1172
1189
  apiName: "submission",
1173
1190
  kebabName: "submission",
@@ -1223,16 +1240,22 @@ var API_LIST = [
1223
1240
  kebabName: "user",
1224
1241
  title: "User API",
1225
1242
  serverUrl: "https://user.sls.epilot.io",
1226
- operationCount: 34,
1243
+ operationCount: 41,
1227
1244
  operationIds: [
1228
1245
  "signUpUser",
1229
1246
  "getMeV2",
1247
+ "listUserSettings",
1248
+ "getUserSettingsScope",
1249
+ "getUserSetting",
1250
+ "putUserSetting",
1251
+ "deleteUserSetting",
1230
1252
  "listUsersV2",
1231
1253
  "getUserV2",
1232
1254
  "updateUserV2",
1233
1255
  "deleteUserV2",
1234
1256
  "inviteUser",
1235
1257
  "resendUserInvitation",
1258
+ "sendUserPasswordReset",
1236
1259
  "getGroupsForUser",
1237
1260
  "getGroups",
1238
1261
  "createGroup",
@@ -1243,6 +1266,7 @@ var API_LIST = [
1243
1266
  "createNavigation",
1244
1267
  "getNavigation",
1245
1268
  "verifyEmailWithToken",
1269
+ "requestPasswordReset",
1246
1270
  "checkInviteToken",
1247
1271
  "activateUser",
1248
1272
  "rejectInvite",
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  API_LIST
4
- } from "./chunk-YSFRKKRY.js";
4
+ } from "./chunk-VOOQ4GMS.js";
5
5
  import {
6
6
  DIM,
7
7
  GREEN,
@@ -0,0 +1,56 @@
1
+ #!/usr/bin/env node
2
+ import {
3
+ callApi
4
+ } from "./chunk-5ZFPCFKV.js";
5
+ import "./chunk-IOLKUHUB.js";
6
+ import "./chunk-M3M3C5WH.js";
7
+ import "./chunk-YHQA2AVG.js";
8
+ import "./chunk-7ZQ666ZQ.js";
9
+
10
+ // src/commands/apis/snapshot.ts
11
+ import { defineCommand } from "citty";
12
+ var snapshot_default = defineCommand({
13
+ meta: { name: "snapshot", description: "Snapshot API" },
14
+ args: {
15
+ operation: { type: "positional", description: "operationId to call", required: false },
16
+ param: { type: "string", alias: "p", description: "Parameter key=value" },
17
+ data: { type: "string", alias: "d", description: "Request body JSON" },
18
+ header: { type: "string", alias: "H", description: "Custom header" },
19
+ include: { type: "boolean", alias: "i", description: "Include response headers" },
20
+ definition: { type: "string", description: "Override OpenAPI spec file/URL" },
21
+ server: { type: "string", alias: "s", description: "Override server base URL" },
22
+ "use-dev": { type: "boolean", description: "Target dev environment" },
23
+ "use-staging": { type: "boolean", description: "Target staging environment" },
24
+ profile: { type: "string", description: "Use a named profile" },
25
+ token: { type: "string", alias: "t", description: "Bearer token" },
26
+ json: { type: "boolean", description: "Output raw JSON" },
27
+ verbose: { type: "boolean", alias: "v", description: "Verbose output" },
28
+ guided: { type: "boolean", description: "Prompt for all parameters interactively" },
29
+ interactive: { type: "boolean", description: "Interactive mode" },
30
+ jsonata: { type: "string", description: "JSONata expression to transform response" },
31
+ _ophelp: { type: "boolean", description: "Show operation help", required: false },
32
+ _apihelp: { type: "boolean", description: "Show API help", required: false }
33
+ },
34
+ run: ({ args, rawArgs }) => {
35
+ const positionalArgs = [];
36
+ if (args.operation && rawArgs) {
37
+ const opIdx = rawArgs.indexOf(args.operation);
38
+ if (opIdx >= 0) {
39
+ for (let i = opIdx + 1; i < rawArgs.length; i++) {
40
+ const arg = rawArgs[i];
41
+ if (arg.startsWith("-")) break;
42
+ positionalArgs.push(arg);
43
+ }
44
+ }
45
+ }
46
+ return callApi("snapshot", {
47
+ ...args,
48
+ help: !!args._ophelp,
49
+ _apihelp: !!args._apihelp,
50
+ _args: positionalArgs
51
+ });
52
+ }
53
+ });
54
+ export {
55
+ snapshot_default as default
56
+ };
@@ -72,7 +72,7 @@ ${GREEN}${BOLD}Upgraded to @epilot/cli@${latest}${RESET}
72
72
  }
73
73
  });
74
74
  var getCurrentVersion = () => {
75
- if (true) return "0.1.46";
75
+ if (true) return "0.1.47";
76
76
  try {
77
77
  const output = execSync("npm ls -g @epilot/cli --depth=0 --json 2>/dev/null", {
78
78
  encoding: "utf-8",