@merginit/brandpeel 0.1.0 → 0.2.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.
package/README.md CHANGED
@@ -1,8 +1,33 @@
1
- # @merginit/brandpeel
2
-
3
- This package installs the native [`brandpeel`](https://brandpeel.app/developers)
4
- command for the current operating system and CPU architecture.
5
-
6
- ```sh
7
- npx @merginit/brandpeel --help
8
- ```
1
+ # @merginit/brandpeel
2
+
3
+ This package installs the native [`brandpeel`](https://brandpeel.app/developers)
4
+ command for the current operating system and CPU architecture.
5
+
6
+ ```sh
7
+ npx @merginit/brandpeel --help
8
+ ```
9
+
10
+ ## MCP
11
+
12
+ The native executable includes a stdio MCP server with four local export tools
13
+ and seven read-only API tools. Configure your MCP client with:
14
+
15
+ ```json
16
+ {
17
+ "mcpServers": {
18
+ "brandpeel": {
19
+ "command": "npx",
20
+ "args": ["-y", "@merginit/brandpeel", "mcp"]
21
+ }
22
+ }
23
+ }
24
+ ```
25
+
26
+ Requires an MCP client supporting the `2025-11-25` handshake-based protocol.
27
+ Local tools require absolute paths. Token exports and book compilation return
28
+ content by default; files are written only with an explicit `output`, and existing
29
+ files are replaced only with `force: true`. The server uses the caller's account
30
+ filesystem permissions and does not provide a filesystem sandbox. MCP mode does
31
+ not accept `--json`.
32
+
33
+ See the [repository documentation](https://github.com/merginit/unpeeled.cli#readme) for tool inputs, limits, and API configuration.
package/bin/brandpeel.js CHANGED
@@ -1,57 +1,57 @@
1
1
  #!/usr/bin/env node
2
-
3
- import { spawn } from "node:child_process";
4
- import { createRequire } from "node:module";
5
-
6
- const require = createRequire(import.meta.url);
7
- const supported = new Set([
8
- "darwin-arm64",
9
- "darwin-x64",
10
- "linux-arm64",
11
- "linux-x64",
12
- "win32-arm64",
13
- "win32-x64",
14
- ]);
15
- const platformKey = `${process.platform}-${process.arch}`;
16
-
17
- if (!supported.has(platformKey)) {
18
- console.error(
19
- `Brand Peel CLI does not provide a binary for ${process.platform}/${process.arch}.`,
20
- );
21
- process.exit(1);
22
- }
23
-
24
- const packageName = `@merginit/brandpeel-${platformKey}`;
25
- const extension = process.platform === "win32" ? ".exe" : "";
26
-
27
- let binaryPath;
28
- try {
29
- binaryPath = require.resolve(`${packageName}/bin/brandpeel${extension}`);
30
- } catch {
31
- console.error(`Could not find the optional native package ${packageName}.`);
32
- console.error("Reinstall @merginit/brandpeel without omitting optional dependencies.");
33
- process.exit(1);
34
- }
35
-
36
- const child = spawn(binaryPath, process.argv.slice(2), {
37
- stdio: "inherit",
38
- shell: false,
39
- windowsHide: true,
40
- });
41
-
42
- for (const signal of ["SIGINT", "SIGTERM"]) {
43
- process.on(signal, () => child.kill(signal));
44
- }
45
-
46
- child.on("error", (error) => {
47
- console.error(`Failed to start Brand Peel CLI: ${error.message}`);
48
- process.exit(1);
49
- });
50
-
51
- child.on("exit", (code, signal) => {
52
- if (signal) {
53
- process.kill(process.pid, signal);
54
- return;
55
- }
56
- process.exit(code ?? 1);
57
- });
2
+
3
+ import { spawn } from "node:child_process";
4
+ import { createRequire } from "node:module";
5
+
6
+ const require = createRequire(import.meta.url);
7
+ const supported = new Set([
8
+ "darwin-arm64",
9
+ "darwin-x64",
10
+ "linux-arm64",
11
+ "linux-x64",
12
+ "win32-arm64",
13
+ "win32-x64",
14
+ ]);
15
+ const platformKey = `${process.platform}-${process.arch}`;
16
+
17
+ if (!supported.has(platformKey)) {
18
+ console.error(
19
+ `Brand Peel CLI does not provide a binary for ${process.platform}/${process.arch}.`,
20
+ );
21
+ process.exit(1);
22
+ }
23
+
24
+ const packageName = `@merginit/brandpeel-${platformKey}`;
25
+ const extension = process.platform === "win32" ? ".exe" : "";
26
+
27
+ let binaryPath;
28
+ try {
29
+ binaryPath = require.resolve(`${packageName}/bin/brandpeel${extension}`);
30
+ } catch {
31
+ console.error(`Could not find the optional native package ${packageName}.`);
32
+ console.error("Reinstall @merginit/brandpeel without omitting optional dependencies.");
33
+ process.exit(1);
34
+ }
35
+
36
+ const child = spawn(binaryPath, process.argv.slice(2), {
37
+ stdio: "inherit",
38
+ shell: false,
39
+ windowsHide: true,
40
+ });
41
+
42
+ for (const signal of ["SIGINT", "SIGTERM"]) {
43
+ process.on(signal, () => child.kill(signal));
44
+ }
45
+
46
+ child.on("error", (error) => {
47
+ console.error(`Failed to start Brand Peel CLI: ${error.message}`);
48
+ process.exit(1);
49
+ });
50
+
51
+ child.on("exit", (code, signal) => {
52
+ if (signal) {
53
+ process.kill(process.pid, signal);
54
+ return;
55
+ }
56
+ process.exit(code ?? 1);
57
+ });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@merginit/brandpeel",
3
- "version": "0.1.0",
3
+ "version": "0.2.0",
4
4
  "description": "Official native CLI for Brand Peel exports and the public Brand Peel API",
5
5
  "type": "module",
6
6
  "bin": {
@@ -36,11 +36,11 @@
36
36
  "provenance": true
37
37
  },
38
38
  "optionalDependencies": {
39
- "@merginit/brandpeel-darwin-arm64": "0.1.0",
40
- "@merginit/brandpeel-darwin-x64": "0.1.0",
41
- "@merginit/brandpeel-linux-arm64": "0.1.0",
42
- "@merginit/brandpeel-linux-x64": "0.1.0",
43
- "@merginit/brandpeel-win32-arm64": "0.1.0",
44
- "@merginit/brandpeel-win32-x64": "0.1.0"
39
+ "@merginit/brandpeel-darwin-arm64": "0.2.0",
40
+ "@merginit/brandpeel-darwin-x64": "0.2.0",
41
+ "@merginit/brandpeel-linux-arm64": "0.2.0",
42
+ "@merginit/brandpeel-linux-x64": "0.2.0",
43
+ "@merginit/brandpeel-win32-arm64": "0.2.0",
44
+ "@merginit/brandpeel-win32-x64": "0.2.0"
45
45
  }
46
46
  }