@junobuild/cli 0.13.10 → 0.13.12

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@junobuild/cli",
3
- "version": "0.13.10",
3
+ "version": "0.13.12",
4
4
  "description": "The Juno command-line interface",
5
5
  "author": "David Dal Busco (https://daviddalbusco.com)",
6
6
  "license": "MIT",
@@ -33,16 +33,16 @@
33
33
  "@dfinity/zod-schemas": "^3.0.2",
34
34
  "@icp-sdk/canisters": "^3.3.0",
35
35
  "@icp-sdk/core": "^5.0.0",
36
- "@junobuild/admin": "^3.3.0",
37
- "@junobuild/cdn": "^2.2.0",
38
- "@junobuild/cli-tools": "^0.10.0",
39
- "@junobuild/config": "^2.9.0",
40
- "@junobuild/config-loader": "^0.4.7",
41
- "@junobuild/core": "^3.4.0",
42
- "@junobuild/did-tools": "^0.3.8",
43
- "@junobuild/ic-client": "^7.1.0",
44
- "@junobuild/storage": "^2.2.0",
45
- "@junobuild/utils": "^0.2.5",
36
+ "@junobuild/admin": "^4.1.0",
37
+ "@junobuild/cdn": "^2.3.0",
38
+ "@junobuild/cli-tools": "^0.10.2",
39
+ "@junobuild/config": "^2.11.0",
40
+ "@junobuild/config-loader": "^0.4.8",
41
+ "@junobuild/core": "^5.2.0",
42
+ "@junobuild/did-tools": "^0.3.9",
43
+ "@junobuild/ic-client": "^8.0.0",
44
+ "@junobuild/storage": "^2.3.0",
45
+ "@junobuild/utils": "^0.2.6",
46
46
  "chokidar": "^4.0.3",
47
47
  "conf": "^14.0.0",
48
48
  "open": "^11.0.0",
@@ -54,20 +54,19 @@
54
54
  "zod": "^4.3.5"
55
55
  },
56
56
  "devDependencies": {
57
- "@dfinity/internet-identity-playwright": "^2.0.0",
58
57
  "@eslint/eslintrc": "^3.3.3",
59
58
  "@eslint/js": "^9.39.2",
60
- "@junobuild/functions": "^0.5.4",
61
- "@playwright/test": "^1.57.0",
62
- "@types/node": "^25.0.3",
59
+ "@junobuild/functions": "^0.5.6",
60
+ "@playwright/test": "^1.58.1",
61
+ "@types/node": "24.10.9",
63
62
  "@types/prompts": "^2.4.9",
64
63
  "@types/semver": "^7.7.1",
65
64
  "esbuild": "^0.27.2",
66
65
  "eslint": "^9.39.2",
67
- "eslint-config-love": "^140.0.0",
66
+ "eslint-config-love": "^149.0.0",
68
67
  "eslint-config-prettier": "^10.1.8",
69
- "globals": "^17.0.0",
70
- "prettier": "^3.7.4",
68
+ "globals": "^17.2.0",
69
+ "prettier": "^3.8.1",
71
70
  "prettier-plugin-organize-imports": "^4.3.0",
72
71
  "typescript": "^5.9.3"
73
72
  },
@@ -12,7 +12,7 @@ ic-cdk = "0.19.0"
12
12
  ic-cdk-macros = "0.19.0"
13
13
  serde = "1.0.225"
14
14
  serde_cbor = "0.11.2"
15
- junobuild-satellite = "0.4.0"
15
+ junobuild-satellite = "0.5.0"
16
16
  junobuild-macros = "0.2.0"
17
17
  junobuild-utils = "0.2.0"
18
18
 
@@ -20,12 +20,25 @@ type AssetNoContent = record {
20
20
  version : opt nat64;
21
21
  };
22
22
  type AssetsUpgradeOptions = record { clear_existing_assets : opt bool };
23
+ type AuthenticateAutomationArgs = variant {
24
+ OpenId : OpenIdPrepareAutomationArgs;
25
+ };
26
+ type AuthenticateAutomationResultResponse = variant {
27
+ Ok : record { principal; AutomationController };
28
+ Err : AuthenticationAutomationError;
29
+ };
23
30
  type AuthenticateResultResponse = variant {
24
31
  Ok : Authentication;
25
32
  Err : AuthenticationError;
26
33
  };
27
34
  type Authentication = record { doc : Doc; delegation : PreparedDelegation };
28
35
  type AuthenticationArgs = variant { OpenId : OpenIdPrepareDelegationArgs };
