@sealant/sdk-next 0.40.0-next.870 → 0.40.0-next.874

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/client.js CHANGED
@@ -1,4 +1,4 @@
1
- import { archiveConnectedAccountOp, archiveSshKeyOp, cancelWorkspaceCreateOp, createAccessTokenOp, createBoatAccountOp, createConnectedAccountOp, createSshKeyOp, createWorkspaceOp, ensureUserOp, getRunOp, getSetupStateOp, getUserOp, bindUserPersonOp, getWorkspaceCreateOp, getWorkspaceOp, inferenceRespondOp, inspectWorkspaceImageOp, listWorkspaceRuntimesOp, listBoatAccountsOp, listConnectedAccountsOp, listSshKeysOp, listWorkspacesOp, markConnectedAccountInvalidOp, removeBoatAccountOp, rotateBoatAccountKeyOp, setConnectedAccountDefaultOp, } from "./effect/operations.js";
1
+ import { archiveConnectedAccountOp, archiveSshKeyOp, cancelWorkspaceCreateOp, createAccessTokenOp, checkBoatAccountOp, checkBoatInstallKeyOp, getBoatInstallKeyOp, proveBoatAccountOp, createBoatAccountOp, createConnectedAccountOp, createSshKeyOp, createWorkspaceOp, ensureUserOp, getRunOp, getSetupStateOp, getUserOp, bindUserPersonOp, getWorkspaceCreateOp, getWorkspaceOp, inferenceRespondOp, inspectWorkspaceImageOp, listWorkspaceRuntimesOp, listBoatAccountsOp, listConnectedAccountsOp, listSshKeysOp, listWorkspacesOp, markConnectedAccountInvalidOp, removeBoatAccountOp, rotateBoatAccountKeyOp, setConnectedAccountDefaultOp, } from "./effect/operations.js";
2
2
  import { runHarness, startHarness } from "./effect/run-harness.js";
3
3
  import { makeSdkRuntime } from "./effect/runtime.js";
4
4
  import { SealantBudgetExceededError, SealantError } from "./errors.js";
@@ -27,6 +27,10 @@ const mapBoatAccount = (wire) => ({
27
27
  state: wire.state,
28
28
  createdAt: wire.createdAt,
29
29
  keyRotatedAt: wire.keyRotatedAt,
30
+ // An older control plane sends neither: no organization named, no report.
31
+ organization: wire.organization ?? null,
32
+ report: wire.report ?? null,
33
+ lastProof: wire.lastProof ?? null,
30
34
  });
31
35
  const mapConnectedAccount = (wire) => ({
32
36
  connectedAccountId: wire.connectedAccountId,
@@ -289,9 +293,17 @@ export class Sealant {
289
293
  * the workspaces created with `boatAccountId`. With a service key; keys go in, none come out.
290
294
  */
291
295
  boatAccounts = {
292
- create: async (options) => mapBoatAccount(await this.#runtime.run(createBoatAccountOp({ label: options.label, apiKey: options.apiKey }))),
296
+ create: async (options) => mapBoatAccount(await this.#runtime.run(createBoatAccountOp({
297
+ label: options.label,
298
+ apiKey: options.apiKey,
299
+ ...(options.organization === undefined ? {} : { organization: options.organization }),
300
+ }))),
293
301
  list: async () => (await this.#runtime.run(listBoatAccountsOp())).items.map(mapBoatAccount),
294
302
  rotateKey: async (boatAccountId, apiKey) => mapBoatAccount(await this.#runtime.run(rotateBoatAccountKeyOp(boatAccountId, { apiKey }))),
303
+ check: async (boatAccountId) => mapBoatAccount(await this.#runtime.run(checkBoatAccountOp(boatAccountId))),
304
+ prove: async (boatAccountId) => await this.#runtime.run(proveBoatAccountOp(boatAccountId)),
305
+ installKey: async () => await this.#runtime.run(getBoatInstallKeyOp()),
306
+ checkInstallKey: async () => await this.#runtime.run(checkBoatInstallKeyOp()),
295
307
  remove: async (boatAccountId) => mapBoatAccount(await this.#runtime.run(removeBoatAccountOp(boatAccountId))),
296
308
  };
297
309
  /** This client's owner's Claude / Codex / GitHub accounts. Secrets go in; none come out. */