@kodycodes/cli 3.0.2 → 3.0.4

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.
Files changed (66) hide show
  1. package/README.md +21 -21
  2. package/dist/{auth-5Z3XBOGI.js → auth-FV2O77LC.js} +6 -6
  3. package/dist/bin.js +8 -8
  4. package/dist/{chunk-JWDLZGIR.js → chunk-4NYWQWSY.js} +8 -8
  5. package/dist/{chunk-XHKHDK76.js → chunk-5X563FYY.js} +3 -3
  6. package/dist/{chunk-PWWN6JI2.js → chunk-BML3W5CO.js} +2 -2
  7. package/dist/{chunk-57IZ5V4O.js → chunk-BS24HBMB.js} +46 -45
  8. package/dist/chunk-BS24HBMB.js.map +6 -0
  9. package/dist/{chunk-5BJUKHNZ.js → chunk-CCRCEU7S.js} +2 -2
  10. package/dist/{chunk-V7TJUMHF.js → chunk-DCQ57UXY.js} +2 -2
  11. package/dist/{chunk-OXDC6GJU.js → chunk-KZ3CZL54.js} +4 -4
  12. package/dist/{chunk-LSFY5BNX.js → chunk-NHRYNRXG.js} +2 -2
  13. package/dist/{chunk-LSFY5BNX.js.map → chunk-NHRYNRXG.js.map} +1 -1
  14. package/dist/{chunk-5YWQO43I.js → chunk-PIPQ2TTK.js} +4 -4
  15. package/dist/{chunk-QXRBLEAK.js → chunk-PUQGDXIY.js} +4 -4
  16. package/dist/{chunk-KK3NWPOZ.js → chunk-PZKBPKJ2.js} +3 -3
  17. package/dist/{chunk-TUUFQYWP.js → chunk-RAZBIC6O.js} +91 -22
  18. package/dist/chunk-RAZBIC6O.js.map +6 -0
  19. package/dist/{chunk-WB7BWPKK.js → chunk-SSBZQMVX.js} +3 -3
  20. package/dist/{chunk-EIFHXJDK.js → chunk-TG3SWAW3.js} +3 -3
  21. package/dist/{chunk-UY3U64VR.js → chunk-UZL5QBO3.js} +3 -3
  22. package/dist/cli.js +8 -8
  23. package/dist/{dev-command-CNSJ7DRG.js → dev-command-QGGRDTRC.js} +12 -12
  24. package/dist/{git-credential-GFQJHBTK.js → git-credential-6CJWVNED.js} +7 -7
  25. package/dist/{local-execute-GV6CVM3R.js → local-execute-ADQRK3T5.js} +7 -7
  26. package/dist/{local-package-graph-NAZNI2VP.js → local-package-graph-5N5L6NHU.js} +4 -4
  27. package/dist/{local-package-run-JFVEKBVM.js → local-package-run-CV4CN74S.js} +11 -11
  28. package/dist/{mock-dep-resolve-HJLRVWYS.js → mock-dep-resolve-TTCQQEN2.js} +7 -7
  29. package/dist/{mock-fetch-gateway-DIHCENGI.js → mock-fetch-gateway-TNK74HEP.js} +4 -4
  30. package/dist/{mock-local-deps-XOTGC6SA.js → mock-local-deps-IMNSSGPW.js} +6 -6
  31. package/dist/{mock-server-NO5RFVAF.js → mock-server-CJQI6B3A.js} +5 -5
  32. package/dist/{open-api-client-5BQMPAQY.js → open-api-client-42L6TM2U.js} +5 -5
  33. package/dist/{package-manifest-DFF6XCPV.js → package-manifest-FZOHGLVL.js} +2 -2
  34. package/dist/package-manifest.d.ts +10 -12
  35. package/dist/publish-exit.d.ts +1 -1
  36. package/dist/{remote-execute-DNOU4AMT.js → remote-execute-J35MQTUC.js} +5 -5
  37. package/dist/{setup-git-CZFPTTTQ.js → setup-git-IGLLNSLA.js} +6 -6
  38. package/package.json +1 -1
  39. package/dist/chunk-57IZ5V4O.js.map +0 -6
  40. package/dist/chunk-TUUFQYWP.js.map +0 -6
  41. /package/dist/{auth-5Z3XBOGI.js.map → auth-FV2O77LC.js.map} +0 -0
  42. /package/dist/{chunk-JWDLZGIR.js.map → chunk-4NYWQWSY.js.map} +0 -0
  43. /package/dist/{chunk-XHKHDK76.js.map → chunk-5X563FYY.js.map} +0 -0
  44. /package/dist/{chunk-PWWN6JI2.js.map → chunk-BML3W5CO.js.map} +0 -0
  45. /package/dist/{chunk-5BJUKHNZ.js.map → chunk-CCRCEU7S.js.map} +0 -0
  46. /package/dist/{chunk-V7TJUMHF.js.map → chunk-DCQ57UXY.js.map} +0 -0
  47. /package/dist/{chunk-OXDC6GJU.js.map → chunk-KZ3CZL54.js.map} +0 -0
  48. /package/dist/{chunk-5YWQO43I.js.map → chunk-PIPQ2TTK.js.map} +0 -0
  49. /package/dist/{chunk-QXRBLEAK.js.map → chunk-PUQGDXIY.js.map} +0 -0
  50. /package/dist/{chunk-KK3NWPOZ.js.map → chunk-PZKBPKJ2.js.map} +0 -0
  51. /package/dist/{chunk-WB7BWPKK.js.map → chunk-SSBZQMVX.js.map} +0 -0
  52. /package/dist/{chunk-EIFHXJDK.js.map → chunk-TG3SWAW3.js.map} +0 -0
  53. /package/dist/{chunk-UY3U64VR.js.map → chunk-UZL5QBO3.js.map} +0 -0
  54. /package/dist/{dev-command-CNSJ7DRG.js.map → dev-command-QGGRDTRC.js.map} +0 -0
  55. /package/dist/{git-credential-GFQJHBTK.js.map → git-credential-6CJWVNED.js.map} +0 -0
  56. /package/dist/{local-execute-GV6CVM3R.js.map → local-execute-ADQRK3T5.js.map} +0 -0
  57. /package/dist/{local-package-graph-NAZNI2VP.js.map → local-package-graph-5N5L6NHU.js.map} +0 -0
  58. /package/dist/{local-package-run-JFVEKBVM.js.map → local-package-run-CV4CN74S.js.map} +0 -0
  59. /package/dist/{mock-dep-resolve-HJLRVWYS.js.map → mock-dep-resolve-TTCQQEN2.js.map} +0 -0
  60. /package/dist/{mock-fetch-gateway-DIHCENGI.js.map → mock-fetch-gateway-TNK74HEP.js.map} +0 -0
  61. /package/dist/{mock-local-deps-XOTGC6SA.js.map → mock-local-deps-IMNSSGPW.js.map} +0 -0
  62. /package/dist/{mock-server-NO5RFVAF.js.map → mock-server-CJQI6B3A.js.map} +0 -0
  63. /package/dist/{open-api-client-5BQMPAQY.js.map → open-api-client-42L6TM2U.js.map} +0 -0
  64. /package/dist/{package-manifest-DFF6XCPV.js.map → package-manifest-FZOHGLVL.js.map} +0 -0
  65. /package/dist/{remote-execute-DNOU4AMT.js.map → remote-execute-J35MQTUC.js.map} +0 -0
  66. /package/dist/{setup-git-CZFPTTTQ.js.map → setup-git-IGLLNSLA.js.map} +0 -0
