mandala-computer-mcp 0.5.0 → 0.6.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.
Files changed (66) hide show
  1. package/README.md +119 -11
  2. package/dist/api.d.ts +47 -1
  3. package/dist/api.d.ts.map +1 -1
  4. package/dist/api.js +248 -22
  5. package/dist/api.js.map +1 -1
  6. package/dist/cli.d.ts.map +1 -1
  7. package/dist/cli.js +17 -0
  8. package/dist/cli.js.map +1 -1
  9. package/dist/errors.d.ts +93 -2
  10. package/dist/errors.d.ts.map +1 -1
  11. package/dist/errors.js +166 -7
  12. package/dist/errors.js.map +1 -1
  13. package/dist/format.d.ts +25 -0
  14. package/dist/format.d.ts.map +1 -1
  15. package/dist/format.js +31 -2
  16. package/dist/format.js.map +1 -1
  17. package/dist/http.d.ts +42 -0
  18. package/dist/http.d.ts.map +1 -1
  19. package/dist/http.js +379 -3
  20. package/dist/http.js.map +1 -1
  21. package/dist/index.d.ts +4 -3
  22. package/dist/index.d.ts.map +1 -1
  23. package/dist/index.js +3 -3
  24. package/dist/index.js.map +1 -1
  25. package/dist/paths.d.ts +10 -2
  26. package/dist/paths.d.ts.map +1 -1
  27. package/dist/paths.js +15 -5
  28. package/dist/paths.js.map +1 -1
  29. package/dist/secret-errors.d.ts +59 -0
  30. package/dist/secret-errors.d.ts.map +1 -0
  31. package/dist/secret-errors.js +199 -0
  32. package/dist/secret-errors.js.map +1 -0
  33. package/dist/secret-store.d.ts +115 -0
  34. package/dist/secret-store.d.ts.map +1 -0
  35. package/dist/secret-store.js +105 -0
  36. package/dist/secret-store.js.map +1 -0
  37. package/dist/server.d.ts +1 -1
  38. package/dist/server.js +1 -1
  39. package/dist/session.d.ts +6 -1
  40. package/dist/session.d.ts.map +1 -1
  41. package/dist/session.js +1 -1
  42. package/dist/session.js.map +1 -1
  43. package/dist/tool-filters.d.ts +1 -1
  44. package/dist/tool-filters.d.ts.map +1 -1
  45. package/dist/tool-filters.js +9 -1
  46. package/dist/tool-filters.js.map +1 -1
  47. package/dist/tools/computers.d.ts.map +1 -1
  48. package/dist/tools/computers.js +11 -10
  49. package/dist/tools/computers.js.map +1 -1
  50. package/dist/tools/guest.d.ts.map +1 -1
  51. package/dist/tools/guest.js +134 -20
  52. package/dist/tools/guest.js.map +1 -1
  53. package/dist/tools/input.d.ts +2 -0
  54. package/dist/tools/input.d.ts.map +1 -1
  55. package/dist/tools/input.js +31 -5
  56. package/dist/tools/input.js.map +1 -1
  57. package/dist/tools/secrets.d.ts +33 -13
  58. package/dist/tools/secrets.d.ts.map +1 -1
  59. package/dist/tools/secrets.js +259 -15
  60. package/dist/tools/secrets.js.map +1 -1
  61. package/dist/tools/snapshots.d.ts.map +1 -1
  62. package/dist/tools/snapshots.js +9 -3
  63. package/dist/tools/snapshots.js.map +1 -1
  64. package/dist/tools/webhooks.js +1 -1
  65. package/dist/tools/webhooks.js.map +1 -1
  66. package/package.json +1 -1
package/README.md CHANGED
@@ -155,6 +155,17 @@ Parameter and response-mode support remains a separate contract.
155
155
  `list_windows`, `window_action`, `read_clipboard`, `write_clipboard`,
156
156
  `read_file`, `write_file`, `list_directory`
157
157
 
