@sealant/api-contracts-next 0.40.0-next.879 → 0.40.0-next.880

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.
@@ -43,6 +43,55 @@ export declare const boatKeyNotObservedSchema: Schema.Struct<{
43
43
  }>>;
44
44
  }>;
45
45
  export type BoatKeyNotObserved = typeof boatKeyNotObservedSchema.Type;
46
+ export declare const boatWalletSchema: Schema.Struct<{
47
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
48
+ organizationId: Schema.optional<Schema.String>;
49
+ organizationName: Schema.optional<Schema.String>;
50
+ role: Schema.optional<Schema.String>;
51
+ }>;
52
+ export type BoatWallet = typeof boatWalletSchema.Type;
53
+ /**
54
+ * One wallet the key's Boat account can bill (`GET /orgs`): its own (`personal`), or an
55
+ * organization it belongs to, with the account's role there. `active`: the account's active wallet,
56
+ * which an unpinned personal key bills. `id` is what a pin names: an organization's id, or
57
+ * `personal` for the account's own wallet.
58
+ */
59
+ export declare const boatKeyWalletChoiceSchema: Schema.Struct<{
60
+ readonly id: Schema.String;
61
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
62
+ readonly name: Schema.optional<Schema.String>;
63
+ readonly role: Schema.optional<Schema.String>;
64
+ readonly active: Schema.Boolean;
65
+ }>;
66
+ export type BoatKeyWalletChoice = typeof boatKeyWalletChoiceSchema.Type;
67
+ /**
68
+ * Whether the account's requests name the wallet to bill. `pinned`: every request names
69
+ * `organization` (an organization's id or name, or `personal`), so the bill never follows the key's
70
+ * active wallet. `key-organization`: an organization's Boat key, which bills that organization and
71
+ * nothing else; there is nothing to choose. `active-wallet`: a personal key with no pin, which bills
72
+ * whichever wallet its Boat account has active, and that the person can change in Boat at any time
73
+ * (a stored account is in it only until sealant pins it, right after an upgrade);
74
+ * `walletChanged` says the wallet it bills now is not the one an earlier report saw (`from`), first
75
+ * seen at `observedAt`, and stays while the wallet stays.
76
+ */
77
+ export declare const boatKeyBillingSchema: Schema.Union<readonly [Schema.Struct<{
78
+ readonly mode: Schema.Literal<"pinned">;
79
+ readonly organization: Schema.String;
80
+ }>, Schema.Struct<{
81
+ readonly mode: Schema.Literal<"key-organization">;
82
+ }>, Schema.Struct<{
83
+ readonly mode: Schema.Literal<"active-wallet">;
84
+ readonly walletChanged: Schema.optional<Schema.Struct<{
85
+ readonly from: Schema.Struct<{
86
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
87
+ organizationId: Schema.optional<Schema.String>;
88
+ organizationName: Schema.optional<Schema.String>;
89
+ role: Schema.optional<Schema.String>;
90
+ }>;
91
+ readonly observedAt: Schema.String;
92
+ }>>;
93
+ }>]>;
94
+ export type BoatKeyBilling = typeof boatKeyBillingSchema.Type;
46
95
  /**
47
96
  * What sealant observed of a Boat key, from Boat's own answers, at `observedAt`. Each fact is
48
97
  * `observed: true` with its value, or `observed: false` with the reason Boat did not show it.
@@ -128,6 +177,58 @@ export declare const boatKeyReportSchema: Schema.Struct<{
128
177
  readonly billingUrl: Schema.optional<Schema.String>;
129
178
  }>>;
130
179
  }>]>;
180
+ /**
181
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
182
+ * reports made before sealant read them.
183
+ */
184
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
185
+ readonly observed: Schema.Literal<true>;
186
+ } & {
187
+ choices: Schema.$Array<Schema.Struct<{
188
+ readonly id: Schema.String;
189
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
190
+ readonly name: Schema.optional<Schema.String>;
191
+ readonly role: Schema.optional<Schema.String>;
192
+ readonly active: Schema.Boolean;
193
+ }>>;
194
+ }>, Schema.Struct<{
195
+ readonly observed: Schema.Literal<false>;
196
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
197
+ readonly boat: Schema.optional<Schema.Struct<{
198
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
199
+ readonly retryable: Schema.Boolean;
200
+ readonly operation: Schema.optional<Schema.String>;
201
+ readonly code: Schema.optional<Schema.String>;
202
+ readonly message: Schema.optional<Schema.String>;
203
+ readonly requestId: Schema.optional<Schema.String>;
204
+ readonly status: Schema.optional<Schema.Int>;
205
+ readonly permission: Schema.optional<Schema.String>;
206
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
207
+ readonly retryAt: Schema.optional<Schema.String>;
208
+ readonly billingUrl: Schema.optional<Schema.String>;
209
+ }>>;
210
+ }>]>>;
211
+ /**
212
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
213
+ * reports made before sealant said so.
214
+ */
215
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
216
+ readonly mode: Schema.Literal<"pinned">;
217
+ readonly organization: Schema.String;
218
+ }>, Schema.Struct<{
219
+ readonly mode: Schema.Literal<"key-organization">;
220
+ }>, Schema.Struct<{
221
+ readonly mode: Schema.Literal<"active-wallet">;
222
+ readonly walletChanged: Schema.optional<Schema.Struct<{
223
+ readonly from: Schema.Struct<{
224
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
225
+ organizationId: Schema.optional<Schema.String>;
226
+ organizationName: Schema.optional<Schema.String>;
227
+ role: Schema.optional<Schema.String>;
228
+ }>;
229
+ readonly observedAt: Schema.String;
230
+ }>>;
231
+ }>]>>;
131
232
  /** The permissions sealant needs of every key, from the Boat calls it makes. */
132
233
  readonly requiredPermissions: Schema.$Array<Schema.String>;
133
234
  /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
@@ -298,6 +399,22 @@ export declare const boatKeyProofSchema: Schema.Struct<{
298
399
  }>;
299
400
  }>;
300
401
  export type BoatKeyProof = typeof boatKeyProofSchema.Type;
402
+ /**
403
+ * What a key's account made in Boat before sealant recorded wallets, that sealant cannot reach: Boat
404
+ * has it in none of the wallets the key can bill (for a key without `account.read`, which cannot list
405
+ * them: not in the one it bills). It was since deleted in Boat, or is in an organization the key's
406
+ * account has left. sealant keeps it recorded, never uses or removes it, and waits on it for nothing;
407
+ * look for it in Boat, in each organization the key's account has been in.
408
+ */
409
+ export declare const boatUnreachableSchema: Schema.Struct<{
410
+ /** Saved images, by snapshot name (Saved snapshots in Boat). */
411
+ readonly savedImages: Schema.$Array<Schema.String>;
412
+ /** Runs whose VM it was, by run id: each ended as gone, its VM in no wallet the key can bill. */
413
+ readonly runs: Schema.optional<Schema.$Array<Schema.String>>;
414
+ /** Image builds, by publication id: abandoned, and built again in the wallet the key bills now. */
415
+ readonly builds: Schema.optional<Schema.$Array<Schema.String>>;
416
+ }>;
417
+ export type BoatUnreachableWire = typeof boatUnreachableSchema.Type;
301
418
  export declare const boatAccountSchema: Schema.Struct<{
302
419
  readonly boatAccountId: Schema.String;
303
420
  readonly label: Schema.String;
@@ -306,7 +423,12 @@ export declare const boatAccountSchema: Schema.Struct<{
306
423
  readonly createdAt: Schema.String;
307
424
  /** When its key was last replaced; null when it still has the key it was created with. */
308
425
  readonly keyRotatedAt: Schema.NullOr<Schema.String>;
309
- /** The Boat organization the account bills, sent on every request for it; null: none named. */
426
+ /**
427
+ * The wallet the account bills, named (`X-Boat-Org`) on every request it makes: an
428
+ * organization's id, or `personal`. Every personal key is pinned (to the wallet it billed when it
429
+ * was connected, unless the caller named another). Null: an organization's key, which has one
430
+ * wallet, or an account connected before sealant pinned accounts that the worker has not pinned yet.
431
+ */
310
432
  readonly organization: Schema.optional<Schema.NullOr<Schema.String>>;
311
433
  /** The key's last report, with when it was observed; null until the key is checked. */
312
434
  readonly report: Schema.optional<Schema.NullOr<Schema.Struct<{
@@ -390,6 +512,58 @@ export declare const boatAccountSchema: Schema.Struct<{
390
512
  readonly billingUrl: Schema.optional<Schema.String>;
391
513
  }>>;
392
514
  }>]>;
515
+ /**
516
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
517
+ * reports made before sealant read them.
518
+ */
519
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
520
+ readonly observed: Schema.Literal<true>;
521
+ } & {
522
+ choices: Schema.$Array<Schema.Struct<{
523
+ readonly id: Schema.String;
524
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
525
+ readonly name: Schema.optional<Schema.String>;
526
+ readonly role: Schema.optional<Schema.String>;
527
+ readonly active: Schema.Boolean;
528
+ }>>;
529
+ }>, Schema.Struct<{
530
+ readonly observed: Schema.Literal<false>;
531
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
532
+ readonly boat: Schema.optional<Schema.Struct<{
533
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
534
+ readonly retryable: Schema.Boolean;
535
+ readonly operation: Schema.optional<Schema.String>;
536
+ readonly code: Schema.optional<Schema.String>;
537
+ readonly message: Schema.optional<Schema.String>;
538
+ readonly requestId: Schema.optional<Schema.String>;
539
+ readonly status: Schema.optional<Schema.Int>;
540
+ readonly permission: Schema.optional<Schema.String>;
541
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
542
+ readonly retryAt: Schema.optional<Schema.String>;
543
+ readonly billingUrl: Schema.optional<Schema.String>;
544
+ }>>;
545
+ }>]>>;
546
+ /**
547
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
548
+ * reports made before sealant said so.
549
+ */
550
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
551
+ readonly mode: Schema.Literal<"pinned">;
552
+ readonly organization: Schema.String;
553
+ }>, Schema.Struct<{
554
+ readonly mode: Schema.Literal<"key-organization">;
555
+ }>, Schema.Struct<{
556
+ readonly mode: Schema.Literal<"active-wallet">;
557
+ readonly walletChanged: Schema.optional<Schema.Struct<{
558
+ readonly from: Schema.Struct<{
559
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
560
+ organizationId: Schema.optional<Schema.String>;
561
+ organizationName: Schema.optional<Schema.String>;
562
+ role: Schema.optional<Schema.String>;
563
+ }>;
564
+ readonly observedAt: Schema.String;
565
+ }>>;
566
+ }>]>>;
393
567
  /** The permissions sealant needs of every key, from the Boat calls it makes. */
