@ziggs-ai/ziggs-mcp 0.1.7 → 0.1.9

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.
@@ -4,6 +4,7 @@ export interface OperatorKeyClaims {
4
4
  keyId?: string;
5
5
  ownerId?: string;
6
6
  boundAgentId?: string | null;
7
+ boundOrgId?: string | null;
7
8
  exp?: number;
8
9
  }
9
10
  declare const MINT_KEY_HELP: string;
@@ -15,6 +15,7 @@ export function decodeOperatorKeyClaims(token) {
15
15
  keyId: payload.keyId,
16
16
  ownerId: payload.ownerId,
17
17
  boundAgentId: payload.boundAgentId ?? null,
18
+ boundOrgId: payload.boundOrgId ?? null,
18
19
  exp: payload.exp,
19
20
  };
20
21
  }
package/dist/tools.js CHANGED
@@ -47,16 +47,20 @@ async function writeArtifactStrict(creds, input) {
47
47
  }
48
48
  }
49
49
  export function registerZiggsTools(server, creds, cfg) {
50
- server.tool('ziggs_connection_status', 'ZIG-503 — Verify MCP OAuth binding: delegate agent id, owner user id, and personal-org scope. Call after connect before inbox/chats.', {}, async () => {
50
+ server.tool('ziggs_connection_status', 'ZIG-503 — Verify MCP OAuth binding: delegate agent id, owner user id, and org scope. Call after connect before inbox/chats.', {}, async () => {
51
51
  const claims = decodeOperatorKeyClaims(creds.operatorKey);
52
+ const boundOrgId = claims?.boundOrgId?.trim() || null;
52
53
  return textResult({
53
54
  ok: true,
54
55
  agentId: creds.agentId,
55
56
  ownerId: claims?.ownerId ?? cfg.ZIGGS_OWNER_USER_ID ?? null,
56
57
  keyId: claims?.keyId ?? null,
57
58
  tokenType: claims?.type ?? 'operator',
58
- orgBinding: 'personal',
59
- orgBindingNote: 'MCP OAuth binds to your personal org today; team org picker is not available yet (ZIG-504).',
59
+ orgId: boundOrgId,
60
+ orgBinding: boundOrgId ? 'selected' : 'personal',
61
+ orgBindingNote: boundOrgId
62
+ ? 'MCP OAuth is bound to the organization you chose at consent (ZIG-504).'
63
+ : 'MCP OAuth binds to your personal org when no org was specified at consent.',
60
64
  apiBase: getBackendUrl(),
61
65
  docs: 'https://ziggsai.com/docs',
62
66
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ziggs-ai/ziggs-mcp",
3
- "version": "0.1.7",
3
+ "version": "0.1.9",
4
4
  "description": "MCP server for Claude Code, Cursor, and other MCP hosts — act as your Ziggs delegate agent",
5
5
  "type": "module",
6
6
  "bin": {
@@ -34,14 +34,20 @@
34
34
  },
35
35
  "dependencies": {
36
36
  "@modelcontextprotocol/sdk": "^1.29.0",
37
- "@ziggs-ai/api-client": "^0.1.9",
37
+ "@ziggs-ai/api-client": "^0.1.11",
38
38
  "dotenv": "^16.6.1",
39
39
  "zod": "^3.24.2"
40
40
  },
41
41
  "engines": {
42
42
  "node": ">=20"
43
43
  },
44
- "keywords": ["ziggs", "mcp", "claude", "cursor", "model-context-protocol"],
44
+ "keywords": [
45
+ "ziggs",
46
+ "mcp",
47
+ "claude",
48
+ "cursor",
49
+ "model-context-protocol"
50
+ ],
45
51
  "license": "MIT",
46
52
  "files": [
47
53
  "dist",