158
+ `write_file` replaces a file already at the path. With `overwrite: false` it
159
+ creates the file only if nothing is there, and a path that is taken is refused
160
+ without that attempt writing anything (Linux computers only). Incomplete
161
+ contents are never published at the path, but a failure while publishing or
162
+ answering can leave the complete file there, so after any error read the path
163
+ before retrying or overwriting. `read_file` and `write_file` take `no_wake: true`
164
+ to refuse (409) rather than resume a computer that is not running. For
165
+ embedders, the `Api` raises that refusal as `FileExistsError`, and a
166
+ create-only 409 whose reason could not be read as `CreateOnlyConflictError`,
167
+ which says nothing about the path; `isTransient` is false for both.
168
+
158
169
  **Retained versions** — `retain_execution_output`, `get_result`, `read_result_output`,
159
170
  `delete_result`, `publish_artifact`, `get_artifact`, `read_artifact`, `delete_artifact`
160
171
 
@@ -186,14 +197,27 @@ was issued to, not to the account, and are accepted by every computer with SSH
186
197
  on, on every account where that person is an owner or member. A
187
198
  workspace-scoped key can read keys but not add or remove them.
188
199
 
189
- **Secret bindings** — `get_computer_secrets`, `set_computer_secrets`, and
190
- `create_computer`'s `secrets`. Which of the account's secrets a computer
191
- receives, at which revision, and where: as an environment variable (`env`) or as
192
- a file under `/run/mandala-secrets/user/files` (`file`). Values never cross these
193
- tools. A set replaces the whole list (`[]` removes every binding) and reaches the
194
- guest at the computer's next start or restart; send the `version` a read
195
- answered to have it refused with 409 if the list changed since. A secret bound
196
- as a file is also rewritten on a running computer when its value is replaced.
200
+ **Secrets** — `list_secrets`, `get_secret`, `create_secret`, `replace_secret`,
201
+ `delete_secret` for the account's secret store, and `get_computer_secrets`,
202
+ `set_computer_secrets` and `create_computer`'s `secrets` for which of them a
203
+ computer receives. A value goes in through `create_secret` or `replace_secret`
204
+ and never comes back out. No route answers one, and a store tool's result
205
+ holds only the decoded documented fields (success) or the status, the `reason`
206
+ word and a sentence of its own (refusal). It never includes the platform's
207
+ response text, and the `Api` keeps none for these routes. The bindings carry
208
+ only secret ids, revisions and names. A computer receives a secret as an environment variable (`env`) or as a
209
+ file under `/run/mandala-secrets/user/files` (`file`). A set replaces the whole
210
+ binding list (`[]` removes every binding) and reaches the guest at the
211
+ computer's next start or restart; send the `version` a read answered to have it
212
+ refused with 409 if the list changed since. A replaced value also reaches a
213
+ running computer: a file binding's file is rewritten in place, and on an image
214
+ that supports it an env binding reaches new shells and `exec` with
215
+ `desktop: true` (programs already running keep the old value until a restart).
216
+ A command that needs a bound variable should use `desktop: true`. Whether a
217
+ plain root `exec` sees it depends on the platform version. `replace_secret`
218
+ and `delete_secret` need the current `revision_id`, and a stale one is a 409.
219
+ `delete_secret` also needs `confirm: true`: a computer still bound to a deleted
220
+ secret cannot start again until that binding is removed.
197
221
 
198
222
  **Delegating** — `run_agent`, `run_agent_chat`, registered only when a model key is present:
199
223
  `MANDALA_MODEL_KEY` on stdio, or the caller's own `X-Model-Key` header over HTTP.
@@ -233,7 +257,7 @@ with an error listing all valid tags.
233
257
  | `usage` | `get_usage` |
234
258
  | `webhooks` | All webhook tools listed above |
235
259
  | `ssh` | All SSH tools listed above |
236
- | `secrets` | `get_computer_secrets`, `set_computer_secrets` |
260
+ | `secrets` | `list_secrets`, `get_secret`, `create_secret`, `replace_secret`, `delete_secret`, `get_computer_secrets`, `set_computer_secrets` |
237
261
  | `agent` | `run_agent`, `run_agent_chat` |
