@ornncompute/cli 1.0.147 → 1.0.149

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.
@@ -312,6 +312,11 @@ function runRemote(request, body2) {
312
312
  return request(remoteRunPath, { method: "POST", body: body2 });
313
313
  }
314
314
 
315
+ // ../../packages/api-client/dist/orchestrator/virtual-machines.js
316
+ function rebootVirtualMachine(request, nodeId3, id, body2 = {}) {
317
+ return request(`/v1/orchestrator/nodes/${encodeURIComponent(nodeId3)}/virtual-machines/${encodeURIComponent(id)}/reboot`, { method: "POST", body: body2 });
318
+ }
319
+
315
320
  // ../../packages/capabilities/dist/capabilities/admin-ssh.js
316
321
  import { z } from "zod";
317
322
 
@@ -357,7 +362,7 @@ function visibleToClient(capability, client, role) {
357
362
  return false;
358
363
  return help3.audience === "customer" ? role === "user" : role === "admin";
359
364
  }
360
- return capability.mcp != null;
365
+ return capability.mcp != null && (capability.mcp.roles?.includes(role) ?? true);
361
366
  }
362
367
  function forRole(catalog2, role, client) {
363
368
  return catalog2.filter((capability) => visibleToClient(capability, client, role));
@@ -728,6 +733,7 @@ var listNodesCapability = defineCapability({
728
733
  id: "nodes.list",
729
734
  domain: "fleet",
730
735
  roles: ["user", "admin"],
736
+ mcp: { roles: ["admin"] },
731
737
  description: "List nodes. Users see their own reserved machines. Admins see enrolled and ghost nodes. Call with no filters for the whole fleet. Optional reservation_id lists the nodes on one reservation (find a customer's reservations with reservation.list customerId). Optional organization_id (supplier), facility_id, and status (ghost, bare-metal) narrow the same list. Paginate large fleets with cursor + max: pass the response's next_cursor back as cursor to fetch the next page; next_cursor is omitted once the page is not full. Never invent nodes. Never print private keys.",
732
738
  mutation: "read",
733
739
  slack: {
@@ -1404,18 +1410,19 @@ var adminNodeHealthCapability = defineCapability({
1404
1410
  id: "nodes.health",
1405
1411
  domain: "fleet",
1406
1412
  roles: ["admin"],
1407
- description: "Read lifecycle and readiness facts for one enrolled node.",
1413
+ description: "Internal staff only: show details for a single node.",
1408
1414
  mutation: "read",
1409
1415
  cli: {
1416
+ input: nodeInput,
1417
+ execute: (ctx, input) => adminNodeHealthCapability.execute(ctx, { nodeId: nodeInput.parse(input).node_id }),
1410
1418
  command: ["admin", "nodes", "health"],
1411
1419
  vnext: adminHelp(["admin", "nodes", "health"], "Inspect lifecycle and readiness facts for one node.", "ornn admin nodes health <node-id>", "ornn admin nodes health <node-id> --format json", ["canonical node ID"])
1412
1420
  },
1413
- mcp: false,
1421
+ mcp: { name: "node_show" },
1414
1422
  slack: false,
1415
- input: nodeInput,
1423
+ input: z6.object({ nodeId: z6.string() }),
1416
1424
  execute: async (ctx, input) => {
1417
- const parsed = nodeInput.parse(input);
1418
- return getNode(ctx.fetch, parsed.node_id);
1425
+ return getNode(ctx.fetch, input.nodeId);
1419
1426
  }
1420
1427
  });
1421
1428
  var adminNodeMetricsCapability = withAdminBinding(telemetryLatestCapability, adminHelp(["admin", "nodes", "metrics"], "Read a bounded telemetry window for one node.", "ornn admin nodes metrics <node-id> [--span 15m] [--start TIME --end TIME] [--max-points 240]", "ornn admin nodes metrics <node-id> --span 15m [--start TIME --end TIME] --max-points 240 --format json", ["canonical node ID"]));
@@ -3136,8 +3143,11 @@ var hardResetInput = rebootInput.extend({
3136
3143
  });
3137
3144
  var assignmentInput = z15.object({
3138
3145
  ...commonInput,
3139
- reservation_id: z15.string().trim().min(1)
3146
+ reservation_id: z15.string().trim().min(1),
3147
+ expected_reservation_id: z15.string().nullable().optional()
3140
3148
  });
3149
+ var machineRebootInput = z15.object({ instanceId: z15.string(), confirm: z15.boolean().optional() });
3150
+ var rebootOperationInput = machineRebootInput.extend({ idempotencyKey: z15.string().optional() });
3141
3151
  function adminLifecycleHelp(command, outcome, human, automation, review) {
3142
3152
  return {
3143
3153
  audience: "admin",
@@ -3160,10 +3170,7 @@ function nodeId2(input) {
3160
3170
  function requestHeaders(idempotencyKey) {
3161
3171
  return idempotencyKey ? { "Idempotency-Key": idempotencyKey } : void 0;
3162
3172
  }
3163
- function preview2(action, payload) {
3164
- return { ok: true, action, payload };
3165
- }
3166
- async function reboot(ctx, input, mode) {
3173
+ async function cliReboot(ctx, input, mode) {
3167
3174
  const parsed = mode === "hard_reset" ? hardResetInput.parse(input) : rebootInput.parse(input);
3168
3175
  const payload = {
3169
3176
  node_id: parsed.node_id,
@@ -3172,67 +3179,95 @@ async function reboot(ctx, input, mode) {
3172
3179
  ...mode === "hard_reset" ? { erase_local_data: true } : {}
3173
3180
  };
3174
3181
  if (!ctx.confirmed)
3175
- return preview2(`nodes.${mode}`, payload);
3182
+ return preview(`nodes.${mode}`, payload);
3176
3183
  if (!parsed.machine_id)
3177
3184
  throw new Error("The live machine target must be resolved before reboot.");
3178
- return rebootNode(ctx.fetch, parsed.machine_id, {
3179
- mode,
3180
- ...parsed.idempotency_key ? { request_id: parsed.idempotency_key } : {}
3181
- }, requestHeaders(parsed.idempotency_key));
3185
+ const capability = mode === "hard_reset" ? adminNodeHardResetCapability : adminNodeRebootCapability;
3186
+ return capability.execute(ctx, {
3187
+ instanceId: parsed.machine_id,
3188
+ idempotencyKey: parsed.idempotency_key
3189
+ });
3190
+ }
3191
+ async function reboot(ctx, input, mode) {
3192
+ const parsed = rebootOperationInput.parse(input);
3193
+ const body2 = { mode, ...parsed.idempotencyKey ? { request_id: parsed.idempotencyKey } : {} };
3194
+ if (!ctx.confirmed)
3195
+ return preview(`nodes.${mode}`, { instanceId: parsed.instanceId, ...body2 });
3196
+ return rebootNode(ctx.fetch, parsed.instanceId, body2, requestHeaders(parsed.idempotencyKey));
3182
3197
  }
3183
3198
  var adminNodeRebootCapability = defineCapability({
3184
3199
  id: "nodes.reboot",
3185
3200
  domain: "fleet",
3186
3201
  roles: ["admin"],
3187
- description: "Reboot the exact live machine backing one managed node after a normalized review.",
3202
+ description: "Internal staff only: reboot a live machine (a node's running instance). Plain OS reboot -- keeps storage and SSH keys. Address the machine by its instance id (see admin_reservation_machines_list)..",
3188
3203
  mutation: "preview-confirm",
3189
3204
  cli: {
3205
+ input: rebootInput,
3206
+ execute: (ctx, input) => cliReboot(ctx, input, "reboot"),
3190
3207
  command: ["admin", "nodes", "reboot"],
3191
3208
  vnext: adminLifecycleHelp(["admin", "nodes", "reboot"], "Reboot one exact live machine while preserving local data and access configuration.", "ornn admin nodes reboot <node-ref> [] [--no-wait] [--timeout SECONDS]", "Unsupported: reboot requires an eligible human terminal.", "Node and live-machine identities, supplier, facility, capacity assignment, and preserved access.")
3192
3209
  },
3193
- mcp: false,
3210
+ mcp: { name: "node_reboot", input: machineRebootInput },
3194
3211
  slack: false,
3195
- input: rebootInput,
3212
+ input: rebootOperationInput,
3196
3213
  execute: (ctx, input) => reboot(ctx, input, "reboot")
3197
3214
  });
3198
3215
  var adminNodeHardResetCapability = defineCapability({
3199
3216
  id: "nodes.hard_reset",
3200
3217
  domain: "fleet",
3201
3218
  roles: ["admin"],
3202
- description: "Hard reset the exact live machine backing one node with explicit local-data erasure scope.",
3219
+ description: "Internal staff only: hard-reset a live machine (a node's running instance) -- clean the host (wipe tenant storage, users, keys, caches) then reboot. This does NOT restore SSH access; after the reset completes, run admin_ssh_key_push to re-push the reservation's organization SSH keys. The tenant KEEPS ownership. Address the machine by its instance id (see admin_reservation_machines_list)..",
3203
3220
  mutation: "preview-confirm",
3204
3221
  cli: {
3222
+ input: hardResetInput,
3223
+ execute: (ctx, input) => cliReboot(ctx, input, "hard_reset"),
3205
3224
  command: ["admin", "nodes", "hard-reset"],
3206
3225
  vnext: adminLifecycleHelp(["admin", "nodes", "hard-reset"], "Erase local tenant data and hard reset one exact live machine.", "ornn admin nodes hard-reset <node-ref> --erase-local-data [] [--no-wait] [--timeout SECONDS]", "Unsupported: hard reset requires an eligible human terminal.", "Node and live-machine identities, supplier, facility, capacity assignment, erased local data, and restored keys.")
3207
3226
  },
3208
- mcp: false,
3227
+ mcp: { name: "node_hard_reset", input: machineRebootInput },
3209
3228
  slack: false,
3210
- input: hardResetInput,
3229
+ input: rebootOperationInput,
3211
3230
  execute: (ctx, input) => reboot(ctx, input, "hard_reset")
3212
3231
  });
3232
+ var nodeAssignInput = z15.object({
3233
+ nodeId: z15.string(),
3234
+ reservationId: z15.string(),
3235
+ expectedReservationId: z15.string().nullable().optional().describe("The reservation the node is expected to currently hold, or null/omitted for a free node. The owner re-checks this under a row lock and rejects the assignment if the node's actual reservation differs, so a mistyped occupied node is never silently evicted. Pass the current reservation id to intentionally move an already-assigned node."),
3236
+ confirm: z15.boolean().optional()
3237
+ });
3213
3238
  var adminNodeAssignCapability = defineCapability({
3214
3239
  id: "nodes.assign",
3215
3240
  domain: "fleet",
3216
3241
  roles: ["admin"],
3217
- description: "Assign one exact node to one exact capacity reservation after consequence review.",
3242
+ description: "Internal staff only: assign one exact node to one exact capacity reservation (whole-node attach), e.g. a rebuilt host replacing a terminated node's slot. The owner verifies the node's current reservation under a row lock: by default the node must be free, so pass expectedReservationId to move a node that already holds a reservation. Does not grow the reservation's size.",
3218
3243
  mutation: "preview-confirm",
3219
3244
  cli: {
3245
+ input: assignmentInput,
3246
+ execute: (ctx, input) => {
3247
+ const parsed = assignmentInput.parse(input);
3248
+ return adminNodeAssignCapability.execute(ctx, {
3249
+ nodeId: nodeId2(parsed),
3250
+ reservationId: parsed.reservation_id,
3251
+ expectedReservationId: parsed.expected_reservation_id ?? null,
3252
+ idempotencyKey: parsed.idempotency_key
3253
+ });
3254
+ },
3220
3255
  command: ["admin", "nodes", "assign"],
3221
3256
  vnext: adminLifecycleHelp(["admin", "nodes", "assign"], "Assign one exact node to one exact capacity reservation.", "ornn admin nodes assign <node-ref> --reservation <reservation-id> [] [--no-wait]", "ornn admin nodes assign <node-id> --reservation <reservation-id> --idempotency-key KEY --format json", "Node, supplier, facility, previous and requested capacity assignments, and tenant access change.")
3222
3257
  },
3223
- mcp: false,
3258
+ mcp: { name: "node_assign", input: nodeAssignInput },
3224
3259
  slack: false,
3225
- input: assignmentInput,
3260
+ input: nodeAssignInput.extend({ idempotencyKey: z15.string().optional() }),
3226
3261
  execute: async (ctx, input) => {
3227
- const parsed = assignmentInput.parse(input);
3228
- const id = nodeId2(parsed);
3229
3262
  const body2 = {
3230
- reservation_id: parsed.reservation_id,
3231
- ...parsed.idempotency_key ? { request_id: parsed.idempotency_key } : {}
3263
+ reservation_id: input.reservationId,
3264
+ check_reservation_id: true,
3265
+ expected_reservation_id: input.expectedReservationId ?? null,
3266
+ ...input.idempotencyKey ? { request_id: input.idempotencyKey } : {}
3232
3267
  };
3233
3268
  if (!ctx.confirmed)
3234
- return preview2("nodes.assign", { node_id: id, ...body2 });
3235
- return assignNode(ctx.fetch, id, body2, requestHeaders(parsed.idempotency_key));
3269
+ return preview("nodes.assign", { nodeId: input.nodeId, ...body2 });
3270
+ return assignNode(ctx.fetch, input.nodeId, body2, requestHeaders(input.idempotencyKey));
3236
3271
  }
3237
3272
  });
3238
3273
  var adminNodeLifecycleCapabilities = [
@@ -3666,14 +3701,43 @@ var machineWaitCapability = cliOnly({
3666
3701
  },
3667
3702
  execute: executeMachines("wait")
3668
3703
  });
3669
- var machineSwitchCapability = cliOnly({
3704
+ var accessSwitchInput = z18.object({
3705
+ reservationId: z18.string(),
3706
+ networkMode: z18.enum(["public", "private"]),
3707
+ sshKeyIds: z18.array(z18.string()).min(1),
3708
+ accessMode: z18.enum(["bare-metal", "virtual-machine"]).optional(),
3709
+ username: z18.string().optional(),
3710
+ requestId: z18.string().regex(/\S/),
3711
+ confirm: z18.boolean().optional()
3712
+ });
3713
+ var nodeIdInput = z18.object({ nodeId: z18.string(), confirm: z18.boolean().optional() });
3714
+ var nodeMaintenanceInput = nodeIdInput.extend({
3715
+ requestId: z18.string().optional(),
3716
+ eraseLocalData: z18.boolean().optional()
3717
+ });
3718
+ function rebootMachine(mode) {
3719
+ return (ctx, input) => input.virtualMachineId ? rebootVirtualMachine(ctx.fetch, input.nodeId, input.virtualMachineId, { mode }) : rebootNode(ctx.fetch, input.nodeId, {
3720
+ mode,
3721
+ ...input.requestId !== void 0 ? { request_id: input.requestId } : {},
3722
+ ...input.eraseLocalData !== void 0 ? { erase_local_data: input.eraseLocalData } : {}
3723
+ });
3724
+ }
3725
+ var machineSwitchCapability = defineCapability({
3670
3726
  id: "access.machines.switch",
3671
3727
  domain: "access",
3672
3728
  roles: ["user"],
3673
- description: "Switch one direct-machine reservation's mode or network intent.",
3729
+ description: "Switch a live reservation between public/private network mode (and optionally VM/Bare Metal) via switch-access. Use this instead of re-launching when machines are already running. Supply a unique requestId and keep it to check progress, including after a timeout. Acceptance does not confirm completion.",
3674
3730
  mutation: "preview-confirm",
3675
- input: machineSwitchInput,
3731
+ input: accessSwitchInput.extend({
3732
+ accessMode: z18.enum(["bare-metal", "virtual-machine"]).nullable().optional(),
3733
+ eraseLocalData: z18.boolean().optional(),
3734
+ machineCount: z18.number().int().positive().optional()
3735
+ }),
3736
+ mcp: { name: "access_switch", input: accessSwitchInput },
3737
+ slack: false,
3676
3738
  cli: {
3739
+ input: machineSwitchInput,
3740
+ execute: executeMachines("switch"),
3677
3741
  command: ["machines", "switch"],
3678
3742
  vnext: {
3679
3743
  arguments: "semantic",
@@ -3689,16 +3753,27 @@ var machineSwitchCapability = cliOnly({
3689
3753
  related: ["machines wait", "connect"]
3690
3754
  }
3691
3755
  },
3692
- execute: executeMachines("switch")
3756
+ execute: (ctx, input) => switchReservationAccess(ctx.fetch, input.reservationId, {
3757
+ ...input.accessMode !== null ? { access_mode: input.accessMode ?? "bare-metal" } : {},
3758
+ ...input.eraseLocalData !== void 0 ? { erase_local_data: input.eraseLocalData } : {},
3759
+ ...input.machineCount !== void 0 ? { machine_count: input.machineCount } : {},
3760
+ network_mode: input.networkMode,
3761
+ request_id: input.requestId,
3762
+ ssh_key_ids: input.sshKeyIds
3763
+ })
3693
3764
  });
3694
- var machineRebootCapability = cliOnly({
3765
+ var machineRebootCapability = defineCapability({
3695
3766
  id: "access.machines.reboot",
3696
3767
  domain: "access",
3697
3768
  roles: ["user"],
3698
- description: "Reboot one exact direct machine after reviewing the access interruption.",
3769
+ description: "Reboot a running reservation machine. Keeps storage and SSH keys. Pass the machine/node instance id from access_show.",
3699
3770
  mutation: "preview-confirm",
3700
- input: machineMaintenanceInput,
3771
+ input: nodeMaintenanceInput.extend({ virtualMachineId: z18.string().optional() }),
3772
+ mcp: { name: "nodes_reboot", input: nodeIdInput },
3773
+ slack: false,
3701
3774
  cli: {
3775
+ input: machineMaintenanceInput,
3776
+ execute: executeMachines("reboot"),
3702
3777
  command: ["machines", "reboot"],
3703
3778
  vnext: {
3704
3779
  arguments: "semantic",
@@ -3718,16 +3793,20 @@ var machineRebootCapability = cliOnly({
3718
3793
  related: ["machines wait", "connect"]
3719
3794
  }
3720
3795
  },
3721
- execute: executeMachines("reboot")
3796
+ execute: rebootMachine("reboot")
3722
3797
  });
3723
- var machineResetCapability = cliOnly({
3798
+ var machineResetCapability = defineCapability({
3724
3799
  id: "access.machines.reset",
3725
3800
  domain: "access",
3726
3801
  roles: ["user"],
3727
- description: "Erase local data and hard reset one exact Bare Metal host.",
3802
+ description: "Hard-reset a running reservation machine: clean (wipe tenant storage, users, keys, caches) then reboot and re-push keys. The tenant keeps ownership.",
3728
3803
  mutation: "preview-confirm",
3729
- input: machineMaintenanceInput,
3804
+ input: nodeMaintenanceInput,
3805
+ mcp: { name: "nodes_hard_reset", input: nodeIdInput },
3806
+ slack: false,
3730
3807
  cli: {
3808
+ input: machineMaintenanceInput,
3809
+ execute: executeMachines("reset"),
3731
3810
  command: ["machines", "reset"],
3732
3811
  vnext: {
3733
3812
  arguments: "semantic",
@@ -3747,7 +3826,7 @@ var machineResetCapability = cliOnly({
3747
3826
  related: ["machines wait", "connect"]
3748
3827
  }
3749
3828
  },
3750
- execute: executeMachines("reset")
3829
+ execute: rebootMachine("hard_reset")
3751
3830
  });
3752
3831
  var sshKeyListCapability = defineCapability({
3753
3832
  id: "access.ssh_keys.list",
@@ -3975,100 +4054,56 @@ var computeCapabilities = [
3975
4054
  sshKeyAssignmentSyncCapability,
3976
4055
  sshKeyAssignmentStatusCapability
3977
4056
  ];
3978
- var nodeIdInput = z18.object({ nodeId: z18.string(), confirm: z18.boolean().optional() });
3979
- function rebootMachine(mode) {
3980
- return (ctx, input) => rebootNode(ctx.fetch, input.nodeId, { mode });
3981
- }
3982
- var accessVerbCapabilities = [
3983
- defineCapability({
3984
- id: "access.show",
3985
- domain: "access",
3986
- roles: ["user"],
3987
- description: "Show VM and Bare Metal SSH access machines for a reservation.",
3988
- mutation: "read",
3989
- input: z18.object({ reservationId: z18.string() }),
3990
- slack: false,
3991
- execute: (ctx, input) => listNodes(ctx.fetch, { reservation_id: input.reservationId })
3992
- }),
3993
- defineCapability({
3994
- id: "access.activate",
3995
- domain: "access",
3996
- roles: ["user"],
3997
- description: "Activate access (bare-metal by default, or VM via accessMode) for a reservation and launch machine(s) with the given SSH key(s), optionally on the private network via networkMode. A VM launches on the reservation's saved disk; pass diskId to choose one, which a reservation without a saved disk needs.",
3998
- mutation: "preview-confirm",
3999
- input: z18.object({
4000
- reservationId: z18.string(),
4001
- sshKeyIds: z18.array(z18.string()).min(1),
4002
- username: z18.string().optional(),
4003
- machineCount: z18.number().int().positive().optional(),
4004
- requestId: z18.string().optional(),
4005
- accessMode: z18.enum(["bare-metal", "vm"]).optional(),
4006
- networkMode: z18.enum(["public", "private"]).optional(),
4007
- diskId: z18.string().optional(),
4008
- storageLoadDriveId: z18.string().optional(),
4009
- storageSaveDriveId: z18.string().optional(),
4010
- confirm: z18.boolean().optional()
4011
- }),
4012
- slack: false,
4013
- // Without disk_id the orchestrator boots "virtual-machine" from the
4014
- // reservation's saved disk and refuses when there is none.
4015
- execute: (ctx, input) => launchReservation(ctx.fetch, input.reservationId, {
4016
- access_mode: input.accessMode === "vm" ? "virtual-machine" : "bare-metal",
4017
- machine_count: input.machineCount ?? 1,
4018
- request_id: input.requestId ?? null,
4019
- ssh_key_ids: input.sshKeyIds,
4020
- ...input.networkMode ? { network_mode: input.networkMode } : {},
4021
- ...input.diskId ? { disk_id: input.diskId } : {},
4022
- ...input.storageLoadDriveId ? { storage_load_drive_id: input.storageLoadDriveId } : {},
4023
- ...input.storageSaveDriveId ? { storage_save_drive_id: input.storageSaveDriveId } : {}
4024
- })
4025
- }),
4026
- defineCapability({
4027
- id: "access.switch",
4028
- domain: "access",
4029
- roles: ["user"],
4030
- description: "Switch a live reservation between public/private network mode (and optionally VM/Bare Metal) via switch-access. Use this instead of re-launching when machines are already running. Supply a unique requestId and keep it to check progress, including after a timeout. Acceptance does not confirm completion.",
4031
- mutation: "preview-confirm",
4032
- input: z18.object({
4033
- reservationId: z18.string(),
4034
- networkMode: z18.enum(["public", "private"]),
4035
- sshKeyIds: z18.array(z18.string()).min(1),
4036
- accessMode: z18.enum(["bare-metal", "virtual-machine"]).optional(),
4037
- username: z18.string().optional(),
4038
- requestId: z18.string().regex(/\S/),
4039
- confirm: z18.boolean().optional()
4040
- }),
4041
- slack: false,
4042
- execute: (ctx, input) => switchReservationAccess(ctx.fetch, input.reservationId, {
4043
- access_mode: input.accessMode ?? "bare-metal",
4044
- network_mode: input.networkMode,
4045
- request_id: input.requestId,
4046
- ssh_key_ids: input.sshKeyIds
4047
- })
4048
- }),
4049
- defineCapability({
4050
- id: "machine.reboot",
4051
- domain: "access",
4052
- roles: ["user"],
4053
- description: "Reboot a running reservation machine. Keeps storage and SSH keys. Pass the machine/node instance id from access_show.",
4054
- mutation: "preview-confirm",
4055
- input: nodeIdInput,
4056
- mcp: { name: "nodes_reboot" },
4057
- slack: false,
4058
- execute: rebootMachine("reboot")
4057
+ var accessShowCapability = defineCapability({
4058
+ id: "access.show",
4059
+ domain: "access",
4060
+ roles: ["user"],
4061
+ description: "Show VM and Bare Metal SSH access machines for a reservation.",
4062
+ mutation: "read",
4063
+ input: z18.object({ reservationId: z18.string() }),
4064
+ slack: false,
4065
+ execute: (ctx, input) => listNodes(ctx.fetch, { reservation_id: input.reservationId })
4066
+ });
4067
+ var accessActivateInput = z18.object({
4068
+ reservationId: z18.string(),
4069
+ sshKeyIds: z18.array(z18.string()).min(1),
4070
+ username: z18.string().optional(),
4071
+ machineCount: z18.number().int().positive().optional(),
4072
+ requestId: z18.string().optional(),
4073
+ accessMode: z18.enum(["bare-metal", "vm"]).optional(),
4074
+ networkMode: z18.enum(["public", "private"]).optional(),
4075
+ diskId: z18.string().optional(),
4076
+ storageLoadDriveId: z18.string().optional(),
4077
+ storageSaveDriveId: z18.string().optional(),
4078
+ confirm: z18.boolean().optional()
4079
+ });
4080
+ var accessActivateCapability = defineCapability({
4081
+ id: "access.activate",
4082
+ domain: "access",
4083
+ roles: ["user"],
4084
+ description: "Activate access (bare-metal by default, or VM via accessMode) for a reservation and launch machine(s) with the given SSH key(s), optionally on the private network via networkMode. A VM launches on the reservation's saved disk; pass diskId to choose one, which a reservation without a saved disk needs.",
4085
+ mutation: "preview-confirm",
4086
+ input: accessActivateInput.extend({
4087
+ diskId: z18.string().nullable().optional(),
4088
+ zone: z18.string().nullable().optional()
4059
4089
  }),
4060
- defineCapability({
4061
- id: "machine.hard_reset",
4062
- domain: "access",
4063
- roles: ["user"],
4064
- description: "Hard-reset a running reservation machine: clean (wipe tenant storage, users, keys, caches) then reboot and re-push keys. The tenant keeps ownership.",
4065
- mutation: "preview-confirm",
4066
- input: nodeIdInput,
4067
- mcp: { name: "nodes_hard_reset" },
4068
- slack: false,
4069
- execute: rebootMachine("hard_reset")
4090
+ mcp: { input: accessActivateInput },
4091
+ slack: false,
4092
+ // Without disk_id the orchestrator boots "virtual-machine" from the
4093
+ // reservation's saved disk and refuses when there is none.
4094
+ execute: (ctx, input) => launchReservation(ctx.fetch, input.reservationId, {
4095
+ access_mode: input.accessMode === "vm" ? "virtual-machine" : "bare-metal",
4096
+ machine_count: input.machineCount ?? 1,
4097
+ request_id: input.requestId ?? null,
4098
+ ssh_key_ids: input.sshKeyIds,
4099
+ ...input.networkMode ? { network_mode: input.networkMode } : {},
4100
+ ...input.diskId || input.diskId === null ? { disk_id: input.diskId } : {},
4101
+ ...input.zone !== void 0 ? { zone: input.zone } : {},
4102
+ ...input.storageLoadDriveId ? { storage_load_drive_id: input.storageLoadDriveId } : {},
4103
+ ...input.storageSaveDriveId ? { storage_save_drive_id: input.storageSaveDriveId } : {}
4070
4104
  })
4071
- ];
4105
+ });
4106
+ var accessVerbCapabilities = [accessShowCapability, accessActivateCapability];
4072
4107
 
4073
4108
  // ../../packages/capabilities/dist/capabilities/credits.js
4074
4109
  import { z as z19 } from "zod";
@@ -4311,12 +4346,14 @@ var clusterCliInput = z21.object({
4311
4346
  wait: z21.boolean().optional(),
4312
4347
  yes: z21.boolean().optional()
4313
4348
  }).strict();
4314
- function clusterExecutor(context) {
4315
- const runtime3 = context.cli?.interaction;
4316
- if (!runtime3?.cluster) {
4317
- throw new Error("This capability must execute through the Ornn CLI cluster runtime.");
4318
- }
4319
- return runtime3.cluster.bind(runtime3);
4349
+ function executeCluster(command) {
4350
+ return (context, input) => {
4351
+ const runtime3 = context.cli?.interaction;
4352
+ if (!runtime3?.cluster) {
4353
+ throw new Error("This capability must execute through the Ornn CLI cluster runtime.");
4354
+ }
4355
+ return runtime3.cluster(command, input, context);
4356
+ };
4320
4357
  }
4321
4358
  function clusterCliCapability({ acceptedReferences = [], automation, command, description, human, id, mutation, outcome, related = [], review }) {
4322
4359
  return defineCapability({
@@ -4343,31 +4380,210 @@ function clusterCliCapability({ acceptedReferences = [], automation, command, de
4343
4380
  },
4344
4381
  mcp: false,
4345
4382
  slack: false,
4346
- execute: async (context, input) => clusterExecutor(context)(id, input)
4383
+ execute: executeCluster(id)
4347
4384
  });
4348
4385
  }
4349
- var clusterCliCapabilities = [
4350
- clusterCliCapability({
4351
- id: "clusters.list",
4386
+ var clusterType = z21.enum(["kubernetes", "slurm"]);
4387
+ var reservationCluster = z21.object({ reservationId: z21.string(), type: clusterType });
4388
+ var reservationWrite = reservationCluster.extend({ confirm: z21.boolean().optional() });
4389
+ var controllerNode = z21.object({
4390
+ controllerId: z21.string(),
4391
+ nodeId: z21.string(),
4392
+ confirm: z21.boolean().optional()
4393
+ });
4394
+ var clusterListCapability = defineCapability({
4395
+ id: "clusters.list",
4396
+ domain: "clusters",
4397
+ roles: ["user"],
4398
+ description: "List this tenant's kubernetes/slurm clusters.",
4399
+ mutation: "read",
4400
+ input: z21.object({}),
4401
+ mcp: { name: "clusters_list" },
4402
+ slack: false,
4403
+ execute: (ctx) => listClusters(ctx.fetch),
4404
+ cli: {
4352
4405
  command: ["clusters", "list"],
4353
- description: "List customer-safe Kubernetes and Slurm cluster facts in one bounded page.",
4354
- mutation: "read",
4355
- outcome: "List clusters without generated names, credentials, or controller details.",
4356
- human: "ornn clusters list [--limit <1-500>] [--cursor <cursor>]",
4357
- automation: "ornn clusters list --limit 50 --format json",
4358
- related: ["clusters show", "clusters wait"]
4359
- }),
4360
- clusterCliCapability({
4361
- id: "clusters.show",
4406
+ input: clusterCliInput,
4407
+ execute: executeCluster("clusters.list"),
4408
+ vnext: {
4409
+ arguments: "semantic",
4410
+ audience: "customer",
4411
+ category: "resource",
4412
+ outcome: "List clusters without generated names, credentials, or controller details.",
4413
+ human: "ornn clusters list [--limit <1-500>] [--cursor <cursor>]",
4414
+ automation: "ornn clusters list --limit 50 --format json",
4415
+ related: ["clusters show", "clusters wait"],
4416
+ acceptedReferences: [],
4417
+ resumableStates: ["working", "ready", "partial", "failed", "ended"]
4418
+ }
4419
+ }
4420
+ });
4421
+ var clusterShowCapability = defineCapability({
4422
+ id: "clusters.show",
4423
+ domain: "clusters",
4424
+ roles: ["user"],
4425
+ description: "Show a kubernetes or slurm cluster's status for a reservation.",
4426
+ mutation: "read",
4427
+ input: reservationCluster,
4428
+ mcp: { name: "clusters_show" },
4429
+ slack: false,
4430
+ execute: (ctx, input) => getReservationCluster(ctx.fetch, input.type, input.reservationId),
4431
+ cli: {
4362
4432
  command: ["clusters", "show"],
4363
- description: "Inspect one exact cluster through safe customer facts.",
4364
- mutation: "read",
4365
- outcome: "Show lifecycle and membership without exposing credentials or controller internals.",
4366
- human: "ornn clusters show [<cluster-id>] [--guided]",
4367
- automation: "ornn clusters show <cluster-id> --format json",
4368
- acceptedReferences: ["canonical cluster ID", "invocation-local guided choice"],
4369
- related: ["clusters wait", "connect"]
4433
+ input: clusterCliInput,
4434
+ execute: executeCluster("clusters.show"),
4435
+ vnext: {
4436
+ arguments: "semantic",
4437
+ audience: "customer",
4438
+ category: "resource",
4439
+ outcome: "Show lifecycle and membership without exposing credentials or controller internals.",
4440
+ human: "ornn clusters show [<cluster-id>] [--guided]",
4441
+ automation: "ornn clusters show <cluster-id> --format json",
4442
+ acceptedReferences: ["canonical cluster ID", "invocation-local guided choice"],
4443
+ related: ["clusters wait", "connect"],
4444
+ resumableStates: ["working", "ready", "partial", "failed", "ended"]
4445
+ }
4446
+ }
4447
+ });
4448
+ var clusterTeardownCapability = defineCapability({
4449
+ id: "clusters.teardown",
4450
+ domain: "clusters",
4451
+ roles: ["user"],
4452
+ description: "Tear down a kubernetes or slurm cluster on a reservation.",
4453
+ mutation: "preview-confirm",
4454
+ input: reservationWrite.extend({ idempotencyKey: z21.string().optional() }),
4455
+ mcp: { name: "clusters_teardown", input: reservationWrite },
4456
+ slack: false,
4457
+ execute: (ctx, input) => teardownReservationCluster(ctx.fetch, input.type, input.reservationId, input.idempotencyKey ? { headers: { "Idempotency-Key": input.idempotencyKey } } : void 0),
4458
+ cli: {
4459
+ command: ["clusters", "teardown"],
4460
+ input: clusterCliInput,
4461
+ execute: executeCluster("clusters.teardown"),
4462
+ vnext: {
4463
+ arguments: "semantic",
4464
+ audience: "customer",
4465
+ category: "resource",
4466
+ outcome: "End cluster lifecycle while reporting partial member failures and continuing reservation charges.",
4467
+ human: "ornn clusters teardown [<cluster-id>] [--guided] [--no-wait]",
4468
+ automation: "ornn clusters teardown <cluster-id> --idempotency-key <key> --format json",
4469
+ acceptedReferences: ["canonical cluster ID", "invocation-local guided choice"],
4470
+ review: "The cluster and native access end; the capacity reservation and its charges remain.",
4471
+ related: ["clusters show", "reservations show"],
4472
+ resumableStates: ["working", "ready", "partial", "failed", "ended"]
4473
+ }
4474
+ }
4475
+ });
4476
+ var clusterCredentialsCapability = defineCapability({
4477
+ id: "cluster.credentials",
4478
+ domain: "clusters",
4479
+ roles: ["user"],
4480
+ description: "Fetch a kubernetes or slurm cluster's connection credentials for a reservation.",
4481
+ mutation: "read",
4482
+ input: reservationCluster,
4483
+ mcp: { name: "clusters_credentials" },
4484
+ slack: false,
4485
+ execute: (ctx, input) => getReservationClusterCredentials(ctx.fetch, input.type, input.reservationId)
4486
+ });
4487
+ var clusterAddNodeCapability = defineCapability({
4488
+ id: "clusters.add_node",
4489
+ domain: "clusters",
4490
+ roles: ["user"],
4491
+ description: "Join a node to a controller.",
4492
+ mutation: "preview-confirm",
4493
+ input: controllerNode.extend({ idempotencyKey: z21.string().optional() }),
4494
+ mcp: { name: "clusters_add_node", input: controllerNode },
4495
+ slack: false,
4496
+ cli: {
4497
+ command: ["clusters", "add-node"],
4498
+ input: clusterCliInput,
4499
+ execute: executeCluster("clusters.add_node"),
4500
+ vnext: {
4501
+ arguments: "semantic",
4502
+ audience: "customer",
4503
+ category: "resource",
4504
+ outcome: "Add one currently eligible machine, or rediscover that exact membership goal.",
4505
+ human: "ornn clusters add-node [<cluster-id>] [<machine-id-or-hostname>] [--guided] [--no-wait]",
4506
+ automation: "ornn clusters add-node <cluster-id> <machine-id> --idempotency-key <key> --format json",
4507
+ acceptedReferences: [
4508
+ "canonical cluster ID",
4509
+ "canonical machine ID",
4510
+ "exact unique eligible hostname",
4511
+ "invocation-local guided choice"
4512
+ ],
4513
+ review: "Review the exact cluster, selected machine, and resulting membership count.",
4514
+ resumableStates: ["working", "ready", "partial", "failed", "ended"],
4515
+ related: ["clusters eligible-machines", "clusters remove-node"]
4516
+ }
4517
+ },
4518
+ execute: (ctx, input) => addControllerNode(ctx.fetch, input.controllerId, input.nodeId, input.idempotencyKey ? { headers: { "Idempotency-Key": input.idempotencyKey } } : void 0)
4519
+ });
4520
+ var clusterRemoveNodeCapability = defineCapability({
4521
+ id: "clusters.remove_node",
4522
+ domain: "clusters",
4523
+ roles: ["user"],
4524
+ description: "Remove a node from a controller.",
4525
+ mutation: "preview-confirm",
4526
+ input: controllerNode.extend({ idempotencyKey: z21.string().optional() }),
4527
+ mcp: { name: "clusters_remove_node", input: controllerNode },
4528
+ slack: false,
4529
+ cli: {
4530
+ command: ["clusters", "remove-node"],
4531
+ input: clusterCliInput,
4532
+ execute: executeCluster("clusters.remove_node"),
4533
+ vnext: {
4534
+ arguments: "semantic",
4535
+ audience: "customer",
4536
+ category: "resource",
4537
+ outcome: "Remove one exact member, or rediscover that exact membership goal.",
4538
+ human: "ornn clusters remove-node [<cluster-id>] [<machine-id-or-hostname>] [--guided] [--no-wait]",
4539
+ automation: "ornn clusters remove-node <cluster-id> <machine-id> --idempotency-key <key> --format json",
4540
+ acceptedReferences: [
4541
+ "canonical cluster ID",
4542
+ "canonical machine ID",
4543
+ "exact unique member hostname",
4544
+ "invocation-local guided choice"
4545
+ ],
4546
+ review: "Review the exact cluster, removed machine, access reduction, and resulting membership count.",
4547
+ resumableStates: ["working", "ready", "partial", "failed", "ended"],
4548
+ related: ["clusters eligible-machines", "clusters add-node"]
4549
+ }
4550
+ },
4551
+ execute: (ctx, input) => removeControllerNode(ctx.fetch, input.controllerId, input.nodeId, input.idempotencyKey ? { headers: { "Idempotency-Key": input.idempotencyKey } } : void 0)
4552
+ });
4553
+ var clusterCreateInput = z21.object({
4554
+ reservationId: z21.string(),
4555
+ type: clusterType,
4556
+ networkMode: z21.enum(["public", "private"]).optional(),
4557
+ nodeIds: z21.array(z21.string()).optional(),
4558
+ nodeCount: z21.number().int().positive().optional(),
4559
+ confirm: z21.boolean().optional()
4560
+ }).strict();
4561
+ var clusterCreateCapability = defineCapability({
4562
+ id: "cluster.create",
4563
+ domain: "clusters",
4564
+ roles: ["user"],
4565
+ description: "Launch a kubernetes or slurm cluster on a reservation.",
4566
+ mutation: "preview-confirm",
4567
+ input: clusterCreateInput.extend({
4568
+ virtualMachineIds: z21.array(z21.string()).optional(),
4569
+ sshKeyIds: z21.array(z21.string()).optional(),
4570
+ idempotencyKey: z21.string().optional()
4370
4571
  }),
4572
+ mcp: { name: "clusters_create", input: clusterCreateInput },
4573
+ slack: false,
4574
+ execute: (ctx, input) => createController(ctx.fetch, {
4575
+ kind: input.type,
4576
+ reservation_id: input.reservationId,
4577
+ ...input.networkMode ? { network_mode: input.networkMode } : {},
4578
+ ...input.nodeCount !== void 0 ? { node_count: input.nodeCount } : {},
4579
+ ...input.nodeIds?.length ? { node_ids: input.nodeIds } : {},
4580
+ ...input.virtualMachineIds?.length ? { virtual_machine_ids: input.virtualMachineIds } : {},
4581
+ ...input.sshKeyIds?.length ? { ssh_key_ids: input.sshKeyIds } : {}
4582
+ }, input.idempotencyKey ? { headers: { "Idempotency-Key": input.idempotencyKey } } : void 0)
4583
+ });
4584
+ var clusterCapabilities = [
4585
+ clusterListCapability,
4586
+ clusterShowCapability,
4371
4587
  clusterCliCapability({
4372
4588
  id: "clusters.wait",
4373
4589
  command: ["clusters", "wait"],
@@ -4390,72 +4606,6 @@ var clusterCliCapabilities = [
4390
4606
  acceptedReferences: ["canonical cluster ID", "invocation-local guided choice"],
4391
4607
  related: ["clusters add-node", "clusters remove-node"]
4392
4608
  }),
4393
- clusterCliCapability({
4394
- id: "clusters.add_node",
4395
- command: ["clusters", "add-node"],
4396
- description: "Reconcile one exact cluster membership-increase goal.",
4397
- mutation: "preview-confirm",
4398
- outcome: "Add one currently eligible machine, or rediscover that exact membership goal.",
4399
- human: "ornn clusters add-node [<cluster-id>] [<machine-id-or-hostname>] [--guided] [--no-wait]",
4400
- automation: "ornn clusters add-node <cluster-id> <machine-id> --idempotency-key <key> --format json",
4401
- acceptedReferences: [
4402
- "canonical cluster ID",
4403
- "canonical machine ID",
4404
- "exact unique eligible hostname",
4405
- "invocation-local guided choice"
4406
- ],
4407
- review: "Review the exact cluster, selected machine, and resulting membership count.",
4408
- related: ["clusters eligible-machines", "clusters remove-node"]
4409
- }),
4410
- clusterCliCapability({
4411
- id: "clusters.remove_node",
4412
- command: ["clusters", "remove-node"],
4413
- description: "Reconcile one exact cluster membership-reduction goal.",
4414
- mutation: "preview-confirm",
4415
- outcome: "Remove one exact member, or rediscover that exact membership goal.",
4416
- human: "ornn clusters remove-node [<cluster-id>] [<machine-id-or-hostname>] [--guided] [--no-wait]",
4417
- automation: "ornn clusters remove-node <cluster-id> <machine-id> --idempotency-key <key> --format json",
4418
- acceptedReferences: [
4419
- "canonical cluster ID",
4420
- "canonical machine ID",
4421
- "exact unique member hostname",
4422
- "invocation-local guided choice"
4423
- ],
4424
- review: "Review the exact cluster, removed machine, access reduction, and resulting membership count.",
4425
- related: ["clusters eligible-machines", "clusters add-node"]
4426
- }),
4427
- clusterCliCapability({
4428
- id: "clusters.teardown",
4429
- command: ["clusters", "teardown"],
4430
- description: "Tear down one cluster without surrendering its capacity reservation.",
4431
- mutation: "preview-confirm",
4432
- outcome: "End cluster lifecycle while reporting partial member failures and continuing reservation charges.",
4433
- human: "ornn clusters teardown [<cluster-id>] [--guided] [--no-wait]",
4434
- automation: "ornn clusters teardown <cluster-id> --idempotency-key <key> --format json",
4435
- acceptedReferences: ["canonical cluster ID", "invocation-local guided choice"],
4436
- review: "The cluster and native access end; the capacity reservation and its charges remain.",
4437
- related: ["clusters show", "reservations show"]
4438
- })
4439
- ];
4440
- var clusterType = z21.enum(["kubernetes", "slurm"]);
4441
- var reservationCluster = z21.object({ reservationId: z21.string(), type: clusterType });
4442
- var controllerNode = z21.object({
4443
- controllerId: z21.string(),
4444
- nodeId: z21.string(),
4445
- confirm: z21.boolean().optional()
4446
- });
4447
- var clusterCapabilities = [
4448
- defineCapability({
4449
- id: "cluster.list",
4450
- domain: "clusters",
4451
- roles: ["user"],
4452
- description: "List this tenant's kubernetes/slurm clusters.",
4453
- mutation: "read",
4454
- input: z21.object({}),
4455
- mcp: { name: "clusters_list" },
4456
- slack: false,
4457
- execute: (ctx) => listClusters(ctx.fetch)
4458
- }),
4459
4609
  defineCapability({
4460
4610
  id: "cluster.reservations.list",
4461
4611
  domain: "clusters",
@@ -4472,52 +4622,8 @@ var clusterCapabilities = [
4472
4622
  return listReservations(ctx.fetch, { status: "active", limit: 100, cursor: input.cursor });
4473
4623
  }
4474
4624
  }),
4475
- defineCapability({
4476
- id: "cluster.create",
4477
- domain: "clusters",
4478
- roles: ["user"],
4479
- description: "Launch a kubernetes or slurm cluster on a reservation.",
4480
- mutation: "preview-confirm",
4481
- input: z21.object({
4482
- reservationId: z21.string(),
4483
- type: clusterType,
4484
- networkMode: z21.enum(["public", "private"]).optional(),
4485
- nodeIds: z21.array(z21.string()).optional(),
4486
- nodeCount: z21.number().int().positive().optional(),
4487
- confirm: z21.boolean().optional()
4488
- }).strict(),
4489
- mcp: { name: "clusters_create" },
4490
- slack: false,
4491
- execute: (ctx, input) => createController(ctx.fetch, {
4492
- kind: input.type,
4493
- reservation_id: input.reservationId,
4494
- ...input.networkMode ? { network_mode: input.networkMode } : {},
4495
- ...input.nodeCount !== void 0 ? { node_count: input.nodeCount } : {},
4496
- ...input.nodeIds?.length ? { node_ids: input.nodeIds } : {}
4497
- })
4498
- }),
4499
- defineCapability({
4500
- id: "cluster.show",
4501
- domain: "clusters",
4502
- roles: ["user"],
4503
- description: "Show a kubernetes or slurm cluster's status for a reservation.",
4504
- mutation: "read",
4505
- input: reservationCluster,
4506
- mcp: { name: "clusters_show" },
4507
- slack: false,
4508
- execute: (ctx, input) => getReservationCluster(ctx.fetch, input.type, input.reservationId)
4509
- }),
4510
- defineCapability({
4511
- id: "cluster.credentials",
4512
- domain: "clusters",
4513
- roles: ["user"],
4514
- description: "Fetch a kubernetes or slurm cluster's connection credentials for a reservation.",
4515
- mutation: "read",
4516
- input: reservationCluster,
4517
- mcp: { name: "clusters_credentials" },
4518
- slack: false,
4519
- execute: (ctx, input) => getReservationClusterCredentials(ctx.fetch, input.type, input.reservationId)
4520
- }),
4625
+ clusterCreateCapability,
4626
+ clusterCredentialsCapability,
4521
4627
  defineCapability({
4522
4628
  id: "cluster.kubeconfig",
4523
4629
  domain: "clusters",
@@ -4528,46 +4634,19 @@ var clusterCapabilities = [
4528
4634
  mcp: { name: "clusters_kubeconfig" },
4529
4635
  slack: false,
4530
4636
  execute: async (ctx, input) => {
4531
- const credentials = await getReservationClusterCredentials(ctx.fetch, "kubernetes", input.reservationId);
4637
+ const credentials = await clusterCredentialsCapability.execute(ctx, {
4638
+ reservationId: input.reservationId,
4639
+ type: "kubernetes"
4640
+ });
4532
4641
  const kubeconfig = String(credentials?.kubeconfig || "");
4533
4642
  if (!kubeconfig.trim())
4534
4643
  throw new Error("Kubernetes kubeconfig is not ready yet.");
4535
4644
  return { kubeconfig };
4536
4645
  }
4537
4646
  }),
4538
- defineCapability({
4539
- id: "cluster.add_node",
4540
- domain: "clusters",
4541
- roles: ["user"],
4542
- description: "Join a node to a controller.",
4543
- mutation: "preview-confirm",
4544
- input: controllerNode,
4545
- mcp: { name: "clusters_add_node" },
4546
- slack: false,
4547
- execute: (ctx, input) => addControllerNode(ctx.fetch, input.controllerId, input.nodeId)
4548
- }),
4549
- defineCapability({
4550
- id: "cluster.remove_node",
4551
- domain: "clusters",
4552
- roles: ["user"],
4553
- description: "Remove a node from a controller.",
4554
- mutation: "preview-confirm",
4555
- input: controllerNode,
4556
- mcp: { name: "clusters_remove_node" },
4557
- slack: false,
4558
- execute: (ctx, input) => removeControllerNode(ctx.fetch, input.controllerId, input.nodeId)
4559
- }),
4560
- defineCapability({
4561
- id: "cluster.teardown",
4562
- domain: "clusters",
4563
- roles: ["user"],
4564
- description: "Tear down a kubernetes or slurm cluster on a reservation.",
4565
- mutation: "preview-confirm",
4566
- input: reservationCluster.extend({ confirm: z21.boolean().optional() }),
4567
- mcp: { name: "clusters_teardown" },
4568
- slack: false,
4569
- execute: (ctx, input) => teardownReservationCluster(ctx.fetch, input.type, input.reservationId)
4570
- })
4647
+ clusterAddNodeCapability,
4648
+ clusterRemoveNodeCapability,
4649
+ clusterTeardownCapability
4571
4650
  ];
4572
4651
 
4573
4652
  // ../../packages/capabilities/dist/capabilities/external-buckets.js
@@ -5129,8 +5208,8 @@ function mutationOptions(idempotencyKey) {
5129
5208
  return idempotencyKey ? { headers: { "Idempotency-Key": idempotencyKey } } : void 0;
5130
5209
  }
5131
5210
  var reservationInput = z25.object({ reservationId: z25.string() });
5132
- var reservationWrite = reservationInput.extend({ confirm: z25.boolean().optional() });
5133
- var attachInput = reservationWrite.extend({
5211
+ var reservationWrite2 = reservationInput.extend({ confirm: z25.boolean().optional() });
5212
+ var attachInput = reservationWrite2.extend({
5134
5213
  driveId: z25.string(),
5135
5214
  readOnly: z25.boolean().optional()
5136
5215
  });
@@ -5237,8 +5316,8 @@ var volumeMountDetachCapability = defineCapability({
5237
5316
  roles: ["user"],
5238
5317
  description: "Detach the reservation storage attachment (after unmount) so the volume can be deleted.",
5239
5318
  mutation: "preview-confirm",
5240
- input: reservationWrite.extend({ idempotencyKey: z25.string().optional() }),
5241
- mcp: { name: "storage_undeploy", input: reservationWrite },
5319
+ input: reservationWrite2.extend({ idempotencyKey: z25.string().optional() }),
5320
+ mcp: { name: "storage_undeploy", input: reservationWrite2 },
5242
5321
  slack: false,
5243
5322
  cli: {
5244
5323
  command: ["volume-mounts", "detach"],
@@ -5491,6 +5570,7 @@ var slackListingCreateParams = {
5491
5570
  };
5492
5571
  var listCatalogTermsCapability = defineCapability({
5493
5572
  id: "listings.catalog_terms",
5573
+ mcp: false,
5494
5574
  domain: "listings",
5495
5575
  roles: ["admin"],
5496
5576
  description: "Dump the orchestrator hardware dictionary (display name + aliases). Call once and pick from it. Hardware fields on listings must match a term. Optional kind filter: gpu, cpu, node, or link.",
@@ -5512,6 +5592,7 @@ var listCatalogTermsCapability = defineCapability({
5512
5592
  });
5513
5593
  var listListingsCapability = defineCapability({
5514
5594
  id: "listings.available",
5595
+ mcp: false,
5515
5596
  domain: "listings",
5516
5597
  roles: ["user", "admin"],
5517
5598
  description: "List currently available marketplace listings. GPU, CPU, and fabric filters must be orchestrator catalog display names, canonicals, or aliases \u2014 not raw slang or spec-sheet text. Site may be a facility nickname. Returns spec-shaped JSON plus public reserve/OG/PDF URLs. Filters combine as AND. Date filters are inclusive YYYY-MM-DD.",
@@ -6901,7 +6982,7 @@ var catalog = [
6901
6982
  ...computeCapabilities,
6902
6983
  ...fleetCapabilities.filter((capability) => capability.id !== "node.exec"),
6903
6984
  ...networkCapabilities,
6904
- ...clusterCliCapabilities,
6985
+ ...clusterCapabilities,
6905
6986
  ...tokenCapabilities,
6906
6987
  ...userCapabilities,
6907
6988
  ...volumeCapabilities,
@@ -6909,7 +6990,6 @@ var catalog = [
6909
6990
  ...externalBucketCapabilities,
6910
6991
  ...evidenceCapabilities,
6911
6992
  ...observabilityCapabilities,
6912
- ...clusterCapabilities,
6913
6993
  ...accessVerbCapabilities,
6914
6994
  reservationKeysPushCapability,
6915
6995
  ...metricsCapabilities,
@@ -7188,6 +7268,8 @@ export {
7188
7268
  ADMIN_CLI_ROOTS,
7189
7269
  CLI_MIGRATION_GUIDE_URL,
7190
7270
  LEGACY_CLI_MIGRATIONS,
7271
+ accessActivateCapability,
7272
+ accessShowCapability,
7191
7273
  bucketConnectCapability,
7192
7274
  bucketDisconnectCapability,
7193
7275
  bucketListCapability,
@@ -7197,9 +7279,19 @@ export {
7197
7279
  byCliCommand,
7198
7280
  byMcpName,
7199
7281
  catalog,
7282
+ clusterAddNodeCapability,
7283
+ clusterCreateCapability,
7284
+ clusterCredentialsCapability,
7285
+ clusterListCapability,
7286
+ clusterRemoveNodeCapability,
7287
+ clusterShowCapability,
7288
+ clusterTeardownCapability,
7200
7289
  findLegacyCliMigration,
7201
7290
  forRole,
7202
7291
  gpuDisplay,
7292
+ machineRebootCapability,
7293
+ machineResetCapability,
7294
+ machineSwitchCapability,
7203
7295
  metricsHistoryCapability,
7204
7296
  metricsSnapshotCapability,
7205
7297
  parseHardwareCatalog,