package/README.md CHANGED
@@ -69,27 +69,27 @@ multi-org store as the active org (no re-login).
69
69
 
70
70
  ## Commands
71
71
 
72
- | Command | Purpose |
73
- | ------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
74
- | `kody install` | Detect running local MCP clients, write their config, and start host OAuth. **Recommended long-term path.** |
75
- | `kody skill install` | Copies the getting-started skill into Claude Code / Cursor / Agents. |
76
- | `kody login` | Browser OAuth (CIMD + PKCE) for the CLI itself. Adds/replaces one org login (browser picker, or `kody login --org acme`) and keeps other org logins. |
77
- | `kody org list` | Lists logged-in orgs and marks the active one. `--json` for agents. |
78
- | `kody org use [<slug>]` | Switches the active org. With a slug (agents) switches directly; with no slug on a TTY opens a chooser; without a TTY pass a slug. |
79
- | `kody logout` | Removes the active org login (or `--org <slug>` for one org) and clears a stored bootstrap/API token when appropriate. |
80
- | `kody status` | Shows CLI login / stored API token state without printing secrets. |
81
- | `kody auth bootstrap --code` | Redeems a one-shot `kody_bc_…` from MCP `cliCredentialBootstrap` and stores the resulting `kody_at_…` for `execute --local` (never prints the token). |
82
- | `kody auth bootstrap --scopes` | Opt-in extra scopes: mints the code itself by passing `scopes` to `cliCredentialBootstrap` (with `--token`, else the `kody login` session, else a stored token), then redeems and stores it. See [Opt-in scopes](#opt-in-scopes). |
83
- | `kody auth setup-git` | Installs a Git credential helper for `https://kody.codes/@owner/name.git` (persistent `kody_at_…`, user-owned token with `package:read`/`package:write`). See [Git HTTPS](#git-https-setup-git). |
84
- | `kody auth remove-git` | Inverse of `setup-git`: clears Kody HTTPS git helpers, revokes the stored API token, deletes it from the keychain. Leaves `kody login` alone. |
85
- | `kody git-credential` | Credential helper invoked by Git after `setup-git` (`get` / `store` / `erase`). |
86
- | `kody whoami` | Confirms the CLI MCP connection and lists tools. With a scoped API token (and no login), shows token identity via the Open API. |
87
- | `kody search [query]` | Calls Kody `search` from the CLI (prefer the host MCP tool). Token-only auth uses Open API `GET /v1/search`. |
88
- | `kody api <operationId>` | Thin Open API wrapper matching the MCP `api` tool: `operationId` + flat `--params` JSON. Auth: `--token` / `KODY_API_TOKEN` / stored `auth bootstrap` token. The parsed `/openapi.json` route map is cached under the Kody cache dir keyed by the document's `ETag` and revalidated with `If-None-Match` on each run. |
89
- | `kody package publish` | Thin wrapper for `packagePublishExternalPush`. Optional positional `@owner/leaf`, bare leaf name, or package UUID (names are resolved to the package UUID via `packageList`); extra fields via `--params`. Same auth as `kody api`. Prints the API JSON. Exit **0** for `published`, `already_published` (including `artifacts_rebuilt: true`), and `dispatched` (poll `workflowRunList`). Exit **1** for refusal/rejection statuses (`checks_failed`, `locked`, `approval_required`, `not_fast_forward`) with the API `message` (or a checks summary) on stderr, like npm. Auth / permission / network failures also exit 1; `--json` adds `{ error, message, sent }` on stdout for network errors (`sent: false` = not sent; `sent: "unknown"` = maybe sent — prefer `kody api workflowRunList` before retry). Re-publishing the same commit is safe (durable dedupe / `already_published`). |
90
- | `kody package collaborators` / `grant` / `revoke` | Who can use one package, and add or remove teams and members of the org (`--org`). `<package>` is `@owner/leaf`, the kody id, or the package id. `grant <package> --team <slug>\|--user <username> [--preset use\|contribute\|manage]` (default `use`) adds or changes a collaborator via `packageCollaboratorSet`; people outside the org are refused. `revoke <package> --team\|--user\|--grant <grant_id>` removes one via `packageCollaboratorRemove`. Needs Manage on the package and a token with `package:manage_access` (`auth bootstrap --scopes …,package:manage_access`). Prints a summary, or JSON with `--json`. |
91
- | `kody execute` | Calls Kody `execute` from the CLI (`--invoke`, `--code`, `--file`, or stdin via `--file -`). With a scoped API token and no login (or with `--token`), cloud execute goes through CapabilityProxy → `kody.execute` — no `kody login`. Add `--local` to run the module (and static `kody:@…` package modules) on this machine instead. `--credential key=name` (repeatable; `org:name` / `personal:name` / empty `=` for none) picks ADR 0068 credentials for `--local` or a `kody login` MCP session. `--allow-private-network` opts local execution into private and local network access. `--target prod\|mock` (default `prod`) sends CapabilityProxy / search hops to prod or the built-in CLI mock; `--target mock` implies local workerd. |
92
- | `kody dev` | Local testing for unpublished packages. Serves `kody.app.entry` on localhost via workerd with hot reload. Subcommands: `fetch`, `job`, `webhook`, `emit`, `check`. Default `--target mock` (scratch storage, fake credentials). Covers exports, webhooks, schedules (run-once), and subscriptions. See [Local package testing](#local-package-testing-kody-dev). |
72
+ | Command | Purpose |
73
+ | ------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
74
+ | `kody install` | Detect running local MCP clients, write their config, and start host OAuth. **Recommended long-term path.** |
75
+ | `kody skill install` | Copies the getting-started skill into Claude Code / Cursor / Agents. |
76
+ | `kody login` | Browser OAuth (CIMD + PKCE) for the CLI itself. Adds/replaces one org login (browser picker, or `kody login --org acme`) and keeps other org logins. |
77
+ | `kody org list` | Lists logged-in orgs and marks the active one. `--json` for agents. |
78
+ | `kody org use [<slug>]` | Switches the active org. With a slug (agents) switches directly; with no slug on a TTY opens a chooser; without a TTY pass a slug. |
79
+ | `kody logout` | Removes the active org login (or `--org <slug>` for one org) and clears a stored bootstrap/API token when appropriate. |
80
+ | `kody status` | Shows CLI login / stored API token state without printing secrets. |
81
+ | `kody auth bootstrap --code` | Redeems a one-shot `kody_bc_…` from MCP `cliCredentialBootstrap` and stores the resulting `kody_at_…` for `execute --local` (never prints the token). |
82
+ | `kody auth bootstrap --scopes` | Opt-in extra scopes: mints the code itself by passing `scopes` to `cliCredentialBootstrap` (with `--token`, else the `kody login` session, else a stored token), then redeems and stores it. See [Opt-in scopes](#opt-in-scopes). |
83
+ | `kody auth setup-git` | Installs a Git credential helper for `https://kody.codes/@owner/name.git` (persistent `kody_at_…`, user-owned token with `package:read`/`package:write`). See [Git HTTPS](#git-https-setup-git). |
84
+ | `kody auth remove-git` | Inverse of `setup-git`: clears Kody HTTPS git helpers, revokes the stored API token, deletes it from the keychain. Leaves `kody login` alone. |
85
+ | `kody git-credential` | Credential helper invoked by Git after `setup-git` (`get` / `store` / `erase`). |
86
+ | `kody whoami` | Confirms the CLI MCP connection and lists tools. With a scoped API token (and no login), shows token identity via the Open API. |
87
+ | `kody search [query]` | Calls Kody `search` from the CLI (prefer the host MCP tool). Token-only auth uses Open API `GET /v1/search`. |
88
+ | `kody api <operationId>` | Thin Open API wrapper matching the MCP `api` tool: `operationId` + flat `--params` JSON. Auth: `--token` / `KODY_API_TOKEN` / stored `auth bootstrap` token. The parsed `/openapi.json` route map is cached under the Kody cache dir keyed by the document's `ETag` and revalidated with `If-None-Match` on each run. |
89
+ | `kody package publish` | Thin wrapper for `packagePublishExternalPush`. Optional positional `@owner/leaf`, bare leaf name, or package UUID (names are resolved to the package UUID via `packageList`); extra fields via `--params`. Same auth as `kody api`. Prints the API JSON. Exit **0** for `published`, `already_published` (including `artifacts_rebuilt: true`), and `dispatched` (poll `workflowRunList({ workflow_id })`). Exit **1** for refusal/rejection statuses (`checks_failed`, `locked`, `approval_required`, `not_fast_forward`) with the API `message` (or a checks summary) on stderr, like npm. Auth / permission / network failures also exit 1; `--json` adds `{ error, message, sent }` on stdout for network errors (`sent: false` = not sent; `sent: "unknown"` = maybe sent — prefer `kody api workflowRunList` with `workflow_id` when known, otherwise a recent list, before retry). Re-publishing the same commit is safe (durable dedupe / `already_published`). |
90
+ | `kody package collaborators` / `grant` / `revoke` | Who can use one package, and add or remove teams and members of the org (`--org`). `<package>` is `@owner/leaf`, the kody id, or the package id. `grant <package> --team <slug>\|--user <username> [--preset use\|contribute\|manage]` (default `use`) adds or changes a collaborator via `packageCollaboratorSet`; people outside the org are refused. `revoke <package> --team\|--user\|--grant <grant_id>` removes one via `packageCollaboratorRemove`. Needs Manage on the package and a token with `package:manage_access` (`auth bootstrap --scopes …,package:manage_access`). Prints a summary, or JSON with `--json`. |
91
+ | `kody execute` | Calls Kody `execute` from the CLI (`--invoke`, `--code`, `--file`, or stdin via `--file -`). With a scoped API token and no login (or with `--token`), cloud execute goes through CapabilityProxy → `kody.execute` — no `kody login`. Add `--local` to run the module (and static `kody:@…` package modules) on this machine instead. `--credential key=name` (repeatable; `org:name` / `personal:name` / empty `=` for none) picks ADR 0068 credentials for `--local` or a `kody login` MCP session. `--allow-private-network` opts local execution into private and local network access. `--target prod\|mock` (default `prod`) sends CapabilityProxy / search hops to prod or the built-in CLI mock; `--target mock` implies local workerd. |
92
+ | `kody dev` | Local testing for unpublished packages. Serves `kody.app.entry` on localhost via workerd with hot reload. Subcommands: `fetch`, `job`, `webhook`, `emit`, `check`. Default `--target mock` (scratch storage, fake credentials). Covers exports, webhooks, schedules (run-once), and subscriptions. See [Local package testing](#local-package-testing-kody-dev). |
93
93
 
94
94
  `--json` prints structured MCP results. On command failures it also prints a
95
95
  JSON error object on stdout (`error`, `message`, and when a network hop failed
@@ -7,14 +7,14 @@ import {
7
7
  login,
8
8
  refreshStoredCredentials,
9
9
  resolvePendingOrgSlug
10
- } from "./chunk-WB7BWPKK.js";
10
+ } from "./chunk-SSBZQMVX.js";
11
11
  import "./chunk-CASGRYOF.js";
12
12
  import "./chunk-GVSGNTG6.js";
13
- import "./chunk-5YWQO43I.js";
13
+ import "./chunk-PIPQ2TTK.js";
14
14
  import "./chunk-46IJPEID.js";
15
- import "./chunk-PWWN6JI2.js";
16
- import "./chunk-5BJUKHNZ.js";
17
- import "./chunk-LSFY5BNX.js";
15
+ import "./chunk-BML3W5CO.js";
16
+ import "./chunk-CCRCEU7S.js";
17
+ import "./chunk-NHRYNRXG.js";
18
18
  import "./chunk-CWWHR4FH.js";
19
19
  import "./chunk-3H72XY5R.js";
20
20
  import "./chunk-BTL3PJ2H.js";
@@ -28,4 +28,4 @@ export {
28
28
  refreshStoredCredentials,
29
29
  resolvePendingOrgSlug
30
30
  };
31
- //# sourceMappingURL=auth-5Z3XBOGI.js.map
31
+ //# sourceMappingURL=auth-FV2O77LC.js.map
package/dist/bin.js CHANGED
@@ -2,21 +2,21 @@
2
2
  import { createRequire as __createRequire } from 'node:module'; const require = __createRequire(import.meta.url);
3
3
  import {
4
4
  runCli
5
- } from "./chunk-57IZ5V4O.js";
5
+ } from "./chunk-BS24HBMB.js";
6
6
  import "./chunk-2XPH7L2P.js";
7
7
  import "./chunk-SLNAWWQK.js";
8
8
  import "./chunk-YDWTXEKQ.js";
9
- import "./chunk-KK3NWPOZ.js";
10
- import "./chunk-QXRBLEAK.js";
9
+ import "./chunk-PZKBPKJ2.js";
10
+ import "./chunk-PUQGDXIY.js";
11
11
  import "./chunk-6ZYUGXVW.js";
12
- import "./chunk-WB7BWPKK.js";
12
+ import "./chunk-SSBZQMVX.js";
13
13
  import "./chunk-CASGRYOF.js";
14
14
  import "./chunk-GVSGNTG6.js";
15
- import "./chunk-5YWQO43I.js";
15
+ import "./chunk-PIPQ2TTK.js";
16
16
  import "./chunk-46IJPEID.js";
17
- import "./chunk-PWWN6JI2.js";
18
- import "./chunk-5BJUKHNZ.js";
19
- import "./chunk-LSFY5BNX.js";
17
+ import "./chunk-BML3W5CO.js";
18
+ import "./chunk-CCRCEU7S.js";
19
+ import "./chunk-NHRYNRXG.js";
20
20
  import "./chunk-7PRJ36I5.js";
21
21
  import "./chunk-CWWHR4FH.js";
22
22
  import "./chunk-3H72XY5R.js";
@@ -4,15 +4,15 @@ import {
4
4
  forwardLocalGatewayFetchStream,
5
5
  installMockFetchShimModules,
6
6
  startLocalRuntimeBridge
7
- } from "./chunk-EIFHXJDK.js";
7
+ } from "./chunk-TG3SWAW3.js";
8
8
  import {
9
9
  resolveMockFetchGateway,
10
10
  tryHandleMockGatewayFetchCall
11
- } from "./chunk-V7TJUMHF.js";
11
+ } from "./chunk-DCQ57UXY.js";
12
12
  import {
13
13
  parseKodyPackageSpecifier,
14
14
  tryLoadSelfManifest
15
- } from "./chunk-UY3U64VR.js";
15
+ } from "./chunk-UZL5QBO3.js";
16
16
  import {
17
17
  bundleLocalUserModule
18
18
  } from "./chunk-7RLOLQIT.js";
@@ -28,20 +28,20 @@ import {
28
28
  runSecretEnvVar,
29
29
  runSecretHeader,
30
30
  writePackageModuleFiles
31
- } from "./chunk-OXDC6GJU.js";
31
+ } from "./chunk-KZ3CZL54.js";
32
32
  import {
33
33
  redact
34
34
  } from "./chunk-CASGRYOF.js";
35
35
  import {
36
36
  callOpenApiOperation
37
- } from "./chunk-5YWQO43I.js";
37
+ } from "./chunk-PIPQ2TTK.js";
38
38
  import {
39
39
  ensureWorkerdBinary
40
- } from "./chunk-PWWN6JI2.js";
40
+ } from "./chunk-BML3W5CO.js";
41
41
  import {
42
42
  assertTokenSafeApiUrl,
43
43
  callCapabilityProxy
44
- } from "./chunk-5BJUKHNZ.js";
44
+ } from "./chunk-CCRCEU7S.js";
45
45
  import {
46
46
  apiTokenEnvVar
47
47
  } from "./chunk-BTL3PJ2H.js";
