@hardfin/cli 0.1.1-dev.54 → 0.1.1-dev.55
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/README.md +35 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -411,7 +411,8 @@ projects come ready. Running it again updates only what it wrote.
|
|
|
411
411
|
| `.vscode/mcp.json` | The `hardfin` server, for VS Code |
|
|
412
412
|
|
|
413
413
|
The server is the hosted one at the authorization server's host, `https://api.hardfin.com/mcp`
|
|
414
|
-
by default.
|
|
414
|
+
by default. [Serving an agent](#serving-an-agent) says how it differs from the local server
|
|
415
|
+
this CLI runs. Every other server in an MCP config, and everything in `AGENTS.md` outside the
|
|
415
416
|
markers, is left as it was. A config that does not hold JSON is skipped, never overwritten.
|
|
416
417
|
|
|
417
418
|
`init` refuses an address that `config.local.json` or `.env` in the folder chose, because the
|
|
@@ -423,17 +424,46 @@ package, so `init` writes the copy that matches the installed CLI.
|
|
|
423
424
|
|
|
424
425
|
## Serving an agent
|
|
425
426
|
|
|
427
|
+
Hardfin has two MCP servers, and an agent needs only one of them. Hardfin hosts one. The
|
|
428
|
+
other is this CLI, run on your machine. Read this section to choose between them.
|
|
429
|
+
|
|
430
|
+
| | The hosted server | The local server |
|
|
431
|
+
| --------------------- | -------------------------------------------------------------------- | ------------------------------------------------------ |
|
|
432
|
+
| Runs | At Hardfin, at `https://api.hardfin.com/mcp` | On your machine, started by the agent's client |
|
|
433
|
+
| Needs installed | Nothing | This CLI, and Node 20.12 or later |
|
|
434
|
+
| Set up by | `hardfin init` | `claude mcp add hardfin -- hardfin mcp` |
|
|
435
|
+
| Signs in as | Whoever signs in to Hardfin from the client | Whoever ran `hardfin login` here, or `HARDFIN_API_KEY` |
|
|
436
|
+
| Tools | `hardfin_read`, `hardfin_create`, `hardfin_update`, `hardfin_delete` | `hardfin_read`, `hardfin_write`, `hardfin_delete` |
|
|
437
|
+
| A call names | An operation from the API reference, with its parameters and body | A command, as the words typed after `hardfin` |
|
|
438
|
+
| Read-only when | The sign in was not granted `hardfin:write` | The same, or it was started with `--read-only` |
|
|
439
|
+
| Files on your machine | Out of reach | Uploaded and downloaded, inside the folder it runs in |
|
|
440
|
+
|
|
441
|
+
Choose the hosted server unless one of these holds.
|
|
442
|
+
|
|
443
|
+
- The agent has to upload a file from your machine, or download one to it
|
|
444
|
+
- The agent runs where your browser cannot sign in to Hardfin, and you have a stored sign in or an API key on the machine
|
|
445
|
+
- You want a local build of the API, which `hardfin mcp` reaches through `config.local.json`
|
|
446
|
+
|
|
447
|
+
The two servers place one command differently. Scrapping an asset goes through
|
|
448
|
+
`hardfin_delete` on the local server and through `hardfin_update` on the hosted one. Both ask
|
|
449
|
+
before it by default, because both tools carry the destructive hint.
|
|
450
|
+
|
|
451
|
+
Both set-ups name the server `hardfin`, so adding one to a project replaces the other. To run
|
|
452
|
+
both, give the local one another name:
|
|
453
|
+
|
|
426
454
|
```sh
|
|
427
|
-
hardfin mcp
|
|
455
|
+
claude mcp add hardfin-local -- hardfin mcp
|
|
428
456
|
```
|
|
429
457
|
|
|
430
|
-
|
|
431
|
-
other client can run Hardfin commands.
|
|
458
|
+
The rest of this section is about the local server.
|
|
432
459
|
|
|
433
460
|
```sh
|
|
434
|
-
|
|
461
|
+
hardfin mcp
|
|
435
462
|
```
|
|
436
463
|
|
|
464
|
+
It speaks the Model Context Protocol on standard input and output, so Claude, Codex or any
|
|
465
|
+
other client can run Hardfin commands.
|
|
466
|
+
|
|
437
467
|
### Three tools, and resources for the rest
|
|
438
468
|
|
|
439
469
|
Every tool a server lists sits in the agent's context for the entire session, so this server
|