36
+ type AuthenticationAutomationError = variant {
37
+ PrepareAutomation : PrepareAutomationError;
38
+ RegisterController : text;
39
+ SaveWorkflowMetadata : text;
40
+ SaveUniqueJtiToken : text;
41
+ };
29
42
  type AuthenticationConfig = record {
30
43
  updated_at : opt nat64;
31
44
  openid : opt AuthenticationConfigOpenId;
@@ -40,13 +53,31 @@ type AuthenticationConfigInternetIdentity = record {
40
53
  };
41
54
  type AuthenticationConfigOpenId = record {
42
55
  observatory_id : opt principal;
43
- providers : vec record { OpenIdProvider; OpenIdProviderConfig };
56
+ providers : vec record { OpenIdDelegationProvider; OpenIdAuthProviderConfig };
44
57
  };
45
58
  type AuthenticationError = variant {
46
59
  PrepareDelegation : PrepareDelegationError;
47
60
  RegisterUser : text;
48
61
  };
49
62
  type AuthenticationRules = record { allowed_callers : vec principal };
63
+ type AutomationConfig = record {
64
+ updated_at : opt nat64;
65
+ openid : opt AutomationConfigOpenId;
66
+ created_at : opt nat64;
67
+ version : opt nat64;
68
+ };
69
+ type AutomationConfigOpenId = record {
70
+ observatory_id : opt principal;
71
+ providers : vec record {
72
+ OpenIdAutomationProvider;
73
+ OpenIdAutomationProviderConfig;
74
+ };
75
+ };
76
+ type AutomationController = record {
77
+ scope : AutomationScope;
78
+ expires_at : nat64;
79
+ };
80
+ type AutomationScope = variant { Write; Submit };
50
81
  type CollectionType = variant { Db; Storage };
51
82
  type CommitBatch = record {
52
83
  batch_id : nat;
@@ -58,15 +89,18 @@ type Config = record {
58
89
  db : opt DbConfig;
59
90
  authentication : opt AuthenticationConfig;
60
91
  storage : StorageConfig;
92
+ automation : opt AutomationConfig;
61
93
  };
62
94
  type ConfigMaxMemorySize = record { stable : opt nat64; heap : opt nat64 };
63
95
  type Controller = record {
64
96
  updated_at : nat64;
65
97
  metadata : vec record { text; text };
98
+ kind : opt ControllerKind;
66
99
  created_at : nat64;
67
100
  scope : ControllerScope;
68
101
  expires_at : opt nat64;
69
102
  };
103
+ type ControllerKind = variant { Emulator; Automation };
70
104
  type ControllerScope = variant { Write; Admin; Submit };
71
105
  type CustomDomain = record {
72
106
  updated_at : nat64;
@@ -106,6 +140,7 @@ type GetDelegationError = variant {
106
140
  JwtVerify : JwtVerifyError;
107
141
  GetOrFetchJwks : GetOrRefreshJwksError;
108
142
  DeriveSeedFailed : text;
143
+ InvalidObservatoryId : text;
109
144
  };
110
145
  type GetDelegationResultResponse = variant {
111
146
  Ok : SignedDelegation;
@@ -210,33 +245,55 @@ type ListRulesResults = record {
210
245
  };
211
246
  type Memory = variant { Heap; Stable };
212
247
  type MemorySize = record { stable : nat64; heap : nat64 };
248
+ type OpenIdAuthProviderConfig = record {
249
+ delegation : opt OpenIdAuthProviderDelegationConfig;
250
+ client_id : text;
251
+ };
252
+ type OpenIdAuthProviderDelegationConfig = record {
253
+ targets : opt vec principal;
254
+ max_time_to_live : opt nat64;
255
+ };
256
+ type OpenIdAutomationProvider = variant { GitHub };
257
+ type OpenIdAutomationProviderConfig = record {
258
+ controller : opt OpenIdAutomationProviderControllerConfig;
259
+ repositories : vec record { RepositoryKey; OpenIdAutomationRepositoryConfig };
260
+ };
261
+ type OpenIdAutomationProviderControllerConfig = record {
262
+ scope : opt AutomationScope;
263
+ max_time_to_live : opt nat64;
264
+ };
265
+ type OpenIdAutomationRepositoryConfig = record { refs : opt vec text };
266
+ type OpenIdDelegationProvider = variant { GitHub; Google };
213
267
  type OpenIdGetDelegationArgs = record {
214
268
  jwt : text;
215
269
  session_key : blob;
216
270
  salt : blob;
217
271
  expiration : nat64;
218
272
  };
273
+ type OpenIdPrepareAutomationArgs = record { jwt : text; salt : blob };
219
274
  type OpenIdPrepareDelegationArgs = record {
220
275
  jwt : text;
221
276
  session_key : blob;
222
277
  salt : blob;
223
278
  };
224
- type OpenIdProvider = variant { Google };
225
- type OpenIdProviderConfig = record {
226
- delegation : opt OpenIdProviderDelegationConfig;
227
- client_id : text;
228
- };
229
- type OpenIdProviderDelegationConfig = record {
230
- targets : opt vec principal;
231
- max_time_to_live : opt nat64;
232
- };
233
279
  type Permission = variant { Controllers; Private; Public; Managed };
280
+ type PrepareAutomationError = variant {
281
+ JwtFindProvider : JwtFindProviderError;
282
+ InvalidController : text;
283
+ GetCachedJwks;
284
+ JwtVerify : JwtVerifyError;
285
+ GetOrFetchJwks : GetOrRefreshJwksError;
286
+ ControllerAlreadyExists;
287
+ InvalidObservatoryId : text;
288
+ TooManyControllers : text;
289
+ };
234
290
  type PrepareDelegationError = variant {
235
291
  JwtFindProvider : JwtFindProviderError;
236
292
  GetCachedJwks;
237
293
  JwtVerify : JwtVerifyError;
238
294
  GetOrFetchJwks : GetOrRefreshJwksError;
239
295
  DeriveSeedFailed : text;
296
+ InvalidObservatoryId : text;
240
297
  };
241
298
  type PreparedDelegation = record { user_key : blob; expiration : nat64 };
242
299
  type Proposal = record {
@@ -263,6 +320,7 @@ type ProposalType = variant {
263
320
  SegmentsDeployment : SegmentsDeploymentOptions;
264
321
  };
265
322
  type RateConfig = record { max_tokens : nat64; time_per_token_ns : nat64 };
323
+ type RepositoryKey = record { owner : text; name : text };
266
324
  type Rule = record {
267
325
  max_capacity : opt nat32;
268
326
  memory : opt Memory;
@@ -287,8 +345,13 @@ type SetAuthenticationConfig = record {
287
345
  internet_identity : opt AuthenticationConfigInternetIdentity;
288
346
  rules : opt AuthenticationRules;
289
347
  };
348
+ type SetAutomationConfig = record {
349
+ openid : opt AutomationConfigOpenId;
350
+ version : opt nat64;
351
+ };
290
352
  type SetController = record {
291
353
  metadata : vec record { text; text };
354
+ kind : opt ControllerKind;
292
355
  scope : ControllerScope;
293
356
  expires_at : opt nat64;
294
357
  };
@@ -373,6 +436,9 @@ type UploadChunk = record {
373
436
  type UploadChunkResult = record { chunk_id : nat };
374
437
  service : (InitSatelliteArgs) -> {
375
438
  authenticate : (AuthenticationArgs) -> (AuthenticateResultResponse);
439
+ authenticate_automation : (AuthenticateAutomationArgs) -> (
440
+ AuthenticateAutomationResultResponse,
441
+ );
376
442
  commit_asset_upload : (CommitBatch) -> ();
377
443
  commit_proposal : (CommitProposal) -> (null);
378
444
  commit_proposal_asset_upload : (CommitBatch) -> ();
@@ -384,6 +450,7 @@ service : (InitSatelliteArgs) -> {
384
450
  count_proposals : () -> (nat64) query;
385
451
  del_asset : (text, text) -> ();
386
452
  del_assets : (text) -> ();
453
+ del_controller_self : () -> ();
387
454
  del_controllers : (DeleteControllersArgs) -> (
388
455
  vec record { principal; Controller },
389
456
  );
@@ -399,6 +466,7 @@ service : (InitSatelliteArgs) -> {
399
466
  deposit_cycles : (DepositCyclesArgs) -> ();
400
467
  get_asset : (text, text) -> (opt AssetNoContent) query;
401
468
  get_auth_config : () -> (opt AuthenticationConfig) query;
469
+ get_automation_config : () -> (opt AutomationConfig) query;
402
470
  get_config : () -> (Config);
403
471
  get_db_config : () -> (opt DbConfig) query;
404
472
  get_delegation : (GetDelegationArgs) -> (GetDelegationResultResponse) query;
@@ -432,6 +500,7 @@ service : (InitSatelliteArgs) -> {
432
500
  reject_proposal : (CommitProposal) -> (null);
433
501
  set_asset_token : (text, text, opt text) -> ();
434
502
  set_auth_config : (SetAuthenticationConfig) -> (AuthenticationConfig);
503
+ set_automation_config : (SetAutomationConfig) -> (AutomationConfig);
435
504
  set_controllers : (SetControllersArgs) -> (
436
505
  vec record { principal; Controller },
437
506
  );