@kosuke-ai/cli 6.9.0 → 6.10.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.
@@ -5,7 +5,7 @@ export const operation = {
5
5
  "integrations",
6
6
  "execute"
7
7
  ],
8
- "summary": "Run one integration tool. An agent runs it for its own workspace, or on the member’s personal connection when that member started the turn. With an API key, name a workspace you belong to: the call runs only on your own personal connections, and one on a workspace connection is refused. The answer names the connection it ran on, or lists the connections to choose from when the call needs one. A tool failure answers 200 with isError true. A Connector Token or a browser session is refused.",
8
+ "summary": "Run one integration tool. An agent runs it for its own workspace, or on the member’s personal connection when that member started the turn; the Slack Bot’s agent runs only the workspace’s. With an API key, name a workspace you belong to: the call runs only on your own personal connections, and one on a workspace connection is refused. The answer names the connection it ran on, or lists the connections to choose from when the call needs one. A tool failure answers 200 with isError true. A Connector Token or a browser session is refused.",
9
9
  "pathParams": [],
10
10
  "query": [
11
11
  {
@@ -46,7 +46,7 @@ export const operation = {
46
46
  "attachments": false,
47
47
  "anonymous": false,
48
48
  "sandboxToken": true,
49
- "orchestratorToken": false,
49
+ "orchestratorToken": true,
50
50
  "cronToken": true,
51
51
  "leadToken": true
52
52
  };
@@ -5,7 +5,7 @@ export const operation = {
5
5
  "integrations",
6
6
  "tools"
7
7
  ],
8
- "summary": "List the integration tools you can run now, with the connections that run them. An agent reads its own workspace. With an API key, name a workspace you belong to: it shows that workspace’s connections and your own personal ones. A Connector Token or a browser session is refused.",
8
+ "summary": "List the integration tools you can run now, with the connections that run them. An agent reads its own workspace; the Slack Bot’s agent sees the workspace’s connections only. With an API key, name a workspace you belong to: it shows that workspace’s connections and your own personal ones. A Connector Token or a browser session is refused.",
9
9
  "pathParams": [],
10
10
  "query": [
11
11
  {
@@ -67,7 +67,7 @@ export const operation = {
67
67
  "attachments": false,
68
68
  "anonymous": false,
69
69
  "sandboxToken": true,
70
- "orchestratorToken": false,
70
+ "orchestratorToken": true,
71
71
  "cronToken": true,
72
72
  "leadToken": true
73
73
  };
package/dist/program.js CHANGED
@@ -56,11 +56,8 @@ export function createProgram(options = {}) {
56
56
  // member's own key and their Lead may mark Activity seen, so the others
57
57
  // read it with `--peek`.
58
58
  attachAgentCommands(program, lazy, options.agent);
59
- // Beside the generated `integrations tools` and `execute`, which stay raw passthroughs. The
60
- // orchestrator token reaches neither: Slack triage has no integration tools.
61
- if (narrowedTo !== 'orchestratorToken') {
62
- attachIntegrationsCommands(program, lazy, options.integrations);
63
- }
59
+ // Beside the generated `integrations tools` and `execute`, which stay raw passthroughs.
60
+ attachIntegrationsCommands(program, lazy, options.integrations);
64
61
  // The job stream admits a member's API key only; it closes 4401 on every narrower token.
65
62
  if (narrowedTo === null)
66
63
  attachWatchCommand(program, lazy, options.watch);
@@ -37,12 +37,10 @@ const LEAD_TOKEN_PREFIX = 'kosuke_lead_';
37
37
  export function isLeadToken(token) {
38
38
  return token?.startsWith(LEAD_TOKEN_PREFIX) ?? false;
39
39
  }
40
- /**
41
- * A credential that decides its own workspace: a sandbox, cron or Lead token.
42
- * The orchestrator token is left out because it reaches no integration tools.
43
- */
40
+ /** A credential that decides its own workspace: any of the four agent tokens. */
44
41
  export function isTurnToken(token) {
45
42
  return (isSandboxAgentToken(token ?? undefined) ||
43
+ isOrchestratorToken(token ?? undefined) ||
46
44
  isCronToken(token ?? undefined) ||
47
45
  isLeadToken(token ?? undefined));
48
46
  }
package/openapi.json CHANGED
@@ -144,10 +144,11 @@
144
144
  "/api/agent-integrations/execute": {
145
145
  "post": {
146
146
  "operationId": "integrationsExecute",
147
- "summary": "Run one integration tool. An agent runs it for its own workspace, or on the member’s personal connection when that member started the turn. With an API key, name a workspace you belong to: the call runs only on your own personal connections, and one on a workspace connection is refused. The answer names the connection it ran on, or lists the connections to choose from when the call needs one. A tool failure answers 200 with isError true. A Connector Token or a browser session is refused.",
147
+ "summary": "Run one integration tool. An agent runs it for its own workspace, or on the member’s personal connection when that member started the turn; the Slack Bot’s agent runs only the workspace’s. With an API key, name a workspace you belong to: the call runs only on your own personal connections, and one on a workspace connection is refused. The answer names the connection it ran on, or lists the connections to choose from when the call needs one. A tool failure answers 200 with isError true. A Connector Token or a browser session is refused.",
148
148
  "tags": ["integrations"],
149
149
  "x-kosuke-command": ["integrations", "execute"],
150
150
  "x-kosuke-sandbox-token": true,
151
+ "x-kosuke-orchestrator-token": true,
151
152
  "x-kosuke-cron-token": true,
152
153
  "x-kosuke-lead-token": true,
153
154
  "parameters": [
@@ -235,10 +236,11 @@
235
236
  "/api/agent-integrations/tools": {
236
237
  "get": {
237
238
  "operationId": "integrationsTools",
238
- "summary": "List the integration tools you can run now, with the connections that run them. An agent reads its own workspace. With an API key, name a workspace you belong to: it shows that workspace’s connections and your own personal ones. A Connector Token or a browser session is refused.",
239
+ "summary": "List the integration tools you can run now, with the connections that run them. An agent reads its own workspace; the Slack Bot’s agent sees the workspace’s connections only. With an API key, name a workspace you belong to: it shows that workspace’s connections and your own personal ones. A Connector Token or a browser session is refused.",
239
240
  "tags": ["integrations"],
240
241
  "x-kosuke-command": ["integrations", "tools"],
241
242
  "x-kosuke-sandbox-token": true,
243
+ "x-kosuke-orchestrator-token": true,
242
244
  "x-kosuke-cron-token": true,
243
245
  "x-kosuke-lead-token": true,
244
246
  "parameters": [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kosuke-ai/cli",
3
- "version": "6.9.0",
3
+ "version": "6.10.0",
4
4
  "description": "Kosuke platform CLI. The client customers install to drive app.kosuke.ai from their own machine.",
5
5
  "license": "MIT",
6
6
  "repository": {