@@ -1050,4 +1050,4 @@ export {
1050
1050
  resolveLocalPackageBinding,
1051
1051
  packageIdMatchesLocalPackage
1052
1052
  };
1053
- //# sourceMappingURL=chunk-JWDLZGIR.js.map
1053
+ //# sourceMappingURL=chunk-4NYWQWSY.js.map
@@ -1,14 +1,14 @@
1
1
  import { createRequire as __createRequire } from 'node:module'; const require = __createRequire(import.meta.url);
2
2
  import {
3
3
  unmockedRequestError
4
- } from "./chunk-V7TJUMHF.js";
4
+ } from "./chunk-DCQ57UXY.js";
5
5
  import {
6
6
  StructuredCliError,
7
7
  notImplementedInMock
8
8
  } from "./chunk-XV6D6HSG.js";
9
9
  import {
10
10
  userCacheDir
11
- } from "./chunk-PWWN6JI2.js";
11
+ } from "./chunk-BML3W5CO.js";
12
12
 
13
13
  // src/mock/mock-server.ts
14
14
  import {
@@ -768,4 +768,4 @@ export {
768
768
  ensureMockTarget,
769
769
  withMockServer
770
770
  };
771
- //# sourceMappingURL=chunk-XHKHDK76.js.map
771
+ //# sourceMappingURL=chunk-5X563FYY.js.map
@@ -1,7 +1,7 @@
1
1
  import { createRequire as __createRequire } from 'node:module'; const require = __createRequire(import.meta.url);
2
2
  import {
3
3
  describeNetworkError
4
- } from "./chunk-LSFY5BNX.js";
4
+ } from "./chunk-NHRYNRXG.js";
5
5
 