238
262
  | `activities` | `list_activities`, `get_activity`, `get_activity_results` |
239
263
  | `signals` | `read_signals` |
@@ -719,6 +743,25 @@ available. A missing computer, snapshot, route or guest file remains
719
743
  `NotFoundError` (404); other guest failures keep their own status and message.
720
744
  Neither response causes an automatic retry or method switch.
721
745
 
746
+ `isTransient(err)` answers "is this worth sending again unchanged". A `503` is
747
+ transient only for a GET or HEAD. Any change answered `503` may or may not have
748
+ happened, because the platform answers a failure after the request was sent the
749
+ same way. So `isTransient` is false for it whatever `reason` it carries, the
750
+ tool's answer says to read the current state first, and `error.method` records
751
+ the method. A `reason` this version does not
752
+ know, such as a new word, is treated as no classification. `reasonKind` returns
753
+ `undefined` for it, and the status decides.
754
+
755
+ The secret store has typed calls on `api.secrets`: `list`, `create`, `get`,
756
+ `replace` and `delete`. Each answer is decoded strictly to the documented
757
+ fields, and none of them carries a value:
758
+
759
+ ```ts
760
+ const { secrets } = await api.secrets.list();
761
+ const s = await api.secrets.create({ name: 'OPENAI_API_KEY', value: key });
762
+ await api.secrets.replace(s.id, { value: next, revisionId: s.revision_id });
763
+ ```
764
+
722
765
  Embedders can inspect optional diagnostics on every `APIError`:
723
766
 
724
767
  ```ts
@@ -746,7 +789,7 @@ and nested chat accounting. `allow` and `wwwAuthenticate` come only from receive
746
789
  headers. HEAD failures can carry these fields with no body. Older servers,
747
790
  intermediaries and connection failures may supply none of them. Existing
748
791
  constructor arguments retain their meanings; an optional trailing
749
- `APIErrorMetadata` object adds these three fields.
792
+ `APIErrorMetadata` object adds these three fields, and `method`.
750
793
 
751
794
  MCP error results include supplied `reason`, `request_id`, `allow`,
752
795
  `www_authenticate` and `retry_after_ms` as labelled JSON metadata. Diagnostic
@@ -895,6 +938,69 @@ not list it, and every request is refused with a 403. Set
895
938
  is in force, so a `403` on a deployment that worked before has a line above it
896
939
  naming the fix.
897
940
 
941
+ ### Hosted, with OAuth
942
+
943
+ The endpoint at `https://app.mandala.computer/mcp` is this server run with
944
+ `--http` behind the platform's own proxy, with the platform as its OAuth 2.1
945
+ authorization server. Nobody pastes a key:
946
+
947
+ ```sh
948
+ claude mcp add --transport http mandala https://app.mandala.computer/mcp
949
+ ```
950
+
951
+ Two variables make an HTTP server behave that way, and without them nothing
952
+ changes — self-hosters keep bringing API keys:
953
+
954
+ ```sh
955
+ MANDALA_MCP_RESOURCE_METADATA_URL=https://app.mandala.computer/.well-known/oauth-protected-resource/mcp \
956
+ MANDALA_MCP_SERVICE_SECRET=… \
957
+ MANDALA_ALLOWED_HOSTS=app.mandala.computer \
958
+ npx mandala-computer-mcp --http --host 127.0.0.1 --port 3000
959
+ ```
960
+
961
+ In this mode `X-Forwarded-For` is believed from a loopback peer only, so the
962
+ proxy in front must be on the same machine and must set it to the real client
963
+ address.
964
+
965
+ - **Every `/mcp` request needs a bearer**, initialize and `tools/list`
966
+ included. One without is answered `401` with exactly
967
+ `WWW-Authenticate: Bearer resource_metadata="<that URL>", scope="mcp:tools"`,
968
+ which is how a client finds where to authorize. `/healthz` stays open.
969
+ - **The bearer is passed through unchanged** — an `mcpat_…` access token, or an
970
+ API key, which the platform still accepts. The access token is good for this
971
+ endpoint only. It is not an API key: sent to the API directly, the platform
972
+ refuses it with `401` (`reason: "invalid"`). A person revokes it under
973
+ Settings → Connected apps.
974
+ - **A bearer is checked with the platform before it gets anything.** An
975
+ initialize makes no session until the platform accepts its token — a `2xx`
976
+ from `GET ssh-keys`, which every valid credential gets — so invented tokens
977
+ cannot fill the session pool. A `401` is the challenge above; any other
978
+ answer is `503` and nothing is remembered. Refused initializes are budgeted
979
+ per source address, 20 a minute. Past that, a token already accepted still
980
+ passes and a new one is still checked, but only one every 5 s per address;
981
+ the rest get `429` with `Retry-After`. The budget comes back when its minute
982
+ is up. A POST
983
+ carrying a request is checked again before it is dispatched, with an
984
+ acceptance cached for 60 s under the token's digest, so an expired or
985
+ revoked token is a clean `401` before any stream opens.
986
+ - **A token the platform refuses during a call comes back as that same
987
+ `401`**, not as a tool error, so the client refreshes or authorizes again —
988
+ the answer is held until its first byte for this. The one case that cannot
989
+ work: a token that dies mid-call AFTER the stream has committed (the SDK's
990
+ 15 s keep-alive, a progress notification or a partial result). That call
991
+ ends as a tool error, the session remembers the refusal, and the next
992
+ request on that token gets the `401` without reaching the platform.
993
+ - **A refreshed token starts a new session.** A session is bound to the digest
994
+ of the bearer that opened it, and a different bearer on it is answered
995
+ `404 Unknown session`, the MCP spec's signal to initialize again. An access
996
+ token says nothing this server can check about which grant it came from, so
997
+ rebinding would let any valid credential that learned a session id take over
998
+ its bound computer, buffered events and retained results.
999
+ - `X-Mandala-MCP-Service` carries `MANDALA_MCP_SERVICE_SECRET` on every
1000
+ platform request, only ever to `MANDALA_BASE_URL`, so a token cannot be
1001
+ replayed at the API directly by the app it was issued to. A client's own
1002
+ header of that name is never forwarded.
1003
+
898
1004
  ### Configuration
