@sentinelsup/mcp 0.1.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.
Files changed (4) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +70 -0
  3. package/index.js +75 -0
  4. package/package.json +43 -0
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Sentinel Edge Networks LTD
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,70 @@
1
+ # Sentinel MCP Server
2
+
3
+ Check any IP address for fraud signals — VPN, proxy, Tor, datacenter hosting, anonymity — straight from Claude, Cursor, or any MCP client. Powered by the [Sentinel](https://sntlhq.com) fraud detection API.
4
+
5
+ ## Tools
6
+
7
+ | Tool | What it does |
8
+ |------|--------------|
9
+ | `lookup_ip` | Verdict for any public IPv4/IPv6: `allow` / `review` / `block`, 0–100 risk score, VPN/proxy/Tor/datacenter/anonymity signals, ASN + org + country |
10
+ | `service_status` | Sentinel API health, uptime, and latency |
11
+
12
+ ## Setup
13
+
14
+ Grab a free API key at [sntlhq.com/signup](https://sntlhq.com/signup) (1,000 lookups/hour, no card). The server also works without a key for a few lookups per minute — enough to try it.
15
+
16
+ ### Claude Code
17
+
18
+ ```bash
19
+ claude mcp add sentinel -e SENTINEL_API_KEY=sk_live_your_key -- npx -y @sentinelsup/mcp
20
+ ```
21
+
22
+ ### Claude Desktop
23
+
24
+ Add to `claude_desktop_config.json`:
25
+
26
+ ```json
27
+ {
28
+ "mcpServers": {
29
+ "sentinel": {
30
+ "command": "npx",
31
+ "args": ["-y", "@sentinelsup/mcp"],
32
+ "env": { "SENTINEL_API_KEY": "sk_live_your_key" }
33
+ }
34
+ }
35
+ }
36
+ ```
37
+
38
+ ### Cursor / other MCP clients
39
+
40
+ Any client that speaks stdio MCP works the same way: command `npx`, args `["-y", "@sentinelsup/mcp"]`, env `SENTINEL_API_KEY`.
41
+
42
+ ## Example
43
+
44
+ > "Is 185.220.101.34 safe to allow through signup?"
45
+
46
+ ```json
47
+ {
48
+ "ip": "185.220.101.34",
49
+ "known": true,
50
+ "verdict": "block",
51
+ "risk_score": 90,
52
+ "signals": { "vpn": false, "proxied": false, "tor": true, "dch": true, "anon": true },
53
+ "network": { "asn": 205100, "org": "F3 Netze e.V.", "country": "DE" }
54
+ }
55
+ ```
56
+
57
+ ## Environment
58
+
59
+ | Variable | Required | Default | Purpose |
60
+ |----------|----------|---------|---------|
61
+ | `SENTINEL_API_KEY` | recommended | — | API key from your [dashboard](https://sntlhq.com/dashboard); unlocks 1,000 lookups/hour |
62
+ | `SENTINEL_BASE_URL` | no | `https://sntlhq.com` | Override for testing |
63
+
64
+ ## Links
65
+
66
+ - [API docs](https://sntlhq.com/api)
67
+ - [Node SDK](https://github.com/sentinelsup/sentinel-node) · [Python SDK](https://pypi.org/project/sentinelsup/)
68
+ - [Status](https://sntlhq.com/status)
69
+
70
+ MIT © Sentinel Edge Networks LTD
package/index.js ADDED
@@ -0,0 +1,75 @@
1
+ #!/usr/bin/env node
2
+ // Sentinel MCP server — IP fraud intelligence for MCP clients (Claude Code,
3
+ // Claude Desktop, Cursor, ...). One stdio server, two tools.
4
+ //
5
+ // With SENTINEL_API_KEY set, lookups go through the authenticated API
6
+ // (GET /v1/lookup/{ip}, 1,000 req/hr on the free tier). Without a key they
7
+ // fall back to the free web-tool endpoint, which is fine for trying it out
8
+ // but rate-limited to a handful of lookups per minute.
9
+ import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
10
+ import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
11
+ import { z } from 'zod';
12
+
13
+ const BASE = process.env.SENTINEL_BASE_URL || 'https://sntlhq.com';
14
+ const API_KEY = process.env.SENTINEL_API_KEY || '';
15
+
16
+ async function lookupIp(ip) {
17
+ const opts = { headers: { 'Accept': 'application/json' } };
18
+ let res;
19
+ if (API_KEY) {
20
+ res = await fetch(`${BASE}/v1/lookup/${encodeURIComponent(ip)}`, {
21
+ ...opts,
22
+ headers: { ...opts.headers, 'Authorization': `Bearer ${API_KEY}` }
23
+ });
24
+ } else {
25
+ res = await fetch(`${BASE}/api/lookup`, {
26
+ method: 'POST',
27
+ headers: { ...opts.headers, 'Content-Type': 'application/json' },
28
+ body: JSON.stringify({ ip })
29
+ });
30
+ }
31
+ const data = await res.json().catch(() => ({}));
32
+ if (!res.ok) {
33
+ const hint = !API_KEY && res.status === 429
34
+ ? ' (keyless mode is tightly rate-limited — set SENTINEL_API_KEY for 1,000 lookups/hour; free key at https://sntlhq.com/signup)'
35
+ : '';
36
+ throw new Error(`${data.error || `HTTP ${res.status}`}${hint}`);
37
+ }
38
+ return data;
39
+ }
40
+
41
+ function text(obj) {
42
+ return { content: [{ type: 'text', text: JSON.stringify(obj, null, 2) }] };
43
+ }
44
+
45
+ const server = new McpServer({ name: 'sentinel', version: '0.1.0' });
46
+
47
+ server.tool(
48
+ 'lookup_ip',
49
+ 'Check an IP address for fraud signals: VPN, proxy, Tor exit node, datacenter hosting, and anonymity. Returns an allow/review/block verdict, a 0-100 risk score, the individual signals, and network info (ASN, organization, country).',
50
+ { ip: z.string().describe('Public IPv4 or IPv6 address to check, e.g. "185.220.101.34"') },
51
+ async ({ ip }) => {
52
+ try {
53
+ return text(await lookupIp(ip.trim()));
54
+ } catch (e) {
55
+ return { ...text({ error: e.message }), isError: true };
56
+ }
57
+ }
58
+ );
59
+
60
+ server.tool(
61
+ 'service_status',
62
+ 'Current operational status of the Sentinel API: uptime, per-service health, and average latency.',
63
+ {},
64
+ async () => {
65
+ try {
66
+ const res = await fetch(`${BASE}/api/status`, { headers: { 'Accept': 'application/json' } });
67
+ return text(await res.json());
68
+ } catch (e) {
69
+ return { ...text({ error: e.message }), isError: true };
70
+ }
71
+ }
72
+ );
73
+
74
+ const transport = new StdioServerTransport();
75
+ await server.connect(transport);
package/package.json ADDED
@@ -0,0 +1,43 @@
1
+ {
2
+ "name": "@sentinelsup/mcp",
3
+ "version": "0.1.0",
4
+ "description": "MCP server for Sentinel — check any IP for VPNs, proxies, Tor, datacenter hosting, and fraud risk from Claude, Cursor, or any MCP client.",
5
+ "keywords": [
6
+ "mcp",
7
+ "model-context-protocol",
8
+ "fraud-detection",
9
+ "ip-lookup",
10
+ "vpn-detection",
11
+ "proxy-detection",
12
+ "bot-detection",
13
+ "sentinel",
14
+ "sntlhq"
15
+ ],
16
+ "type": "module",
17
+ "main": "index.js",
18
+ "bin": {
19
+ "sentinel-mcp": "index.js"
20
+ },
21
+ "files": [
22
+ "index.js",
23
+ "README.md",
24
+ "LICENSE"
25
+ ],
26
+ "repository": {
27
+ "type": "git",
28
+ "url": "git+https://github.com/sentinelsup/sentinel-mcp.git"
29
+ },
30
+ "homepage": "https://sntlhq.com",
31
+ "bugs": {
32
+ "url": "https://github.com/sentinelsup/sentinel-mcp/issues"
33
+ },
34
+ "author": "Sentinel Edge Networks LTD <support@sntlhq.com>",
35
+ "license": "MIT",
36
+ "engines": {
37
+ "node": ">=18"
38
+ },
39
+ "dependencies": {
40
+ "@modelcontextprotocol/sdk": "^1.0.0",
41
+ "zod": "^3.23.0"
42
+ }
43
+ }