@forgemeshlabs/anomaly-mcp 0.1.1 → 0.3.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,17 +1,15 @@
1
1
  # Anomaly Tracker MCP
2
2
 
3
- Blockchain event sequence anomaly detection for MCP clients and x402-powered agents.
3
+ Blockchain event sequence anomaly detection for AI agents. Detects unusual financial event patterns across Ethereum, Base, and Arbitrum using NASA-derived sequence mining. Returns a story label and anomaly score, not just a number.
4
4
 
5
- This MCP server gives AI agents access to the ForgeMesh Anomaly Tracker API, which detects unusual financial event sequences before they look obvious on a chart. Powered by NASA-derived sequence mining methods. Returns a human-readable story label and anomaly score (0-100), not just a number.
5
+ This MCP server gives AI agents access to the ForgeMesh Anomaly Tracker API via 5 tools chain-wide anomaly scanning, single-token analysis, whale alerts, model health, and API status.
6
6
 
7
- This package is a thin client around the hosted API:
8
-
9
- `https://anomaly.forgemesh.io`
10
-
11
- Architecture:
7
+ Thin client architecture:
12
8
 
13
9
  `Agent/MCP client -> this MCP server -> ForgeMesh Anomaly Tracker API`
14
10
 
11
+ Hosted API: `https://anomaly.forgemesh.io`
12
+
15
13
  ## Install
16
14
 