394
568
  readonly requiredPermissions: Schema.$Array<Schema.String>;
395
569
  /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
@@ -521,6 +695,15 @@ export declare const boatAccountSchema: Schema.Struct<{
521
695
  readonly removalConfirmed: Schema.Boolean;
522
696
  }>;
523
697
  }>>>;
698
+ /** What the account made in Boat that sealant cannot reach (`boatUnreachableSchema`). */
699
+ readonly unreachable: Schema.optional<Schema.NullOr<Schema.Struct<{
700
+ /** Saved images, by snapshot name (Saved snapshots in Boat). */
701
+ readonly savedImages: Schema.$Array<Schema.String>;
702
+ /** Runs whose VM it was, by run id: each ended as gone, its VM in no wallet the key can bill. */
703
+ readonly runs: Schema.optional<Schema.$Array<Schema.String>>;
704
+ /** Image builds, by publication id: abandoned, and built again in the wallet the key bills now. */
705
+ readonly builds: Schema.optional<Schema.$Array<Schema.String>>;
706
+ }>>>;
524
707
  }>;
525
708
  export type BoatAccountWire = typeof boatAccountSchema.Type;
526
709
  /**
@@ -612,6 +795,58 @@ export declare const boatInstallKeySchema: Schema.Struct<{
612
795
  readonly billingUrl: Schema.optional<Schema.String>;
613
796
  }>>;
614
797
  }>]>;
798
+ /**
799
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
800
+ * reports made before sealant read them.
801
+ */
802
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
803
+ readonly observed: Schema.Literal<true>;
804
+ } & {
805
+ choices: Schema.$Array<Schema.Struct<{
806
+ readonly id: Schema.String;
807
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
808
+ readonly name: Schema.optional<Schema.String>;
809
+ readonly role: Schema.optional<Schema.String>;
810
+ readonly active: Schema.Boolean;
811
+ }>>;
812
+ }>, Schema.Struct<{
813
+ readonly observed: Schema.Literal<false>;
814
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
815
+ readonly boat: Schema.optional<Schema.Struct<{
816
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
817
+ readonly retryable: Schema.Boolean;
818
+ readonly operation: Schema.optional<Schema.String>;
819
+ readonly code: Schema.optional<Schema.String>;
820
+ readonly message: Schema.optional<Schema.String>;
821
+ readonly requestId: Schema.optional<Schema.String>;
822
+ readonly status: Schema.optional<Schema.Int>;
823
+ readonly permission: Schema.optional<Schema.String>;
824
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
825
+ readonly retryAt: Schema.optional<Schema.String>;
826
+ readonly billingUrl: Schema.optional<Schema.String>;
827
+ }>>;
828
+ }>]>>;
829
+ /**
830
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
831
+ * reports made before sealant said so.
832
+ */
833
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
834
+ readonly mode: Schema.Literal<"pinned">;
835
+ readonly organization: Schema.String;
836
+ }>, Schema.Struct<{
837
+ readonly mode: Schema.Literal<"key-organization">;
838
+ }>, Schema.Struct<{
839
+ readonly mode: Schema.Literal<"active-wallet">;
840
+ readonly walletChanged: Schema.optional<Schema.Struct<{
841
+ readonly from: Schema.Struct<{
842
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
843
+ organizationId: Schema.optional<Schema.String>;
844
+ organizationName: Schema.optional<Schema.String>;
845
+ role: Schema.optional<Schema.String>;
846
+ }>;
847
+ readonly observedAt: Schema.String;
848
+ }>>;
849
+ }>]>>;
615
850
  /** The permissions sealant needs of every key, from the Boat calls it makes. */
616
851
  readonly requiredPermissions: Schema.$Array<Schema.String>;
617
852
  /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
@@ -713,6 +948,15 @@ export declare const boatInstallKeySchema: Schema.Struct<{
713
948
  }>>;
714
949
  }>]>;
715
950
  }>>;
951
+ /** What the install's key made in Boat that sealant cannot reach (`boatUnreachableSchema`). */
952
+ readonly unreachable: Schema.optional<Schema.NullOr<Schema.Struct<{
953
+ /** Saved images, by snapshot name (Saved snapshots in Boat). */
954
+ readonly savedImages: Schema.$Array<Schema.String>;
955
+ /** Runs whose VM it was, by run id: each ended as gone, its VM in no wallet the key can bill. */
956
+ readonly runs: Schema.optional<Schema.$Array<Schema.String>>;
957
+ /** Image builds, by publication id: abandoned, and built again in the wallet the key bills now. */
958
+ readonly builds: Schema.optional<Schema.$Array<Schema.String>>;
959
+ }>>>;
716
960
  }>;
717
961
  export type BoatInstallKeyWire = typeof boatInstallKeySchema.Type;
718
962
  export declare const createBoatAccountRequestSchema: Schema.Struct<{
@@ -727,6 +971,15 @@ export declare const createBoatAccountRequestSchema: Schema.Struct<{
727
971
  readonly organization: Schema.optional<Schema.String>;
728
972
  }>;
729
973
  export type CreateBoatAccountRequest = typeof createBoatAccountRequestSchema.Type;
974
+ export declare const setBoatAccountOrganizationRequestSchema: Schema.Struct<{
975
+ /**
976
+ * The wallet to bill from now on: an organization's id (or name) from the key report's
977
+ * `wallets`, or `personal` for the key's own Boat account. Only a personal key can be pointed at
978
+ * a wallet. Null is refused: a personal key's account is never unpinned.
979
+ */
980
+ readonly organization: Schema.NullOr<Schema.String>;
981
+ }>;
982
+ export type SetBoatAccountOrganizationRequest = typeof setBoatAccountOrganizationRequestSchema.Type;
730
983
  export declare const rotateBoatAccountKeyRequestSchema: Schema.Struct<{
731
984
  /** The new Boat key, for the same Boat account: it must see every VM the account runs. */
732
985
  readonly apiKey: Schema.String;
@@ -741,7 +994,12 @@ export declare const listBoatAccountsResponseSchema: Schema.Struct<{
741
994
  readonly createdAt: Schema.String;
742
995
  /** When its key was last replaced; null when it still has the key it was created with. */
743
996
  readonly keyRotatedAt: Schema.NullOr<Schema.String>;
744
- /** The Boat organization the account bills, sent on every request for it; null: none named. */
997
+ /**
998
+ * The wallet the account bills, named (`X-Boat-Org`) on every request it makes: an
999
+ * organization's id, or `personal`. Every personal key is pinned (to the wallet it billed when it
1000
+ * was connected, unless the caller named another). Null: an organization's key, which has one
1001
+ * wallet, or an account connected before sealant pinned accounts that the worker has not pinned yet.
1002
+ */
745
1003
  readonly organization: Schema.optional<Schema.NullOr<Schema.String>>;
746
1004
  /** The key's last report, with when it was observed; null until the key is checked. */
747
1005
  readonly report: Schema.optional<Schema.NullOr<Schema.Struct<{
@@ -825,6 +1083,58 @@ export declare const listBoatAccountsResponseSchema: Schema.Struct<{
825
1083
  readonly billingUrl: Schema.optional<Schema.String>;
826
1084
  }>>;
827
1085
  }>]>;
1086
+ /**
1087
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
1088
+ * reports made before sealant read them.
1089
+ */
1090
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
1091
+ readonly observed: Schema.Literal<true>;
1092
+ } & {
1093
+ choices: Schema.$Array<Schema.Struct<{
1094
+ readonly id: Schema.String;
1095
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
1096
+ readonly name: Schema.optional<Schema.String>;
1097
+ readonly role: Schema.optional<Schema.String>;
1098
+ readonly active: Schema.Boolean;
1099
+ }>>;
1100
+ }>, Schema.Struct<{
1101
+ readonly observed: Schema.Literal<false>;
1102
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
1103
+ readonly boat: Schema.optional<Schema.Struct<{
1104
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
1105
+ readonly retryable: Schema.Boolean;
1106
+ readonly operation: Schema.optional<Schema.String>;
1107
+ readonly code: Schema.optional<Schema.String>;
1108
+ readonly message: Schema.optional<Schema.String>;
1109
+ readonly requestId: Schema.optional<Schema.String>;
1110
+ readonly status: Schema.optional<Schema.Int>;
1111
+ readonly permission: Schema.optional<Schema.String>;
1112
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
1113
+ readonly retryAt: Schema.optional<Schema.String>;
1114
+ readonly billingUrl: Schema.optional<Schema.String>;
1115
+ }>>;
1116
+ }>]>>;
1117
+ /**
1118
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
1119
+ * reports made before sealant said so.
1120
+ */
1121
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
1122
+ readonly mode: Schema.Literal<"pinned">;
1123
+ readonly organization: Schema.String;
1124
+ }>, Schema.Struct<{
1125
+ readonly mode: Schema.Literal<"key-organization">;
1126
+ }>, Schema.Struct<{
1127
+ readonly mode: Schema.Literal<"active-wallet">;
1128
+ readonly walletChanged: Schema.optional<Schema.Struct<{
1129
+ readonly from: Schema.Struct<{
1130
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
1131
+ organizationId: Schema.optional<Schema.String>;
1132
+ organizationName: Schema.optional<Schema.String>;
1133
+ role: Schema.optional<Schema.String>;
1134
+ }>;
1135
+ readonly observedAt: Schema.String;
1136
+ }>>;
1137
+ }>]>>;
828
1138
  /** The permissions sealant needs of every key, from the Boat calls it makes. */
