@cookiemunch/mcp 0.7.0 → 0.8.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/dist/bin.d.ts ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * stdio entry point for the Cookie Munch MCP server. Reads COOKIEMUNCH_API_KEY
4
+ * (required) and COOKIEMUNCH_BASE_URL (optional) from the environment, builds the
5
+ * server, and serves it over stdio — the transport Claude Desktop / Claude Code use
6
+ * to spawn local MCP servers.
7
+ */
8
+ export {};
package/dist/bin.js CHANGED
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  createCookieMunchMcp
4
- } from "./chunk-QCLUFJZ5.js";
4
+ } from "./chunk-E2YZUVQY.js";
5
5
 
6
6
  // src/bin.ts
7
7
  import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
@@ -551,8 +551,10 @@ function registerPlatformTools(tool, client) {
551
551
  revokeAtlasIdGrant: z2.boolean().optional().describe("A preset param, when the preset's params list it: default false. True adds an optional step that revokes the person's app grant on erasure; a credential without the scope reports skipped: insufficient_scope."),
552
552
  label: z2.string().optional().describe("Your name for the credential, shown beside keyPrefix."),
553
553
  system: z2.string().optional().describe("The name this connection answers to in a plan, e.g. identity or crm. Required unless the preset has a default."),
554
- baseUrl: z2.string().optional().describe("The system's public https origin. Required unless the preset sets it."),
555
- secretKey: z2.string().describe("Its API key, with whatever scope that system needs to export and erase a user."),
554
+ baseUrl: z2.string().optional().describe("The system's public https origin, or a base with a path (cm-standard-v1 v4 on: the path replaces /api/privacy; cm-standard-v2: the contract paths hang off it). Required unless the preset sets it."),
555
+ secretKey: z2.string().optional().describe("Its API key, with whatever scope that system needs to export and erase a user. Send this or mintFrom."),
556
+ mintFrom: z2.string().optional().describe("In place of secretKey: a partner id (one that registered an executorKeyUrl, e.g. chatly, forumulate, referalli) that mints the key for the site under its partner link. The connection is scoped to that site. With dryRun, the answer's mint says who would mint it; nothing is minted."),
557
+ externalId: z2.string().optional().describe("With mintFrom: the partner account the key is minted for. Default: the one the site's live link for that partner names."),
556
558
  webhookSecret: z2.string().optional().describe("Signing secret of its webhook endpoint. Optional: polling closes tasks without it."),
557
559
  auto: z2.boolean().optional().describe("Open a sub-task automatically when a request reaches fulfilment. Default true."),
558
560
  orchestrator: z2.union([z2.literal(1), z2.literal(2)]).optional().describe("How it takes part in cases. Default 2 (v2 headers on every call); 1 is the v1 adapter. The answer carries a completionSecret, shown once, that signs its completions."),
@@ -799,7 +801,7 @@ function registerIntegrationTools(tool, client) {
799
801
  );
800
802
  tool(
801
803
  "get_embed_manifest",
802
- "A site\u2019s embed manifest (the tenant variant of /.well-known/forgedeck-embed.json): every origin the Cookie Munch embed touches on that site, by CSP directive (non-origin sources such as 'unsafe-inline' under requires), every cookie and browser-storage key it writes with category and lifetime, the checkers\u2019 User-Agent, and the hosts of the site\u2019s rights page and preference centre. Use it to build a Content-Security-Policy. Read-only.",
804
+ "A site\u2019s embed manifest (the tenant variant of /.well-known/cookiemunch-embed.json): every origin the Cookie Munch embed touches on that site, by CSP directive (non-origin sources such as 'unsafe-inline' under requires), every cookie and browser-storage key it writes with category and lifetime, the checkers\u2019 User-Agent, and the hosts of the site\u2019s rights page and preference centre. Use it to build a Content-Security-Policy. Read-only.",
803
805
  { cbid: z3.string() },
804
806
  (a) => client.embedManifest(a.cbid)
805
807
  );
@@ -921,12 +923,12 @@ function registerKeyAndTagTools(tool, client) {
921
923
  const tagsSchema = z4.object({
922
924
  type: z4.enum(TAGGED),
923
925
  id: z4.string(),
924
- metadata: z4.record(z4.union([z4.string(), z4.number(), z4.boolean(), z4.null()])).describe("Keys to set; null removes one. forgedeck_sandbox cannot be set here."),
926
+ metadata: z4.record(z4.union([z4.string(), z4.number(), z4.boolean(), z4.null()])).describe("Keys to set; null removes one. stack_sandbox cannot be set here."),
925
927
  dryRun: z4.boolean().optional().describe("Answer with the diff, storing nothing. Do this first.")
926
928
  });
927
929
  tool(
928
930
  "update_resource_tags",
929
- "Change a resource\u2019s tags (merge). For adopting resources created before tags existed, e.g. forgedeck_product and forgedeck_env. A resource can never be made a sandbox after it was created.",
931
+ "Change a resource\u2019s tags (merge). For adopting resources created before tags existed, e.g. stack_product and stack_env. A resource can never be made a sandbox after it was created.",
930
932
  tagsSchema.shape,
931
933
  (a) => {
932
934
  const { type, id, metadata, dryRun } = tagsSchema.parse(a);
@@ -961,7 +963,7 @@ function registerKeyAndTagTools(tool, client) {
961
963
  );
962
964
  tool(
963
965
  "get_provision_env",
964
- "What `forgedeck env` writes for a product provisioned with this forgedeck ref: variable names, non-secret values (cbid, script URL, API base) and references for secrets, never a secret. Read-only.",
966
+ "What `env` writes for a product provisioned with this stack ref: variable names, non-secret values (cbid, script URL, API base) and references for secrets, never a secret. Read-only.",
965
967
  { ref: z4.string() },
966
968
  (a) => client.provisionEnv(a.ref)
967
969
  );
@@ -1407,13 +1409,13 @@ ${JSON.stringify(r, null, 2)}` : r;
1407
1409
  type: z6.string().describe("access | deletion | closure | restriction | rectification, or erasure / erase / export."),
1408
1410
  emails: z6.array(z6.string()).optional().describe("The person's addresses."),
1409
1411
  identity: z6.object({ iss: z6.string(), sub: z6.string(), ext: z6.string().optional(), principal: z6.string().optional() }).optional().describe("A signed-in identity from the site's sign-in issuer. People are never linked on email when it is present."),
1410
- source: z6.enum(["product", "atlas", "admin"]).optional(),
1412
+ source: z6.enum(["product", "identity", "admin"]).optional().describe("identity: the site's sign-in provider, whichever it is."),
1411
1413
  reason: z6.string().optional(),
1412
1414
  skipSystems: z6.array(z6.string()).optional().describe("System names, connection ids, or self."),
1413
1415
  fulfill: z6.boolean().optional(),
1414
1416
  test: z6.boolean().optional(),
1415
1417
  idempotencyKey: z6.string().optional(),
1416
- trace: z6.string().optional().describe("An X-ForgeDeck-Trace to keep, from the caller.")
1418
+ trace: z6.string().optional().describe("An X-Trace-Id to keep, from the caller.")
1417
1419
  },
1418
1420
  (a) => client.dsar.openCase(
1419
1421
  {
@@ -1452,7 +1454,7 @@ ${JSON.stringify(r, null, 2)}` : r;
1452
1454
  );
1453
1455
  tool(
1454
1456
  "find_dsar_by_trace",
1455
- "The rights request carrying one X-ForgeDeck-Trace id \u2014 to follow one event across products. Read-only.",
1457
+ "The rights request carrying one X-Trace-Id id \u2014 to follow one event across products. Read-only.",
1456
1458
  { trace: z6.string() },
1457
1459
  (a) => client.dsar.listByTrace(a.trace)
1458
1460
  );
@@ -1482,6 +1484,22 @@ ${JSON.stringify(r, null, 2)}` : r;
1482
1484
  typeof a.iss === "string" && typeof a.sub === "string" ? { iss: a.iss, sub: a.sub } : { email: String(a.email ?? "") }
1483
1485
  )
1484
1486
  );
1487
+ tool(
1488
+ "connect_identity_provider",
1489
+ "Connect an identity provider's privacy orchestrator in one call, so it opens a rights case here when a person deletes their account there. Mints a key holding only dsar:write, locked to the site (no keys:write needed), and hands it to the provider, authorised with the provider instance key. The minted key is never returned, only its prefix; connecting again replaces it. Built in: atlas. Any other provider: pass connector. Run with dryRun first: it mints and sends nothing.",
1490
+ {
1491
+ provider: z6.string().describe("The provider id, e.g. atlas."),
1492
+ cbid: z6.string().describe("The site the provider opens cases on."),
1493
+ providerKey: z6.string().describe("The provider instance's secret key (Atlas: the instance secret key). Used for this one call, never stored."),
1494
+ connector: z6.object({ url: z6.string(), method: z6.enum(["PUT", "POST"]).optional(), body: z6.record(z6.unknown()) }).optional().describe('Only for a provider with no built-in connector: its https orchestrator URL and JSON body; a body value "{apiKey}" becomes the minted key.'),
1495
+ dryRun: z6.boolean().optional().describe("Show the key and the request that would be made, minting and sending nothing.")
1496
+ },
1497
+ (a) => client.integrations.connect(
1498
+ a.provider,
1499
+ { cbid: a.cbid, providerKey: a.providerKey, ...a.connector ? { connector: a.connector } : {} },
1500
+ { dryRun: a.dryRun === true }
1501
+ )
1502
+ );
1485
1503
  tool(
1486
1504
  "advance_dsar",
1487
1505
  "Advance a DSAR to a new status (received \u2192 verifying \u2192 in_progress \u2192 completed, or rejected).",
@@ -1869,7 +1887,7 @@ ${JSON.stringify(r, null, 2)}` : r;
1869
1887
  (a) => client.sites.applyImport(a.cbid, a.data, a.overwrite ? { overwrite: true } : void 0)
1870
1888
  );
1871
1889
  const declarationShape = {
1872
- category: z6.string().describe("necessary, preferences, statistics, marketing, or one of the site\u2019s categories.custom ids."),
1890
+ category: z6.string().describe("necessary, preferences, statistics, marketing, or one of the site\u2019s categories.suite or categories.custom ids."),
1873
1891
  purpose: z6.string().describe("What the cookie does, as visitors will read it \u2014 and the fallback for any language purposes lacks."),
1874
1892
  purposes: z6.record(z6.string(), z6.string().max(1e3)).nullable().optional().describe('The purpose in other languages, keyed by BCP-47 tag: {"es": "\u2026", "pt-BR": "\u2026"}. The banner, data-cc="declaration" and cookie-declaration.js draw the visitor\u2019s language. null clears.'),
1875
1893
  provider: z6.string().optional(),
@@ -1962,7 +1980,7 @@ ${JSON.stringify(r, null, 2)}` : r;
1962
1980
  );
1963
1981
  tool(
1964
1982
  "import_cookie_manifest",
1965
- 'Declare ANY vendor\u2019s cookies and browser storage from its embed manifest (/.well-known/forgedeck-embed.json): give its https URL (re-read hourly afterwards) or the manifest document. The vendor id is the manifest\u2019s product; rows are marked source "manifest". An invalid manifest is refused with each broken rule named. Use dryRun first; remove it with remove_cookie_preset and the product id.',
1983
+ 'Declare ANY vendor\u2019s cookies and browser storage from its embed manifest (/.well-known/<product>-embed.json): give its https URL (re-read hourly afterwards) or the manifest document. The vendor id is the manifest\u2019s product; rows are marked source "manifest". An invalid manifest is refused with each broken rule named. Use dryRun first; remove it with remove_cookie_preset and the product id.',
1966
1984
  {
1967
1985
  cbid: z6.string(),
1968
1986
  url: z6.string().optional().describe("An https:// embed manifest URL."),
@@ -2419,7 +2437,7 @@ ${JSON.stringify(r, null, 2)}` : r;
2419
2437
  }
2420
2438
 
2421
2439
  // src/index.ts
2422
- var MCP_VERSION = "0.7.0";
2440
+ var MCP_VERSION = "0.8.0";
2423
2441
  function createCookieMunchMcp(opts) {
2424
2442
  const client = opts.client ?? createCookieMunch({ apiKey: opts.apiKey, baseUrl: opts.baseUrl, userAgent: opts.userAgent ?? `cookiemunch-mcp/${MCP_VERSION}` });
2425
2443
  const server = new McpServer({ name: "cookiemunch", version: "1.0.0" });
@@ -2432,4 +2450,4 @@ export {
2432
2450
  MCP_VERSION,
2433
2451
  createCookieMunchMcp
2434
2452
  };
2435
- //# sourceMappingURL=chunk-QCLUFJZ5.js.map
2453
+ //# sourceMappingURL=chunk-E2YZUVQY.js.map