6
6
  // src/workerd-binary.ts
7
7
  import { createHash } from "node:crypto";
@@ -112,4 +112,4 @@ export {
112
112
  userCacheDir,
113
113
  ensureWorkerdBinary
114
114
  };
115
- //# sourceMappingURL=chunk-PWWN6JI2.js.map
115
+ //# sourceMappingURL=chunk-BML3W5CO.js.map
@@ -11,7 +11,7 @@ import {
11
11
  } from "./chunk-YDWTXEKQ.js";
12
12
  import {
13
13
  resolveLocalExecuteBearer
14
- } from "./chunk-KK3NWPOZ.js";
14
+ } from "./chunk-PZKBPKJ2.js";
15
15
  import {
16
16
  authBootstrap,
17
17
  authBootstrapWithScopes,
@@ -21,7 +21,7 @@ import {
21
21
  parseCliScopesFlag,
22
22
  refreshGitCredentialHelperPinIfNeeded,
23
23
  resolveCliTokenLifetime
24
- } from "./chunk-QXRBLEAK.js";
24
+ } from "./chunk-PUQGDXIY.js";
25
25
  import {
26
26
  redactError
27
27
  } from "./chunk-CASGRYOF.js";
@@ -37,7 +37,7 @@ import {
37
37
  readPackageVersion,
38
38
  requireApiToken,
39
39
  resolveScopedApiToken
40
- } from "./chunk-5BJUKHNZ.js";
40
+ } from "./chunk-CCRCEU7S.js";
41
41
  import {
42
42
  resolveOrgSlug
43
43
  } from "./chunk-7PRJ36I5.js";