829
1139
  readonly requiredPermissions: Schema.$Array<Schema.String>;
830
1140
  /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
@@ -956,6 +1266,15 @@ export declare const listBoatAccountsResponseSchema: Schema.Struct<{
956
1266
  readonly removalConfirmed: Schema.Boolean;
957
1267
  }>;
958
1268
  }>>>;
1269
+ /** What the account made in Boat that sealant cannot reach (`boatUnreachableSchema`). */
1270
+ readonly unreachable: Schema.optional<Schema.NullOr<Schema.Struct<{
1271
+ /** Saved images, by snapshot name (Saved snapshots in Boat). */
1272
+ readonly savedImages: Schema.$Array<Schema.String>;
1273
+ /** Runs whose VM it was, by run id: each ended as gone, its VM in no wallet the key can bill. */
1274
+ readonly runs: Schema.optional<Schema.$Array<Schema.String>>;
1275
+ /** Image builds, by publication id: abandoned, and built again in the wallet the key bills now. */
1276
+ readonly builds: Schema.optional<Schema.$Array<Schema.String>>;
1277
+ }>>>;
959
1278
  }>>;
960
1279
  }>;
961
1280
  export type ListBoatAccountsResponse = typeof listBoatAccountsResponseSchema.Type;
@@ -1062,6 +1381,58 @@ declare const BoatAccountKeyRefusedError_base: Schema.Class<BoatAccountKeyRefuse
1062
1381
  readonly billingUrl: Schema.optional<Schema.String>;
1063
1382
  }>>;
1064
1383
  }>]>;
1384
+ /**
1385
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
1386
+ * reports made before sealant read them.
1387
+ */
1388
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
1389
+ readonly observed: Schema.Literal<true>;
1390
+ } & {
1391
+ choices: Schema.$Array<Schema.Struct<{
1392
+ readonly id: Schema.String;
1393
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
1394
+ readonly name: Schema.optional<Schema.String>;
1395
+ readonly role: Schema.optional<Schema.String>;
1396
+ readonly active: Schema.Boolean;
1397
+ }>>;
1398
+ }>, Schema.Struct<{
1399
+ readonly observed: Schema.Literal<false>;
1400
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
1401
+ readonly boat: Schema.optional<Schema.Struct<{
1402
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
1403
+ readonly retryable: Schema.Boolean;
1404
+ readonly operation: Schema.optional<Schema.String>;
1405
+ readonly code: Schema.optional<Schema.String>;
1406
+ readonly message: Schema.optional<Schema.String>;
1407
+ readonly requestId: Schema.optional<Schema.String>;
1408
+ readonly status: Schema.optional<Schema.Int>;
1409
+ readonly permission: Schema.optional<Schema.String>;
1410
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
1411
+ readonly retryAt: Schema.optional<Schema.String>;
1412
+ readonly billingUrl: Schema.optional<Schema.String>;
1413
+ }>>;
1414
+ }>]>>;
1415
+ /**
1416
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
1417
+ * reports made before sealant said so.
1418
+ */
1419
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
1420
+ readonly mode: Schema.Literal<"pinned">;
1421
+ readonly organization: Schema.String;
1422
+ }>, Schema.Struct<{
1423
+ readonly mode: Schema.Literal<"key-organization">;
1424
+ }>, Schema.Struct<{
1425
+ readonly mode: Schema.Literal<"active-wallet">;
1426
+ readonly walletChanged: Schema.optional<Schema.Struct<{
1427
+ readonly from: Schema.Struct<{
1428
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
1429
+ organizationId: Schema.optional<Schema.String>;
1430
+ organizationName: Schema.optional<Schema.String>;
1431
+ role: Schema.optional<Schema.String>;
1432
+ }>;
1433
+ readonly observedAt: Schema.String;
1434
+ }>>;
1435
+ }>]>>;
1065
1436
  /** The permissions sealant needs of every key, from the Boat calls it makes. */
1066
1437
  readonly requiredPermissions: Schema.$Array<Schema.String>;
1067
1438
  /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
@@ -1180,8 +1551,9 @@ export declare class BoatAccountNotFoundError extends BoatAccountNotFoundError_b
1180
1551
  }
1181
1552
  declare const BoatAccountConflictError_base: Schema.Class<BoatAccountConflictError, Schema.TaggedStruct<"BoatAccountConflictError", {
1182
1553
  readonly message: Schema.String;
1183
- readonly code: Schema.Literals<readonly ["boat-account-in-use", "boat-key-cannot-see", "boat-account-removing", "boat-account-changed", "boat-account-environment", "boat-proof-running"]>;
1554
+ readonly code: Schema.Literals<readonly ["boat-account-in-use", "boat-key-cannot-see", "boat-account-removing", "boat-account-changed", "boat-account-environment", "boat-proof-running", "boat-key-organization", "boat-account-wallet-unresolved"]>;
1184
1555
  readonly liveRuns: Schema.optional<Schema.Int>;
1556
+ readonly unsettledRuns: Schema.optional<Schema.Int>;
1185
1557
  readonly buildsInFlight: Schema.optional<Schema.Int>;
1186
1558
  readonly unseen: Schema.optional<Schema.Int>;
1187
1559
  }>, import("effect/Cause").YieldableError>;
@@ -1196,7 +1568,12 @@ declare const BoatAccountConflictError_base: Schema.Class<BoatAccountConflictErr
1196
1568
  * `boat-account-environment`: the install's own key (`default`) is set in its environment, not
1197
1569
  * through this API. `boat-proof-running`: a full check of the account is running, or Boat may
1198
1570
  * still hold what one made (the message names the VM and the snapshot): a second check, a key
1199
- * rotation and a removal wait until sealant has deleted it.
1571
+ * rotation, a removal and a change of organization wait until sealant has deleted it.
1572
+ * `boat-key-organization`: a change of organization for an organization's Boat key, which bills
1573
+ * its own organization and nothing else. `boat-account-wallet-unresolved`: not answered any more
1574
+ * (kept so a client that lists it still decodes): a change of organization, a rotation and a removal
1575
+ * wait for nothing the account made, which each stay in their own wallet. A full check of an account
1576
+ * sealant has not pinned yet (its key cannot show the wallet it bills) answers `boat-account-in-use`.
1200
1577
  */
1201
1578
  export declare class BoatAccountConflictError extends BoatAccountConflictError_base {
1202
1579
  }
@@ -1221,7 +1598,12 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
1221
1598
  readonly createdAt: Schema.String;
1222
1599
  /** When its key was last replaced; null when it still has the key it was created with. */
1223
1600
  readonly keyRotatedAt: Schema.NullOr<Schema.String>;
1224
- /** The Boat organization the account bills, sent on every request for it; null: none named. */
1601
+ /**
1602
+ * The wallet the account bills, named (`X-Boat-Org`) on every request it makes: an
1603
+ * organization's id, or `personal`. Every personal key is pinned (to the wallet it billed when it
1604
+ * was connected, unless the caller named another). Null: an organization's key, which has one
1605
+ * wallet, or an account connected before sealant pinned accounts that the worker has not pinned yet.
1606
+ */
1225
1607
  readonly organization: Schema.optional<Schema.NullOr<Schema.String>>;
1226
1608
  /** The key's last report, with when it was observed; null until the key is checked. */
1227
1609
  readonly report: Schema.optional<Schema.NullOr<Schema.Struct<{
@@ -1305,6 +1687,58 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
1305
1687
  readonly billingUrl: Schema.optional<Schema.String>;
1306
1688
  }>>;
1307
1689
  }>]>;
1690
+ /**
1691
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
1692
+ * reports made before sealant read them.
1693
+ */
1694
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
1695
+ readonly observed: Schema.Literal<true>;
1696
+ } & {
1697
+ choices: Schema.$Array<Schema.Struct<{
1698
+ readonly id: Schema.String;
1699
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
1700
+ readonly name: Schema.optional<Schema.String>;
1701
+ readonly role: Schema.optional<Schema.String>;
1702
+ readonly active: Schema.Boolean;
1703
+ }>>;
1704
+ }>, Schema.Struct<{
1705
+ readonly observed: Schema.Literal<false>;
1706
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
1707
+ readonly boat: Schema.optional<Schema.Struct<{
1708
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
1709
+ readonly retryable: Schema.Boolean;
1710
+ readonly operation: Schema.optional<Schema.String>;
1711
+ readonly code: Schema.optional<Schema.String>;
1712
+ readonly message: Schema.optional<Schema.String>;
1713
+ readonly requestId: Schema.optional<Schema.String>;
1714
+ readonly status: Schema.optional<Schema.Int>;
1715
+ readonly permission: Schema.optional<Schema.String>;
1716
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
1717
+ readonly retryAt: Schema.optional<Schema.String>;
1718
+ readonly billingUrl: Schema.optional<Schema.String>;
1719
+ }>>;
1720
+ }>]>>;
1721
+ /**
1722
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
1723
+ * reports made before sealant said so.
1724
+ */
1725
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
1726
+ readonly mode: Schema.Literal<"pinned">;
1727
+ readonly organization: Schema.String;
1728
+ }>, Schema.Struct<{
1729
+ readonly mode: Schema.Literal<"key-organization">;
1730
+ }>, Schema.Struct<{
1731
+ readonly mode: Schema.Literal<"active-wallet">;
1732
+ readonly walletChanged: Schema.optional<Schema.Struct<{
1733
+ readonly from: Schema.Struct<{
1734
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
1735
+ organizationId: Schema.optional<Schema.String>;
1736
+ organizationName: Schema.optional<Schema.String>;
1737
+ role: Schema.optional<Schema.String>;
1738
+ }>;
1739
+ readonly observedAt: Schema.String;
1740
+ }>>;
1741
+ }>]>>;
1308
1742
  /** The permissions sealant needs of every key, from the Boat calls it makes. */
