@kodycodes/cli 1.26.1 → 1.26.3
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/auth-4FW6GCLG.js +26 -0
- package/dist/auth-4FW6GCLG.js.map +6 -0
- package/dist/bin.js +27 -3
- package/dist/bin.js.map +6 -1
- package/dist/chunk-46IJPEID.js +30 -0
- package/dist/chunk-46IJPEID.js.map +6 -0
- package/dist/chunk-4D6ORNXY.js +24404 -0
- package/dist/chunk-4D6ORNXY.js.map +6 -0
- package/dist/chunk-64IM6G4Z.js +341 -0
- package/dist/chunk-64IM6G4Z.js.map +6 -0
- package/dist/{package-local-runtime-source.js → chunk-64XN367G.js} +373 -52
- package/dist/chunk-64XN367G.js.map +6 -0
- package/dist/chunk-6XQP5SWX.js +26 -0
- package/dist/chunk-6XQP5SWX.js.map +6 -0
- package/dist/chunk-75RZUXQL.js +62 -0
- package/dist/chunk-75RZUXQL.js.map +6 -0
- package/dist/chunk-BISUL7CE.js +106 -0
- package/dist/chunk-BISUL7CE.js.map +6 -0
- package/dist/chunk-BPGY4IE7.js +57 -0
- package/dist/chunk-BPGY4IE7.js.map +6 -0
- package/dist/chunk-CASGRYOF.js +21 -0
- package/dist/chunk-CASGRYOF.js.map +6 -0
- package/dist/chunk-CWWHR4FH.js +19 -0
- package/dist/chunk-CWWHR4FH.js.map +6 -0
- package/dist/chunk-D55XPY3T.js +1382 -0
- package/dist/chunk-D55XPY3T.js.map +6 -0
- package/dist/chunk-EOCV74B2.js +948 -0
- package/dist/chunk-EOCV74B2.js.map +6 -0
- package/dist/chunk-FBVNFWR6.js +437 -0
- package/dist/chunk-FBVNFWR6.js.map +6 -0
- package/dist/chunk-G4YN6XP5.js +14 -0
- package/dist/chunk-G4YN6XP5.js.map +6 -0
- package/dist/chunk-G6LJWROP.js +18 -0
- package/dist/chunk-G6LJWROP.js.map +6 -0
- package/dist/chunk-IHP6PV6X.js +49 -0
- package/dist/chunk-IHP6PV6X.js.map +6 -0
- package/dist/chunk-JWEFKKAD.js +24 -0
- package/dist/chunk-JWEFKKAD.js.map +6 -0
- package/dist/chunk-LWNB26KO.js +147 -0
- package/dist/chunk-LWNB26KO.js.map +6 -0
- package/dist/chunk-OVGXPRSY.js +20 -0
- package/dist/chunk-OVGXPRSY.js.map +6 -0
- package/dist/chunk-PDWCKWQF.js +453 -0
- package/dist/chunk-PDWCKWQF.js.map +6 -0
- package/dist/chunk-QHBCP4OB.js +44 -0
- package/dist/chunk-QHBCP4OB.js.map +6 -0
- package/dist/chunk-R4IUV5P5.js +664 -0
- package/dist/chunk-R4IUV5P5.js.map +6 -0
- package/dist/chunk-RM34N3KI.js +525 -0
- package/dist/chunk-RM34N3KI.js.map +6 -0
- package/dist/chunk-RTWUNV76.js +309 -0
- package/dist/chunk-RTWUNV76.js.map +6 -0
- package/dist/chunk-SMURF26I.js +23 -0
- package/dist/chunk-SMURF26I.js.map +6 -0
- package/dist/chunk-SXHULGL4.js +426 -0
- package/dist/chunk-SXHULGL4.js.map +6 -0
- package/dist/chunk-TIL35OWA.js +1959 -0
- package/dist/chunk-TIL35OWA.js.map +6 -0
- package/dist/chunk-VQS5YSCI.js +54 -0
- package/dist/chunk-VQS5YSCI.js.map +6 -0
- package/dist/chunk-XDCOWU5R.js +696 -0
- package/dist/chunk-XDCOWU5R.js.map +6 -0
- package/dist/chunk-XOPPGRUP.js +605 -0
- package/dist/chunk-XOPPGRUP.js.map +6 -0
- package/dist/cli.js +74 -1500
- package/dist/cli.js.map +6 -1
- package/dist/dev/dev-watcher.d.ts +5 -1
- package/dist/dev-command-3LX234N6.js +4900 -0
- package/dist/dev-command-3LX234N6.js.map +6 -0
- package/dist/git-credential-FUE3JE3T.js +163 -0
- package/dist/git-credential-FUE3JE3T.js.map +6 -0
- package/dist/install-ZML2TCDG.js +10694 -0
- package/dist/install-ZML2TCDG.js.map +6 -0
- package/dist/local-execute-SZV6XN4T.js +368 -0
- package/dist/local-execute-SZV6XN4T.js.map +6 -0
- package/dist/local-package-run-2TMCAZZ2.js +23 -0
- package/dist/local-package-run-2TMCAZZ2.js.map +6 -0
- package/dist/mcp-G2AWTIXR.js +21 -0
- package/dist/mcp-G2AWTIXR.js.map +6 -0
- package/dist/mock-dep-resolve-TVABDNR7.js +52 -0
- package/dist/mock-dep-resolve-TVABDNR7.js.map +6 -0
- package/dist/mock-fetch-gateway-B5TFGGQS.js +34 -0
- package/dist/mock-fetch-gateway-B5TFGGQS.js.map +6 -0
- package/dist/mock-local-deps-5SZT3PWT.js +197 -0
- package/dist/mock-local-deps-5SZT3PWT.js.map +6 -0
- package/dist/mock-server-SV2IKC4I.js +21 -0
- package/dist/mock-server-SV2IKC4I.js.map +6 -0
- package/dist/open-api-client-DVVMLY7P.js +42 -0
- package/dist/open-api-client-DVVMLY7P.js.map +6 -0
- package/dist/org-X7B5BI4R.js +132 -0
- package/dist/org-X7B5BI4R.js.map +6 -0
- package/dist/package-manifest-QH2RU64C.js +14 -0
- package/dist/package-manifest-QH2RU64C.js.map +6 -0
- package/dist/remote-execute-QMQDVHOY.js +110 -0
- package/dist/remote-execute-QMQDVHOY.js.map +6 -0
- package/dist/setup-git-5KCUBYPB.js +88 -0
- package/dist/setup-git-5KCUBYPB.js.map +6 -0
- package/dist/skill-ENPATRIW.js +43 -0
- package/dist/skill-ENPATRIW.js.map +6 -0
- package/dist/store-WTMRH527.js +48 -0
- package/dist/store-WTMRH527.js.map +6 -0
- package/dist/structured-error-C65GQ53Z.js +13 -0
- package/dist/structured-error-C65GQ53Z.js.map +6 -0
- package/dist/target-3QHY7JT4.js +45 -0
- package/dist/target-3QHY7JT4.js.map +6 -0
- package/dist/webapi-NTVP4BO3.js +2482 -0
- package/dist/webapi-NTVP4BO3.js.map +6 -0
- package/package.json +8 -8
- package/dist/add-mcp-install.js +0 -59
- package/dist/add-mcp-install.js.map +0 -1
- package/dist/api-token-store.js +0 -120
- package/dist/api-token-store.js.map +0 -1
- package/dist/api-token.js +0 -238
- package/dist/api-token.js.map +0 -1
- package/dist/auth-bootstrap.js +0 -373
- package/dist/auth-bootstrap.js.map +0 -1
- package/dist/auth.js +0 -386
- package/dist/auth.js.map +0 -1
- package/dist/capability-proxy.js +0 -527
- package/dist/capability-proxy.js.map +0 -1
- package/dist/credential-call-map.js +0 -155
- package/dist/credential-call-map.js.map +0 -1
- package/dist/credential-client-runtime-source.js +0 -9
- package/dist/credential-client-runtime-source.js.map +0 -1
- package/dist/credentialed-fetch-scan.js +0 -98
- package/dist/credentialed-fetch-scan.js.map +0 -1
- package/dist/defaults.js +0 -34
- package/dist/defaults.js.map +0 -1
- package/dist/detect-running-hosts.js +0 -13
- package/dist/detect-running-hosts.js.map +0 -1
- package/dist/dev/dev-assets.js +0 -202
- package/dist/dev/dev-assets.js.map +0 -1
- package/dist/dev/dev-bundler.js +0 -65
- package/dist/dev/dev-bundler.js.map +0 -1
- package/dist/dev/dev-events.js +0 -94
- package/dist/dev/dev-events.js.map +0 -1
- package/dist/dev/dev-port.js +0 -80
- package/dist/dev/dev-port.js.map +0 -1
- package/dist/dev/dev-protocol.js +0 -14
- package/dist/dev/dev-protocol.js.map +0 -1
- package/dist/dev/dev-registry.js +0 -95
- package/dist/dev/dev-registry.js.map +0 -1
- package/dist/dev/dev-watcher.js +0 -156
- package/dist/dev/dev-watcher.js.map +0 -1
- package/dist/dev/error-page.js +0 -64
- package/dist/dev/error-page.js.map +0 -1
- package/dist/dev/live-reload.js +0 -148
- package/dist/dev/live-reload.js.map +0 -1
- package/dist/dev/prebuild.js +0 -102
- package/dist/dev/prebuild.js.map +0 -1
- package/dist/dev/process-reaper.js +0 -151
- package/dist/dev/process-reaper.js.map +0 -1
- package/dist/dev/stack-trace.js +0 -56
- package/dist/dev/stack-trace.js.map +0 -1
- package/dist/dev/workerd-process.js +0 -118
- package/dist/dev/workerd-process.js.map +0 -1
- package/dist/dev-command.js +0 -672
- package/dist/dev-command.js.map +0 -1
- package/dist/discover-login-identity.js +0 -77
- package/dist/discover-login-identity.js.map +0 -1
- package/dist/discover-org.js +0 -62
- package/dist/discover-org.js.map +0 -1
- package/dist/git-credential.js +0 -147
- package/dist/git-credential.js.map +0 -1
- package/dist/help.js +0 -333
- package/dist/help.js.map +0 -1
- package/dist/host-catalog.js +0 -427
- package/dist/host-catalog.js.map +0 -1
- package/dist/host-config.js +0 -80
- package/dist/host-config.js.map +0 -1
- package/dist/http-error-body.js +0 -35
- package/dist/http-error-body.js.map +0 -1
- package/dist/install-hosts.js +0 -328
- package/dist/install-hosts.js.map +0 -1
- package/dist/install.js +0 -120
- package/dist/install.js.map +0 -1
- package/dist/invoke-passthrough.js +0 -60
- package/dist/invoke-passthrough.js.map +0 -1
- package/dist/local-bundle.js +0 -200
- package/dist/local-bundle.js.map +0 -1
- package/dist/local-execute-auth.js +0 -53
- package/dist/local-execute-auth.js.map +0 -1
- package/dist/local-execute.js +0 -338
- package/dist/local-execute.js.map +0 -1
- package/dist/local-gateway-fetch-forward.js +0 -135
- package/dist/local-gateway-fetch-forward.js.map +0 -1
- package/dist/local-host-runtime-surface.js +0 -75
- package/dist/local-host-runtime-surface.js.map +0 -1
- package/dist/local-package-graph.js +0 -405
- package/dist/local-package-graph.js.map +0 -1
- package/dist/local-package-run.js +0 -307
- package/dist/local-package-run.js.map +0 -1
- package/dist/local-runtime-bridge.js +0 -132
- package/dist/local-runtime-bridge.js.map +0 -1
- package/dist/local-runtime-source.js +0 -541
- package/dist/local-runtime-source.js.map +0 -1
- package/dist/login-callback-assets.js +0 -10
- package/dist/login-callback-assets.js.map +0 -1
- package/dist/login-callback-page.js +0 -362
- package/dist/login-callback-page.js.map +0 -1
- package/dist/mcp.js +0 -134
- package/dist/mcp.js.map +0 -1
- package/dist/mock/ensure-msw.js +0 -215
- package/dist/mock/ensure-msw.js.map +0 -1
- package/dist/mock/install-mock-fetch-shim.js +0 -36
- package/dist/mock/install-mock-fetch-shim.js.map +0 -1
- package/dist/mock/load-package-mocks.js +0 -136
- package/dist/mock/load-package-mocks.js.map +0 -1
- package/dist/mock/mock-fetch-gateway.js +0 -343
- package/dist/mock/mock-fetch-gateway.js.map +0 -1
- package/dist/mock/mock-gateway-fetch-shim.js +0 -104
- package/dist/mock/mock-gateway-fetch-shim.js.map +0 -1
- package/dist/mock/mock-server.js +0 -499
- package/dist/mock/mock-server.js.map +0 -1
- package/dist/mock/mock-storage.js +0 -186
- package/dist/mock/mock-storage.js.map +0 -1
- package/dist/mock/mock-supported.js +0 -63
- package/dist/mock/mock-supported.js.map +0 -1
- package/dist/mock-dep-resolve.js +0 -47
- package/dist/mock-dep-resolve.js.map +0 -1
- package/dist/mock-local-deps.js +0 -207
- package/dist/mock-local-deps.js.map +0 -1
- package/dist/network-error.js +0 -11
- package/dist/network-error.js.map +0 -1
- package/dist/node-engine.js +0 -21
- package/dist/node-engine.js.map +0 -1
- package/dist/oauth-provider.js +0 -107
- package/dist/oauth-provider.js.map +0 -1
- package/dist/onboarding-prompt.js +0 -15
- package/dist/onboarding-prompt.js.map +0 -1
- package/dist/open-api-client.js +0 -432
- package/dist/open-api-client.js.map +0 -1
- package/dist/open-url.js +0 -21
- package/dist/open-url.js.map +0 -1
- package/dist/org-resolve.js +0 -16
- package/dist/org-resolve.js.map +0 -1
- package/dist/org-slug.js +0 -11
- package/dist/org-slug.js.map +0 -1
- package/dist/org.js +0 -100
- package/dist/org.js.map +0 -1
- package/dist/package-app-dev.js +0 -905
- package/dist/package-app-dev.js.map +0 -1
- package/dist/package-collaborators.js +0 -179
- package/dist/package-collaborators.js.map +0 -1
- package/dist/package-info.js +0 -19
- package/dist/package-info.js.map +0 -1
- package/dist/package-local-runtime-source.js.map +0 -1
- package/dist/package-manifest.js +0 -364
- package/dist/package-manifest.js.map +0 -1
- package/dist/process-info.js +0 -14
- package/dist/process-info.js.map +0 -1
- package/dist/redact.js +0 -16
- package/dist/redact.js.map +0 -1
- package/dist/remote-execute.js +0 -108
- package/dist/remote-execute.js.map +0 -1
- package/dist/setup-git.js +0 -676
- package/dist/setup-git.js.map +0 -1
- package/dist/skill.js +0 -35
- package/dist/skill.js.map +0 -1
- package/dist/store.js +0 -597
- package/dist/store.js.map +0 -1
- package/dist/structured-error.js +0 -57
- package/dist/structured-error.js.map +0 -1
- package/dist/target.js +0 -52
- package/dist/target.js.map +0 -1
- package/dist/tool-result.js +0 -19
- package/dist/tool-result.js.map +0 -1
- package/dist/which.js +0 -22
- package/dist/which.js.map +0 -1
- package/dist/workerd-binary.js +0 -98
- package/dist/workerd-binary.js.map +0 -1
package/dist/help.js
DELETED
|
@@ -1,333 +0,0 @@
|
|
|
1
|
-
import { apiTokenEnvVar, defaultApiUrl, defaultMcpUrl, onboardingUrl } from './defaults.js';
|
|
2
|
-
import { hostIds } from './host-catalog.js';
|
|
3
|
-
import { orgEnvVar } from './org-slug.js';
|
|
4
|
-
import { readPackageVersion } from './package-info.js';
|
|
5
|
-
import { listStoredOrgs, } from './store.js';
|
|
6
|
-
function formatOrgsHelpBlock(orgs, indent = ' ') {
|
|
7
|
-
if (orgs.length === 0) {
|
|
8
|
-
return `${indent}Not logged in. Run \`kody login\`.\n`;
|
|
9
|
-
}
|
|
10
|
-
const lines = [`${indent}Logged-in orgs:`];
|
|
11
|
-
for (const org of orgs) {
|
|
12
|
-
const mark = org.active ? '*' : ' ';
|
|
13
|
-
const pending = org.pending
|
|
14
|
-
? ' (slug pending — run any authenticated command)'
|
|
15
|
-
: '';
|
|
16
|
-
lines.push(`${indent} ${mark} ${org.slug}${org.active ? ' (active)' : ''}${pending}`);
|
|
17
|
-
}
|
|
18
|
-
return `${lines.join('\n')}\n`;
|
|
19
|
-
}
|
|
20
|
-
export function buildUsage(input = {}) {
|
|
21
|
-
const mcpUrl = input.mcpUrl ?? defaultMcpUrl;
|
|
22
|
-
let orgs = input.orgs;
|
|
23
|
-
if (!orgs) {
|
|
24
|
-
try {
|
|
25
|
-
orgs = listStoredOrgs(mcpUrl, input.backend, input.resolution);
|
|
26
|
-
}
|
|
27
|
-
catch {
|
|
28
|
-
orgs = [];
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
const orgBlock = formatOrgsHelpBlock(orgs);
|
|
32
|
-
return `Kody CLI ${readPackageVersion()}
|
|
33
|
-
|
|
34
|
-
Install Kody as a remote MCP server in local agents, or use this CLI as a local client.
|
|
35
|
-
|
|
36
|
-
Usage:
|
|
37
|
-
kody login [--mcp-url <url>] [--org <slug>] [--no-browser]
|
|
38
|
-
kody logout [--org <slug>] [--mcp-url <url>] [--api-url <url>]
|
|
39
|
-
kody org list [--json] [--mcp-url <url>]
|
|
40
|
-
kody org use [<slug>] [--mcp-url <url>]
|
|
41
|
-
kody status [--mcp-url <url>] [--api-url <url>]
|
|
42
|
-
kody auth bootstrap (--code <kody_bc_…> | --scopes <list>) (--lifetime short|long | --idle-ttl-seconds <n> --max-lifetime-seconds <n>)
|
|
43
|
-
[--token <token>] [--mcp-url <url>] [--api-url <url>]
|
|
44
|
-
kody auth setup-git [--lifetime long|short] [--scopes <list>] [--token <token>] [--mcp-url <url>] [--api-url <url>]
|
|
45
|
-
kody auth remove-git [--mcp-url <url>] [--api-url <url>]
|
|
46
|
-
kody git-credential <get|store|erase>
|
|
47
|
-
kody whoami [--org <slug>] [--target prod|mock] [--mcp-url <url>] [--token <token>] [--api-url <url>] [--json]
|
|
48
|
-
kody search [query] [--org <slug>] [--entity <ref>] [--domain <id>] [--limit <n>] [--target prod|mock] [--token <token>] [--api-url <url>] [--json]
|
|
49
|
-
kody api <operationId> [--org <slug>] [--params <json>] [--token <token>] [--api-url <url>] [--json]
|
|
50
|
-
kody package publish [<@owner/leaf|package_id>] [--org <slug>] [--params <json>] [--token <token>] [--api-url <url>]
|
|
51
|
-
kody package collaborators <package> [--org <slug>] [--json] [--token <token>] [--api-url <url>]
|
|
52
|
-
kody package grant <package> (--team <slug> | --user <username>) [--preset use|contribute|manage] [--org <slug>] [--json]
|
|
53
|
-
kody package revoke <package> (--team <slug> | --user <username> | --grant <grant_id>) [--org <slug>] [--json]
|
|
54
|
-
kody execute [--org <slug>] [--invoke <ref> | --code <esm> | --file <path>] [--params <json>] [--conversation-id <id>] [--json]
|
|
55
|
-
[--credential <key=name>]… [--target prod|mock] [--token <token>] [--api-url <url>] [--local] [--allow-private-network]
|
|
56
|
-
kody dev [serve] [--org <slug>] [--target prod|mock] [--reset-storage] [--port <n>] [--app-base-path <path>] [--allow-private-network] [--no-live-reload] [--json] [--ready-file <path>]
|
|
57
|
-
kody dev fetch <path> [--method <verb>] [--body <file>] [--target prod|mock] [--json] [--no-attach]
|
|
58
|
-
kody dev job <name> [--target prod|mock] [--dry-run] [--json]
|
|
59
|
-
kody dev webhook <name> --body <file.json> [--target prod|mock] [--dry-run] [--json]
|
|
60
|
-
kody dev emit <event> --body <event.json> [--target prod|mock] [--dry-run] [--json]
|
|
61
|
-
kody dev check [--target prod|mock] [--json]
|
|
62
|
-
kody install [--mcp-url <url>] [--clients <ids>] [--yes] [--project] [--json]
|
|
63
|
-
kody skill install [--project]
|
|
64
|
-
|
|
65
|
-
kody install configures running local MCP clients (Cursor, Claude Desktop,
|
|
66
|
-
VS Code, Goose, and others). For web-based clients (ChatGPT, Claude.ai, Grok),
|
|
67
|
-
see ${onboardingUrl(defaultMcpUrl)}
|
|
68
|
-
|
|
69
|
-
Orgs (local store, offline):
|
|
70
|
-
${orgBlock}
|
|
71
|
-
--org <slug>
|
|
72
|
-
For \`kody login\` / \`kody logout\`: only the flag counts
|
|
73
|
-
(${orgEnvVar} is ignored). Login binds the browser grant to
|
|
74
|
-
this organization (adds/replaces that org's stored login;
|
|
75
|
-
other orgs stay). Example: \`kody login --org acme\`
|
|
76
|
-
Omit and the server picker binds one org.
|
|
77
|
-
For org-scoped commands (whoami, search, api, execute, …):
|
|
78
|
-
run as this org for one call. Precedence: flag, then
|
|
79
|
-
${orgEnvVar}, then the active org (\`kody org use\`).
|
|
80
|
-
|
|
81
|
-
kody org list
|
|
82
|
-
Show logged-in orgs and mark the active one. \`--json\` for agents.
|
|
83
|
-
|
|
84
|
-
kody org use [<slug>]
|
|
85
|
-
Switch the active org. With a slug (agents), switches directly.
|
|
86
|
-
With no slug on a TTY (humans), opens an interactive chooser.
|
|
87
|
-
Without a TTY, pass a slug.
|
|
88
|
-
|
|
89
|
-
kody logout
|
|
90
|
-
Without \`--org\`, removes the active org login only (or the
|
|
91
|
-
pending legacy session). With \`--org <slug>\`, removes just
|
|
92
|
-
that org. Other org logins stay. Also clears a stored
|
|
93
|
-
bootstrap/API token when present.
|
|
94
|
-
|
|
95
|
-
--clients Comma-separated ids: ${hostIds.join(', ')}
|
|
96
|
-
|
|
97
|
-
auth bootstrap
|
|
98
|
-
Redeem a one-shot \`kody_bc_…\` from MCP \`cliCredentialBootstrap\`
|
|
99
|
-
(POST /v1/tokens/bootstrap/redeem, no Authorization header).
|
|
100
|
-
Lifetime is required: \`--lifetime short|long\` (\`short\` = 1h
|
|
101
|
-
idle / 24h max; \`long\` = 14d idle / 3mo max), or both
|
|
102
|
-
\`--idle-ttl-seconds\` and \`--max-lifetime-seconds\`.
|
|
103
|
-
Single-task agents should use \`--lifetime short\`.
|
|
104
|
-
Stores the resulting \`kody_at_…\` for \`execute --local\`,
|
|
105
|
-
search, whoami, api, and token-auth cloud execute without
|
|
106
|
-
printing the token. Prefer this over tokenCreate for agents
|
|
107
|
-
already on MCP. Interactive humans can use \`kody login\`
|
|
108
|
-
instead. Do not call \`kody api cliCredentialBootstrapRedeem\`
|
|
109
|
-
— that would print the token.
|
|
110
|
-
|
|
111
|
-
--scopes <list>
|
|
112
|
-
Opt in to scopes beyond the cliCredentialBootstrap defaults
|
|
113
|
-
(comma- or space-separated, e.g.
|
|
114
|
-
\`--scopes org:execute,org:read,package:read,package:write\`).
|
|
115
|
-
The list replaces the defaults, so include every scope you
|
|
116
|
-
need. Instead of \`--code\`, the CLI mints the code itself by
|
|
117
|
-
passing \`scopes\` to cliCredentialBootstrap, then redeems and
|
|
118
|
-
stores it. It mints with \`--token\` if given, else the
|
|
119
|
-
\`kody login\` session (any scope your org role grants), else
|
|
120
|
-
${apiTokenEnvVar} / a stored token (only scopes that token
|
|
121
|
-
already holds). A bootstrap code's scopes are fixed when it is
|
|
122
|
-
minted, so \`--code\` with \`--scopes\` is an error. Defaults
|
|
123
|
-
stay least-privilege; \`insufficient_scope\` errors print the
|
|
124
|
-
exact \`--scopes\` command to run.
|
|
125
|
-
|
|
126
|
-
auth setup-git
|
|
127
|
-
Install a Git credential helper for HTTPS clones/fetches/pushes
|
|
128
|
-
at \`https://kody.codes/@owner/name.git\` (see guide:auth_setup_git).
|
|
129
|
-
Uses a \`kody login\` session (or \`--token\` / ${apiTokenEnvVar} /
|
|
130
|
-
stored bootstrap token) to mint a user-owned \`kody_at_…\` with
|
|
131
|
-
at least \`package:read\` and \`package:write\` (default
|
|
132
|
-
\`--lifetime long\`; reuses a suitable stored token). That token
|
|
133
|
-
authorizes every repo you can access across all orgs — login
|
|
134
|
-
\`--org\` only scopes the MCP mint session, not git. User-wide:
|
|
135
|
-
one setup covers every org. Requires a server that advertises
|
|
136
|
-
\`org_binding\`. Configures a stable
|
|
137
|
-
\`credential.https://<host>.helper\` (global \`kody\` only when
|
|
138
|
-
its version supports \`git-credential\`, else
|
|
139
|
-
\`npx -y @kodycodes/cli@<exact>\` — never a major-only range or
|
|
140
|
-
ephemeral npx cache path) + \`useHttpPath\`. Re-run (or any
|
|
141
|
-
newer CLI command) rewrites stale helper pins. Undo with
|
|
142
|
-
\`kody auth remove-git\`. Does not change \`kody login\` /
|
|
143
|
-
existing auth flows.
|
|
144
|
-
|
|
145
|
-
auth remove-git
|
|
146
|
-
Inverse of \`auth setup-git\`: removes every
|
|
147
|
-
\`credential.https://<host>.*\` helper entry setup-git may have
|
|
148
|
-
written (global and local; including stale \`~/.npm/_npx\` and
|
|
149
|
-
major-only \`@1\` pins), revokes the stored API token on the
|
|
150
|
-
server (\`token:delete\` / DELETE /v1/tokens/current), and
|
|
151
|
-
deletes it from the OS keychain. Idempotent when nothing is
|
|
152
|
-
set up; prints what it removed. Leaves \`kody login\` sessions
|
|
153
|
-
alone.
|
|
154
|
-
|
|
155
|
-
git-credential
|
|
156
|
-
Git credential helper invoked by git after \`auth setup-git\`
|
|
157
|
-
(\`get\` returns username=x / password=kody_at_… for the Kody
|
|
158
|
-
host with no network while the stored token is still valid;
|
|
159
|
-
silently remints via \`kody login\` only when expired or near
|
|
160
|
-
expiry; \`store\`/\`erase\` are no-ops). Not meant for interactive
|
|
161
|
-
use.
|
|
162
|
-
|
|
163
|
-
api Call one Open API operation by operationId + flat --params
|
|
164
|
-
JSON (same shape as the MCP \`api\` tool). Uses scoped API
|
|
165
|
-
auth only (\`--token\` / ${apiTokenEnvVar} / stored bootstrap).
|
|
166
|
-
Prints JSON. Example: \`kody api usageGet --params '{}'\`.
|
|
167
|
-
Unknown operationIds error clearly; see
|
|
168
|
-
${defaultApiUrl}/openapi.json. tokenCreate / tokenRotate
|
|
169
|
-
responses include a one-time token value — prefer env storage
|
|
170
|
-
over pasting into chat.
|
|
171
|
-
|
|
172
|
-
package publish
|
|
173
|
-
Thin wrapper for Open API \`packagePublishExternalPush\` (same
|
|
174
|
-
auth as \`kody api\`). Optional positional is a \`package_id\`, or a
|
|
175
|
-
name (\`@owner/leaf\` or bare leaf) resolved to its package_id
|
|
176
|
-
via \`packageList\` in the current org. Extra fields
|
|
177
|
-
via \`--params\` JSON (e.g. \`allow_force\`). Prints JSON.
|
|
178
|
-
|
|
179
|
-
package collaborators | grant | revoke
|
|
180
|
-
Who can use one package, and add or remove teams and members of
|
|
181
|
-
the org (\`--org\`). \`<package>\` is \`@owner/leaf\`, the kody id,
|
|
182
|
-
or the package id. \`grant\` adds a team or org member or changes
|
|
183
|
-
their preset (default \`use\`) via \`packageCollaboratorSet\`;
|
|
184
|
-
people outside the org are refused. \`revoke\` removes one by
|
|
185
|
-
team, user, or grant id via \`packageCollaboratorRemove\`. Needs
|
|
186
|
-
Manage on the package and a token with
|
|
187
|
-
\`package:manage_access\` (\`auth bootstrap --scopes …\`); same
|
|
188
|
-
auth as \`kody api\`. Prints a short summary, or the API JSON
|
|
189
|
-
with \`--json\`.
|
|
190
|
-
|
|
191
|
-
--token / ${apiTokenEnvVar}
|
|
192
|
-
Scoped API token (preferred via env). With no \`kody login\`
|
|
193
|
-
session, search / whoami / api / execute use the Open API and
|
|
194
|
-
CapabilityProxy — including cloud execute without --local.
|
|
195
|
-
Auth priority matches \`execute --local\`: \`--token\` /
|
|
196
|
-
${apiTokenEnvVar}; stored bootstrap/API token from
|
|
197
|
-
\`auth bootstrap\`; then \`kody login\` where applicable.
|
|
198
|
-
Prefer \`cliCredentialBootstrap\` then \`auth bootstrap\`
|
|
199
|
-
(\`--lifetime short|long\`). CI/headless: \`tokenCreate\` with
|
|
200
|
-
\`org:execute\` plus the capability scopes you need.
|
|
201
|
-
For \`execute --local\`, a valid \`kody login\` session can also
|
|
202
|
-
supply Bearer when no scoped token is available (no tokenCreate
|
|
203
|
-
exchange). User-owned tokens (\`org_binding: user\`) honor
|
|
204
|
-
\`--org\` / ${orgEnvVar} as \`?org=\` on API calls.
|
|
205
|
-
|
|
206
|
-
--local Run the execute module on this machine (workerd, Linux/macOS).
|
|
207
|
-
Requires Node.js 22 or newer. \`--file\` entries are bundled
|
|
208
|
-
(relative imports and npm packages; \`kody:*\` stays external)
|
|
209
|
-
before workerd loads them — same shape as hosted execute /
|
|
210
|
-
publish. Unresolvable imports fail with a clear bundle error.
|
|
211
|
-
\`--invoke kody:@scope/pkg/export\` (or \`@scope/pkg#export\`)
|
|
212
|
-
works with \`--local\` / \`--target mock\` — mints the same thin
|
|
213
|
-
passthrough as a \`--code\` import wrapper. From a package
|
|
214
|
-
directory, \`--invoke ./export\` runs a local package.json#exports
|
|
215
|
-
key. Auth: \`--token\` /
|
|
216
|
-
${apiTokenEnvVar}, else stored \`auth bootstrap\` token, else
|
|
217
|
-
paired \`kody login\` credentials. Static kody:@… imports are fetched via POST
|
|
218
|
-
/v1/local-execute/package-graph and embedded in local workerd
|
|
219
|
-
(CapabilityProxy only for per-call kody:runtime hops — never a
|
|
220
|
-
whole-module cloud kody.execute defer). Fails clearly when that
|
|
221
|
-
package-graph API is unavailable. Cloud token execute (no
|
|
222
|
-
--local) uses CapabilityProxy → kody.execute for every module.
|
|
223
|
-
|
|
224
|
-
--credential <key=name>
|
|
225
|
-
ADR 0068 call map: pick which credential each \`credential(key)\`
|
|
226
|
-
/ \`credentials(key)\` call gets. Repeatable.
|
|
227
|
-
\`--credential github=work\`, \`--credential x=org:work\`
|
|
228
|
-
(or \`personal:name\`), \`--credential github=\` for none on
|
|
229
|
-
purpose. With \`--local\`, sent as CapabilityProxy top-level
|
|
230
|
-
\`credentials\` (code never sets the map) after a
|
|
231
|
-
\`credentialClientCheck\` preflight. With a \`kody login\` MCP
|
|
232
|
-
session (no token), passed as MCP execute \`credentials\`.
|
|
233
|
-
Token-auth cloud execute (CapabilityProxy → kody.execute)
|
|
234
|
-
rejects the flag — use \`--local\` or MCP.
|
|
235
|
-
|
|
236
|
-
--allow-private-network
|
|
237
|
-
Allow execute --local / \`kody dev\` code to fetch private and
|
|
238
|
-
local network addresses. Default is public-only.
|
|
239
|
-
|
|
240
|
-
--target prod|mock
|
|
241
|
-
Where server-side calls go (storage, credentials, kody:*,
|
|
242
|
-
execute, invoke, search). Same meaning on \`dev\`, \`execute\`,
|
|
243
|
-
and \`search\`. Defaults: \`mock\` for \`kody dev\`; \`prod\` for
|
|
244
|
-
execute/search (unchanged). \`--target mock\` starts the
|
|
245
|
-
built-in CLI mock (no kody-celld); scratch storage; fake or
|
|
246
|
-
local credentials so unpublished packages never touch real
|
|
247
|
-
secrets. Unimplemented mock routes refuse with
|
|
248
|
-
\`not_implemented_in_mock\`.
|
|
249
|
-
|
|
250
|
-
--reset-storage
|
|
251
|
-
With \`--target mock\`, wipe the mock session's scratch storage
|
|
252
|
-
before the command.
|
|
253
|
-
|
|
254
|
-
--dry-run With \`kody dev job|webhook|emit\`, print the module path and
|
|
255
|
-
params that would run without invoking (safe against prod side
|
|
256
|
-
effects). Does not apply to serve/fetch/check.
|
|
257
|
-
|
|
258
|
-
--passthrough <host,…>
|
|
259
|
-
With \`--target mock\` and a package \`.kody/mocks.ts\`, allow
|
|
260
|
-
listed hosts to use the real network (credentials stay fake —
|
|
261
|
-
never carries real secrets). Unmatched hosts fail with
|
|
262
|
-
\`unmocked_request\` plus a paste-ready MSW handler stub.
|
|
263
|
-
Ignored on \`--target prod\`. On mock, outbound fetch always
|
|
264
|
-
goes through the Node gateway: with \`.kody/mocks.ts\`, unmatched
|
|
265
|
-
hosts (and all \`createAuthenticatedFetch\` / credentialed hops
|
|
266
|
-
without a handler) fail closed; without the file, public hosts
|
|
267
|
-
passthrough and private hosts need \`--allow-private-network\`.
|
|
268
|
-
|
|
269
|
-
kody dev Local testing for unpublished packages. Serves \`kody.app.entry\`
|
|
270
|
-
on localhost via workerd with hot reload (mount-stripped path;
|
|
271
|
-
packageContext.hostedUrl / appBasePath point at localhost).
|
|
272
|
-
Rebuilds swap to a new workerd only once it listens (requests
|
|
273
|
-
wait; no 503 or stale bundle). Build errors (file:line:col +
|
|
274
|
-
code frame) and uncaught handler errors (stack mapped to your
|
|
275
|
-
.ts sources) are served as dev-only 500 pages until fixed. App
|
|
276
|
-
console.* streams to the terminal tagged by request. HTML pages
|
|
277
|
-
live-reload after each rebuild and show an error overlay
|
|
278
|
-
(SSE at /__kody/dev/events; \`--no-live-reload\` disables).
|
|
279
|
-
Stable default port per package (4100-4999, next free port
|
|
280
|
-
if taken); \`--port <n>\` is exact (\`--port 0\` = any).
|
|
281
|
-
Serves \`kody.app.client\` at /_assets/client.<hash>.js
|
|
282
|
-
(packageContext.clientModuleUrl), \`kody.app.assets\` under
|
|
283
|
-
/_assets/, and /_assets/__version.json. \`kody.dev.prebuild\`
|
|
284
|
-
(shell command, run before every build) regenerates assets;
|
|
285
|
-
\`kody.dev.ignore\` lists watcher path prefixes to skip.
|
|
286
|
-
Agents: \`--json\` streams NDJSON events (ready, rebuild_start,
|
|
287
|
-
rebuild_ok, build_error, runtime_error, log); GET
|
|
288
|
-
/__kody/dev/status returns build id + last error;
|
|
289
|
-
\`--ready-file <path>\` writes { url, port, basePath, pid } once
|
|
290
|
-
ready. \`kody dev fetch\` attaches to a running \`kody dev\` for
|
|
291
|
-
the same package and target (\`--no-attach\` boots a one-shot
|
|
292
|
-
server).
|
|
293
|
-
Bundles with the same esbuild path as publish (\`local-bundle\`).
|
|
294
|
-
Four surfaces: exports (\`execute --invoke ./export\` or
|
|
295
|
-
\`--file\` against the local package), webhooks
|
|
296
|
-
(\`kody dev webhook\`), schedules (\`kody dev job\` — runs once,
|
|
297
|
-
never schedules locally), subscriptions
|
|
298
|
-
(\`kody dev emit <event> --body event.json\`). \`kody dev check\`
|
|
299
|
-
bundles + light publish validations without running; when the
|
|
300
|
-
package uses credentialed fetch and \`.kody/mocks.ts\` is
|
|
301
|
-
missing, check soft-suggests adding that file. On
|
|
302
|
-
\`--target mock\`, \`kody:@\` deps resolve from this package's
|
|
303
|
-
exports, \`.kody/deps.json\` / \`package.json#kody.localDeps\`
|
|
304
|
-
path maps, then published package-graph when a login/API token
|
|
305
|
-
is available (storage/credentials stay on the mock; local-only
|
|
306
|
-
deps need no login). Optional \`.kody/mocks.ts\` exports MSW
|
|
307
|
-
\`handlers\` for outbound fetch mocking (Node gateway; not
|
|
308
|
-
published with the package) — \`createAuthenticatedFetch\`,
|
|
309
|
-
\`credential().fetch\`, \`gatewayFetch\`, and
|
|
310
|
-
\`gatewayFetchStream\` all match against them. Unmocked
|
|
311
|
-
requests fail closed with a ready-to-paste MSW handler stub
|
|
312
|
-
pointing at \`.kody/mocks.ts\`. Share previews are out of scope.
|
|
313
|
-
|
|
314
|
-
Environment:
|
|
315
|
-
KODY_MCP_URL Override the default MCP URL (${defaultMcpUrl})
|
|
316
|
-
${orgEnvVar} Default org slug for org-scoped commands (overridden by --org)
|
|
317
|
-
${apiTokenEnvVar} Scoped API token for token-auth search / whoami / api / execute
|
|
318
|
-
KODY_API_URL Override the Kody API URL (${defaultApiUrl})
|
|
319
|
-
KODY_TARGET Default \`prod\`|\`mock\` (overridden by --target)
|
|
320
|
-
KODY_MOCK_SESSION_ID Scratch storage key for --target mock (default: default)
|
|
321
|
-
KODY_CACHE_DIR Where execute --local caches workerd (default: user cache dir)
|
|
322
|
-
KODY_WORKERD_PATH Use this workerd binary instead of the pinned download
|
|
323
|
-
`;
|
|
324
|
-
}
|
|
325
|
-
/**
|
|
326
|
-
* Build usage on demand. Do not call at module load: reading the credential
|
|
327
|
-
* store (and pulling keyring) on every `kody --version` blows the startup
|
|
328
|
-
* budget. Callers that need the offline org list pass `mcpUrl` / `backend`.
|
|
329
|
-
*/
|
|
330
|
-
export function usage(input) {
|
|
331
|
-
return buildUsage(input);
|
|
332
|
-
}
|
|
333
|
-
//# sourceMappingURL=help.js.map
|
package/dist/help.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"help.js","sourceRoot":"","sources":["../src/help.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,aAAa,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,eAAe,CAAA;AAC3F,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAA;AAC3C,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAA;AACzC,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAA;AACtD,OAAO,EACN,cAAc,GAId,MAAM,YAAY,CAAA;AAEnB,SAAS,mBAAmB,CAAC,IAAsB,EAAE,MAAM,GAAG,IAAI;IACjE,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACvB,OAAO,GAAG,MAAM,sCAAsC,CAAA;IACvD,CAAC;IACD,MAAM,KAAK,GAAG,CAAC,GAAG,MAAM,iBAAiB,CAAC,CAAA;IAC1C,KAAK,MAAM,GAAG,IAAI,IAAI,EAAE,CAAC;QACxB,MAAM,IAAI,GAAG,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,CAAA;QACnC,MAAM,OAAO,GAAG,GAAG,CAAC,OAAO;YAC1B,CAAC,CAAC,kDAAkD;YACpD,CAAC,CAAC,EAAE,CAAA;QACL,KAAK,CAAC,IAAI,CACT,GAAG,MAAM,KAAK,IAAI,IAAI,GAAG,CAAC,IAAI,GAAG,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,EAAE,GAAG,OAAO,EAAE,CAC3E,CAAA;IACF,CAAC;IACD,OAAO,GAAG,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAA;AAC/B,CAAC;AAED,MAAM,UAAU,UAAU,CAAC,QAKvB,EAAE;IACL,MAAM,MAAM,GAAG,KAAK,CAAC,MAAM,IAAI,aAAa,CAAA;IAC5C,IAAI,IAAI,GAAG,KAAK,CAAC,IAAI,CAAA;IACrB,IAAI,CAAC,IAAI,EAAE,CAAC;QACX,IAAI,CAAC;YACJ,IAAI,GAAG,cAAc,CAAC,MAAM,EAAE,KAAK,CAAC,OAAO,EAAE,KAAK,CAAC,UAAU,CAAC,CAAA;QAC/D,CAAC;QAAC,MAAM,CAAC;YACR,IAAI,GAAG,EAAE,CAAA;QACV,CAAC;IACF,CAAC;IACD,MAAM,QAAQ,GAAG,mBAAmB,CAAC,IAAI,CAAC,CAAA;IAE1C,OAAO,YAAY,kBAAkB,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAmChC,aAAa,CAAC,aAAa,CAAC;;;EAGlC,QAAQ;;;gBAGM,SAAS;;;;;;eAMV,SAAS;;;;;;;;;;;;;;;;oCAgBY,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;eAyBvC,cAAc;;;;;;;;;+DASkC,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wCAoCrC,cAAc;;;eAGvC,aAAa;;;;;;;;;;;;;;;;;;;;;;;cAuBd,cAAc;;;;;eAKb,cAAc;;;;;;;;2BAQF,SAAS;;;;;;;;;;;;eAYrB,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;sDAmGyB,aAAa;IAC/D,SAAS;IACT,cAAc;mDACiC,aAAa;;;;;CAK/D,CAAA;AACD,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,KAAK,CAAC,KAAwC;IAC7D,OAAO,UAAU,CAAC,KAAK,CAAC,CAAA;AACzB,CAAC"}
|