@@ -246,14 +246,15 @@ ${orgBlock}
246
246
  via \`--params\` JSON (e.g. \`allow_force\`). Prints the API JSON
247
247
  body. Exit 0 for \`published\`, \`already_published\` (including
248
248
  when \`artifacts_rebuilt\` is true), and \`dispatched\` (poll
249
- \`workflowRunList\`). Exit 1 for refusal/rejection statuses
250
- (\`checks_failed\`, \`locked\`, \`approval_required\`,
249
+ \`workflowRunList({ workflow_id })\`). Exit 1 for refusal/rejection
250
+ statuses (\`checks_failed\`, \`locked\`, \`approval_required\`,
251
251
  \`not_fast_forward\`) \u2014 the API \`message\` (or a checks summary)
252
252
  goes to stderr, like npm. Auth / permission / network failures
253
253
  also exit 1; with \`--json\`, stdout also gets
254
254
  \`{ error, message, sent }\` where \`sent\` is \`false\` (connect
255
255
  phase \u2014 request not sent) or \`"unknown"\` (may have reached the
256
- server \u2014 prefer \`kody api workflowRunList\` before retrying).
256
+ server \u2014 prefer \`kody api workflowRunList\` with \`workflow_id\`
257
+ when known before retrying).
257
258
  Re-publishing the same commit is safe: an active durable run is
258
259
  deduped; a finished publish returns \`already_published\`.
259
260
 
@@ -937,7 +938,7 @@ async function dispatch(parsed, write, writeErr) {
937
938
  `);
938
939
  return 0;