1309
1743
  readonly requiredPermissions: Schema.$Array<Schema.String>;
1310
1744
  /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
@@ -1436,6 +1870,15 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
1436
1870
  readonly removalConfirmed: Schema.Boolean;
1437
1871
  }>;
1438
1872
  }>>>;
1873
+ /** What the account made in Boat that sealant cannot reach (`boatUnreachableSchema`). */
1874
+ readonly unreachable: Schema.optional<Schema.NullOr<Schema.Struct<{
1875
+ /** Saved images, by snapshot name (Saved snapshots in Boat). */
1876
+ readonly savedImages: Schema.$Array<Schema.String>;
1877
+ /** Runs whose VM it was, by run id: each ended as gone, its VM in no wallet the key can bill. */
1878
+ readonly runs: Schema.optional<Schema.$Array<Schema.String>>;
1879
+ /** Image builds, by publication id: abandoned, and built again in the wallet the key bills now. */
1880
+ readonly builds: Schema.optional<Schema.$Array<Schema.String>>;
1881
+ }>>>;
1439
1882
  }>>, Schema.toCodecJson<typeof BoatAccountKeyRefusedError | typeof BoatAccountNotFoundError | typeof BoatAccountServiceUnavailableError | typeof BoatAccountInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"checkBoatInstallKey", "POST", "/install-key", never, never, never, never, Schema.toCodecJson<Schema.Struct<{
1440
1883
  readonly label: Schema.String;
1441
1884
  /** The key's last report, with when it was observed; null until it is checked. */
@@ -1520,6 +1963,58 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
1520
1963
  readonly billingUrl: Schema.optional<Schema.String>;
1521
1964
  }>>;
1522
1965
  }>]>;
1966
+ /**
1967
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
1968
+ * reports made before sealant read them.
1969
+ */
1970
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
1971
+ readonly observed: Schema.Literal<true>;
1972
+ } & {
1973
+ choices: Schema.$Array<Schema.Struct<{
1974
+ readonly id: Schema.String;
1975
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
1976
+ readonly name: Schema.optional<Schema.String>;
1977
+ readonly role: Schema.optional<Schema.String>;
1978
+ readonly active: Schema.Boolean;
1979
+ }>>;
1980
+ }>, Schema.Struct<{
1981
+ readonly observed: Schema.Literal<false>;
1982
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
1983
+ readonly boat: Schema.optional<Schema.Struct<{
1984
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
1985
+ readonly retryable: Schema.Boolean;
1986
+ readonly operation: Schema.optional<Schema.String>;
1987
+ readonly code: Schema.optional<Schema.String>;
1988
+ readonly message: Schema.optional<Schema.String>;
1989
+ readonly requestId: Schema.optional<Schema.String>;
1990
+ readonly status: Schema.optional<Schema.Int>;
1991
+ readonly permission: Schema.optional<Schema.String>;
1992
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
1993
+ readonly retryAt: Schema.optional<Schema.String>;
1994
+ readonly billingUrl: Schema.optional<Schema.String>;
1995
+ }>>;
1996
+ }>]>>;
1997
+ /**
1998
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
1999
+ * reports made before sealant said so.
2000
+ */
2001
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
2002
+ readonly mode: Schema.Literal<"pinned">;
2003
+ readonly organization: Schema.String;
2004
+ }>, Schema.Struct<{
2005
+ readonly mode: Schema.Literal<"key-organization">;
2006
+ }>, Schema.Struct<{
2007
+ readonly mode: Schema.Literal<"active-wallet">;
2008
+ readonly walletChanged: Schema.optional<Schema.Struct<{
2009
+ readonly from: Schema.Struct<{
2010
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
2011
+ organizationId: Schema.optional<Schema.String>;
2012
+ organizationName: Schema.optional<Schema.String>;
2013
+ role: Schema.optional<Schema.String>;
2014
+ }>;
2015
+ readonly observedAt: Schema.String;
2016
+ }>>;
2017
+ }>]>>;
1523
2018
  /** The permissions sealant needs of every key, from the Boat calls it makes. */
1524
2019
  readonly requiredPermissions: Schema.$Array<Schema.String>;
1525
2020
  /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
@@ -1621,6 +2116,15 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
1621
2116
  }>>;
1622
2117
  }>]>;
1623
2118
  }>>;
2119
+ /** What the install's key made in Boat that sealant cannot reach (`boatUnreachableSchema`). */
2120
+ readonly unreachable: Schema.optional<Schema.NullOr<Schema.Struct<{
2121
+ /** Saved images, by snapshot name (Saved snapshots in Boat). */
2122
+ readonly savedImages: Schema.$Array<Schema.String>;
2123
+ /** Runs whose VM it was, by run id: each ended as gone, its VM in no wallet the key can bill. */
2124
+ readonly runs: Schema.optional<Schema.$Array<Schema.String>>;
2125
+ /** Image builds, by publication id: abandoned, and built again in the wallet the key bills now. */
2126
+ readonly builds: Schema.optional<Schema.$Array<Schema.String>>;
2127
+ }>>>;
1624
2128
  }>>, Schema.toCodecJson<typeof BoatAccountKeyRefusedError | typeof BoatAccountServiceUnavailableError | typeof BoatAccountInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"createBoatAccount", "POST", "/", never, never, Schema.toCodecJson<Schema.Struct<{
1625
2129
  /** The caller's name for the account (an organization's name, say). At most 200 characters. */
1626
2130
  readonly label: Schema.String;
@@ -1639,7 +2143,12 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
1639
2143
  readonly createdAt: Schema.String;
1640
2144
  /** When its key was last replaced; null when it still has the key it was created with. */
1641
2145
  readonly keyRotatedAt: Schema.NullOr<Schema.String>;
1642
- /** The Boat organization the account bills, sent on every request for it; null: none named. */
2146
+ /**
2147
+ * The wallet the account bills, named (`X-Boat-Org`) on every request it makes: an
2148
+ * organization's id, or `personal`. Every personal key is pinned (to the wallet it billed when it
2149
+ * was connected, unless the caller named another). Null: an organization's key, which has one
2150
+ * wallet, or an account connected before sealant pinned accounts that the worker has not pinned yet.
2151
+ */
1643
2152
  readonly organization: Schema.optional<Schema.NullOr<Schema.String>>;
1644
2153
  /** The key's last report, with when it was observed; null until the key is checked. */
1645
2154
  readonly report: Schema.optional<Schema.NullOr<Schema.Struct<{
@@ -1723,6 +2232,58 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
1723
2232
  readonly billingUrl: Schema.optional<Schema.String>;
1724
2233
  }>>;
1725
2234
  }>]>;
2235
+ /**
2236
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
2237
+ * reports made before sealant read them.
2238
+ */
2239
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
2240
+ readonly observed: Schema.Literal<true>;
2241
+ } & {
2242
+ choices: Schema.$Array<Schema.Struct<{
2243
+ readonly id: Schema.String;
2244
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
2245
+ readonly name: Schema.optional<Schema.String>;
2246
+ readonly role: Schema.optional<Schema.String>;
2247
+ readonly active: Schema.Boolean;
2248
+ }>>;
2249
+ }>, Schema.Struct<{
2250
+ readonly observed: Schema.Literal<false>;
2251
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
2252
+ readonly boat: Schema.optional<Schema.Struct<{
2253
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
2254
+ readonly retryable: Schema.Boolean;
2255
+ readonly operation: Schema.optional<Schema.String>;
2256
+ readonly code: Schema.optional<Schema.String>;
2257
+ readonly message: Schema.optional<Schema.String>;
2258
+ readonly requestId: Schema.optional<Schema.String>;
2259
+ readonly status: Schema.optional<Schema.Int>;
2260
+ readonly permission: Schema.optional<Schema.String>;
2261
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
2262
+ readonly retryAt: Schema.optional<Schema.String>;
2263
+ readonly billingUrl: Schema.optional<Schema.String>;
2264
+ }>>;
2265
+ }>]>>;
2266
+ /**
2267
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
2268
+ * reports made before sealant said so.
2269
+ */
2270
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
2271
+ readonly mode: Schema.Literal<"pinned">;
2272
+ readonly organization: Schema.String;
2273
+ }>, Schema.Struct<{
2274
+ readonly mode: Schema.Literal<"key-organization">;
2275
+ }>, Schema.Struct<{
2276
+ readonly mode: Schema.Literal<"active-wallet">;
2277
+ readonly walletChanged: Schema.optional<Schema.Struct<{
2278
+ readonly from: Schema.Struct<{
2279
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
2280
+ organizationId: Schema.optional<Schema.String>;
2281
+ organizationName: Schema.optional<Schema.String>;
2282
+ role: Schema.optional<Schema.String>;
2283
+ }>;
2284
+ readonly observedAt: Schema.String;
2285
+ }>>;
2286
+ }>]>>;
1726
2287
  /** The permissions sealant needs of every key, from the Boat calls it makes. */
1727
2288
  readonly requiredPermissions: Schema.$Array<Schema.String>;
1728
2289
  /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
@@ -1854,6 +2415,15 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
1854
2415
  readonly removalConfirmed: Schema.Boolean;
1855
2416
  }>;
1856
2417
  }>>>;