899
1005
 
900
1006
  | Variable | Meaning |
@@ -909,8 +1015,10 @@ naming the fix.
909
1015
  | `MANDALA_READ_ONLY` | Keep only tools annotated `readOnlyHint: true`; strict boolean parsing as described under Tool filters. |
910
1016
  | `MANDALA_TAGS` | Comma-separated lowercase tool tags; see Tool filters for the inventory and intersection rules. |
911
1017
  | `MANDALA_ALLOWED_HOSTS`, `MANDALA_ALLOWED_ORIGINS` | Comma-separated. Which `Host` and `Origin` values this server answers to. On a loopback bind the host list defaults to the address it was given, so DNS-rebinding protection is on without configuration; set this when serving under a name. |
1018
+ | `MANDALA_MCP_RESOURCE_METADATA_URL` | `--http` only. The OAuth protected-resource metadata URL this server is published under. Set, it answers OAuth clients as described under Hosted, with OAuth; unset, callers bring an API key. |
1019
+ | `MANDALA_MCP_SERVICE_SECRET` | `--http` only. Sent as `X-Mandala-MCP-Service` on every platform request, to `MANDALA_BASE_URL` only. Never logged. |
912
1020
 
913
- Every one of these but the model key and the two tool filters has a flag as well, and a flag overrides
1021
+ Every one of these but the model key, the two tool filters and the two OAuth settings has a flag as well, and a flag overrides
914
1022
  the environment: `--http`, `--port`, `--host`, `--base-url`, `--computer`,
915
1023
  `--allowed-hosts`, `--allowed-origins`, `--no-lifecycle`, local `--profile`, plus `--help` and
916
1024
  `--version`. `--key` exists for a caller launching several servers under
package/dist/api.d.ts CHANGED
@@ -1,7 +1,19 @@
1
1
  import { Agent } from 'undici';