17
15
  ```bash
@@ -44,36 +42,49 @@ npx -y @forgemeshlabs/anomaly-mcp
44
42
 
45
43
  | Tool | Description | Cost |
46
44
  | --- | --- | --- |
47
- | `get_api_status` | API health check | Free |
48
- | `get_discovery_metadata` | Fetch llms.txt, openapi.json, or x402.json | Free |
49
- | `inspect_x402_challenge` | Inspect x402 payment challenge without settling | Free |
50
- | `detect_sequence_anomaly` | Score a blockchain event window for sequence anomalies | $0.05 USDC |
51
- | `get_model_status` | SequenceMiner model health and training stats per chain | $0.01 USDC |
45
+ | `health_check` | API health and uptime | Free |
46
+ | `anomaly_scan` | Chain-wide sequence anomaly scan scores event windows for unusual patterns | $0.05 USDC |
47
+ | `token_scan` | Single-token anomaly scan scores transfer patterns for one token | $0.03 USDC |
48
+ | `whale_alerts` | Recent whale movements, CEX flows, bridge activity, stablecoin mints/burns | $0.02 USDC |
49
+ | `model_status` | SequenceMiner model health and training stats per chain | $0.01 USDC |
50
+
51
+ ### anomaly_scan
52
+
53
+ Scan a blockchain for sequence anomalies across all monitored addresses.
54
+
55
+ - **chain**: `ethereum`, `base`, or `arbitrum` (default: ethereum)
56
+ - **window**: `1h`, `4h`, `24h`, or `168h` (default: 24h)
57
+
58
+ Returns: `sequence_score` (0-100), `story` (human label), `novelty`, `peak_window`, `possible_failure_modes`
59
+
60
+ ### token_scan
61
+
62
+ Anomaly scan for a single token's recent transfer patterns.
63
+
64
+ - **token** (required): Contract address (`0x...`) or symbol — `usdt`, `usdc`, `weth`, `wbtc`, `link`, `uni`, `aave`, `steth`, `pepe`, `dai`, `cbeth`, `arb`
65
+ - **chain**: `ethereum`, `base`, or `arbitrum` (default: ethereum)
66
+ - **window**: `1h`, `4h`, `24h`, or `168h` (default: 24h)
67
+
68
+ Returns: `sequence_score`, `story`, `novelty`, `peak_window`, `transfers` (recent transfer events with source/direction)
52
69
 
53
- ## Anomaly Detection
70
+ ### whale_alerts
54
71
 
55
- The `detect_sequence_anomaly` tool accepts:
72
+ Recent whale movements from 12+ monitored addresses: Binance, Coinbase, Kraken, OKX, Bybit, Arbitrum/Optimism/Polygon bridges, Tether Treasury, Circle.
56
73
 
57
- - **domain**: Event domain (`financial` is currently live)
58
- - **chain**: `ethereum`, `base`, or `arbitrum`
59
- - **window**: Lookback period: `1h`, `4h`, `24h`, or `168h`
74
+ - **chain**: `ethereum`, `base`, or `arbitrum` (default: ethereum)
75
+ - **hours**: 1-168 (default: 4)
60
76
 
61
- Returns:
62
- - **sequence_score**: 0 (normal) to 100 (highly anomalous)
63
- - **story**: Human-readable label like "Supply Expansion", "Exchange Drain", "Normal Activity"
64
- - **novelty**: `low`, `medium`, `high`, or `extreme`
65
- - **peak_window**: The most anomalous symbol sequence found
66
- - **possible_failure_modes**: What could go wrong if this pattern continues
77
+ Returns: `alerts` array with `symbol`, `source`, `amount_eth`/`amount_usd`, `timestamp`
67
78
 
68
79
  ## Symbol Alphabet
69
80
 
70
- The financial domain tracks 16 event types across whale wallets, exchanges, bridges, and stablecoin issuers:
81
+ The financial domain tracks 16 event types:
71
82
 
72
83
  `WHALE_BUY`, `WHALE_SELL`, `CEX_INFLOW`, `CEX_OUTFLOW`, `BRIDGE_IN`, `BRIDGE_OUT`, `DEX_SWAP`, `DEX_LIQUIDITY_ADD`, `DEX_LIQUIDITY_REMOVE`, `STABLECOIN_MINT`, `STABLECOIN_REDEEM`, `STABLECOIN_BURN`, `TOKEN_MINT`, `TOKEN_BURN`, `FUNDING_SPIKE`, `LIQUIDATION`
73
84
 
74
85
  ## Payment
75
86
 
76
- Paid endpoints use x402 protocol. Agents pay per call in USDC on Base mainnet. No API key needed.
87
+ Paid tools use x402 protocol. Agents pay per call in USDC on Base mainnet. No API key needed.
77
88
 
78
89
  By default, paid endpoints return x402 challenge metadata (pricing, network, wallet) without settling. To settle payments, configure a wallet private key in your agent's x402 client.
79
90
 
package/dist/index.js CHANGED
@@ -5,7 +5,7 @@ import { CallToolRequestSchema, ListToolsRequestSchema } from "@modelcontextprot
5
5
  import { callTool, tools } from "./tools.js";
6
6
  const server = new Server({
7
7
  name: "anomaly-mcp",
8
- version: "0.1.1"
8
+ version: "0.2.0"
9
9
  }, {
10
10
  capabilities: {
11
11
  tools: {}
package/dist/tools.d.ts CHANGED
@@ -4,11 +4,15 @@ export declare const tools: ({
4
4
  inputSchema: {
5
5
  type: "object";
6
6
  properties: {
7
- file?: undefined;
8
- endpoint?: undefined;
9
- domain?: undefined;
10
7
  chain?: undefined;
11
8
  window?: undefined;
9
+ token?: undefined;
10
+ hours?: undefined;
11
+ address?: undefined;
12
+ protocol?: undefined;
13
+ region?: undefined;
14
+ days?: undefined;
15
+ repo?: undefined;
12
16
  };
13
17
  required?: undefined;
14
18
  };
@@ -18,15 +22,52 @@ export declare const tools: ({
18
22
  inputSchema: {
19
23
  type: "object";
20
24
  properties: {
21
- file: {
25
+ chain: {
22
26
  type: string;
23
27
  enum: string[];
24
28
  description: string;
25
29
  };
26
- endpoint?: undefined;
27
- domain?: undefined;
28
- chain?: undefined;
29
- window?: undefined;
30
+ window: {
31
+ type: string;
32
+ enum: string[];
33
+ description: string;
34
+ };
35
+ token?: undefined;
36
+ hours?: undefined;
37
+ address?: undefined;
38
+ protocol?: undefined;
39
+ region?: undefined;
40
+ days?: undefined;
41
+ repo?: undefined;
42
+ };
43
+ required?: undefined;
44
+ };
45
+ } | {
46
+ name: string;
47
+ description: string;
48
+ inputSchema: {
49
+ type: "object";
50
+ properties: {
51
+ token: {
52
+ type: string;
53
+ description: string;
54
+ };
55
+ chain: {
56
+ type: string;
57
+ enum: string[];
58
+ description: string;
59
+ };
60
+ window: {
61
+ type: string;
62
+ enum: string[];
63
+ description: string;
64
+ };
65
+ hours?: undefined;
66
+ address?: undefined;
67
+ protocol?: undefined;
68
+ region?: undefined;
69
+ days?: undefined;
70
+ repo?: undefined;
30
71
  };
31
72
  required: string[];
32
73
  };
@@ -36,17 +77,24 @@ export declare const tools: ({
36
77
  inputSchema: {
37
78
  type: "object";
38
79
  properties: {
39
- endpoint: {
80
+ chain: {
40
81
  type: string;
41
82
  enum: string[];
42
83
  description: string;
43
84
  };
44
- file?: undefined;
45
- domain?: undefined;
46
- chain?: undefined;
85
+ hours: {
86
+ type: string;
87
+ description: string;
88
+ };
47
89
  window?: undefined;
90
+ token?: undefined;
91
+ address?: undefined;
92
+ protocol?: undefined;
93
+ region?: undefined;
94
+ days?: undefined;
95
+ repo?: undefined;
48
96
  };
49
- required: string[];
97
+ required?: undefined;
50
98
  };
51
99
  } | {
52
100
  name: string;
@@ -54,11 +102,39 @@ export declare const tools: ({
54
102
  inputSchema: {
55
103
  type: "object";
56
104
  properties: {
57
- domain: {
105
+ address: {
106
+ type: string;
107
+ description: string;
108
+ };
109
+ chain: {
110
+ type: string;
111
+ enum: string[];
112
+ description: string;
113
+ };
114
+ window: {
58
115
  type: string;
59
116
  enum: string[];
60
117
  description: string;
61
118
  };
119
+ token?: undefined;
120
+ hours?: undefined;
121
+ protocol?: undefined;
122
+ region?: undefined;
123
+ days?: undefined;
124
+ repo?: undefined;
125
+ };
126
+ required: string[];
127
+ };
128
+ } | {
129
+ name: string;
130
+ description: string;
131
+ inputSchema: {
132
+ type: "object";
133
+ properties: {
134
+ protocol: {
135
+ type: string;
136
+ description: string;
137
+ };
62
138
  chain: {
63
139
  type: string;
64
140
  enum: string[];
@@ -69,10 +145,79 @@ export declare const tools: ({
69
145
  enum: string[];
70
146
  description: string;
71
147
  };
72
- file?: undefined;
73
- endpoint?: undefined;
148
+ token?: undefined;
149
+ hours?: undefined;
150
+ address?: undefined;
151
+ region?: undefined;
152
+ days?: undefined;
153
+ repo?: undefined;
154
+ };
155
+ required: string[];
156
+ };
157
+ } | {
158
+ name: string;
159
+ description: string;
160
+ inputSchema: {
161
+ type: "object";
162
+ properties: {
163
+ region: {
164
+ type: string;
165
+ enum: string[];
166
+ description: string;
167
+ };
168
+ chain?: undefined;
169
+ window?: undefined;
170
+ token?: undefined;
171
+ hours?: undefined;
172
+ address?: undefined;
173
+ protocol?: undefined;
174
+ days?: undefined;
175
+ repo?: undefined;
74
176
  };
75
177
  required?: undefined;
76
178
  };
179
+ } | {
180
+ name: string;
181
+ description: string;
182
+ inputSchema: {
183
+ type: "object";
184
+ properties: {
185
+ days: {
186
+ type: string;
187
+ enum: string[];
188
+ description: string;
189
+ };
190
+ chain?: undefined;
191
+ window?: undefined;
192
+ token?: undefined;
193
+ hours?: undefined;
194
+ address?: undefined;
195
+ protocol?: undefined;
196
+ region?: undefined;
197
+ repo?: undefined;
198
+ };
199
+ required?: undefined;
200
+ };
201
+ } | {
202
+ name: string;
203
+ description: string;
204
+ inputSchema: {
205
+ type: "object";
206
+ properties: {
207
+ repo: {
208
+ type: string;
209
+ description: string;
210
+ };
211
+ chain?: undefined;
212
+ window?: undefined;
213
+ token?: undefined;
214
+ hours?: undefined;
215
+ address?: undefined;
216
+ protocol?: undefined;
217
+ region?: undefined;
218
+ days?: undefined;
219
+ };
220
+ required: string[];
221
+ };
77
222
  })[];
78
223
  export declare function callTool(name: string, args: Record<string, unknown>): Promise<unknown>;
package/dist/tools.js CHANGED
@@ -1,71 +1,203 @@
1
1
  const API_BASE = process.env.ANOMALY_API_BASE || "https://anomaly.forgemesh.io";
2
2
  export const tools = [
3
3
  {
4
- name: "get_api_status",
5
- description: "Check ForgeMesh Anomaly Tracker API health.",
4
+ name: "health_check",
5
+ description: "Check ForgeMesh Anomaly Tracker API health and uptime.",
6
6
  inputSchema: { type: "object", properties: {} }
7
7
  },
8
8
  {
9
- name: "get_discovery_metadata",
10
- description: "Fetch agent discovery files: llms.txt, openapi.json, or .well-known/x402.json.",
9
+ name: "anomaly_scan",
10
+ description: "Scan a blockchain for sequence anomalies — unusual patterns of whale movements, exchange flows, bridge activity, and stablecoin mints/burns. Returns a story label, anomaly score (0-100), novelty level, and the peak anomalous symbol window. Costs $0.05 USDC on Base mainnet.",
11
11
  inputSchema: {
12
12
  type: "object",
13
13
  properties: {
14
- file: {
14
+ chain: {
15
+ type: "string",
16
+ enum: ["ethereum", "base", "arbitrum"],
17
+ description: "Blockchain to analyze (default: ethereum)"
18
+ },
19
+ window: {
15
20
  type: "string",
16
- enum: ["llms.txt", "openapi.json", "x402.json"],
17
- description: "Which discovery file to fetch"
21
+ enum: ["1h", "4h", "24h", "168h"],
22
+ description: "Lookback window (default: 24h)"
23
+ }
24
+ }
25
+ }
26
+ },
27
+ {
28
+ name: "token_scan",
29
+ description: "Anomaly scan for a single token — scores recent transfer patterns for unusual activity (large CEX flows, whale accumulation, token mints/burns). Pass a contract address or well-known symbol. Costs $0.03 USDC on Base mainnet.",
30
+ inputSchema: {
31
+ type: "object",
32
+ properties: {
33
+ token: {
34
+ type: "string",
35
+ description: "Token contract address (0x...) or symbol: usdt, usdc, weth, wbtc, link, uni, aave, steth, pepe, dai, cbeth, arb"
36
+ },
37
+ chain: {
38
+ type: "string",
39
+ enum: ["ethereum", "base", "arbitrum"],
40
+ description: "Blockchain to analyze (default: ethereum)"
41
+ },
42
+ window: {
43
+ type: "string",
44
+ enum: ["1h", "4h", "24h", "168h"],
45
+ description: "Lookback window (default: 24h)"
18
46
  }
19
47
  },
20
- required: ["file"]
48
+ required: ["token"]
49
+ }
50
+ },
51
+ {
52
+ name: "whale_alerts",
53
+ description: "Get recent whale movements, CEX inflows/outflows, bridge activity, and stablecoin mints/burns from monitored addresses (Binance, Coinbase, Kraken, OKX, Bybit, major bridges, Tether, Circle). Costs $0.02 USDC on Base mainnet.",
54
+ inputSchema: {
55
+ type: "object",
56
+ properties: {
57
+ chain: {
58
+ type: "string",
59
+ enum: ["ethereum", "base", "arbitrum"],
60
+ description: "Blockchain to monitor (default: ethereum)"
61
+ },
62
+ hours: {
63
+ type: "integer",
64
+ description: "Lookback window in hours, 1-168 (default: 4)"
65
+ }
66
+ }
21
67
  }
22
68
  },
23
69
  {
24
- name: "inspect_x402_challenge",
25
- description: "Inspect the x402 payment challenge for a paid endpoint without settling. Returns pricing, network, wallet, and Bazaar metadata.",
70
+ name: "address_scan",
71
+ description: "Scan any wallet address for anomalous transaction patterns. Classifies each transaction by checking counterparties against known CEX wallets, bridges, and stablecoin issuers. Costs $0.03 USDC on Base mainnet.",
26
72
  inputSchema: {
27
73
  type: "object",
28
74
  properties: {
29
- endpoint: {
75
+ address: {
30
76
  type: "string",
31
- enum: ["sequence-anomaly", "status"],
32
- description: "Which paid endpoint to inspect"
77
+ description: "Wallet address to scan (0x...)"
78
+ },
79
+ chain: {
80
+ type: "string",
81
+ enum: ["ethereum", "base", "arbitrum"],
82
+ description: "Blockchain to scan (default: ethereum)"
83
+ },
84
+ window: {
85
+ type: "string",
86
+ enum: ["1h", "4h", "24h", "168h"],
87
+ description: "Lookback window (default: 24h)"
33
88
  }
34
89
  },
35
- required: ["endpoint"]
90
+ required: ["address"]
91
+ }
92
+ },
93
+ {
94
+ name: "model_status",
95
+ description: "Get SequenceMiner model health and training stats per chain — training sequence count and last retrain time. Costs $0.01 USDC on Base mainnet.",
96
+ inputSchema: {
97
+ type: "object",
98
+ properties: {}
36
99
  }
37
100
  },
101
+ // ── NFT & DeFi ────────────────────────────────────────────────────────────
38
102
  {
39
- name: "detect_sequence_anomaly",
40
- description: "Score a blockchain event window for sequence anomalies. Returns a story label, anomaly score (0-100), novelty level, and the peak anomalous symbol window. Costs $0.05 USDC on Base mainnet.",
103
+ name: "nft_scan",
104
+ description: "Anomaly scan for an NFT collection detects sweep accumulation, wash trading patterns, and mint surges before they're obvious. Pass a contract address. Returns a story label (e.g. 'Sweep Accumulation', 'Wash Trading Detected') and anomaly score. Costs $0.03 USDC on Base mainnet.",
41
105
  inputSchema: {
42
106
  type: "object",
43
107
  properties: {
44
- domain: {
108
+ token: {
45
109
  type: "string",
46
- enum: ["financial"],
47
- description: "Event domain. Currently only 'financial' is live."
110
+ description: "NFT contract address (ERC-721 or ERC-1155), e.g. 0xbc4ca0eda7647a8ab7c2061c2e118a18a936f13d"
48
111
  },
49
112
  chain: {
50
113
  type: "string",
51
114
  enum: ["ethereum", "base", "arbitrum"],
52
- description: "Blockchain to analyze (default: ethereum)"
115
+ description: "Blockchain (default: ethereum)"
53
116
  },
54
117
  window: {
55
118
  type: "string",
56
119
  enum: ["1h", "4h", "24h", "168h"],
57
120
  description: "Lookback window (default: 24h)"
58
121
  }
59
- }
122
+ },
123
+ required: ["token"]
60
124
  }
61
125
  },
62
126
  {
63
- name: "get_model_status",
64
- description: "Get SequenceMiner model health and training stats per chain. Costs $0.01 USDC on Base mainnet.",
127
+ name: "defi_scan",
128
+ description: "Anomaly scan for a DeFi protocol — detects unusual flows through major lending and DEX contracts (Uniswap, Aave, Curve, Compound). Pass a protocol name or contract address. Returns a story label and anomaly score. Costs $0.03 USDC on Base mainnet.",
129
+ inputSchema: {
130
+ type: "object",
131
+ properties: {
132
+ protocol: {
133
+ type: "string",
134
+ description: "Protocol name (uniswap_v3, uniswap_v3_r2, aave_v3, aave_v2, curve_3pool, compound_v3) or a 0x contract address"
135
+ },
136
+ chain: {
137
+ type: "string",
138
+ enum: ["ethereum", "base", "arbitrum"],
139
+ description: "Blockchain (default: ethereum)"
140
+ },
141
+ window: {
142
+ type: "string",
143
+ enum: ["1h", "4h", "24h", "168h"],
144
+ description: "Lookback window (default: 24h)"
145
+ }
146
+ },
147
+ required: ["protocol"]
148
+ }
149
+ },
150
+ // ── Aviation ──────────────────────────────────────────────────────────────
151
+ {
152
+ name: "squawk_alerts",
153
+ description: "Live global sweep of active aviation emergency squawk codes via OpenSky Network. Returns all aircraft currently squawking 7700 (general emergency), 7600 (radio failure), or 7500 (hijack) with position, altitude, and velocity. Costs $0.02 USDC on Base mainnet.",
65
154
  inputSchema: {
66
155
  type: "object",
67
156
  properties: {}
68
157
  }
158
+ },
159
+ {
160
+ name: "flight_scan",
161
+ description: "Sequence anomaly analysis for a named airspace region — detects unusual clustering of emergency squawks, rapid descents, or speed anomalies using the SequenceMiner engine. Costs $0.03 USDC on Base mainnet.",
162
+ inputSchema: {
163
+ type: "object",
164
+ properties: {
165
+ region: {
166
+ type: "string",
167
+ enum: ["north_atlantic", "europe", "north_america", "asia_pacific", "middle_east", "africa", "global"],
168
+ description: "Airspace region to analyze (default: global)"
169
+ }
170
+ }
171
+ }
172
+ },
173
+ // ── Creator signals ───────────────────────────────────────────────────────
174
+ {
175
+ name: "trending_signal",
176
+ description: "GitHub repos with anomalous star velocity right now — early signals before mainstream discovery. Detects repos going viral (200+ stars/day), overnight explosions, fork surges, and issue floods. Useful for trend hunting, VC scouting, developer tool discovery. Costs $0.02 USDC on Base mainnet.",
177
+ inputSchema: {
178
+ type: "object",
179
+ properties: {
180
+ days: {
181
+ type: "string",
182
+ enum: ["3", "7", "14", "30"],
183
+ description: "Search repos created in the last N days (default: 7)"
184
+ }
185
+ }
186
+ }
187
+ },
188
+ {
189
+ name: "repo_scan",
190
+ description: "Deep anomaly scan for a single GitHub repository — scores star velocity, fork ratio, overnight explosion signals, and issue flood patterns. Returns a story label (e.g. 'Breakout Signal', 'Viral Activity') and anomaly score. Costs $0.03 USDC on Base mainnet.",
191
+ inputSchema: {
192
+ type: "object",
193
+ properties: {
194
+ repo: {
195
+ type: "string",
196
+ description: "GitHub repo in owner/repo format, e.g. vercel/ai or microsoft/vscode"
197
+ }
198
+ },
199
+ required: ["repo"]
200
+ }
69
201
  }
70
202
  ];
71
203
  async function apiGet(path) {
@@ -75,7 +207,7 @@ async function apiGet(path) {
75
207
  let decoded = null;
76
208
  if (challenge) {
77
209
  try {
78
- decoded = JSON.parse(Buffer.from(challenge, "base64").toString());
210
+ decoded = JSON.parse(atob(challenge));
79
211
  }
80
212
  catch { }
81
213
  }
@@ -98,7 +230,7 @@ async function apiPost(path, body) {
98
230
  let decoded = null;
99
231
  if (challenge) {
100
232
  try {
101
- decoded = JSON.parse(Buffer.from(challenge, "base64").toString());
233
+ decoded = JSON.parse(atob(challenge));
102
234
  }
103
235
  catch { }
104
236
  }
@@ -112,42 +244,59 @@ async function apiPost(path, body) {
112
244
  }
113
245
  export async function callTool(name, args) {
114
246
  switch (name) {
115
- case "get_api_status":
247
+ case "health_check":
116
248
  return apiGet("/health");
117
- case "get_discovery_metadata": {
118
- const file = args.file;
119
- const pathMap = {
120
- "llms.txt": "/llms.txt",
121
- "openapi.json": "/openapi.json",
122
- "x402.json": "/.well-known/x402.json"
123
- };
124
- const path = pathMap[file];
125
- if (!path)
126
- return { error: "Unknown file. Use: llms.txt, openapi.json, or x402.json" };
127
- if (file === "llms.txt") {
128
- const res = await fetch(`${API_BASE}${path}`);
129
- return { content: await res.text() };
130
- }
131
- return apiGet(path);
132
- }
133
- case "inspect_x402_challenge": {
134
- const ep = args.endpoint;
135
- if (ep === "sequence-anomaly") {
136
- return apiPost("/api/sequence-anomaly", { domain: "financial", chain: "ethereum", window: "24h" });
137
- }
138
- if (ep === "status") {
139
- return apiGet("/api/sequence-anomaly/status");
140
- }
141
- return { error: "Unknown endpoint. Use: sequence-anomaly or status" };
142
- }
143
- case "detect_sequence_anomaly":
249
+ case "anomaly_scan":
144
250
  return apiPost("/api/sequence-anomaly", {
145
- domain: args.domain || "financial",
251
+ domain: "financial",
252
+ chain: args.chain || "ethereum",
253
+ window: args.window || "24h"
254
+ });
255
+ case "token_scan":
256
+ return apiPost("/api/token-scan", {
257
+ token: args.token,
258
+ chain: args.chain || "ethereum",
259
+ window: args.window || "24h"
260
+ });
261
+ case "whale_alerts": {
262
+ const chain = args.chain || "ethereum";
263
+ const hours = args.hours || 4;
264
+ return apiGet(`/api/whale-alerts?chain=${chain}&hours=${hours}`);
265
+ }
266
+ case "address_scan":
267
+ return apiPost("/api/address-scan", {
268
+ address: args.address,
146
269
  chain: args.chain || "ethereum",
147
270
  window: args.window || "24h"
148
271
  });
149
- case "get_model_status":
272
+ case "model_status":
150
273
  return apiGet("/api/sequence-anomaly/status");
274
+ case "nft_scan":
275
+ return apiPost("/api/nft-scan", {
276
+ token: args.token,
277
+ chain: args.chain || "ethereum",
278
+ window: args.window || "24h"
279
+ });
280
+ case "defi_scan":
281
+ return apiPost("/api/defi-scan", {
282
+ protocol: args.protocol,
283
+ chain: args.chain || "ethereum",
284
+ window: args.window || "24h"
285
+ });
286
+ case "squawk_alerts":
287
+ return apiGet("/api/squawk-alerts");
288
+ case "flight_scan":
289
+ return apiPost("/api/flight-scan", {
290
+ region: args.region || "global"
291
+ });
292
+ case "trending_signal": {
293
+ const days = args.days || "7";
294
+ return apiGet(`/api/trending-signal?days=${days}`);
295
+ }
296
+ case "repo_scan":
297
+ return apiPost("/api/repo-scan", {
298
+ repo: args.repo
299
+ });
151
300
  default:
152
301
  return { error: `Unknown tool: ${name}` };
153
302
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@forgemeshlabs/anomaly-mcp",
3
- "version": "0.1.1",
3
+ "version": "0.3.0",
4
4
  "mcpName": "io.github.forgemeshlabs/anomaly-mcp",
5
5
  "description": "Blockchain event sequence anomaly detection MCP server. Detects unusual financial event patterns via x402 micropayments.",
6
6
  "type": "module",
package/server.json CHANGED
@@ -6,12 +6,12 @@
6
6
  "url": "https://github.com/forgemeshlabs/anomaly-mcp",
7
7
  "source": "github"
8
8
  },
9
- "version": "0.1.1",
9
+ "version": "0.2.0",
10
10
  "packages": [
11
11
  {
12
12
  "registryType": "npm",
13
13
  "identifier": "@forgemeshlabs/anomaly-mcp",
14
- "version": "0.1.1",
14
+ "version": "0.2.0",
15
15
  "transport": {
16
16
  "type": "stdio"
17
17
  },