2418
+ /** What the account made in Boat that sealant cannot reach (`boatUnreachableSchema`). */
2419
+ readonly unreachable: Schema.optional<Schema.NullOr<Schema.Struct<{
2420
+ /** Saved images, by snapshot name (Saved snapshots in Boat). */
2421
+ readonly savedImages: Schema.$Array<Schema.String>;
2422
+ /** Runs whose VM it was, by run id: each ended as gone, its VM in no wallet the key can bill. */
2423
+ readonly runs: Schema.optional<Schema.$Array<Schema.String>>;
2424
+ /** Image builds, by publication id: abandoned, and built again in the wallet the key bills now. */
2425
+ readonly builds: Schema.optional<Schema.$Array<Schema.String>>;
2426
+ }>>>;
1857
2427
  }>>, Schema.toCodecJson<typeof BoatAccountBadRequestError | typeof BoatAccountKeyRefusedError | typeof BoatAccountServiceUnavailableError | typeof BoatAccountInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"getBoatInstallKey", "GET", "/install-key", never, never, never, never, Schema.toCodecJson<Schema.Struct<{
1858
2428
  readonly label: Schema.String;
1859
2429
  /** The key's last report, with when it was observed; null until it is checked. */
@@ -1938,16 +2508,20 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
1938
2508
  readonly billingUrl: Schema.optional<Schema.String>;
1939
2509
  }>>;
1940
2510
  }>]>;
1941
- /** The permissions sealant needs of every key, from the Boat calls it makes. */
1942
- readonly requiredPermissions: Schema.$Array<Schema.String>;
1943
- /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
1944
- readonly permissions: Schema.Union<readonly [Schema.Struct<{
2511
+ /**
2512
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
2513
+ * reports made before sealant read them.
2514
+ */
2515
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
1945
2516
  readonly observed: Schema.Literal<true>;
1946
2517
  } & {
1947
- held: Schema.$Array<Schema.String>;
1948
- missing: Schema.$Array<Schema.String>;
1949
- /** The key is limited to some VMs or environments: it cannot reach VMs sealant creates. */
1950
- limitedToSandboxes: Schema.Boolean;
2518
+ choices: Schema.$Array<Schema.Struct<{
2519
+ readonly id: Schema.String;
2520
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
2521
+ readonly name: Schema.optional<Schema.String>;
2522
+ readonly role: Schema.optional<Schema.String>;
2523
+ readonly active: Schema.Boolean;
2524
+ }>>;
1951
2525
  }>, Schema.Struct<{
1952
2526
  readonly observed: Schema.Literal<false>;
1953
2527
  readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
@@ -1964,9 +2538,57 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
1964
2538
  readonly retryAt: Schema.optional<Schema.String>;
1965
2539
  readonly billingUrl: Schema.optional<Schema.String>;
1966
2540
  }>>;
1967
- }>]>;
1968
- /** When the key expires; `expiresAt` null: it never does. */
1969
- readonly expiry: Schema.Union<readonly [Schema.Struct<{
2541
+ }>]>>;
2542
+ /**
2543
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
2544
+ * reports made before sealant said so.
2545
+ */
2546
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
2547
+ readonly mode: Schema.Literal<"pinned">;
2548
+ readonly organization: Schema.String;
2549
+ }>, Schema.Struct<{
2550
+ readonly mode: Schema.Literal<"key-organization">;
2551
+ }>, Schema.Struct<{
2552
+ readonly mode: Schema.Literal<"active-wallet">;
2553
+ readonly walletChanged: Schema.optional<Schema.Struct<{
2554
+ readonly from: Schema.Struct<{
2555
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
2556
+ organizationId: Schema.optional<Schema.String>;
2557
+ organizationName: Schema.optional<Schema.String>;
2558
+ role: Schema.optional<Schema.String>;
2559
+ }>;
2560
+ readonly observedAt: Schema.String;
2561
+ }>>;
2562
+ }>]>>;
2563
+ /** The permissions sealant needs of every key, from the Boat calls it makes. */
2564
+ readonly requiredPermissions: Schema.$Array<Schema.String>;
2565
+ /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
2566
+ readonly permissions: Schema.Union<readonly [Schema.Struct<{
2567
+ readonly observed: Schema.Literal<true>;
2568
+ } & {
2569
+ held: Schema.$Array<Schema.String>;
2570
+ missing: Schema.$Array<Schema.String>;
2571
+ /** The key is limited to some VMs or environments: it cannot reach VMs sealant creates. */
2572
+ limitedToSandboxes: Schema.Boolean;
2573
+ }>, Schema.Struct<{
2574
+ readonly observed: Schema.Literal<false>;
2575
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
2576
+ readonly boat: Schema.optional<Schema.Struct<{
2577
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
2578
+ readonly retryable: Schema.Boolean;
2579
+ readonly operation: Schema.optional<Schema.String>;
2580
+ readonly code: Schema.optional<Schema.String>;
2581
+ readonly message: Schema.optional<Schema.String>;
2582
+ readonly requestId: Schema.optional<Schema.String>;
2583
+ readonly status: Schema.optional<Schema.Int>;
2584
+ readonly permission: Schema.optional<Schema.String>;
2585
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
2586
+ readonly retryAt: Schema.optional<Schema.String>;
2587
+ readonly billingUrl: Schema.optional<Schema.String>;
2588
+ }>>;
2589
+ }>]>;
2590
+ /** When the key expires; `expiresAt` null: it never does. */
2591
+ readonly expiry: Schema.Union<readonly [Schema.Struct<{
1970
2592
  readonly observed: Schema.Literal<true>;
1971
2593
  } & {
1972
2594
  expiresAt: Schema.NullOr<Schema.String>;
@@ -2039,6 +2661,15 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
2039
2661
  }>>;
2040
2662
  }>]>;
2041
2663
  }>>;
2664
+ /** What the install's key made in Boat that sealant cannot reach (`boatUnreachableSchema`). */
2665
+ readonly unreachable: Schema.optional<Schema.NullOr<Schema.Struct<{
2666
+ /** Saved images, by snapshot name (Saved snapshots in Boat). */
2667
+ readonly savedImages: Schema.$Array<Schema.String>;
2668
+ /** Runs whose VM it was, by run id: each ended as gone, its VM in no wallet the key can bill. */
2669
+ readonly runs: Schema.optional<Schema.$Array<Schema.String>>;
2670
+ /** Image builds, by publication id: abandoned, and built again in the wallet the key bills now. */
2671
+ readonly builds: Schema.optional<Schema.$Array<Schema.String>>;
2672
+ }>>>;
2042
2673
  }>>, Schema.toCodecJson<typeof BoatAccountServiceUnavailableError | typeof BoatAccountInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"listBoatAccounts", "GET", "/", never, never, never, never, Schema.toCodecJson<Schema.Struct<{
2043
2674
  readonly items: Schema.$Array<Schema.Struct<{
2044
2675
  readonly boatAccountId: Schema.String;
@@ -2048,7 +2679,12 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
2048
2679
  readonly createdAt: Schema.String;
2049
2680
  /** When its key was last replaced; null when it still has the key it was created with. */
2050
2681
  readonly keyRotatedAt: Schema.NullOr<Schema.String>;
2051
- /** The Boat organization the account bills, sent on every request for it; null: none named. */
2682
+ /**
2683
+ * The wallet the account bills, named (`X-Boat-Org`) on every request it makes: an
2684
+ * organization's id, or `personal`. Every personal key is pinned (to the wallet it billed when it
2685
+ * was connected, unless the caller named another). Null: an organization's key, which has one
2686
+ * wallet, or an account connected before sealant pinned accounts that the worker has not pinned yet.
2687
+ */
2052
2688
  readonly organization: Schema.optional<Schema.NullOr<Schema.String>>;
2053
2689
  /** The key's last report, with when it was observed; null until the key is checked. */
2054
2690
  readonly report: Schema.optional<Schema.NullOr<Schema.Struct<{
@@ -2132,6 +2768,58 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
2132
2768
  readonly billingUrl: Schema.optional<Schema.String>;
2133
2769
  }>>;
2134
2770
  }>]>;
2771
+ /**
2772
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
2773
+ * reports made before sealant read them.
2774
+ */
2775
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
2776
+ readonly observed: Schema.Literal<true>;
2777
+ } & {
2778
+ choices: Schema.$Array<Schema.Struct<{
2779
+ readonly id: Schema.String;
2780
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
2781
+ readonly name: Schema.optional<Schema.String>;
2782
+ readonly role: Schema.optional<Schema.String>;
2783
+ readonly active: Schema.Boolean;
2784
+ }>>;
2785
+ }>, Schema.Struct<{
2786
+ readonly observed: Schema.Literal<false>;
2787
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
2788
+ readonly boat: Schema.optional<Schema.Struct<{
2789
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
2790
+ readonly retryable: Schema.Boolean;
2791
+ readonly operation: Schema.optional<Schema.String>;
2792
+ readonly code: Schema.optional<Schema.String>;
2793
+ readonly message: Schema.optional<Schema.String>;
2794
+ readonly requestId: Schema.optional<Schema.String>;
2795
+ readonly status: Schema.optional<Schema.Int>;
2796
+ readonly permission: Schema.optional<Schema.String>;
2797
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
2798
+ readonly retryAt: Schema.optional<Schema.String>;
2799
+ readonly billingUrl: Schema.optional<Schema.String>;
2800
+ }>>;
2801
+ }>]>>;
2802
+ /**
2803
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
2804
+ * reports made before sealant said so.
2805
+ */
2806
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
2807
+ readonly mode: Schema.Literal<"pinned">;
2808
+ readonly organization: Schema.String;
2809
+ }>, Schema.Struct<{
2810
+ readonly mode: Schema.Literal<"key-organization">;
2811
+ }>, Schema.Struct<{
2812
+ readonly mode: Schema.Literal<"active-wallet">;
2813
+ readonly walletChanged: Schema.optional<Schema.Struct<{
2814
+ readonly from: Schema.Struct<{
2815
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
2816
+ organizationId: Schema.optional<Schema.String>;
2817
+ organizationName: Schema.optional<Schema.String>;
2818
+ role: Schema.optional<Schema.String>;
2819
+ }>;
2820
+ readonly observedAt: Schema.String;
2821
+ }>>;
2822
+ }>]>>;
2135
2823
  /** The permissions sealant needs of every key, from the Boat calls it makes. */