2
+ import { type SecretStore } from './secret-store.js';
3
+ export { isSecretStoreRoute } from './secret-errors.js';
2
4
  export declare const DEFAULT_BASE_URL = "https://app.mandala.computer/api/v1";
3
5
  /** Anthropic's own key, forwarded for the one route that runs a model. */
4
6
  export declare const MODEL_KEY_HEADER = "X-Model-Key";
7
+ /**
8
+ * Proof, to the platform, that a request comes through the hosted MCP service
9
+ * (OPL-4982). The platform takes an OAuth access token only alongside it, so a
10
+ * token cannot be replayed at the API directly by the app it was issued to.
11
+ *
12
+ * Only this server's own value is ever sent. A header of this name arriving
13
+ * from anywhere else — a caller, or a per-call header set — is dropped in
14
+ * `#fetch`, so a client cannot supply the secret or learn anything by trying.
15
+ */
16
+ export declare const SERVICE_HEADER = "X-Mandala-MCP-Service";
5
17
  export type RequestOptions = {
6
18
  query?: Record<string, string | number | boolean | undefined>;
7
19
  body?: unknown;
@@ -114,10 +126,32 @@ export type SSEEvent = {
114
126
  * result goes into a model's context and from there into transcripts, and an
115
127
  * API key is every computer on the account, forever.
116
128
  */
129
+ /**
130
+ * What an embedding transport adds to every request one client makes.
131
+ *
132
+ * Both halves exist for the hosted install (OPL-4982), where this server stands
133
+ * between an OAuth client and the platform: the platform takes an access token
134
+ * only from a caller that also proves it is this service, and a refused token
135
+ * has to reach the MCP client as an HTTP 401 rather than as a tool error.
136
+ */
137
+ export type ApiOptions = {
138
+ /**
139
+ * Sent as {@link SERVICE_HEADER} with every request to the configured base
140
+ * URL, and nowhere else. Never logged and never put on an error, like the
141
+ * key itself.
142
+ */
143
+ serviceSecret?: string;
144
+ /**
145
+ * Called when the platform refuses THE BEARER: a 401 carrying a `Bearer`
146
+ * challenge. A 401 without one is a model provider refusing a model key,
147
+ * which says nothing about this client's credential, and is not reported.
148
+ */
149
+ onBearerRefused?: () => void;
150
+ };
117
151
  export declare class Api {
118
152
  #private;
119
153
  readonly baseUrl: string;
120
- constructor(apiKey: string, baseUrl?: string, signal?: AbortSignal);
154
+ constructor(apiKey: string, baseUrl?: string, signal?: AbortSignal, options?: ApiOptions);
121
155
  /**
122
156
  * This same client, with every request bound to one tool call's cancellation.
123
157
  *
@@ -182,6 +216,18 @@ export declare class Api {
182
216
  }>;
183
217
  /** For the two routes whose body is not JSON: the screenshot and the download. */
184
218
  bytes(method: string, path: string, opts?: RequestOptions, maxBytes?: number | ((contentType: string) => number)): Promise<Bytes>;
219
+ /**
220
+ * The account's secret store, `GET|POST secrets` and `GET|PUT|DELETE
221
+ * secrets/:id`, as five typed calls.
222
+ *
223
+ * Typed, and decoded strictly, because a value goes IN here and the caller
224
+ * must be able to rely on nothing coming back: every answer is reduced to the
225
+ * documented fields before it is returned, so no answer can hand a value on.
226
+ * A malformed answer is a {@link MandalaError}; for a change it says the
227
+ * change may have been made. Bound to this client, so
228
+ * `api.with(signal).secrets` carries the signal.
229
+ */
230
+ get secrets(): SecretStore;
185
231
  /**
186
232
  * The agent route, which answers with a stream of steps rather than a result.
187
233
  *
package/dist/api.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../src/api.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAmE,MAAM,QAAQ,CAAC;AAchG,eAAO,MAAM,gBAAgB,wCAAwC,CAAC;AAEtE,0EAA0E;AAC1E,eAAO,MAAM,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