web-agent-bridge 2.9.0 → 3.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/LICENSE +51 -0
- package/README.ar.md +79 -0
- package/README.md +104 -4
- package/package.json +2 -1
- package/public/.well-known/ai-plugin.json +28 -0
- package/public/agent-workspace.html +3 -1
- package/public/ai.html +5 -3
- package/public/api.html +412 -0
- package/public/browser.html +4 -2
- package/public/cookies.html +4 -2
- package/public/dashboard.html +5 -3
- package/public/demo.html +1770 -1
- package/public/docs.html +6 -4
- package/public/growth.html +463 -0
- package/public/index.html +982 -738
- package/public/llms-full.txt +52 -1
- package/public/llms.txt +39 -0
- package/public/login.html +6 -4
- package/public/premium-dashboard.html +7 -5
- package/public/premium.html +6 -4
- package/public/privacy.html +4 -2
- package/public/register.html +6 -4
- package/public/score.html +263 -0
- package/public/terms.html +4 -2
- package/sdk/index.js +7 -1
- package/sdk/package.json +12 -1
- package/server/index.js +427 -375
- package/server/middleware/rateLimits.js +3 -3
- package/server/migrations/006_growth_suite.sql +138 -0
- package/server/routes/agent-workspace.js +162 -0
- package/server/routes/demo-showcase.js +332 -0
- package/server/routes/discovery.js +18 -7
- package/server/routes/gateway.js +157 -0
- package/server/routes/growth.js +962 -0
- package/server/routes/runtime.js +204 -0
- package/server/routes/universal.js +9 -1
- package/server/routes/wab-api.js +16 -6
- package/server/runtime/container-worker.js +111 -0
- package/server/runtime/container.js +448 -0
- package/server/runtime/distributed-worker.js +362 -0
- package/server/runtime/index.js +21 -1
- package/server/runtime/queue.js +599 -0
- package/server/runtime/replay.js +431 -29
- package/server/runtime/scheduler.js +194 -55
- package/server/services/api-key-engine.js +261 -0
- package/server/services/lfd.js +22 -3
- package/server/services/modules/affiliate-intelligence.js +93 -0
- package/server/services/modules/agent-firewall.js +90 -0
- package/server/services/modules/bounty.js +89 -0
- package/server/services/modules/collective-bargaining.js +92 -0
- package/server/services/modules/dark-pattern.js +66 -0
- package/server/services/modules/gov-intelligence.js +45 -0
- package/server/services/modules/neural.js +55 -0
- package/server/services/modules/notary.js +49 -0
- package/server/services/modules/price-time-machine.js +86 -0
- package/server/services/modules/protocol.js +104 -0
- package/server/services/premium.js +1 -1
- package/server/services/price-intelligence.js +2 -1
- package/server/services/vision.js +2 -2
package/public/llms-full.txt
CHANGED
|
@@ -291,7 +291,54 @@ A: robots.txt says "what you can crawl." WAB says "what you can do" — it's act
|
|
|
291
291
|
|
|
292
292
|
---
|
|
293
293
|
|
|
294
|
-
## 14.
|
|
294
|
+
## 14. MCP Server — AI Coding Tool Integration
|
|
295
|
+
|
|
296
|
+
WAB provides a standalone MCP (Model Context Protocol) server package `wab-mcp-server` that integrates with AI coding tools like Cursor, Claude Desktop, Cline, and Windsurf.
|
|
297
|
+
|
|
298
|
+
### Installation
|
|
299
|
+
```bash
|
|
300
|
+
npm install -g wab-mcp-server
|
|
301
|
+
# or run directly
|
|
302
|
+
npx wab-mcp-server
|
|
303
|
+
```
|
|
304
|
+
|
|
305
|
+
### Configuration
|
|
306
|
+
Add to `.cursor/mcp.json` or Claude Desktop config:
|
|
307
|
+
```json
|
|
308
|
+
{
|
|
309
|
+
"mcpServers": {
|
|
310
|
+
"wab": {
|
|
311
|
+
"command": "npx",
|
|
312
|
+
"args": ["-y", "wab-mcp-server"]
|
|
313
|
+
}
|
|
314
|
+
}
|
|
315
|
+
}
|
|
316
|
+
```
|
|
317
|
+
|
|
318
|
+
### MCP Tools Available
|
|
319
|
+
| Tool | Description |
|
|
320
|
+
|------|-------------|
|
|
321
|
+
| `wab_scan_url` | Scan URLs against 47 threat databases for phishing, malware, scams |
|
|
322
|
+
| `wab_fairness_check` | Score platform transparency (0-100) across 15 signals |
|
|
323
|
+
| `wab_find_deals` | Cross-platform price intelligence with fairness filtering |
|
|
324
|
+
| `wab_agent_query` | Natural language web automation queries |
|
|
325
|
+
| `wab_generate_snippet` | Generate WAB integration code (JS, Python, React, Next.js, Docker) |
|
|
326
|
+
| `wab_get_docs` | Retrieve WAB documentation and API reference |
|
|
327
|
+
|
|
328
|
+
### Viral Embed Engine
|
|
329
|
+
All generated code snippets automatically include WAB attribution comments, ensuring proper credit and discoverability across the developer ecosystem.
|
|
330
|
+
|
|
331
|
+
### SDK Packages
|
|
332
|
+
| Platform | Package | Install |
|
|
333
|
+
|----------|---------|---------|
|
|
334
|
+
| JavaScript/Node.js | `@wab/sdk` | `npm install @wab/sdk` |
|
|
335
|
+
| React | `@wab/react` | `npm install @wab/react` |
|
|
336
|
+
| Python | `wab-sdk` | `pip install wab-sdk` |
|
|
337
|
+
| MCP Server | `wab-mcp-server` | `npm install -g wab-mcp-server` |
|
|
338
|
+
|
|
339
|
+
---
|
|
340
|
+
|
|
341
|
+
## 15. Keywords and Categories
|
|
295
342
|
|
|
296
343
|
- AI agent automation
|
|
297
344
|
- Website automation protocol
|
|
@@ -301,9 +348,13 @@ A: robots.txt says "what you can crawl." WAB says "what you can do" — it's act
|
|
|
301
348
|
- Browser automation alternative
|
|
302
349
|
- Fair AI discovery
|
|
303
350
|
- MCP integration
|
|
351
|
+
- MCP server
|
|
304
352
|
- Web scraping alternative
|
|
305
353
|
- OpenAPI for websites
|
|
306
354
|
- AI-ready websites
|
|
307
355
|
- WordPress AI plugin
|
|
308
356
|
- Agent discovery protocol
|
|
309
357
|
- Structured web commands
|
|
358
|
+
- AI coding tools
|
|
359
|
+
- Cursor integration
|
|
360
|
+
- Claude Desktop integration
|
package/public/llms.txt
CHANGED
|
@@ -79,6 +79,45 @@ Or add the script to any HTML page:
|
|
|
79
79
|
- **WordPress sites** via the official plugin
|
|
80
80
|
- **Any developer** building for the Agentic Web
|
|
81
81
|
|
|
82
|
+
## MCP Server (for AI Coding Tools)
|
|
83
|
+
|
|
84
|
+
WAB provides a Model Context Protocol (MCP) server that works with Cursor, Claude Desktop, Cline, Windsurf, and other MCP-compatible AI tools.
|
|
85
|
+
|
|
86
|
+
### Install
|
|
87
|
+
```bash
|
|
88
|
+
npm install -g wab-mcp-server
|
|
89
|
+
# or use directly
|
|
90
|
+
npx wab-mcp-server
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
### Configure (Cursor / Claude Desktop)
|
|
94
|
+
Add to your MCP configuration:
|
|
95
|
+
```json
|
|
96
|
+
{
|
|
97
|
+
"mcpServers": {
|
|
98
|
+
"wab": {
|
|
99
|
+
"command": "npx",
|
|
100
|
+
"args": ["-y", "wab-mcp-server"]
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
### Available MCP Tools
|
|
107
|
+
- `wab_scan_url` — Scan URLs for phishing, malware, and scams (47 databases)
|
|
108
|
+
- `wab_fairness_check` — Score platform transparency (0-100, 15 signals)
|
|
109
|
+
- `wab_find_deals` — Cross-platform price intelligence with fairness filtering
|
|
110
|
+
- `wab_agent_query` — Natural language web automation
|
|
111
|
+
- `wab_generate_snippet` — Generate WAB integration code (JS, Python, React, Next.js, Docker)
|
|
112
|
+
- `wab_get_docs` — Get WAB documentation and API reference
|
|
113
|
+
|
|
114
|
+
## SDK Packages
|
|
115
|
+
|
|
116
|
+
- **JavaScript/Node.js**: `npm install @wab/sdk`
|
|
117
|
+
- **React**: `npm install @wab/react`
|
|
118
|
+
- **Python**: `pip install wab-sdk`
|
|
119
|
+
- **MCP Server**: `npm install -g wab-mcp-server`
|
|
120
|
+
|
|
82
121
|
## Contact
|
|
83
122
|
|
|
84
123
|
- Support: support@webagentbridge.com
|
package/public/login.html
CHANGED
|
@@ -6,9 +6,11 @@
|
|
|
6
6
|
<title>Sign In — Web Agent Bridge</title>
|
|
7
7
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
8
8
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
9
|
-
<
|
|
10
|
-
<link rel="
|
|
11
|
-
<
|
|
9
|
+
<style>body{background:#0a0e1a;color:#f0f4ff;font-family:Inter,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;margin:0;min-height:100vh}</style>
|
|
10
|
+
<link rel="preload" href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap" as="style" onload="this.onload=null;this.rel='stylesheet'">
|
|
11
|
+
<noscript><link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet"></noscript>
|
|
12
|
+
<link rel="stylesheet" href="/css/styles.css?v=3.0.1">
|
|
13
|
+
<script src="/js/auth-redirect.js?v=3.0.1"></script>
|
|
12
14
|
</head>
|
|
13
15
|
<body>
|
|
14
16
|
<div class="auth-page">
|
|
@@ -78,6 +80,6 @@
|
|
|
78
80
|
}
|
|
79
81
|
});
|
|
80
82
|
</script>
|
|
81
|
-
<script src="/js/cookie-consent.js"></script>
|
|
83
|
+
<script src="/js/cookie-consent.js?v=3.0.1"></script>
|
|
82
84
|
</body>
|
|
83
85
|
</html>
|
|
@@ -15,8 +15,10 @@
|
|
|
15
15
|
</script>
|
|
16
16
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
17
17
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
18
|
-
<
|
|
19
|
-
<link rel="
|
|
18
|
+
<style>body{background:#0a0e1a;color:#f0f4ff;font-family:Inter,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;margin:0;min-height:100vh}</style>
|
|
19
|
+
<link rel="preload" href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap" as="style" onload="this.onload=null;this.rel='stylesheet'">
|
|
20
|
+
<noscript><link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet"></noscript>
|
|
21
|
+
<link rel="stylesheet" href="/css/styles.css?v=3.0.1">
|
|
20
22
|
<style>
|
|
21
23
|
.view { display: none; }
|
|
22
24
|
.view.active { display: block; }
|
|
@@ -1943,7 +1945,7 @@
|
|
|
1943
1945
|
document.querySelectorAll('#cdnEdges input').forEach(cb => { cb.checked = edges.includes(cb.value); });
|
|
1944
1946
|
document.getElementById('cdnStatReqs').textContent = c.requests_count || 0;
|
|
1945
1947
|
document.getElementById('cdnStatBw').textContent = fmtBytes(c.bandwidth_used || 0);
|
|
1946
|
-
const cdnUrl = c.custom_domain ? 'https://' + c.custom_domain + '/bridge/' + sid + '/ai-agent-bridge.js' : 'https://
|
|
1948
|
+
const cdnUrl = c.custom_domain ? 'https://' + c.custom_domain + '/bridge/' + sid + '/ai-agent-bridge.js' : 'https://webagentbridge.com/bridge/' + sid + '/ai-agent-bridge.js';
|
|
1947
1949
|
document.getElementById('cdnUrlDisplay').textContent = cdnUrl;
|
|
1948
1950
|
|
|
1949
1951
|
try {
|
|
@@ -1957,7 +1959,7 @@
|
|
|
1957
1959
|
}
|
|
1958
1960
|
} catch {}
|
|
1959
1961
|
} else {
|
|
1960
|
-
document.getElementById('cdnUrlDisplay').textContent = 'https://
|
|
1962
|
+
document.getElementById('cdnUrlDisplay').textContent = 'https://webagentbridge.com/bridge/' + sid + '/ai-agent-bridge.js';
|
|
1961
1963
|
}
|
|
1962
1964
|
} catch (err) { console.error('loadCdn:', err); }
|
|
1963
1965
|
}
|
|
@@ -2482,6 +2484,6 @@
|
|
|
2482
2484
|
|
|
2483
2485
|
init();
|
|
2484
2486
|
</script>
|
|
2485
|
-
<script src="/js/cookie-consent.js"></script>
|
|
2487
|
+
<script src="/js/cookie-consent.js?v=3.0.1"></script>
|
|
2486
2488
|
</body>
|
|
2487
2489
|
</html>
|
package/public/premium.html
CHANGED
|
@@ -7,8 +7,10 @@
|
|
|
7
7
|
<meta name="description" content="Advanced premium services for Web Agent Bridge: AI traffic intelligence, exploit protection, custom agents, CRM integrations, and more.">
|
|
8
8
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
9
9
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
10
|
-
<
|
|
11
|
-
<link rel="
|
|
10
|
+
<style>body{background:#0a0e1a;color:#f0f4ff;font-family:Inter,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;margin:0;min-height:100vh}</style>
|
|
11
|
+
<link rel="preload" href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;600&display=swap" as="style" onload="this.onload=null;this.rel='stylesheet'">
|
|
12
|
+
<noscript><link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;600&display=swap" rel="stylesheet"></noscript>
|
|
13
|
+
<link rel="stylesheet" href="/css/styles.css?v=3.0.1">
|
|
12
14
|
<link rel="stylesheet" href="/css/premium.css">
|
|
13
15
|
</head>
|
|
14
16
|
<body>
|
|
@@ -777,7 +779,7 @@
|
|
|
777
779
|
</div>
|
|
778
780
|
</footer>
|
|
779
781
|
|
|
780
|
-
<script src="/js/auth-nav.js"></script>
|
|
782
|
+
<script src="/js/auth-nav.js?v=3.0.1"></script>
|
|
781
783
|
<script>
|
|
782
784
|
const navbar = document.getElementById('navbar');
|
|
783
785
|
window.addEventListener('scroll', () => {
|
|
@@ -786,6 +788,6 @@
|
|
|
786
788
|
: 'rgba(10, 14, 26, 0.8)';
|
|
787
789
|
});
|
|
788
790
|
</script>
|
|
789
|
-
<script src="/js/cookie-consent.js"></script>
|
|
791
|
+
<script src="/js/cookie-consent.js?v=3.0.1"></script>
|
|
790
792
|
</body>
|
|
791
793
|
</html>
|
package/public/privacy.html
CHANGED
|
@@ -7,8 +7,10 @@
|
|
|
7
7
|
<meta name="description" content="Privacy Policy for Web Agent Bridge. GDPR and AVG compliant.">
|
|
8
8
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
9
9
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
10
|
-
<
|
|
11
|
-
<link rel="
|
|
10
|
+
<style>body{background:#0a0e1a;color:#f0f4ff;font-family:Inter,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;margin:0;min-height:100vh}</style>
|
|
11
|
+
<link rel="preload" href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;600&display=swap" as="style" onload="this.onload=null;this.rel='stylesheet'">
|
|
12
|
+
<noscript><link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;600&display=swap" rel="stylesheet"></noscript>
|
|
13
|
+
<link rel="stylesheet" href="/css/styles.css?v=3.0.1">
|
|
12
14
|
</head>
|
|
13
15
|
<body>
|
|
14
16
|
|
package/public/register.html
CHANGED
|
@@ -6,9 +6,11 @@
|
|
|
6
6
|
<title>Create Account — Web Agent Bridge</title>
|
|
7
7
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
8
8
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
9
|
-
<
|
|
10
|
-
<link rel="
|
|
11
|
-
<
|
|
9
|
+
<style>body{background:#0a0e1a;color:#f0f4ff;font-family:Inter,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;margin:0;min-height:100vh}</style>
|
|
10
|
+
<link rel="preload" href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap" as="style" onload="this.onload=null;this.rel='stylesheet'">
|
|
11
|
+
<noscript><link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet"></noscript>
|
|
12
|
+
<link rel="stylesheet" href="/css/styles.css?v=3.0.1">
|
|
13
|
+
<script src="/js/auth-redirect.js?v=3.0.1"></script>
|
|
12
14
|
</head>
|
|
13
15
|
<body>
|
|
14
16
|
<div class="auth-page">
|
|
@@ -98,6 +100,6 @@
|
|
|
98
100
|
}
|
|
99
101
|
});
|
|
100
102
|
</script>
|
|
101
|
-
<script src="/js/cookie-consent.js"></script>
|
|
103
|
+
<script src="/js/cookie-consent.js?v=3.0.1"></script>
|
|
102
104
|
</body>
|
|
103
105
|
</html>
|
|
@@ -0,0 +1,263 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8">
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
|
+
<title>WAB Score — Platform Transparency Rating</title>
|
|
7
|
+
<meta name="description" content="Check any platform's WAB Score — the digital world's credit rating for transparency and fairness.">
|
|
8
|
+
<link rel="icon" href="/assets/favicon.svg" type="image/svg+xml">
|
|
9
|
+
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;900&display=swap" rel="stylesheet">
|
|
10
|
+
<link rel="stylesheet" href="/css/styles.css?v=3.0.1">
|
|
11
|
+
<style>
|
|
12
|
+
.score-hero { padding: 80px 20px 40px; text-align: center; background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%); color: #fff; }
|
|
13
|
+
.score-hero h1 { font-size: 42px; margin-bottom: 12px; }
|
|
14
|
+
.score-hero p { color: #94a3b8; font-size: 18px; max-width: 600px; margin: 0 auto 32px; }
|
|
15
|
+
.search-box { display: flex; max-width: 560px; margin: 0 auto; gap: 8px; }
|
|
16
|
+
.search-box input { flex: 1; padding: 14px 20px; border: 2px solid #334155; border-radius: 10px; font-size: 16px; background: #1e293b; color: #fff; outline: none; }
|
|
17
|
+
.search-box input::placeholder { color: #64748b; }
|
|
18
|
+
.search-box input:focus { border-color: #3b82f6; }
|
|
19
|
+
.search-box button { padding: 14px 28px; background: #3b82f6; color: white; border: none; border-radius: 10px; font-weight: 700; font-size: 16px; cursor: pointer; }
|
|
20
|
+
.search-box button:hover { background: #2563eb; }
|
|
21
|
+
.search-box button:disabled { opacity: 0.6; cursor: wait; }
|
|
22
|
+
|
|
23
|
+
.result-container { max-width: 700px; margin: 40px auto; padding: 0 20px; }
|
|
24
|
+
.score-card { background: white; border-radius: 16px; padding: 40px; box-shadow: 0 4px 24px rgba(0,0,0,0.08); display: none; }
|
|
25
|
+
.score-card.visible { display: block; animation: fadeIn 0.3s ease; }
|
|
26
|
+
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
|
|
27
|
+
|
|
28
|
+
.score-header { display: flex; align-items: center; gap: 24px; margin-bottom: 32px; }
|
|
29
|
+
.score-circle { width: 100px; height: 100px; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; flex-shrink: 0; }
|
|
30
|
+
.score-circle .grade { font-size: 32px; font-weight: 900; line-height: 1; }
|
|
31
|
+
.score-circle .number { font-size: 13px; opacity: 0.8; }
|
|
32
|
+
.score-domain { font-size: 28px; font-weight: 700; color: #0f172a; }
|
|
33
|
+
.score-label { font-size: 16px; color: #64748b; margin-top: 4px; }
|
|
34
|
+
|
|
35
|
+
.score-bars { margin-bottom: 32px; }
|
|
36
|
+
.bar-row { margin-bottom: 16px; }
|
|
37
|
+
.bar-label { display: flex; justify-content: space-between; font-size: 14px; margin-bottom: 6px; }
|
|
38
|
+
.bar-label span:first-child { font-weight: 600; color: #334155; }
|
|
39
|
+
.bar-label span:last-child { color: #64748b; }
|
|
40
|
+
.bar-track { height: 10px; background: #f1f5f9; border-radius: 5px; overflow: hidden; }
|
|
41
|
+
.bar-fill { height: 100%; border-radius: 5px; transition: width 0.6s ease; }
|
|
42
|
+
|
|
43
|
+
.signals-list { border-top: 1px solid #e2e8f0; padding-top: 20px; }
|
|
44
|
+
.signals-list h4 { font-size: 14px; color: #64748b; margin-bottom: 12px; text-transform: uppercase; letter-spacing: 1px; }
|
|
45
|
+
.signal { display: flex; justify-content: space-between; padding: 8px 0; font-size: 14px; border-bottom: 1px solid #f1f5f9; }
|
|
46
|
+
.signal:last-child { border-bottom: none; }
|
|
47
|
+
.signal .name { color: #334155; }
|
|
48
|
+
.signal .impact { font-weight: 600; }
|
|
49
|
+
.signal .impact.positive { color: #22c55e; }
|
|
50
|
+
.signal .impact.negative { color: #ef4444; }
|
|
51
|
+
|
|
52
|
+
.badge-embed { margin-top: 24px; padding: 16px; background: #f8fafc; border-radius: 8px; }
|
|
53
|
+
.badge-embed h4 { font-size: 14px; color: #64748b; margin-bottom: 8px; }
|
|
54
|
+
.badge-embed code { display: block; background: #0f172a; color: #e2e8f0; padding: 12px; border-radius: 6px; font-size: 12px; word-break: break-all; }
|
|
55
|
+
|
|
56
|
+
.error-msg { text-align: center; padding: 24px; color: #ef4444; font-weight: 600; display: none; }
|
|
57
|
+
.error-msg.visible { display: block; }
|
|
58
|
+
|
|
59
|
+
.recent-scores { max-width: 700px; margin: 40px auto; padding: 0 20px 60px; }
|
|
60
|
+
.recent-scores h3 { font-size: 20px; color: #0f172a; margin-bottom: 16px; }
|
|
61
|
+
.recent-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
|
|
62
|
+
.recent-item { display: flex; align-items: center; gap: 12px; background: #fff; padding: 12px 16px; border-radius: 8px; border: 1px solid #e2e8f0; cursor: pointer; transition: border-color 0.2s; }
|
|
63
|
+
.recent-item:hover { border-color: #3b82f6; }
|
|
64
|
+
.recent-item .mini-grade { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 900; font-size: 14px; color: white; flex-shrink: 0; }
|
|
65
|
+
.recent-item .info .domain { font-weight: 600; font-size: 14px; color: #0f172a; }
|
|
66
|
+
.recent-item .info .meta { font-size: 12px; color: #64748b; }
|
|
67
|
+
</style>
|
|
68
|
+
</head>
|
|
69
|
+
<body>
|
|
70
|
+
<!-- NAVBAR -->
|
|
71
|
+
<nav class="navbar">
|
|
72
|
+
<div class="container" style="display:flex; align-items:center; justify-content:space-between; height:64px;">
|
|
73
|
+
<a href="/" class="navbar-brand"><div class="brand-icon">⚡</div><span>Web Agent Bridge</span></a>
|
|
74
|
+
<div style="display:flex; gap:20px; align-items:center;">
|
|
75
|
+
<a href="/#features" style="color:var(--text-secondary); text-decoration:none; font-size:14px;">Features</a>
|
|
76
|
+
<a href="/docs" style="color:var(--text-secondary); text-decoration:none; font-size:14px;">Docs</a>
|
|
77
|
+
<a href="/growth" style="color:var(--text-secondary); text-decoration:none; font-size:14px;">Growth Suite</a>
|
|
78
|
+
<a href="/login" class="btn btn-secondary" style="padding:6px 16px; font-size:13px;">Login</a>
|
|
79
|
+
</div>
|
|
80
|
+
</div>
|
|
81
|
+
</nav>
|
|
82
|
+
|
|
83
|
+
<!-- HERO -->
|
|
84
|
+
<section class="score-hero">
|
|
85
|
+
<h1>WAB <span class="gradient-text">Score</span></h1>
|
|
86
|
+
<p>The digital world's credit rating. Check any platform's transparency, fairness, and security score.</p>
|
|
87
|
+
<form class="search-box" id="scoreForm" onsubmit="return false;">
|
|
88
|
+
<input type="text" id="domainInput" placeholder="Enter domain (e.g. amazon.com, shein.com)" autocomplete="off" autofocus>
|
|
89
|
+
<button type="submit" id="searchBtn" onclick="checkScore()">Check Score</button>
|
|
90
|
+
</form>
|
|
91
|
+
</section>
|
|
92
|
+
|
|
93
|
+
<!-- RESULT -->
|
|
94
|
+
<div class="result-container">
|
|
95
|
+
<div class="error-msg" id="errorMsg"></div>
|
|
96
|
+
<div class="score-card" id="scoreCard">
|
|
97
|
+
<div class="score-header">
|
|
98
|
+
<div class="score-circle" id="scoreCircle">
|
|
99
|
+
<span class="grade" id="gradeText"></span>
|
|
100
|
+
<span class="number" id="scoreNumber"></span>
|
|
101
|
+
</div>
|
|
102
|
+
<div>
|
|
103
|
+
<div class="score-domain" id="domainText"></div>
|
|
104
|
+
<div class="score-label" id="gradeLabel"></div>
|
|
105
|
+
</div>
|
|
106
|
+
</div>
|
|
107
|
+
|
|
108
|
+
<div class="score-bars">
|
|
109
|
+
<div class="bar-row">
|
|
110
|
+
<div class="bar-label"><span>Fairness Score</span><span id="fairnessVal"></span></div>
|
|
111
|
+
<div class="bar-track"><div class="bar-fill" id="fairnessBar" style="width:0"></div></div>
|
|
112
|
+
</div>
|
|
113
|
+
<div class="bar-row">
|
|
114
|
+
<div class="bar-label"><span>Security Score</span><span id="securityVal"></span></div>
|
|
115
|
+
<div class="bar-track"><div class="bar-fill" id="securityBar" style="width:0"></div></div>
|
|
116
|
+
</div>
|
|
117
|
+
</div>
|
|
118
|
+
|
|
119
|
+
<div class="signals-list" id="signalsList">
|
|
120
|
+
<h4>Analysis Signals</h4>
|
|
121
|
+
</div>
|
|
122
|
+
|
|
123
|
+
<div class="badge-embed">
|
|
124
|
+
<h4>Embed This Badge</h4>
|
|
125
|
+
<code id="badgeCode"></code>
|
|
126
|
+
</div>
|
|
127
|
+
</div>
|
|
128
|
+
</div>
|
|
129
|
+
|
|
130
|
+
<!-- RECENT -->
|
|
131
|
+
<div class="recent-scores" id="recentSection" style="display:none;">
|
|
132
|
+
<h3>Recently Checked</h3>
|
|
133
|
+
<div class="recent-grid" id="recentGrid"></div>
|
|
134
|
+
</div>
|
|
135
|
+
|
|
136
|
+
<script>
|
|
137
|
+
const recentScores = JSON.parse(localStorage.getItem('wab_recent_scores') || '[]');
|
|
138
|
+
renderRecent();
|
|
139
|
+
|
|
140
|
+
// Allow URL param: /score?domain=amazon.com
|
|
141
|
+
const urlParams = new URLSearchParams(window.location.search);
|
|
142
|
+
const domainParam = urlParams.get('domain');
|
|
143
|
+
if (domainParam) {
|
|
144
|
+
document.getElementById('domainInput').value = domainParam;
|
|
145
|
+
setTimeout(checkScore, 100);
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
async function checkScore() {
|
|
149
|
+
const input = document.getElementById('domainInput');
|
|
150
|
+
const btn = document.getElementById('searchBtn');
|
|
151
|
+
const card = document.getElementById('scoreCard');
|
|
152
|
+
const error = document.getElementById('errorMsg');
|
|
153
|
+
|
|
154
|
+
let domain = input.value.trim().toLowerCase();
|
|
155
|
+
if (!domain) return;
|
|
156
|
+
|
|
157
|
+
// Clean input
|
|
158
|
+
domain = domain.replace(/^https?:\/\//, '').replace(/^www\./, '').replace(/\/.*$/, '');
|
|
159
|
+
if (domain.length < 3 || !domain.includes('.')) {
|
|
160
|
+
error.textContent = 'Please enter a valid domain (e.g. amazon.com)';
|
|
161
|
+
error.classList.add('visible');
|
|
162
|
+
card.classList.remove('visible');
|
|
163
|
+
return;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
btn.disabled = true;
|
|
167
|
+
btn.textContent = 'Checking...';
|
|
168
|
+
error.classList.remove('visible');
|
|
169
|
+
card.classList.remove('visible');
|
|
170
|
+
|
|
171
|
+
try {
|
|
172
|
+
const res = await fetch('/api/growth/score/' + encodeURIComponent(domain));
|
|
173
|
+
const data = await res.json();
|
|
174
|
+
|
|
175
|
+
if (!res.ok) throw new Error(data.error || 'Failed to check score');
|
|
176
|
+
|
|
177
|
+
// Update URL
|
|
178
|
+
history.replaceState(null, '', '/score?domain=' + encodeURIComponent(domain));
|
|
179
|
+
|
|
180
|
+
// Render
|
|
181
|
+
renderScore(data);
|
|
182
|
+
saveRecent(data);
|
|
183
|
+
} catch (err) {
|
|
184
|
+
error.textContent = err.message;
|
|
185
|
+
error.classList.add('visible');
|
|
186
|
+
} finally {
|
|
187
|
+
btn.disabled = false;
|
|
188
|
+
btn.textContent = 'Check Score';
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
function renderScore(data) {
|
|
193
|
+
const card = document.getElementById('scoreCard');
|
|
194
|
+
const circle = document.getElementById('scoreCircle');
|
|
195
|
+
const gradeColors = {
|
|
196
|
+
'A+': '#22c55e', 'A': '#4ade80', 'A-': '#86efac',
|
|
197
|
+
'B+': '#a3e635', 'B': '#facc15', 'B-': '#fbbf24',
|
|
198
|
+
'C+': '#f59e0b', 'C': '#fb923c', 'C-': '#f97316',
|
|
199
|
+
'D': '#ef4444', 'F': '#dc2626'
|
|
200
|
+
};
|
|
201
|
+
const color = data.grade_color || gradeColors[data.grade] || '#64748b';
|
|
202
|
+
|
|
203
|
+
circle.style.background = color;
|
|
204
|
+
circle.style.color = '#fff';
|
|
205
|
+
document.getElementById('gradeText').textContent = data.grade;
|
|
206
|
+
document.getElementById('scoreNumber').textContent = data.score + '/100';
|
|
207
|
+
document.getElementById('domainText').textContent = data.domain;
|
|
208
|
+
document.getElementById('gradeLabel').textContent = data.grade_label;
|
|
209
|
+
|
|
210
|
+
document.getElementById('fairnessVal').textContent = data.fairness_score + '/100';
|
|
211
|
+
document.getElementById('fairnessBar').style.width = data.fairness_score + '%';
|
|
212
|
+
document.getElementById('fairnessBar').style.background = data.fairness_score >= 70 ? '#22c55e' : data.fairness_score >= 50 ? '#f59e0b' : '#ef4444';
|
|
213
|
+
|
|
214
|
+
document.getElementById('securityVal').textContent = data.security_score + '/100';
|
|
215
|
+
document.getElementById('securityBar').style.width = data.security_score + '%';
|
|
216
|
+
document.getElementById('securityBar').style.background = data.security_score >= 70 ? '#22c55e' : data.security_score >= 50 ? '#f59e0b' : '#ef4444';
|
|
217
|
+
|
|
218
|
+
// Signals
|
|
219
|
+
const signalsList = document.getElementById('signalsList');
|
|
220
|
+
signalsList.innerHTML = '<h4>Analysis Signals</h4>';
|
|
221
|
+
if (data.details && data.details.signals) {
|
|
222
|
+
data.details.signals.forEach(s => {
|
|
223
|
+
const isPositive = s.impact.startsWith('+');
|
|
224
|
+
signalsList.innerHTML += '<div class="signal"><span class="name">' + s.signal.replace(/_/g, ' ') + '</span><span class="impact ' + (isPositive ? 'positive' : 'negative') + '">' + s.impact + '</span></div>';
|
|
225
|
+
});
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
// Badge code
|
|
229
|
+
document.getElementById('badgeCode').textContent = '<img src="https://webagentbridge.com/api/growth/trust/badge/' + data.domain + '" alt="WAB Score: ' + data.grade + '" />';
|
|
230
|
+
|
|
231
|
+
card.classList.add('visible');
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
function saveRecent(data) {
|
|
235
|
+
const existing = recentScores.findIndex(s => s.domain === data.domain);
|
|
236
|
+
if (existing >= 0) recentScores.splice(existing, 1);
|
|
237
|
+
recentScores.unshift({ domain: data.domain, score: data.score, grade: data.grade, grade_label: data.grade_label, grade_color: data.grade_color });
|
|
238
|
+
if (recentScores.length > 12) recentScores.pop();
|
|
239
|
+
localStorage.setItem('wab_recent_scores', JSON.stringify(recentScores));
|
|
240
|
+
renderRecent();
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
function renderRecent() {
|
|
244
|
+
const section = document.getElementById('recentSection');
|
|
245
|
+
const grid = document.getElementById('recentGrid');
|
|
246
|
+
if (recentScores.length === 0) { section.style.display = 'none'; return; }
|
|
247
|
+
section.style.display = 'block';
|
|
248
|
+
grid.innerHTML = recentScores.map(s => {
|
|
249
|
+
const gradeColors = { 'A+': '#22c55e', 'A': '#4ade80', 'A-': '#86efac', 'B+': '#a3e635', 'B': '#facc15', 'B-': '#fbbf24', 'C+': '#f59e0b', 'C': '#fb923c', 'C-': '#f97316', 'D': '#ef4444', 'F': '#dc2626' };
|
|
250
|
+
const color = s.grade_color || gradeColors[s.grade] || '#64748b';
|
|
251
|
+
return '<div class="recent-item" onclick="document.getElementById(\'domainInput\').value=\'' + s.domain + '\';checkScore();">' +
|
|
252
|
+
'<div class="mini-grade" style="background:' + color + '">' + s.grade + '</div>' +
|
|
253
|
+
'<div class="info"><div class="domain">' + s.domain + '</div><div class="meta">' + s.score + '/100 · ' + s.grade_label + '</div></div>' +
|
|
254
|
+
'</div>';
|
|
255
|
+
}).join('');
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
document.getElementById('domainInput').addEventListener('keydown', function(e) {
|
|
259
|
+
if (e.key === 'Enter') checkScore();
|
|
260
|
+
});
|
|
261
|
+
</script>
|
|
262
|
+
</body>
|
|
263
|
+
</html>
|
package/public/terms.html
CHANGED
|
@@ -7,8 +7,10 @@
|
|
|
7
7
|
<meta name="description" content="Terms of Service for Web Agent Bridge. EU and Dutch law compliant.">
|
|
8
8
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
9
9
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
10
|
-
<
|
|
11
|
-
<link rel="
|
|
10
|
+
<style>body{background:#0a0e1a;color:#f0f4ff;font-family:Inter,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;margin:0;min-height:100vh}</style>
|
|
11
|
+
<link rel="preload" href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;600&display=swap" as="style" onload="this.onload=null;this.rel='stylesheet'">
|
|
12
|
+
<noscript><link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;600&display=swap" rel="stylesheet"></noscript>
|
|
13
|
+
<link rel="stylesheet" href="/css/styles.css?v=3.0.1">
|
|
12
14
|
</head>
|
|
13
15
|
<body>
|
|
14
16
|
|
package/sdk/index.js
CHANGED
|
@@ -616,4 +616,10 @@ class WABAgentOS {
|
|
|
616
616
|
}
|
|
617
617
|
}
|
|
618
618
|
|
|
619
|
-
|
|
619
|
+
// Re-export WABToolkit from langchain package for convenience
|
|
620
|
+
let WABToolkit;
|
|
621
|
+
try { WABToolkit = require('../packages/langchain').WABToolkit; } catch {
|
|
622
|
+
try { WABToolkit = require('web-agent-bridge-langchain').WABToolkit; } catch {}
|
|
623
|
+
}
|
|
624
|
+
|
|
625
|
+
module.exports = { WABAgent, WABUniversalAgent, WABMultiAgent, WABAgentMesh, WABAgentOS, WABToolkit };
|
package/sdk/package.json
CHANGED
|
@@ -1,9 +1,20 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "web-agent-bridge-sdk",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.1",
|
|
4
4
|
"description": "SDK for building AI agents that interact with Web Agent Bridge (WAB)",
|
|
5
5
|
"main": "index.js",
|
|
6
|
+
"types": "index.d.ts",
|
|
6
7
|
"license": "MIT",
|
|
8
|
+
"author": "Web Agent Bridge <dev@webagentbridge.com>",
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "git+https://github.com/abokenan444/web-agent-bridge.git",
|
|
12
|
+
"directory": "sdk"
|
|
13
|
+
},
|
|
14
|
+
"homepage": "https://www.webagentbridge.com",
|
|
15
|
+
"bugs": {
|
|
16
|
+
"url": "https://github.com/abokenan444/web-agent-bridge/issues"
|
|
17
|
+
},
|
|
7
18
|
"keywords": [
|
|
8
19
|
"wab",
|
|
9
20
|
"ai-agent",
|