2136
2824
  readonly requiredPermissions: Schema.$Array<Schema.String>;
2137
2825
  /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
@@ -2263,6 +2951,15 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
2263
2951
  readonly removalConfirmed: Schema.Boolean;
2264
2952
  }>;
2265
2953
  }>>>;
2954
+ /** What the account made in Boat that sealant cannot reach (`boatUnreachableSchema`). */
2955
+ readonly unreachable: Schema.optional<Schema.NullOr<Schema.Struct<{
2956
+ /** Saved images, by snapshot name (Saved snapshots in Boat). */
2957
+ readonly savedImages: Schema.$Array<Schema.String>;
2958
+ /** Runs whose VM it was, by run id: each ended as gone, its VM in no wallet the key can bill. */
2959
+ readonly runs: Schema.optional<Schema.$Array<Schema.String>>;
2960
+ /** Image builds, by publication id: abandoned, and built again in the wallet the key bills now. */
2961
+ readonly builds: Schema.optional<Schema.$Array<Schema.String>>;
2962
+ }>>>;
2266
2963
  }>>;
2267
2964
  }>>, Schema.toCodecJson<typeof BoatAccountServiceUnavailableError | typeof BoatAccountInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"proveBoatAccount", "POST", "/:boatAccountId/prove", Schema.toCodecStringTree<Schema.Struct<{
2268
2965
  readonly boatAccountId: Schema.String;
@@ -2304,7 +3001,12 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
2304
3001
  readonly createdAt: Schema.String;
2305
3002
  /** When its key was last replaced; null when it still has the key it was created with. */
2306
3003
  readonly keyRotatedAt: Schema.NullOr<Schema.String>;
2307
- /** The Boat organization the account bills, sent on every request for it; null: none named. */
3004
+ /**
3005
+ * The wallet the account bills, named (`X-Boat-Org`) on every request it makes: an
3006
+ * organization's id, or `personal`. Every personal key is pinned (to the wallet it billed when it
3007
+ * was connected, unless the caller named another). Null: an organization's key, which has one
3008
+ * wallet, or an account connected before sealant pinned accounts that the worker has not pinned yet.
3009
+ */
2308
3010
  readonly organization: Schema.optional<Schema.NullOr<Schema.String>>;
2309
3011
  /** The key's last report, with when it was observed; null until the key is checked. */
2310
3012
  readonly report: Schema.optional<Schema.NullOr<Schema.Struct<{
@@ -2388,6 +3090,58 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
2388
3090
  readonly billingUrl: Schema.optional<Schema.String>;
2389
3091
  }>>;
2390
3092
  }>]>;
3093
+ /**
3094
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
3095
+ * reports made before sealant read them.
3096
+ */
3097
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
3098
+ readonly observed: Schema.Literal<true>;
3099
+ } & {
3100
+ choices: Schema.$Array<Schema.Struct<{
3101
+ readonly id: Schema.String;
3102
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
3103
+ readonly name: Schema.optional<Schema.String>;
3104
+ readonly role: Schema.optional<Schema.String>;
3105
+ readonly active: Schema.Boolean;
3106
+ }>>;
3107
+ }>, Schema.Struct<{
3108
+ readonly observed: Schema.Literal<false>;
3109
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
3110
+ readonly boat: Schema.optional<Schema.Struct<{
3111
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
3112
+ readonly retryable: Schema.Boolean;
3113
+ readonly operation: Schema.optional<Schema.String>;
3114
+ readonly code: Schema.optional<Schema.String>;
3115
+ readonly message: Schema.optional<Schema.String>;
3116
+ readonly requestId: Schema.optional<Schema.String>;
3117
+ readonly status: Schema.optional<Schema.Int>;
3118
+ readonly permission: Schema.optional<Schema.String>;
3119
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
3120
+ readonly retryAt: Schema.optional<Schema.String>;
3121
+ readonly billingUrl: Schema.optional<Schema.String>;
3122
+ }>>;
3123
+ }>]>>;
3124
+ /**
3125
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
3126
+ * reports made before sealant said so.
3127
+ */
3128
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
3129
+ readonly mode: Schema.Literal<"pinned">;
3130
+ readonly organization: Schema.String;
3131
+ }>, Schema.Struct<{
3132
+ readonly mode: Schema.Literal<"key-organization">;
3133
+ }>, Schema.Struct<{
3134
+ readonly mode: Schema.Literal<"active-wallet">;
3135
+ readonly walletChanged: Schema.optional<Schema.Struct<{
3136
+ readonly from: Schema.Struct<{
3137
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
3138
+ organizationId: Schema.optional<Schema.String>;
3139
+ organizationName: Schema.optional<Schema.String>;
3140
+ role: Schema.optional<Schema.String>;
3141
+ }>;
3142
+ readonly observedAt: Schema.String;
3143
+ }>>;
3144
+ }>]>>;
2391
3145
  /** The permissions sealant needs of every key, from the Boat calls it makes. */
2392
3146
  readonly requiredPermissions: Schema.$Array<Schema.String>;
2393
3147
  /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
@@ -2519,6 +3273,15 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
2519
3273
  readonly removalConfirmed: Schema.Boolean;
2520
3274
  }>;
2521
3275
  }>>>;
