ankka-console 0.11.0 → 0.12.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.
@@ -44,6 +44,30 @@ export const whoamiSchema = z.object({
44
44
  platformAdmin: z.boolean().default(false),
45
45
  organizations: z.array(organizationMembershipSchema).default([]),
46
46
  });
47
+ /** The installation's cloud: its provider, account and location, and its key for an owner alone. */
48
+ export const cloudInstallationSchema = z.object({
49
+ provider: z.string(),
50
+ account: z.string(),
51
+ location: z.string(),
52
+ kmsKey: optional(z.string()),
53
+ });
54
+ /** Where the installation keeps its secrets, and how long the record of reads is kept (feature 038). */
55
+ export const installationSecretsSchema = z.object({
56
+ backend: z.string(),
57
+ recordRetention: z.string(),
58
+ auditLog: z.string().default("unknown"),
59
+ });
60
+ /**
61
+ * `GET /installation`: the platform's version, and its cloud when it names a provider; and its
62
+ * backups (feature 041); and where it keeps its secrets (feature 038).
63
+ */
64
+ export const installationSchema = z.object({
65
+ platformVersion: z.string(),
66
+ cloud: optional(cloudInstallationSchema),
67
+ // Lazily: its schema is with the other backup schemas, below.
68
+ backups: optional(z.lazy(() => installationStatusSchema)),
69
+ secrets: optional(installationSecretsSchema),
70
+ });
47
71
  export const quotaSchema = z.object({
48
72
  projects: optional(z.number().int()),
49
73
  services: optional(z.number().int()),
@@ -95,6 +119,35 @@ export const mountStatusSchema = z.object({
95
119
  service: z.string(),
96
120
  state: z.string().default(""),
97
121
  });
122
+ /** One name in a move of a service's secrets to Secret Manager, and how the two compare. */
123
+ export const secretMoveNameSchema = z.object({ name: z.string(), state: z.string() });
124
+ /** What a move of a service's secrets did when its instance started; names and states, never a value. */
125
+ export const secretMoveReportSchema = z.object({
126
+ phase: z.string(),
127
+ outcome: z.string(),
128
+ names: z.array(secretMoveNameSchema).default([]),
129
+ detail: optional(z.string()),
130
+ });
131
+ /** Where a service's instance keeps its secrets, and what a move of them did. */
132
+ export const secretStoreReportSchema = z.object({
133
+ backend: z.string(),
134
+ keyRead: z.boolean(),
135
+ move: optional(secretMoveReportSchema),
136
+ });
137
+ /** A DNS record a member creates at their provider; the platform writes none. */
138
+ export const dnsRecordSchema = z.object({
139
+ name: z.string(),
140
+ kind: z.string(),
141
+ value: z.string(),
142
+ });
143
+ /** One custom hostname of a service: where it stands, and the record that points it at the installation. */
144
+ export const customHostnameSchema = z.object({
145
+ hostname: z.string(),
146
+ state: z.string().default("pending"),
147
+ reason: optional(z.string()),
148
+ record: optional(dnsRecordSchema),
149
+ note: optional(z.string()),
150
+ });
98
151
  export const serviceStatusSchema = z.object({
99
152
  name: z.string(),
100
153
  projectId: z.string(),
@@ -118,13 +171,45 @@ export const serviceStatusSchema = z.object({
118
171
  broker: optional(z.string()),
119
172
  /** Topics the service's components use that its project does not declare; absent when not read. */
120
173
  undeclaredTopics: optional(z.array(z.string())),
174
+ /** Where the service keeps its secrets, and what a move of them did, from its instances; absent when not read. */
175
+ secretStore: optional(secretStoreReportSchema),
121
176
  /** Each side the service takes on a declared topic with a contract, checked against it; absent when not read. */
122
177
  topicChecks: optional(z.array(z.lazy(() => topicCheckSchema))),
123
178
  /** Each topic source of the service with how far behind it is, from its instances; absent when not read. */
124
179
  topicSources: optional(z.array(z.lazy(() => topicSourceReportSchema))),
180
+ /** What a member should know and need not act on, worked out from the project's declarations now. */
181
+ warnings: optional(z.array(z.lazy(() => serviceWarningSchema))),
125
182
  objectStorage: optional(z.string()),
126
183
  bucket: optional(z.string()),
127
184
  bucketAddress: optional(z.string()),
185
+ /** Which store the bucket is in, `garage` or `gcs`, as the operator reported it. */
186
+ objectStore: optional(z.string()),
187
+ /** The bucket's location, in Google Cloud Storage. */
188
+ bucketLocation: optional(z.string()),
189
+ /** How many days the bucket keeps a deleted object, in Google Cloud Storage. */
190
+ softDeleteDays: optional(z.number().int()),
191
+ /** Where a move of the bucket from Garage is, as a phrase; its detail is in `detail`. */
192
+ storageMove: optional(z.string()),
193
+ /** The project database cluster the service is on, when a member switched it to a restore. */
194
+ databaseCluster: optional(z.string()),
195
+ /** `mounted` when the service's instances read their project's grants (feature 040). */
196
+ grants: optional(z.string()),
197
+ /** Each other project's topic the service uses, and whether that project grants it; absent when not read. */
198
+ crossProjectTopics: optional(z.array(z.lazy(() => crossProjectTopicSchema))),
199
+ /** Names under domains the project's owner brings, served beside the derived hostname. */
200
+ customHostnames: z.array(customHostnameSchema).default([]),
201
+ /** The TXT record that proves the project controls a name it brings; on a read of one service. */
202
+ proofRecord: optional(dnsRecordSchema),
203
+ });
204
+ /** `POST /services/{project}/{name}/storage/move`: how long the service's writes may be paused. */
205
+ export const storageMoveRequestSchema = z.object({ writePauseBound: optional(z.string()) });
206
+ /** `PUT /projects/{id}/location`. */
207
+ export const setProjectLocationSchema = z.object({ location: z.string() });
208
+ export const crossProjectTopicSchema = z.object({
209
+ project: z.string(),
210
+ topic: z.string(),
211
+ right: z.string(),
212
+ status: z.string(),
128
213
  });
129
214
  export const historyActorSchema = z.object({
130
215
  subject: z.string(),
@@ -139,8 +224,12 @@ export const historyEntrySchema = z.object({
139
224
  /** On an entry that recorded a descriptor: its image, and a digest two such entries share exactly when the descriptors are the same. */
140
225
  image: optional(z.string()),
141
226
  digest: optional(z.string()),
227
+ /** On a custom hostname's entry: the name it added or removed. */
228
+ hostname: optional(z.string()),
142
229
  /** On a rollback: the generation whose descriptor was applied again. */
143
230
  rolledBackTo: optional(z.number().int()),
231
+ /** What else the entry says: for a switch, which cluster the service left and which it is on. */
232
+ detail: optional(z.string()),
144
233
  });
145
234
  export const rollbackRequestSchema = z.object({ generation: optional(z.number().int()) });
146
235
  export const rolledBackSchema = z.object({ rolledBackTo: z.number().int(), status: serviceStatusSchema });
@@ -290,12 +379,37 @@ export const topicCheckSchema = z.object({
290
379
  });
291
380
  /**
292
381
  * `PUT /projects/{id}/topics/{name}`: the partitions a declared topic has, whether the broker keeps
293
- * only the last message under each key, and the contract it carries with its schema document.
382
+ * only the last message under each key, and the contract it carries with its schema document; and
383
+ * how long it keeps, how it is cleaned and how many copies it has, each in the words a member types.
384
+ * A new topic needs its partitions and takes every setting left out from the installation; a topic
385
+ * already declared keeps what is left out. `removes` restates what a change that removes messages
386
+ * removes, in the control plane's own words.
294
387
  */
295
388
  export const topicDeclarationRequestSchema = z.object({
296
- partitions: z.number().int(),
389
+ partitions: optional(z.number().int()),
297
390
  compacted: z.boolean().default(false),
298
391
  contract: optional(z.object({ name: z.string(), schema: z.unknown() })),
392
+ retention: optional(z.string()),
393
+ retentionSize: optional(z.string()),
394
+ cleanup: optional(z.string()),
395
+ tombstoneWindow: optional(z.string()),
396
+ minCompactionLag: optional(z.string()),
397
+ maxCompactionLag: optional(z.string()),
398
+ copies: optional(z.number().int()),
399
+ minInSync: optional(z.number().int()),
400
+ removes: optional(z.string()),
401
+ });
402
+ /** A declared topic's every setting in words, and the ones the installation supplied. */
403
+ export const topicSettingsViewSchema = z.object({
404
+ retention: z.string(),
405
+ retentionSize: z.string(),
406
+ cleanup: z.string(),
407
+ tombstoneWindow: z.string(),
408
+ minCompactionLag: z.string(),
409
+ maxCompactionLag: z.string(),
410
+ copies: optional(z.number().int()),
411
+ minInSync: optional(z.number().int()),
412
+ defaulted: z.array(z.string()).default([]),
299
413
  });
300
414
  /** A topic a project declares, and how far the platform has got with it. */
301
415
  export const projectTopicSchema = z.object({
@@ -306,6 +420,37 @@ export const projectTopicSchema = z.object({
306
420
  compacted: z.boolean().default(false),
307
421
  contract: optional(contractSchema),
308
422
  checks: z.array(topicCheckSchema).default([]),
423
+ settings: optional(topicSettingsViewSchema),
424
+ /** How many copies the broker holds, as the operator last saw. */
425
+ copiesHeld: optional(z.number().int()),
426
+ /** How many broker nodes the installation's broker has. */
427
+ brokerNodes: optional(z.number().int()),
428
+ });
429
+ /** One setting a declaration changed, from what to what. */
430
+ export const settingChangeSchema = z.object({
431
+ setting: z.string(),
432
+ from: z.string(),
433
+ to: z.string(),
434
+ });
435
+ /** Where a partition begins on the broker, and when that message was published. */
436
+ export const partitionGapReportSchema = z.object({
437
+ partition: z.number().int(),
438
+ beginning: z.number().int(),
439
+ earliestRetained: optional(z.string()),
440
+ });
441
+ /** What a topic source's topic no longer holds, per partition, and whether earlier messages are gone. */
442
+ export const retentionGapReportSchema = z.object({
443
+ partitions: z.array(partitionGapReportSchema),
444
+ compacted: z.boolean().default(false),
445
+ gone: z.boolean().default(false),
446
+ readAt: optional(z.string()),
447
+ });
448
+ /** Something about a service a member should know: a view over a topic that keeps too little. */
449
+ export const serviceWarningSchema = z.object({
450
+ kind: z.string(),
451
+ component: z.string(),
452
+ topic: z.string(),
453
+ message: z.string(),
309
454
  });
310
455
  /**
311
456
  * A topic source as a service's instances report it: what reads which topic under which group, the
@@ -325,6 +470,8 @@ export const topicSourceReportSchema = z.object({
325
470
  contract: optional(z.string()),
326
471
  lag: optional(z.number().int()),
327
472
  failing: optional(z.string()),
473
+ /** What the broker still holds of the topic, per partition. */
474
+ gap: optional(retentionGapReportSchema),
328
475
  });
329
476
  /** `PUT /projects/{id}/brokers/{name}`: a broker declared beside the installation's, and how it is reached. */
330
477
  export const brokerDeclarationRequestSchema = z.object({
@@ -347,11 +494,262 @@ export const projectSecretSummarySchema = z.object({
347
494
  setAt: optional(z.string()),
348
495
  setBy: optional(z.string()),
349
496
  });
497
+ /** The record of one read, keep or removal of a service secret: never its value. */
498
+ export const readRecordSchema = z.object({
499
+ at: z.string(),
500
+ project: z.string(),
501
+ service: z.string(),
502
+ hosting: z.string(),
503
+ name: z.string(),
504
+ operation: z.string(),
505
+ outcome: z.string(),
506
+ backend: z.string(),
507
+ traceId: optional(z.string()),
508
+ spanId: optional(z.string()),
509
+ component: optional(z.string()),
510
+ componentKind: optional(z.string()),
511
+ latestSkipped: z.boolean().default(false),
512
+ });
513
+ /** The record of a project's secret reads, newest first, as an owner reads it. */
514
+ export const secretReadsPageSchema = z.object({ records: z.array(readRecordSchema).default([]) });
515
+ // ── Backups and recovery (feature 041) ──────────────────────────────────────
516
+ /** One line of history's backups: `phase` is `backing up`, `failing` or `not backed up`. */
517
+ export const backupLineSchema = z.object({
518
+ line: z.string(),
519
+ cluster: z.string(),
520
+ phase: z.string(),
521
+ lastBaseBackup: optional(z.string()),
522
+ firstRestorable: optional(z.string()),
523
+ lastRestorable: optional(z.string()),
524
+ archiveLagSeconds: optional(z.number()),
525
+ failing: optional(z.string()),
526
+ copiedAt: optional(z.string()),
527
+ });
528
+ export const projectDatabaseSchema = z.object({
529
+ cluster: z.string(),
530
+ instances: z.number().int(),
531
+ readyInstances: z.number().int(),
532
+ primary: optional(z.string()),
533
+ synchronous: z.boolean().default(false),
534
+ writesWaitingOn: optional(z.string()),
535
+ });
536
+ /** One of the project's database clusters: `live`, a `restore`, or `left` once every service has left it. */
537
+ export const projectClusterSchema = z.object({
538
+ name: z.string(),
539
+ line: z.string(),
540
+ phase: z.string(),
541
+ services: z.array(z.string()).default([]),
542
+ since: optional(z.string()),
543
+ leftAt: optional(z.string()),
544
+ });
545
+ /** What one service's database holds in a restore or a rehearsal; secrets by name only. */
546
+ export const serviceVerificationSchema = z.object({
547
+ name: z.string(),
548
+ present: z.boolean(),
549
+ journalRows: z.number().int().default(0),
550
+ stateRows: z.number().int().default(0),
551
+ offsetRows: z.number().int().default(0),
552
+ timerRows: z.number().int().default(0),
553
+ highestSequence: z.number().int().default(0),
554
+ changedSecrets: z.array(z.string()).default([]),
555
+ });
556
+ /** A topic past a restore's moment: messages newer than it, and how many of them a group has read. */
557
+ export const topicDivergenceSchema = z.object({
558
+ topic: z.string(),
559
+ group: optional(z.string()),
560
+ after: z.number().int().default(0),
561
+ read: optional(z.number().int()),
562
+ services: z.array(z.string()).default([]),
563
+ });
564
+ /** A restore: `Restoring`, `Verified`, `Failed` or `InUse`, with what each service's database holds. */
565
+ export const restoreViewSchema = z.object({
566
+ name: z.string(),
567
+ line: z.string(),
568
+ moment: z.string(),
569
+ phase: z.string(),
570
+ requestedBy: optional(z.string()),
571
+ requestedAt: optional(z.string()),
572
+ reachedAt: optional(z.string()),
573
+ services: z.array(serviceVerificationSchema).default([]),
574
+ detail: optional(z.string()),
575
+ broker: z.array(topicDivergenceSchema).default([]),
576
+ notAsked: z.array(z.string()).default([]),
577
+ note: optional(z.string()),
578
+ });
579
+ /** A rehearsal: `Running`, `Completed`, `Failed` or `NotRemoved`, and how long it took. */
580
+ export const rehearsalViewSchema = z.object({
581
+ name: z.string(),
582
+ line: z.string(),
583
+ moment: z.string(),
584
+ outcome: z.string(),
585
+ requestedBy: optional(z.string()),
586
+ requestedAt: optional(z.string()),
587
+ elapsedSeconds: optional(z.number().int()),
588
+ detail: optional(z.string()),
589
+ services: z.array(serviceVerificationSchema).default([]),
590
+ });
591
+ export const projectStatusSchema = z.object({
592
+ id: z.string(),
593
+ backedUp: z.boolean(),
594
+ target: z.string(),
595
+ lines: z.array(backupLineSchema).default([]),
596
+ database: optional(projectDatabaseSchema),
597
+ detail: optional(z.string()),
598
+ clusters: z.array(projectClusterSchema).default([]),
599
+ restores: z.array(restoreViewSchema).default([]),
600
+ rehearsal: optional(rehearsalViewSchema),
601
+ });
602
+ export const secondaryStoreSchema = z.object({
603
+ lastCompleted: optional(z.string()),
604
+ lastFailed: optional(z.string()),
605
+ failure: optional(z.string()),
606
+ buckets: optional(z.number().int()),
607
+ deletedObjects: optional(z.number().int()),
608
+ });
609
+ export const installationStatusSchema = z.object({
610
+ backupTarget: z.string(),
611
+ retentionDays: z.number().int(),
612
+ copyRequired: z.boolean(),
613
+ sharesFailureDomain: z.boolean(),
614
+ encryption: z.string(),
615
+ controlPlane: optional(backupLineSchema),
616
+ notBackedUp: optional(z.string()),
617
+ secondaryStore: optional(secondaryStoreSchema),
618
+ });
619
+ export const serviceDifferenceSchema = z.object({
620
+ project: z.string(),
621
+ service: z.string(),
622
+ recordedGeneration: optional(z.number().int()),
623
+ clusterGeneration: optional(z.number().int()),
624
+ recordedImage: optional(z.string()),
625
+ clusterImage: optional(z.string()),
626
+ });
627
+ /** Whether the control plane is held after its own database was restored, and what differs. */
628
+ export const restoreHoldStatusSchema = z.object({
629
+ held: z.boolean(),
630
+ restoredAt: optional(z.string()),
631
+ targetTime: optional(z.string()),
632
+ releasedAt: optional(z.string()),
633
+ releasedBy: optional(z.string()),
634
+ services: z.array(serviceDifferenceSchema).default([]),
635
+ topics: z.array(z.string()).default([]),
636
+ unknownProjects: z.array(z.string()).default([]),
637
+ reconciled: z.array(z.string()).default([]),
638
+ });
639
+ /** `POST /projects/{id}/restores`: the moment, and the line when services are on more than one. */
640
+ export const restoreRequestSchema = z.object({ moment: z.string(), line: optional(z.string()) });
641
+ /** `POST /services/{p}/{n}/switch`: the cluster to move the service to. */
642
+ export const switchRequestSchema = z.object({ cluster: z.string() });
643
+ /** `POST /projects/{id}/rehearsals`: both may be left out, for the latest restorable moment. */
644
+ export const rehearsalRequestSchema = z.object({ moment: optional(z.string()), line: optional(z.string()) });
645
+ export const credentialReissuedSchema = z.object({ project: z.string(), generation: z.number().int() });
646
+ /** What a project asks of its database, whole. */
647
+ export const databaseSettingSchema = z.object({
648
+ replicas: z.number().int().default(0),
649
+ synchronous: z.boolean().default(false),
650
+ retentionDays: optional(z.number().int()),
651
+ rehearse: optional(z.string()),
652
+ });
653
+ /**
654
+ * Who did what to a project: to its database, or to the topic `topic` names, with each setting it
655
+ * changed (feature 043).
656
+ */
657
+ export const projectHistoryViewSchema = z.object({
658
+ kind: z.string(),
659
+ by: optional(z.string()),
660
+ at: optional(z.string()),
661
+ detail: optional(z.string()),
662
+ topic: optional(z.string()),
663
+ changes: z.array(settingChangeSchema).default([]),
664
+ });
665
+ // ── Grants and machines (feature 040) ───────────────────────────────────────
666
+ /** What a grant opens: one route, one gRPC method, one topic with one right, or the erasure. */
667
+ export const grantTargetSchema = z.object({
668
+ kind: z.string(),
669
+ service: optional(z.string()),
670
+ method: optional(z.string()),
671
+ path: optional(z.string()),
672
+ topic: optional(z.string()),
673
+ right: optional(z.string()),
674
+ decrypt: z.boolean().default(false),
675
+ });
676
+ /** Who did something to a grant, and when. */
677
+ export const grantActSchema = z.object({
678
+ by: optional(z.string()),
679
+ at: optional(z.string()),
680
+ });
681
+ export const grantRequestSchema = z.object({
682
+ grantee: z.string(),
683
+ target: grantTargetSchema,
684
+ });
685
+ /** A grant as its project lists it; `effect` is `in effect`, or why not. */
686
+ export const grantDetailSchema = z.object({
687
+ id: z.string(),
688
+ grantee: z.string(),
689
+ target: grantTargetSchema,
690
+ state: z.string(),
691
+ effect: z.string(),
692
+ granted: grantActSchema,
693
+ answered: optional(grantActSchema),
694
+ ended: optional(grantActSchema),
695
+ });
696
+ export const grantChangeRecordSchema = z.object({
697
+ change: z.string(),
698
+ by: optional(z.string()),
699
+ at: optional(z.string()),
700
+ });
701
+ export const topicSettingsSchema = z.object({
702
+ partitions: z.number().int(),
703
+ compacted: z.boolean().default(false),
704
+ retention: optional(z.string()),
705
+ copies: optional(z.number().int()),
706
+ });
707
+ /** A grant as its grantee's side records it. */
708
+ export const receivedGrantDetailSchema = z.object({
709
+ id: z.string(),
710
+ grantingProject: z.string(),
711
+ grantingOrganization: z.string(),
712
+ grantee: z.string(),
713
+ target: grantTargetSchema,
714
+ state: z.string(),
715
+ changes: z.array(grantChangeRecordSchema).default([]),
716
+ topic: optional(topicSettingsSchema),
717
+ });
718
+ export const machineRegistrationSchema = z.object({ name: z.string() });
719
+ /** A machine just registered: its secret, shown this once. */
720
+ export const machineRegisteredSchema = z.object({
721
+ name: z.string(),
722
+ clientId: z.string(),
723
+ clientSecret: z.string(),
724
+ tokenUrl: z.string(),
725
+ brokerBootstrap: optional(z.string()),
726
+ });
727
+ export const byteRatesRequestSchema = z.object({
728
+ produceBytesPerSecond: z.number().int(),
729
+ consumeBytesPerSecond: z.number().int(),
730
+ requestPercentage: z.number().int(),
731
+ });
732
+ export const machineSummarySchema = z.object({
733
+ name: z.string(),
734
+ clientId: z.string(),
735
+ registeredBy: optional(z.string()),
736
+ registeredAt: optional(z.string()),
737
+ byteRates: optional(byteRatesRequestSchema),
738
+ });
739
+ export const tokenResponseSchema = z.object({
740
+ access_token: z.string(),
741
+ token_type: z.string(),
742
+ expires_in: z.number().int(),
743
+ });
744
+ export const jsonWebKeySetSchema = z.object({
745
+ keys: z.array(z.object({ kty: z.string(), use: z.string(), alg: z.string(), kid: z.string(), n: z.string(), e: z.string() })),
746
+ });
350
747
  /** Every schema by the Scala type's name, as the fixture files name them. */
351
748
  export const schemasByType = {
352
749
  AuthDiscovery: authDiscoverySchema,
353
750
  OrganizationMembership: organizationMembershipSchema,
354
751
  Whoami: whoamiSchema,
752
+ Installation: installationSchema,
355
753
  Quota: quotaSchema,
356
754
  Usage: usageSchema,
357
755
  OrganizationDetail: organizationDetailSchema,
@@ -364,6 +762,8 @@ export const schemasByType = {
364
762
  HistoryActor: historyActorSchema,
365
763
  HistoryEntry: historyEntrySchema,
366
764
  RollbackRequest: rollbackRequestSchema,
765
+ StorageMoveRequest: storageMoveRequestSchema,
766
+ SetProjectLocation: setProjectLocationSchema,
367
767
  RolledBack: rolledBackSchema,
368
768
  InstanceLogs: instanceLogsSchema,
369
769
  LogsResponse: logsResponseSchema,
@@ -392,4 +792,25 @@ export const schemasByType = {
392
792
  Contract: contractSchema,
393
793
  BrokerDeclarationRequest: brokerDeclarationRequestSchema,
394
794
  ProjectBroker: projectBrokerSchema,
795
+ SecretReadsPage: secretReadsPageSchema,
796
+ ProjectStatus: projectStatusSchema,
797
+ InstallationStatus: installationStatusSchema,
798
+ RestoreRequest: restoreRequestSchema,
799
+ RestoreView: restoreViewSchema,
800
+ SwitchRequest: switchRequestSchema,
801
+ ProjectHistoryView: projectHistoryViewSchema,
802
+ DatabaseSetting: databaseSettingSchema,
803
+ RehearsalRequest: rehearsalRequestSchema,
804
+ RehearsalView: rehearsalViewSchema,
805
+ RestoreHoldStatus: restoreHoldStatusSchema,
806
+ CredentialReissued: credentialReissuedSchema,
807
+ GrantRequest: grantRequestSchema,
808
+ GrantDetail: grantDetailSchema,
809
+ ReceivedGrantDetail: receivedGrantDetailSchema,
810
+ MachineRegistration: machineRegistrationSchema,
811
+ MachineRegistered: machineRegisteredSchema,
812
+ MachineSummary: machineSummarySchema,
813
+ ByteRatesRequest: byteRatesRequestSchema,
814
+ TokenResponse: tokenResponseSchema,
815
+ JsonWebKeySet: jsonWebKeySetSchema,
395
816
  };
package/dist/context.d.ts CHANGED
@@ -70,7 +70,7 @@ export interface ActionRefusal {
70
70
  export declare function act<T>(ctx: ConsoleContext, intent: string, form: FormData, work: () => Promise<T>): Promise<T | ReturnType<typeof data<ActionRefusal>>>;
71
71
  export declare const text: (form: FormData, name: string) => string;
72
72
  /** The rail's areas, in the order it shows them. */
73
- export declare const areas: readonly ["organizations", "projects", "services", "members", "tokens"];
73
+ export declare const areas: readonly ["organizations", "projects", "services", "members", "tokens", "machines"];
74
74
  export type Area = (typeof areas)[number];
75
75
  export interface Crumb {
76
76
  label: string;
package/dist/context.js CHANGED
@@ -144,7 +144,7 @@ export const text = (form, name) => {
144
144
  return typeof v === "string" ? v.trim() : "";
145
145
  };
146
146
  /** The rail's areas, in the order it shows them. */
147
- export const areas = ["organizations", "projects", "services", "members", "tokens"];
147
+ export const areas = ["organizations", "projects", "services", "members", "tokens", "machines"];
148
148
  const byName = (a, b) => a.name.localeCompare(b.name);
149
149
  /** The listing of a project's services, in name order, marking the one being read. */
150
150
  export function servicesListing(project, services, current) {
@@ -1,7 +1,7 @@
1
1
  import type { ComponentType } from "react";
2
2
  import type { OrganizationSummary, ProjectDetail, ServiceStatus } from "../client/schemas.ts";
3
3
  /** Every operation the console offers, by the name a host uses to add beside it or hide it. */
4
- export declare const operations: readonly ["organization.create", "organization.rename", "organization.delete", "organization.disable", "organization.enable", "organization.quota.set", "organization.quota.clear", "member.invite", "member.role", "member.remove", "invitation.withdraw", "member.repair", "token.create", "token.revoke", "project.create", "project.rename", "project.delete", "registry.set", "registry.clear", "project-secret.set", "project-secret.unset", "project-topic.set", "project-topic.unset", "project-broker.set", "project-broker.unset", "service.apply", "service.pause", "service.resume", "service.restart", "service.rollback", "service.expose", "service.unexpose", "service.delete", "service.logs"];
4
+ export declare const operations: readonly ["organization.create", "organization.rename", "organization.delete", "organization.disable", "organization.enable", "organization.quota.set", "organization.quota.clear", "member.invite", "member.role", "member.remove", "invitation.withdraw", "member.repair", "token.create", "token.revoke", "machine.register", "machine.delete", "machine.byte-rates", "project.create", "project.rename", "project.delete", "registry.set", "registry.clear", "project-secret.set", "project-secret.unset", "project-topic.set", "project-topic.unset", "project-broker.set", "project-broker.unset", "project.restore", "project.rehearse", "project.database", "project.backup-credential", "installation.release", "service.switch", "grant.make", "grant.end", "grant.answer", "grant.relinquish", "service.apply", "service.pause", "service.resume", "service.restart", "service.rollback", "service.expose", "service.unexpose", "service-hostname.add", "service-hostname.remove", "service.delete", "service.logs", "service.storage-credential", "service.storage-move", "service.storage-settings", "project-location.set", "project-location.clear"];
5
5
  export type Operation = (typeof operations)[number];
6
6
  export interface PanelEntities {
7
7
  organization: OrganizationSummary;
@@ -14,6 +14,9 @@ export const operations = [
14
14
  "member.repair",
15
15
  "token.create",
16
16
  "token.revoke",
17
+ "machine.register",
18
+ "machine.delete",
19
+ "machine.byte-rates",
17
20
  "project.create",
18
21
  "project.rename",
19
22
  "project.delete",
@@ -25,6 +28,18 @@ export const operations = [
25
28
  "project-topic.unset",
26
29
  "project-broker.set",
27
30
  "project-broker.unset",
31
+ "project.restore",
32
+ "project.rehearse",
33
+ "project.database",
34
+ "project.backup-credential",
35
+ "installation.release",
36
+ "service.switch",
37
+ "grant.make",
38
+ "grant.end",
39
+ // An owner of the grantee's side accepting or declining a pending grant, and giving one up: the
40
+ // organization page's "Offered grants" card.
41
+ "grant.answer",
42
+ "grant.relinquish",
28
43
  "service.apply",
29
44
  "service.pause",
30
45
  "service.resume",
@@ -32,6 +47,13 @@ export const operations = [
32
47
  "service.rollback",
33
48
  "service.expose",
34
49
  "service.unexpose",
50
+ "service-hostname.add",
51
+ "service-hostname.remove",
35
52
  "service.delete",
36
53
  "service.logs",
54
+ "service.storage-credential",
55
+ "service.storage-move",
56
+ "service.storage-settings",
57
+ "project-location.set",
58
+ "project-location.clear",
37
59
  ];
@@ -1,8 +1,9 @@
1
1
  /**
2
2
  * The front page: who you are, as the control plane sees you, and the organizations you can see —
3
- * yours with your role in each, or every one of them for a platform administrator.
3
+ * yours with your role in each, or every one of them for a platform administrator — and what the
4
+ * installation is: its version, and its cloud when it names one (feature 044).
4
5
  */
5
- import { type LoaderFunctionArgs, type MetaFunction } from "react-router";
6
+ import { type ActionFunctionArgs, type LoaderFunctionArgs, type MetaFunction } from "react-router";
6
7
  import { ConsoleErrorBoundary } from "../ui/errors.tsx";
7
8
  export declare const meta: MetaFunction;
8
9
  export declare function loader({ context }: LoaderFunctionArgs): Promise<{
@@ -36,6 +37,65 @@ export declare function loader({ context }: LoaderFunctionArgs): Promise<{
36
37
  instances: number;
37
38
  };
38
39
  }[];
40
+ installation: {
41
+ platformVersion: string;
42
+ cloud: {
43
+ provider: string;
44
+ account: string;
45
+ location: string;
46
+ kmsKey: string | undefined;
47
+ } | undefined;
48
+ backups: {
49
+ backupTarget: string;
50
+ retentionDays: number;
51
+ copyRequired: boolean;
52
+ sharesFailureDomain: boolean;
53
+ encryption: string;
54
+ controlPlane: {
55
+ line: string;
56
+ cluster: string;
57
+ phase: string;
58
+ lastBaseBackup: string | undefined;
59
+ firstRestorable: string | undefined;
60
+ lastRestorable: string | undefined;
61
+ archiveLagSeconds: number | undefined;
62
+ failing: string | undefined;
63
+ copiedAt: string | undefined;
64
+ } | undefined;
65
+ notBackedUp: string | undefined;
66
+ secondaryStore: {
67
+ lastCompleted: string | undefined;
68
+ lastFailed: string | undefined;
69
+ failure: string | undefined;
70
+ buckets: number | undefined;
71
+ deletedObjects: number | undefined;
72
+ } | undefined;
73
+ } | undefined;
74
+ secrets: {
75
+ backend: string;
76
+ recordRetention: string;
77
+ auditLog: string;
78
+ } | undefined;
79
+ };
80
+ hold: {
81
+ held: boolean;
82
+ restoredAt: string | undefined;
83
+ targetTime: string | undefined;
84
+ releasedAt: string | undefined;
85
+ releasedBy: string | undefined;
86
+ services: {
87
+ project: string;
88
+ service: string;
89
+ recordedGeneration: number | undefined;
90
+ clusterGeneration: number | undefined;
91
+ recordedImage: string | undefined;
92
+ clusterImage: string | undefined;
93
+ }[];
94
+ topics: string[];
95
+ unknownProjects: string[];
96
+ reconciled: string[];
97
+ } | undefined;
39
98
  }>;
99
+ export declare function action({ request, context }: ActionFunctionArgs): Promise<import("react-router").UNSAFE_DataWithResponseInit<import("../context.ts").ActionRefusal> | Response>;
40
100
  export default function Front(): import("react").JSX.Element;
41
101
  export declare const ErrorBoundary: typeof ConsoleErrorBoundary;