@integrity-labs/agt-cli 0.15.37 → 0.16.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bin/agt.js +50 -50
- package/dist/bin/agt.js.map +1 -1
- package/dist/{chunk-XB7IGF3K.js → chunk-LU6L2J32.js} +118 -11
- package/dist/chunk-LU6L2J32.js.map +1 -0
- package/dist/{claude-pair-runtime-GLO2D7WP.js → claude-pair-runtime-GS6AOYHS.js} +2 -2
- package/dist/claude-pair-runtime-GS6AOYHS.js.map +1 -0
- package/dist/lib/manager-worker.js +131 -107
- package/dist/lib/manager-worker.js.map +1 -1
- package/mcp/slack-channel.js +99 -22
- package/package.json +1 -1
- package/dist/chunk-XB7IGF3K.js.map +0 -1
- package/dist/claude-pair-runtime-GLO2D7WP.js.map +0 -1
package/dist/bin/agt.js
CHANGED
|
@@ -48,7 +48,7 @@ import {
|
|
|
48
48
|
success,
|
|
49
49
|
table,
|
|
50
50
|
warn
|
|
51
|
-
} from "../chunk-
|
|
51
|
+
} from "../chunk-LU6L2J32.js";
|
|
52
52
|
|
|
53
53
|
// src/bin/agt.ts
|
|
54
54
|
import { join as join10 } from "path";
|
|
@@ -2165,8 +2165,8 @@ function preflightAws() {
|
|
|
2165
2165
|
if (aws.status !== 0) {
|
|
2166
2166
|
return "AWS CLI not found. Install: https://aws.amazon.com/cli/";
|
|
2167
2167
|
}
|
|
2168
|
-
const
|
|
2169
|
-
if (
|
|
2168
|
+
const plugin = spawnSync("session-manager-plugin", [], { stdio: "ignore" });
|
|
2169
|
+
if (plugin.error) {
|
|
2170
2170
|
return "session-manager-plugin not found. Install: brew install --cask session-manager-plugin";
|
|
2171
2171
|
}
|
|
2172
2172
|
return null;
|
|
@@ -3732,7 +3732,7 @@ import { execFileSync, execSync } from "child_process";
|
|
|
3732
3732
|
import { existsSync as existsSync5, realpathSync } from "fs";
|
|
3733
3733
|
import chalk17 from "chalk";
|
|
3734
3734
|
import ora15 from "ora";
|
|
3735
|
-
var cliVersion = true ? "0.
|
|
3735
|
+
var cliVersion = true ? "0.16.0" : "dev";
|
|
3736
3736
|
async function fetchLatestVersion() {
|
|
3737
3737
|
const host2 = getHost();
|
|
3738
3738
|
if (!host2) return null;
|
|
@@ -3954,24 +3954,24 @@ async function checkForUpdateOnStartup() {
|
|
|
3954
3954
|
}
|
|
3955
3955
|
}
|
|
3956
3956
|
|
|
3957
|
-
// src/commands/
|
|
3957
|
+
// src/commands/integration.ts
|
|
3958
3958
|
import chalk18 from "chalk";
|
|
3959
3959
|
import ora16 from "ora";
|
|
3960
|
-
async function
|
|
3960
|
+
async function integrationListCommand() {
|
|
3961
3961
|
const json = isJsonMode();
|
|
3962
|
-
const spinner = ora16({ text: "Fetching
|
|
3962
|
+
const spinner = ora16({ text: "Fetching integrations\u2026", isSilent: json }).start();
|
|
3963
3963
|
try {
|
|
3964
3964
|
const data = await api.get("/integrations/bindings");
|
|
3965
3965
|
spinner.stop();
|
|
3966
3966
|
if (json) {
|
|
3967
|
-
jsonOutput({
|
|
3967
|
+
jsonOutput({ integrations: data });
|
|
3968
3968
|
return;
|
|
3969
3969
|
}
|
|
3970
3970
|
if (!data.length) {
|
|
3971
|
-
info("No
|
|
3971
|
+
info("No integrations found for this team.");
|
|
3972
3972
|
return;
|
|
3973
3973
|
}
|
|
3974
|
-
console.log(chalk18.bold("\nAvailable
|
|
3974
|
+
console.log(chalk18.bold("\nAvailable Integrations:\n"));
|
|
3975
3975
|
for (const p of data) {
|
|
3976
3976
|
const statusColor = p.status === "published" ? chalk18.green : p.status === "archived" ? chalk18.gray : chalk18.yellow;
|
|
3977
3977
|
console.log(
|
|
@@ -3984,32 +3984,32 @@ async function pluginListCommand() {
|
|
|
3984
3984
|
handleError(err);
|
|
3985
3985
|
}
|
|
3986
3986
|
}
|
|
3987
|
-
async function
|
|
3987
|
+
async function integrationShowCommand(slug) {
|
|
3988
3988
|
const json = isJsonMode();
|
|
3989
|
-
const spinner = ora16({ text: "Fetching
|
|
3989
|
+
const spinner = ora16({ text: "Fetching integration\u2026", isSilent: json }).start();
|
|
3990
3990
|
try {
|
|
3991
3991
|
const all = await api.get("/integrations/bindings");
|
|
3992
|
-
const
|
|
3993
|
-
if (!
|
|
3992
|
+
const integration2 = all.find((p) => p.slug === slug);
|
|
3993
|
+
if (!integration2) {
|
|
3994
3994
|
spinner.stop();
|
|
3995
|
-
error(`
|
|
3995
|
+
error(`Integration "${slug}" not found.`);
|
|
3996
3996
|
process.exitCode = 1;
|
|
3997
3997
|
return;
|
|
3998
3998
|
}
|
|
3999
|
-
const scopes = await api.get(`/integrations/bindings/${
|
|
3999
|
+
const scopes = await api.get(`/integrations/bindings/${integration2.id}/scopes`);
|
|
4000
4000
|
spinner.stop();
|
|
4001
4001
|
if (json) {
|
|
4002
|
-
jsonOutput({
|
|
4002
|
+
jsonOutput({ integration: integration2, scopes });
|
|
4003
4003
|
return;
|
|
4004
4004
|
}
|
|
4005
4005
|
console.log(chalk18.bold(`
|
|
4006
|
-
${
|
|
4007
|
-
if (
|
|
4006
|
+
${integration2.name}`), chalk18.dim(`(${integration2.slug})`));
|
|
4007
|
+
if (integration2.description) console.log(chalk18.dim(integration2.description));
|
|
4008
4008
|
console.log();
|
|
4009
|
-
console.log(` Status: ${
|
|
4010
|
-
console.log(` Category: ${
|
|
4011
|
-
console.log(` Toolkits: ${
|
|
4012
|
-
console.log(` Skills: ${
|
|
4009
|
+
console.log(` Status: ${integration2.status} v${integration2.version}`);
|
|
4010
|
+
console.log(` Category: ${integration2.category}`);
|
|
4011
|
+
console.log(` Toolkits: ${integration2.required_toolkits.join(", ") || "none"}`);
|
|
4012
|
+
console.log(` Skills: ${integration2.skills?.length ?? 0}`);
|
|
4013
4013
|
if (scopes.length > 0) {
|
|
4014
4014
|
console.log(chalk18.bold("\n Permission Scopes:\n"));
|
|
4015
4015
|
for (const s of scopes) {
|
|
@@ -4026,15 +4026,15 @@ ${plugin2.name}`), chalk18.dim(`(${plugin2.slug})`));
|
|
|
4026
4026
|
handleError(err);
|
|
4027
4027
|
}
|
|
4028
4028
|
}
|
|
4029
|
-
async function
|
|
4029
|
+
async function integrationInstallCommand(slug, options) {
|
|
4030
4030
|
const json = isJsonMode();
|
|
4031
|
-
const spinner = ora16({ text: "Installing
|
|
4031
|
+
const spinner = ora16({ text: "Installing integration\u2026", isSilent: json }).start();
|
|
4032
4032
|
try {
|
|
4033
4033
|
const all = await api.get("/integrations/bindings");
|
|
4034
|
-
const
|
|
4035
|
-
if (!
|
|
4034
|
+
const integration2 = all.find((p) => p.slug === slug);
|
|
4035
|
+
if (!integration2) {
|
|
4036
4036
|
spinner.stop();
|
|
4037
|
-
error(`
|
|
4037
|
+
error(`Integration "${slug}" not found.`);
|
|
4038
4038
|
process.exitCode = 1;
|
|
4039
4039
|
return;
|
|
4040
4040
|
}
|
|
@@ -4049,15 +4049,15 @@ async function pluginInstallCommand(slug, options) {
|
|
|
4049
4049
|
const scopes = options.scopes?.split(",").map((s) => s.trim()).filter(Boolean) ?? [];
|
|
4050
4050
|
const result = await api.post("/integrations/bindings/install", {
|
|
4051
4051
|
agent_id: agent2.agent_id,
|
|
4052
|
-
plugin_id:
|
|
4052
|
+
plugin_id: integration2.id,
|
|
4053
4053
|
scopes
|
|
4054
4054
|
});
|
|
4055
4055
|
spinner.stop();
|
|
4056
4056
|
if (json) {
|
|
4057
|
-
jsonOutput({
|
|
4057
|
+
jsonOutput({ agent_integration: result });
|
|
4058
4058
|
return;
|
|
4059
4059
|
}
|
|
4060
|
-
success(`Installed "${
|
|
4060
|
+
success(`Installed "${integration2.name}" on agent "${options.agent}"`);
|
|
4061
4061
|
if (scopes.length) {
|
|
4062
4062
|
info(`Granted scopes: ${scopes.join(", ")}`);
|
|
4063
4063
|
}
|
|
@@ -4076,15 +4076,15 @@ async function pluginInstallCommand(slug, options) {
|
|
|
4076
4076
|
handleError(err);
|
|
4077
4077
|
}
|
|
4078
4078
|
}
|
|
4079
|
-
async function
|
|
4079
|
+
async function integrationUninstallCommand(slug, options) {
|
|
4080
4080
|
const json = isJsonMode();
|
|
4081
|
-
const spinner = ora16({ text: "Uninstalling
|
|
4081
|
+
const spinner = ora16({ text: "Uninstalling integration\u2026", isSilent: json }).start();
|
|
4082
4082
|
try {
|
|
4083
4083
|
const all = await api.get("/integrations/bindings");
|
|
4084
|
-
const
|
|
4085
|
-
if (!
|
|
4084
|
+
const integration2 = all.find((p) => p.slug === slug);
|
|
4085
|
+
if (!integration2) {
|
|
4086
4086
|
spinner.stop();
|
|
4087
|
-
error(`
|
|
4087
|
+
error(`Integration "${slug}" not found.`);
|
|
4088
4088
|
process.exitCode = 1;
|
|
4089
4089
|
return;
|
|
4090
4090
|
}
|
|
@@ -4098,16 +4098,16 @@ async function pluginUninstallCommand(slug, options) {
|
|
|
4098
4098
|
}
|
|
4099
4099
|
await api.post("/integrations/bindings/uninstall", {
|
|
4100
4100
|
agent_id: agent2.agent_id,
|
|
4101
|
-
plugin_id:
|
|
4101
|
+
plugin_id: integration2.id
|
|
4102
4102
|
});
|
|
4103
4103
|
spinner.stop();
|
|
4104
|
-
success(`Uninstalled "${
|
|
4104
|
+
success(`Uninstalled "${integration2.name}" from agent "${options.agent}"`);
|
|
4105
4105
|
} catch (err) {
|
|
4106
4106
|
spinner.stop();
|
|
4107
4107
|
handleError(err);
|
|
4108
4108
|
}
|
|
4109
4109
|
}
|
|
4110
|
-
async function
|
|
4110
|
+
async function integrationRequestsCommand() {
|
|
4111
4111
|
const json = isJsonMode();
|
|
4112
4112
|
const spinner = ora16({ text: "Fetching scope requests\u2026", isSilent: json }).start();
|
|
4113
4113
|
try {
|
|
@@ -4133,7 +4133,7 @@ async function pluginRequestsCommand() {
|
|
|
4133
4133
|
handleError(err);
|
|
4134
4134
|
}
|
|
4135
4135
|
}
|
|
4136
|
-
async function
|
|
4136
|
+
async function integrationApproveCommand(requestId, options) {
|
|
4137
4137
|
const json = isJsonMode();
|
|
4138
4138
|
const spinner = ora16({ text: "Approving request\u2026", isSilent: json }).start();
|
|
4139
4139
|
try {
|
|
@@ -4152,7 +4152,7 @@ async function pluginApproveCommand(requestId, options) {
|
|
|
4152
4152
|
handleError(err);
|
|
4153
4153
|
}
|
|
4154
4154
|
}
|
|
4155
|
-
async function
|
|
4155
|
+
async function integrationDenyCommand(requestId, options) {
|
|
4156
4156
|
const json = isJsonMode();
|
|
4157
4157
|
const spinner = ora16({ text: "Denying request\u2026", isSilent: json }).start();
|
|
4158
4158
|
try {
|
|
@@ -4181,7 +4181,7 @@ function handleError(err) {
|
|
|
4181
4181
|
}
|
|
4182
4182
|
|
|
4183
4183
|
// src/bin/agt.ts
|
|
4184
|
-
var cliVersion2 = true ? "0.
|
|
4184
|
+
var cliVersion2 = true ? "0.16.0" : "dev";
|
|
4185
4185
|
var program = new Command();
|
|
4186
4186
|
program.name("agt").description("Augmented CLI \u2014 agent provisioning and management").version(cliVersion2).option("--json", "Emit machine-readable JSON output (suppress spinners and colors)").option("--skip-update-check", "Skip the automatic update check on startup");
|
|
4187
4187
|
program.hook("preAction", (thisCommand) => {
|
|
@@ -4253,14 +4253,14 @@ acpx.command("exec <agent> <prompt>").description("One-shot execution (no sessio
|
|
|
4253
4253
|
acpx.command("list-sessions <agent>").description("List active ACP sessions for an agent").action(acpxListSessionsCommand);
|
|
4254
4254
|
acpx.command("cancel <agent>").description("Send cooperative cancel to the running ACP session").action(acpxCancelCommand);
|
|
4255
4255
|
acpx.command("close <agent>").description("Soft-close an ACP session (preserves history)").action(acpxCloseCommand);
|
|
4256
|
-
var
|
|
4257
|
-
|
|
4258
|
-
|
|
4259
|
-
|
|
4260
|
-
|
|
4261
|
-
|
|
4262
|
-
|
|
4263
|
-
|
|
4256
|
+
var integration = program.command("integration").description("Manage integrations \u2014 install, configure, and control permission scopes");
|
|
4257
|
+
integration.command("list").description("List available integrations for the active team").action(integrationListCommand);
|
|
4258
|
+
integration.command("show <slug>").description("Show integration details including permission scopes").action(integrationShowCommand);
|
|
4259
|
+
integration.command("install <slug>").description("Install an integration on an agent").requiredOption("--agent <code-name>", "Agent code name").option("--scopes <scopes>", "Comma-separated scope IDs to grant").action(integrationInstallCommand);
|
|
4260
|
+
integration.command("uninstall <slug>").description("Remove an integration from an agent").requiredOption("--agent <code-name>", "Agent code name").action(integrationUninstallCommand);
|
|
4261
|
+
integration.command("requests").description("List pending scope approval requests for the team").action(integrationRequestsCommand);
|
|
4262
|
+
integration.command("approve <request-id>").description("Approve a scope request").option("--notes <text>", "Review notes").action(integrationApproveCommand);
|
|
4263
|
+
integration.command("deny <request-id>").description("Deny a scope request").option("--reason <text>", "Denial reason").action(integrationDenyCommand);
|
|
4264
4264
|
program.command("update").description("Check for and install CLI updates").option("--force", "Update even if manager or agent sessions are running").action(updateCommand);
|
|
4265
4265
|
var skipUpdateCheck = process.argv.includes("--skip-update-check") || process.argv.includes("--json") || process.argv[2] === "update";
|
|
4266
4266
|
if (!skipUpdateCheck) {
|