3276
+ /** What the account made in Boat that sealant cannot reach (`boatUnreachableSchema`). */
3277
+ readonly unreachable: Schema.optional<Schema.NullOr<Schema.Struct<{
3278
+ /** Saved images, by snapshot name (Saved snapshots in Boat). */
3279
+ readonly savedImages: Schema.$Array<Schema.String>;
3280
+ /** Runs whose VM it was, by run id: each ended as gone, its VM in no wallet the key can bill. */
3281
+ readonly runs: Schema.optional<Schema.$Array<Schema.String>>;
3282
+ /** Image builds, by publication id: abandoned, and built again in the wallet the key bills now. */
3283
+ readonly builds: Schema.optional<Schema.$Array<Schema.String>>;
3284
+ }>>>;
2522
3285
  }>>, Schema.toCodecJson<typeof BoatAccountNotFoundError | typeof BoatAccountConflictError | typeof BoatAccountServiceUnavailableError | typeof BoatAccountInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"rotateBoatAccountKey", "PUT", "/:boatAccountId/key", Schema.toCodecStringTree<Schema.Struct<{
2523
3286
  readonly boatAccountId: Schema.Union<readonly [Schema.String, Schema.Literal<"default">]>;
2524
3287
  }>>, never, Schema.toCodecJson<Schema.Struct<{
@@ -2532,7 +3295,310 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
2532
3295
  readonly createdAt: Schema.String;
2533
3296
  /** When its key was last replaced; null when it still has the key it was created with. */
2534
3297
  readonly keyRotatedAt: Schema.NullOr<Schema.String>;
2535
- /** The Boat organization the account bills, sent on every request for it; null: none named. */
3298
+ /**
3299
+ * The wallet the account bills, named (`X-Boat-Org`) on every request it makes: an
3300
+ * organization's id, or `personal`. Every personal key is pinned (to the wallet it billed when it
3301
+ * was connected, unless the caller named another). Null: an organization's key, which has one
3302
+ * wallet, or an account connected before sealant pinned accounts that the worker has not pinned yet.
3303
+ */
3304
+ readonly organization: Schema.optional<Schema.NullOr<Schema.String>>;
3305
+ /** The key's last report, with when it was observed; null until the key is checked. */
3306
+ readonly report: Schema.optional<Schema.NullOr<Schema.Struct<{
3307
+ readonly observedAt: Schema.String;
3308
+ /** The Boat organization the account bills (`X-Boat-Org` on every request), or null. */
3309
+ readonly organization: Schema.NullOr<Schema.String>;
3310
+ /** Who the key is (`GET /me`). */
3311
+ readonly identity: Schema.Union<readonly [Schema.Struct<{
3312
+ readonly observed: Schema.Literal<true>;
3313
+ } & {
3314
+ /**
3315
+ * Boat's id for the account the key belongs to (`GET /me` `user.id`). A Boat account, never a
3316
+ * Sealant person: it is not a `PersonId` and names no one on this install.
3317
+ */
3318
+ accountId: Schema.optional<Schema.String>;
3319
+ login: Schema.optional<Schema.String>;
3320
+ displayName: Schema.optional<Schema.String>;
3321
+ serviceAccount: Schema.optional<Schema.Boolean>;
3322
+ accountStatus: Schema.Literals<readonly ["active", "suspended", "closed", "unknown"]>;
3323
+ }>, Schema.Struct<{
3324
+ readonly observed: Schema.Literal<false>;
3325
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
3326
+ readonly boat: Schema.optional<Schema.Struct<{
3327
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
3328
+ readonly retryable: Schema.Boolean;
3329
+ readonly operation: Schema.optional<Schema.String>;
3330
+ readonly code: Schema.optional<Schema.String>;
3331
+ readonly message: Schema.optional<Schema.String>;
3332
+ readonly requestId: Schema.optional<Schema.String>;
3333
+ readonly status: Schema.optional<Schema.Int>;
3334
+ readonly permission: Schema.optional<Schema.String>;
3335
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
3336
+ readonly retryAt: Schema.optional<Schema.String>;
3337
+ readonly billingUrl: Schema.optional<Schema.String>;
3338
+ }>>;
3339
+ }>]>;
3340
+ /** A personal (account) key, or an organization's key. */
3341
+ readonly keyKind: Schema.Union<readonly [Schema.Struct<{
3342
+ readonly observed: Schema.Literal<true>;
3343
+ } & {
3344
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
3345
+ }>, Schema.Struct<{
3346
+ readonly observed: Schema.Literal<false>;
3347
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
3348
+ readonly boat: Schema.optional<Schema.Struct<{
3349
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
3350
+ readonly retryable: Schema.Boolean;
3351
+ readonly operation: Schema.optional<Schema.String>;
3352
+ readonly code: Schema.optional<Schema.String>;
3353
+ readonly message: Schema.optional<Schema.String>;
3354
+ readonly requestId: Schema.optional<Schema.String>;
3355
+ readonly status: Schema.optional<Schema.Int>;
3356
+ readonly permission: Schema.optional<Schema.String>;
3357
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
3358
+ readonly retryAt: Schema.optional<Schema.String>;
3359
+ readonly billingUrl: Schema.optional<Schema.String>;
3360
+ }>>;
3361
+ }>]>;
3362
+ /** Which wallet a VM started with the key bills (`GET /limits`). */
3363
+ readonly wallet: Schema.Union<readonly [Schema.Struct<{
3364
+ readonly observed: Schema.Literal<true>;
3365
+ } & {
3366
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
3367
+ organizationId: Schema.optional<Schema.String>;
3368
+ organizationName: Schema.optional<Schema.String>;
3369
+ role: Schema.optional<Schema.String>;
3370
+ }>, Schema.Struct<{
3371
+ readonly observed: Schema.Literal<false>;
3372
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
3373
+ readonly boat: Schema.optional<Schema.Struct<{
3374
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
3375
+ readonly retryable: Schema.Boolean;
3376
+ readonly operation: Schema.optional<Schema.String>;
3377
+ readonly code: Schema.optional<Schema.String>;
3378
+ readonly message: Schema.optional<Schema.String>;
3379
+ readonly requestId: Schema.optional<Schema.String>;
3380
+ readonly status: Schema.optional<Schema.Int>;
3381
+ readonly permission: Schema.optional<Schema.String>;
3382
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
3383
+ readonly retryAt: Schema.optional<Schema.String>;
3384
+ readonly billingUrl: Schema.optional<Schema.String>;
3385
+ }>>;
3386
+ }>]>;
3387
+ /**
3388
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
3389
+ * reports made before sealant read them.
3390
+ */
3391
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
3392
+ readonly observed: Schema.Literal<true>;
3393
+ } & {
3394
+ choices: Schema.$Array<Schema.Struct<{
3395
+ readonly id: Schema.String;
3396
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
3397
+ readonly name: Schema.optional<Schema.String>;
3398
+ readonly role: Schema.optional<Schema.String>;
3399
+ readonly active: Schema.Boolean;
3400
+ }>>;
3401
+ }>, Schema.Struct<{
3402
+ readonly observed: Schema.Literal<false>;
3403
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
3404
+ readonly boat: Schema.optional<Schema.Struct<{
3405
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
3406
+ readonly retryable: Schema.Boolean;
3407
+ readonly operation: Schema.optional<Schema.String>;
3408
+ readonly code: Schema.optional<Schema.String>;
3409
+ readonly message: Schema.optional<Schema.String>;
3410
+ readonly requestId: Schema.optional<Schema.String>;
3411
+ readonly status: Schema.optional<Schema.Int>;
3412
+ readonly permission: Schema.optional<Schema.String>;
3413
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
3414
+ readonly retryAt: Schema.optional<Schema.String>;
3415
+ readonly billingUrl: Schema.optional<Schema.String>;
3416
+ }>>;
3417
+ }>]>>;
3418
+ /**
3419
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
3420
+ * reports made before sealant said so.
3421
+ */
3422
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
3423
+ readonly mode: Schema.Literal<"pinned">;
3424
+ readonly organization: Schema.String;
3425
+ }>, Schema.Struct<{
3426
+ readonly mode: Schema.Literal<"key-organization">;
3427
+ }>, Schema.Struct<{
3428
+ readonly mode: Schema.Literal<"active-wallet">;
3429
+ readonly walletChanged: Schema.optional<Schema.Struct<{
3430
+ readonly from: Schema.Struct<{
3431
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
3432
+ organizationId: Schema.optional<Schema.String>;
3433
+ organizationName: Schema.optional<Schema.String>;
3434
+ role: Schema.optional<Schema.String>;
3435
+ }>;
3436
+ readonly observedAt: Schema.String;
3437
+ }>>;
3438
+ }>]>>;
3439
+ /** The permissions sealant needs of every key, from the Boat calls it makes. */
3440
+ readonly requiredPermissions: Schema.$Array<Schema.String>;
3441
+ /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
3442
+ readonly permissions: Schema.Union<readonly [Schema.Struct<{
3443
+ readonly observed: Schema.Literal<true>;
3444
+ } & {
3445
+ held: Schema.$Array<Schema.String>;
3446
+ missing: Schema.$Array<Schema.String>;
3447
+ /** The key is limited to some VMs or environments: it cannot reach VMs sealant creates. */
3448
+ limitedToSandboxes: Schema.Boolean;
3449
+ }>, Schema.Struct<{
3450
+ readonly observed: Schema.Literal<false>;
3451
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
3452
+ readonly boat: Schema.optional<Schema.Struct<{
3453
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
3454
+ readonly retryable: Schema.Boolean;
3455
+ readonly operation: Schema.optional<Schema.String>;
3456
+ readonly code: Schema.optional<Schema.String>;
3457
+ readonly message: Schema.optional<Schema.String>;
3458
+ readonly requestId: Schema.optional<Schema.String>;
3459
+ readonly status: Schema.optional<Schema.Int>;
3460
+ readonly permission: Schema.optional<Schema.String>;
3461
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
3462
+ readonly retryAt: Schema.optional<Schema.String>;
3463
+ readonly billingUrl: Schema.optional<Schema.String>;
3464
+ }>>;
3465
+ }>]>;
3466
+ /** When the key expires; `expiresAt` null: it never does. */
3467
+ readonly expiry: Schema.Union<readonly [Schema.Struct<{
3468
+ readonly observed: Schema.Literal<true>;
3469
+ } & {
3470
+ expiresAt: Schema.NullOr<Schema.String>;
3471
+ expired: Schema.Boolean;
3472
+ expiringSoon: Schema.Boolean;
3473
+ }>, Schema.Struct<{
3474
+ readonly observed: Schema.Literal<false>;
3475
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
3476
+ readonly boat: Schema.optional<Schema.Struct<{
3477
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
3478
+ readonly retryable: Schema.Boolean;
3479
+ readonly operation: Schema.optional<Schema.String>;
3480
+ readonly code: Schema.optional<Schema.String>;
3481
+ readonly message: Schema.optional<Schema.String>;
3482
+ readonly requestId: Schema.optional<Schema.String>;
3483
+ readonly status: Schema.optional<Schema.Int>;
3484
+ readonly permission: Schema.optional<Schema.String>;
3485
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
3486
+ readonly retryAt: Schema.optional<Schema.String>;
3487
+ readonly billingUrl: Schema.optional<Schema.String>;
3488
+ }>>;
3489
+ }>]>;
3490
+ /** Whether the wallet can start a VM now, why not, and its running and allowed VMs. */
3491
+ readonly start: Schema.Union<readonly [Schema.Struct<{
3492
+ readonly observed: Schema.Literal<true>;
3493
+ } & {
3494
+ canStart: Schema.Boolean;
3495
+ blockedReason: Schema.optional<Schema.String>;
3496
+ billingStatus: Schema.optional<Schema.String>;
3497
+ runningVms: Schema.Int;
3498
+ allowedVms: Schema.Int;
3499
+ }>, Schema.Struct<{
3500
+ readonly observed: Schema.Literal<false>;
3501
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
3502
+ readonly boat: Schema.optional<Schema.Struct<{
3503
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
3504
+ readonly retryable: Schema.Boolean;
3505
+ readonly operation: Schema.optional<Schema.String>;
3506
+ readonly code: Schema.optional<Schema.String>;
3507
+ readonly message: Schema.optional<Schema.String>;
3508
+ readonly requestId: Schema.optional<Schema.String>;
3509
+ readonly status: Schema.optional<Schema.Int>;
3510
+ readonly permission: Schema.optional<Schema.String>;
3511
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
3512
+ readonly retryAt: Schema.optional<Schema.String>;
3513
+ readonly billingUrl: Schema.optional<Schema.String>;
3514
+ }>>;
3515
+ }>]>;
3516
+ /** Saved snapshot slots of the wallet (`GET /saved-snapshots`). */
3517
+ readonly snapshots: Schema.Union<readonly [Schema.Struct<{
3518
+ readonly observed: Schema.Literal<true>;
3519
+ } & {
3520
+ used: Schema.Int;
3521
+ included: Schema.Int;
3522
+ }>, Schema.Struct<{
3523
+ readonly observed: Schema.Literal<false>;
3524
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
3525
+ readonly boat: Schema.optional<Schema.Struct<{
3526
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
3527
+ readonly retryable: Schema.Boolean;
3528
+ readonly operation: Schema.optional<Schema.String>;
3529
+ readonly code: Schema.optional<Schema.String>;
3530
+ readonly message: Schema.optional<Schema.String>;
3531
+ readonly requestId: Schema.optional<Schema.String>;
3532
+ readonly status: Schema.optional<Schema.Int>;
3533
+ readonly permission: Schema.optional<Schema.String>;
3534
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
3535
+ readonly retryAt: Schema.optional<Schema.String>;
3536
+ readonly billingUrl: Schema.optional<Schema.String>;
3537
+ }>>;
3538
+ }>]>;
3539
+ }>>>;
3540
+ /** The account's last full check (`prove`), kept beside its report; null until it is proven. */
3541
+ readonly lastProof: Schema.optional<Schema.NullOr<Schema.Struct<{
3542
+ readonly proofId: Schema.String;
3543
+ readonly startedAt: Schema.String;
3544
+ readonly finishedAt: Schema.String;
3545
+ readonly outcome: Schema.Literals<readonly ["passed", "refused", "interrupted"]>;
3546
+ readonly steps: Schema.$Array<Schema.Struct<{
3547
+ readonly step: Schema.Literals<readonly ["start-vm", "run-command", "publish-port", "save-snapshot", "delete-snapshot", "delete-vm"]>;
3548
+ readonly outcome: Schema.Literals<readonly ["passed", "refused", "no-answer", "not-reached"]>;
3549
+ readonly boat: Schema.optional<Schema.Struct<{
3550
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
3551
+ readonly retryable: Schema.Boolean;
3552
+ readonly operation: Schema.optional<Schema.String>;
3553
+ readonly code: Schema.optional<Schema.String>;
3554
+ readonly message: Schema.optional<Schema.String>;
3555
+ readonly requestId: Schema.optional<Schema.String>;
3556
+ readonly status: Schema.optional<Schema.Int>;
3557
+ readonly permission: Schema.optional<Schema.String>;
3558
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
3559
+ readonly retryAt: Schema.optional<Schema.String>;
3560
+ readonly billingUrl: Schema.optional<Schema.String>;
3561
+ }>>;
3562
+ }>>;
3563
+ readonly starts: Schema.Int;
3564
+ readonly leftBehind: Schema.Struct<{
3565
+ readonly vm: Schema.NullOr<Schema.String>;
3566
+ readonly snapshot: Schema.NullOr<Schema.String>;
3567
+ readonly removalConfirmed: Schema.Boolean;
3568
+ }>;
3569
+ }>>>;
3570
+ /** What the account made in Boat that sealant cannot reach (`boatUnreachableSchema`). */
3571
+ readonly unreachable: Schema.optional<Schema.NullOr<Schema.Struct<{
3572
+ /** Saved images, by snapshot name (Saved snapshots in Boat). */
3573
+ readonly savedImages: Schema.$Array<Schema.String>;
3574
+ /** Runs whose VM it was, by run id: each ended as gone, its VM in no wallet the key can bill. */
3575
+ readonly runs: Schema.optional<Schema.$Array<Schema.String>>;
3576
+ /** Image builds, by publication id: abandoned, and built again in the wallet the key bills now. */
3577
+ readonly builds: Schema.optional<Schema.$Array<Schema.String>>;
3578
+ }>>>;
3579
+ }>>, Schema.toCodecJson<typeof BoatAccountBadRequestError | typeof BoatAccountKeyRefusedError | typeof BoatAccountNotFoundError | typeof BoatAccountConflictError | typeof BoatAccountServiceUnavailableError | typeof BoatAccountInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"setBoatAccountOrganization", "PUT", "/:boatAccountId/organization", Schema.toCodecStringTree<Schema.Struct<{
3580
+ readonly boatAccountId: Schema.Union<readonly [Schema.String, Schema.Literal<"default">]>;
3581
+ }>>, never, Schema.toCodecJson<Schema.Struct<{
3582
+ /**
3583
+ * The wallet to bill from now on: an organization's id (or name) from the key report's
3584
+ * `wallets`, or `personal` for the key's own Boat account. Only a personal key can be pointed at
3585
+ * a wallet. Null is refused: a personal key's account is never unpinned.
3586
+ */
3587
+ readonly organization: Schema.NullOr<Schema.String>;
3588
+ }>>, never, Schema.toCodecJson<Schema.Struct<{
3589
+ readonly boatAccountId: Schema.String;
3590
+ readonly label: Schema.String;
3591
+ /** `active`: workspaces may run in it. `removing`: its removal was asked; none may. */
3592
+ readonly state: Schema.Literals<readonly ["active", "removing"]>;
3593
+ readonly createdAt: Schema.String;
3594
+ /** When its key was last replaced; null when it still has the key it was created with. */
3595
+ readonly keyRotatedAt: Schema.NullOr<Schema.String>;
3596
+ /**
3597
+ * The wallet the account bills, named (`X-Boat-Org`) on every request it makes: an
3598
+ * organization's id, or `personal`. Every personal key is pinned (to the wallet it billed when it
3599
+ * was connected, unless the caller named another). Null: an organization's key, which has one
3600
+ * wallet, or an account connected before sealant pinned accounts that the worker has not pinned yet.
3601
+ */
2536
3602
  readonly organization: Schema.optional<Schema.NullOr<Schema.String>>;
2537
3603
  /** The key's last report, with when it was observed; null until the key is checked. */
2538
3604
  readonly report: Schema.optional<Schema.NullOr<Schema.Struct<{
@@ -2616,6 +3682,58 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
2616
3682
  readonly billingUrl: Schema.optional<Schema.String>;
2617
3683
  }>>;
2618
3684
  }>]>;