939
940
  case "login": {
940
- const { login } = await import("./auth-5Z3XBOGI.js");
941
+ const { login } = await import("./auth-FV2O77LC.js");
941
942
  const openBrowser = parsed.values["no-browser"] !== true;
942
943
  const result = await login({
943
944
  mcpUrl,
@@ -1163,7 +1164,7 @@ async function dispatch(parsed, write, writeErr) {
1163
1164
  parseGitCredentialAction,
1164
1165
  parseGitCredentialInput,
1165
1166
  readGitCredentialStdin
1166
- } = await import("./git-credential-GFQJHBTK.js");
1167
+ } = await import("./git-credential-6CJWVNED.js");
1167
1168
  const action = parseGitCredentialAction(parsed.positionals);
1168
1169
  const raw = await readGitCredentialStdin(process.stdin);
1169
1170
  const output = await handleGitCredential({
@@ -1188,7 +1189,7 @@ async function dispatch(parsed, write, writeErr) {
1188
1189
  apiUrl: typeof parsed.values["api-url"] === "string" ? parsed.values["api-url"] : void 0
1189
1190
  });
1190
1191
  if (target === "mock") {
1191
- const { ensureMockTarget } = await import("./mock-server-NO5RFVAF.js");
1192
+ const { ensureMockTarget } = await import("./mock-server-CJQI6B3A.js");
1192
1193
  const mock = await ensureMockTarget({
1193
1194
  resetStorage: parsed.values["reset-storage"] === true,
1194
1195
  ...org ? { orgSlug: org } : {}
@@ -1230,7 +1231,7 @@ async function dispatch(parsed, write, writeErr) {
1230
1231
  allowEnvWithoutLogin: true,
1231
1232
  ...org ? { org } : {}
1232
1233
  })) {
1233
- const { whoamiWithApiToken: whoamiWithApiToken2 } = await import("./open-api-client-5BQMPAQY.js");
1234
+ const { whoamiWithApiToken: whoamiWithApiToken2 } = await import("./open-api-client-42L6TM2U.js");
1234
1235
  const identity2 = await whoamiWithApiToken2({
1235
1236
  token: requireApiToken(tokenValues, process.env, "whoami", {
1236
1237
  apiUrl
@@ -1257,13 +1258,13 @@ async function dispatch(parsed, write, writeErr) {
1257
1258
  );
1258
1259
  return 0;
1259
1260
  }
1260
- const { ensureOpenApiCredentials } = await import("./auth-5Z3XBOGI.js");
1261
+ const { ensureOpenApiCredentials } = await import("./auth-FV2O77LC.js");
1261
1262
  const credentials = await ensureOpenApiCredentials({
1262
1263
  mcpUrl,
1263
1264
  org,
1264
1265
  apiUrl
1265
1266
  });
1266
- const { whoamiWithApiToken } = await import("./open-api-client-5BQMPAQY.js");
1267
+ const { whoamiWithApiToken } = await import("./open-api-client-42L6TM2U.js");
1267
1268
  const identity = await whoamiWithApiToken({
1268
1269
  token: credentials.accessToken,
1269
1270
  apiUrl,
@@ -1311,13 +1312,13 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1311
1312
  let closeMock;
1312
1313
  try {
1313
1314
  if (target === "mock") {
1314
- const { ensureMockTarget } = await import("./mock-server-NO5RFVAF.js");
1315
+ const { ensureMockTarget } = await import("./mock-server-CJQI6B3A.js");
1315
1316
  const mock = await ensureMockTarget({
1316
1317
  resetStorage: parsed.values["reset-storage"] === true
1317
1318
  });
1318
1319
  apiUrl = mock.apiUrl;
1319
1320
  closeMock = mock.started ? () => mock.server.close() : void 0;
1320
- const { searchWithApiToken: searchWithApiToken2 } = await import("./open-api-client-5BQMPAQY.js");
1321
+ const { searchWithApiToken: searchWithApiToken2 } = await import("./open-api-client-42L6TM2U.js");
1321
1322
  const result2 = await searchWithApiToken2({
1322
1323
  token: mock.token,
1323
1324
  apiUrl,
@@ -1336,7 +1337,7 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1336
1337
  allowEnvWithoutLogin: true,
1337
1338
  ...org ? { org } : {}
1338
1339
  })) {
1339
- const { searchWithApiToken: searchWithApiToken2 } = await import("./open-api-client-5BQMPAQY.js");
1340
+ const { searchWithApiToken: searchWithApiToken2 } = await import("./open-api-client-42L6TM2U.js");
1340
1341
  const result2 = await searchWithApiToken2({
1341
1342
  token: requireApiToken(tokenValues, process.env, "search", {
1342
1343
  apiUrl
@@ -1351,13 +1352,13 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1351
1352
  write(formatToolResult(result2, json));
1352
1353
  return result2.isError ? 1 : 0;
1353
1354
  }
1354
- const { ensureOpenApiCredentials } = await import("./auth-5Z3XBOGI.js");
1355
+ const { ensureOpenApiCredentials } = await import("./auth-FV2O77LC.js");
1355
1356
  const credentials = await ensureOpenApiCredentials({
1356
1357
  mcpUrl,
1357
1358
  org,
1358
1359
  apiUrl
1359
1360
  });
1360
- const { searchWithApiToken } = await import("./open-api-client-5BQMPAQY.js");
1361
+ const { searchWithApiToken } = await import("./open-api-client-42L6TM2U.js");
1361
1362
  const result = await searchWithApiToken({
1362
1363
  token: credentials.accessToken,
1363
1364
  apiUrl,
@@ -1427,7 +1428,7 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1427
1428
  apiUrl: typeof parsed.values["api-url"] === "string" ? parsed.values["api-url"] : void 0
1428
1429
  });
1429
1430
  let apiUrl = prodApiUrl;
1430
- const { parsePassthroughHosts } = await import("./mock-fetch-gateway-DIHCENGI.js");
1431
+ const { parsePassthroughHosts } = await import("./mock-fetch-gateway-TNK74HEP.js");
1431
1432
  const passthroughHosts = parsePassthroughHosts(
1432
1433
  typeof parsed.values.passthrough === "string" ? parsed.values.passthrough : void 0
1433
1434
  );
@@ -1442,7 +1443,7 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1442
1443
  let localPackageRun = localPackageInvoke;
1443
1444
  if (!localPackageRun && local && modulePath !== void 0) {
1444
1445
  try {
1445
- const { loadPackageManifest } = await import("./package-manifest-DFF6XCPV.js");
1446
+ const { loadPackageManifest } = await import("./package-manifest-FZOHGLVL.js");
1446
1447
  const manifest = await loadPackageManifest(process.cwd());
1447
1448
  localPackageRun = {
1448
1449
  modulePath,
@@ -1455,7 +1456,7 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1455
1456
  }
1456
1457
  try {
1457
1458
  if (target === "mock") {
1458
- const { ensureMockTarget } = await import("./mock-server-NO5RFVAF.js");
1459
+ const { ensureMockTarget } = await import("./mock-server-CJQI6B3A.js");
1459
1460
  const mock = await ensureMockTarget({
1460
1461
  resetStorage: parsed.values["reset-storage"] === true,
1461
1462
  packageId: localPackageRun ? `local:${localPackageRun.kodyId}` : void 0,
@@ -1464,7 +1465,7 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1464
1465
  apiUrl = mock.apiUrl;
1465
1466
  mockToken = mock.token;
1466
1467
  closeMock = mock.started ? () => mock.server.close() : void 0;
1467
- const { tryResolveMockDepResolve } = await import("./mock-dep-resolve-HJLRVWYS.js");
1468
+ const { tryResolveMockDepResolve } = await import("./mock-dep-resolve-TTCQQEN2.js");
1468
1469
  mockDepResolve = await tryResolveMockDepResolve({
1469
1470
  tokenValues,
1470
1471
  apiUrl: prodApiUrl,
@@ -1473,7 +1474,7 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1473
1474
  });
1474
1475
  }
1475
1476
  if (localPackageRun) {
1476
- const { buildLocalPackageContext, runLocalPackageModule } = await import("./local-package-run-JFVEKBVM.js");
1477
+ const { buildLocalPackageContext, runLocalPackageModule } = await import("./local-package-run-CV4CN74S.js");
1477
1478
  const result2 = await runLocalPackageModule({
1478
1479
  modulePath: localPackageRun.modulePath,
1479
1480
  params: args.params,
@@ -1511,13 +1512,13 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1511
1512
  let packageRootForMocks;
1512
1513
  if (target === "mock") {
1513
1514
  try {
1514
- const { loadPackageManifest } = await import("./package-manifest-DFF6XCPV.js");
1515
+ const { loadPackageManifest } = await import("./package-manifest-FZOHGLVL.js");
1515
1516
  packageRootForMocks = (await loadPackageManifest(process.cwd())).root;
1516
1517
  } catch {
1517
1518
  packageRootForMocks = void 0;
1518
1519
  }
1519
1520
  }
1520
- const result = local ? await (await import("./local-execute-GV6CVM3R.js")).runLocalExecute({
1521
+ const result = local ? await (await import("./local-execute-ADQRK3T5.js")).runLocalExecute({
1521
1522
  code: args.code,
1522
1523
  ...modulePath !== void 0 ? { modulePath } : {},
1523
1524
  params: args.params,
@@ -1539,7 +1540,7 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1539
1540
  allowPrivateNetwork: parsed.values["allow-private-network"] === true,
1540
1541
  onStatus: (message) => writeErr(`${message}
1541
1542
  `)
1542
- }) : useToken ? await (await import("./remote-execute-DNOU4AMT.js")).runRemoteExecuteWithToken({
1543
+ }) : useToken ? await (await import("./remote-execute-J35MQTUC.js")).runRemoteExecuteWithToken({
1543
1544
  code: typeof args.code === "string" ? args.code : void 0,
1544
1545
  invoke,
1545
1546
  params: args.params,
@@ -1554,13 +1555,13 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1554
1555
  apiUrl,
1555
1556
  ...org ? { org } : {}
1556
1557
  }) : await (async () => {
1557
- const { ensureOpenApiCredentials } = await import("./auth-5Z3XBOGI.js");
1558
+ const { ensureOpenApiCredentials } = await import("./auth-FV2O77LC.js");
1558
1559
  const session = await ensureOpenApiCredentials({
1559
1560
  mcpUrl,
1560
1561
  org,
1561
1562
  apiUrl
1562
1563
  });
1563
- return (await import("./remote-execute-DNOU4AMT.js")).runRemoteExecuteWithToken({
1564
+ return (await import("./remote-execute-J35MQTUC.js")).runRemoteExecuteWithToken({
1564
1565
  code: typeof args.code === "string" ? args.code : void 0,
1565
1566
  invoke,
1566
1567
  params: args.params,
@@ -1575,7 +1576,7 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1575
1576
  return result.isError ? 1 : 0;
1576
1577
  } catch (error) {
1577
1578
  if (json && local) {
1578
- const { LocalPackageGraphError, packageGraphErrorToolResult } = await import("./local-package-graph-NAZNI2VP.js");
1579
+ const { LocalPackageGraphError, packageGraphErrorToolResult } = await import("./local-package-graph-5N5L6NHU.js");
1579
1580
  if (error instanceof LocalPackageGraphError) {
1580
1581
  const redacted = redactError(error).message;
1581
1582
  const result = packageGraphErrorToolResult(error);
@@ -1605,7 +1606,7 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1605
1606
  runDevServe,
1606
1607
  runDevWebhook,
1607
1608
  tryAttachedDevFetch
1608
- } = await import("./dev-command-CNSJ7DRG.js");
1609
+ } = await import("./dev-command-QGGRDTRC.js");
1609
1610
  const target = resolveTarget({
1610
1611
  command: "dev",
1611
1612
  flag: typeof parsed.values.target === "string" ? parsed.values.target : void 0
@@ -1631,8 +1632,8 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1631
1632
  { callOpenApiOperation, formatOpenApiHttpDebugLine },
1632
1633
  { parsePackageCheckResult, PublishChecksAuthError }
1633
1634
  ] = await Promise.all([
1634
- import("./open-api-client-5BQMPAQY.js"),
1635
- import("./dev-command-CNSJ7DRG.js")
1635
+ import("./open-api-client-42L6TM2U.js"),
1636
+ import("./dev-command-QGGRDTRC.js")
1636
1637
  ]);
1637
1638
  let token2;
1638
1639
  try {
@@ -1743,13 +1744,13 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1743
1744
  purpose: "kody dev",
1744
1745
  ...org ? { org } : {}
1745
1746
  }) : "mock";
1746
- const mockDepResolve = target === "mock" ? await (await import("./mock-dep-resolve-HJLRVWYS.js")).tryResolveMockDepResolve({
1747
+ const mockDepResolve = target === "mock" ? await (await import("./mock-dep-resolve-TTCQQEN2.js")).tryResolveMockDepResolve({
1747
1748
  tokenValues,
1748
1749
  apiUrl: prodApiUrl,
1749
1750
  mcpUrl,
1750
1751
  ...org ? { org } : {}
1751
1752
  }) : void 0;
1752
- const { parsePassthroughHosts } = await import("./mock-fetch-gateway-DIHCENGI.js");
1753
+ const { parsePassthroughHosts } = await import("./mock-fetch-gateway-TNK74HEP.js");
1753
1754
  const passthroughHosts = parsePassthroughHosts(
1754
1755
  typeof parsed.values.passthrough === "string" ? parsed.values.passthrough : void 0
1755
1756
  );
@@ -1761,7 +1762,7 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1761
1762
  const allowPrivateNetwork = parsed.values["allow-private-network"] === true;
1762
1763
  let packageId;
1763
1764
  try {
1764
- const { loadPackageManifest } = await import("./package-manifest-DFF6XCPV.js");
1765
+ const { loadPackageManifest } = await import("./package-manifest-FZOHGLVL.js");
1765
1766
  const manifest = await loadPackageManifest(process.cwd());
1766
1767
  packageId = `local:${manifest.kodyId}`;
1767
1768
  } catch {
@@ -1884,7 +1885,7 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1884
1885
  const params = parseApiParamsJson(
1885
1886
  typeof parsed.values.params === "string" ? parsed.values.params : void 0
1886
1887
  );
1887
- const { callOpenApiOperation } = await import("./open-api-client-5BQMPAQY.js");
1888
+ const { callOpenApiOperation } = await import("./open-api-client-42L6TM2U.js");
1888
1889
  const result = await callOpenApiOperation({
1889
1890
  operationId,
1890
1891
  params,
@@ -1919,7 +1920,7 @@ scopes: ${identity.token.scopes.join(", ") || "(none)"}
1919
1920
  mcpUrl,
1920
1921
  org
1921
1922
  });
1922
- const { callOpenApiOperation: callOpenApiOperation2 } = await import("./open-api-client-5BQMPAQY.js");
1923
+ const { callOpenApiOperation: callOpenApiOperation2 } = await import("./open-api-client-42L6TM2U.js");
1923
1924
  write(
1924
1925
  await runPackageCollaboratorPlan({
1925
1926
  plan,
@@ -1945,7 +1946,7 @@ ${packageCollaboratorUsage}`
1945
1946
  positional: parsed.positionals[1],
1946
1947
  paramsJson: typeof parsed.values.params === "string" ? parsed.values.params : void 0
1947
1948
  });
1948
- const { callOpenApiOperation } = await import("./open-api-client-5BQMPAQY.js");
1949
+ const { callOpenApiOperation } = await import("./open-api-client-42L6TM2U.js");
1949
1950
  const publishToken = await accessTokenForOpenApi({
1950
1951
  tokenValues,
1951
1952
  apiUrl,
@@ -2019,7 +2020,7 @@ async function tryResolveLocalPackageInvoke(invoke) {
2019
2020
  const trimmed = invoke.trim();
2020
2021
  if (!trimmed) return null;
2021
2022
  if (isPublishedPackageInvokeSpecifier(trimmed)) return null;
2022
- const { loadPackageManifest, resolveExportModulePath } = await import("./package-manifest-DFF6XCPV.js");
2023
+ const { loadPackageManifest, resolveExportModulePath } = await import("./package-manifest-FZOHGLVL.js");
2023
2024
  const { StructuredCliError } = await import("./structured-error-5MLWXYR3.js");
2024
2025
  let manifest;
2025
2026
  try {
@@ -2083,7 +2084,7 @@ function attachExecuteCommonArgs(args, input) {
2083
2084
  return args;
2084
2085
  }
2085
2086
  async function runAuthSetupGit(input) {
2086
- const { authSetupGit, setupGitDefaultScopes } = await import("./setup-git-CZFPTTTQ.js");
2087
+ const { authSetupGit, setupGitDefaultScopes } = await import("./setup-git-IGLLNSLA.js");
2087
2088
  const apiUrl = apiUrlFrom({
2088
2089
  apiUrl: typeof input.values["api-url"] === "string" ? input.values["api-url"] : void 0
2089
2090
  });
@@ -2140,7 +2141,7 @@ async function runAuthSetupGit(input) {
2140
2141
  return 0;
2141
2142
  }
2142
2143
  async function runAuthRemoveGit(input) {
2143
- const { authRemoveGit, formatAuthRemoveGitReport } = await import("./setup-git-CZFPTTTQ.js");
2144
+ const { authRemoveGit, formatAuthRemoveGitReport } = await import("./setup-git-IGLLNSLA.js");
2144
2145
  const apiUrl = apiUrlFrom({
2145
2146
  apiUrl: typeof input.values["api-url"] === "string" ? input.values["api-url"] : void 0
2146
2147
  });
@@ -2168,7 +2169,7 @@ function bootstrapMinter(input) {
2168
2169
  apiUrl: input.apiUrl
2169
2170
  }
2170
2171
  );
2171
- const { callOpenApiOperation } = await import("./open-api-client-5BQMPAQY.js");
2172
+ const { callOpenApiOperation } = await import("./open-api-client-42L6TM2U.js");
2172
2173
  try {
2173
2174
  return await callOpenApiOperation({
2174
2175
  token,
@@ -2189,13 +2190,13 @@ function bootstrapMinter(input) {
2189
2190
  if (loadCredentials(input.mcpUrl, void 0, void 0, {
2190
2191
  org: input.org
2191
2192
  })) {
2192
- const { ensureOpenApiCredentials } = await import("./auth-5Z3XBOGI.js");
2193
+ const { ensureOpenApiCredentials } = await import("./auth-FV2O77LC.js");
2193
2194
  const session = await ensureOpenApiCredentials({
2194
2195
  mcpUrl: input.mcpUrl,
2195
2196
  apiUrl: input.apiUrl,
2196
2197
  ...input.org ? { org: input.org } : {}
2197
2198
  });
2198
- const { callOpenApiOperation } = await import("./open-api-client-5BQMPAQY.js");
2199
+ const { callOpenApiOperation } = await import("./open-api-client-42L6TM2U.js");
2199
2200
  return callOpenApiOperation({
2200
2201
  operationId: cliCredentialBootstrapOperationId,
2201
2202
  params,
@@ -2221,7 +2222,7 @@ async function accessTokenForOpenApi(input) {
2221
2222
  apiUrl: input.apiUrl
2222
2223
  });
2223
2224
  if (explicit) return explicit;
2224
- const { ensureOpenApiCredentials } = await import("./auth-5Z3XBOGI.js");
2225
+ const { ensureOpenApiCredentials } = await import("./auth-FV2O77LC.js");
2225
2226
  const session = await ensureOpenApiCredentials({
2226
2227
  mcpUrl: input.mcpUrl,
2227
2228
  apiUrl: input.apiUrl,
@@ -2306,4 +2307,4 @@ export {
2306
2307
  resolvePackagePublishTarget,
2307
2308
  shouldUseApiToken
2308
2309
  };
2309
- //# sourceMappingURL=chunk-57IZ5V4O.js.map
2310
+ //# sourceMappingURL=chunk-BS24HBMB.js.map