3685
+ /**
3686
+ * The wallets the key's Boat account can bill (`GET /orgs`), the active one marked. Absent in
3687
+ * reports made before sealant read them.
3688
+ */
3689
+ readonly wallets: Schema.optional<Schema.Union<readonly [Schema.Struct<{
3690
+ readonly observed: Schema.Literal<true>;
3691
+ } & {
3692
+ choices: Schema.$Array<Schema.Struct<{
3693
+ readonly id: Schema.String;
3694
+ readonly kind: Schema.Literals<readonly ["personal", "organization"]>;
3695
+ readonly name: Schema.optional<Schema.String>;
3696
+ readonly role: Schema.optional<Schema.String>;
3697
+ readonly active: Schema.Boolean;
3698
+ }>>;
3699
+ }>, Schema.Struct<{
3700
+ readonly observed: Schema.Literal<false>;
3701
+ readonly reason: Schema.Literals<readonly ["refused", "no-answer", "not-listed", "unreadable"]>;
3702
+ readonly boat: Schema.optional<Schema.Struct<{
3703
+ readonly kind: Schema.Literals<readonly ["key-refused", "key-expired", "permission-missing", "sandbox-outside-key", "organization-mismatch", "account-suspended", "billing-required", "running-limit", "member-cap", "rate-limited", "trial-restricted", "no-machine", "snapshot-allowance-full", "no-answer", "refused"]>;
3704
+ readonly retryable: Schema.Boolean;
3705
+ readonly operation: Schema.optional<Schema.String>;
3706
+ readonly code: Schema.optional<Schema.String>;
3707
+ readonly message: Schema.optional<Schema.String>;
3708
+ readonly requestId: Schema.optional<Schema.String>;
3709
+ readonly status: Schema.optional<Schema.Int>;
3710
+ readonly permission: Schema.optional<Schema.String>;
3711
+ readonly retryAfterSeconds: Schema.optional<Schema.Int>;
3712
+ readonly retryAt: Schema.optional<Schema.String>;
3713
+ readonly billingUrl: Schema.optional<Schema.String>;
3714
+ }>>;
3715
+ }>]>>;
3716
+ /**
3717
+ * Whether the account names the wallet it bills, or follows the key's active wallet. Absent in
3718
+ * reports made before sealant said so.
3719
+ */
3720
+ readonly billing: Schema.optional<Schema.Union<readonly [Schema.Struct<{
3721
+ readonly mode: Schema.Literal<"pinned">;
3722
+ readonly organization: Schema.String;
3723
+ }>, Schema.Struct<{
3724
+ readonly mode: Schema.Literal<"key-organization">;
3725
+ }>, Schema.Struct<{
3726
+ readonly mode: Schema.Literal<"active-wallet">;
3727
+ readonly walletChanged: Schema.optional<Schema.Struct<{
3728
+ readonly from: Schema.Struct<{
3729
+ kind: Schema.Literals<readonly ["personal", "organization"]>;
3730
+ organizationId: Schema.optional<Schema.String>;
3731
+ organizationName: Schema.optional<Schema.String>;
3732
+ role: Schema.optional<Schema.String>;
3733
+ }>;
3734
+ readonly observedAt: Schema.String;
3735
+ }>>;
3736
+ }>]>>;
2619
3737
  /** The permissions sealant needs of every key, from the Boat calls it makes. */
2620
3738
  readonly requiredPermissions: Schema.$Array<Schema.String>;
2621
3739
  /** The key's permissions (`GET /api-keys`), and which of the required ones it lacks. */
@@ -2747,5 +3865,14 @@ export declare const BoatAccountsGroup: HttpApiGroup.HttpApiGroup<"boatAccounts"
2747
3865
  readonly removalConfirmed: Schema.Boolean;
2748
3866
  }>;
2749
3867
  }>>>;
3868
+ /** What the account made in Boat that sealant cannot reach (`boatUnreachableSchema`). */
3869
+ readonly unreachable: Schema.optional<Schema.NullOr<Schema.Struct<{
3870
+ /** Saved images, by snapshot name (Saved snapshots in Boat). */
3871
+ readonly savedImages: Schema.$Array<Schema.String>;
3872
+ /** Runs whose VM it was, by run id: each ended as gone, its VM in no wallet the key can bill. */
3873
+ readonly runs: Schema.optional<Schema.$Array<Schema.String>>;
3874
+ /** Image builds, by publication id: abandoned, and built again in the wallet the key bills now. */
3875
+ readonly builds: Schema.optional<Schema.$Array<Schema.String>>;
3876
+ }>>>;
2750
3877
  }>>, Schema.toCodecJson<typeof BoatAccountBadRequestError | typeof BoatAccountKeyRefusedError | typeof BoatAccountNotFoundError | typeof BoatAccountConflictError | typeof BoatAccountServiceUnavailableError | typeof BoatAccountInternalServerError>, never, never>, false>;
2751
3878
  export {};