web-agent-bridge 3.3.0 → 3.4.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 (83) hide show
  1. package/LICENSE +12 -0
  2. package/README.ar.md +18 -0
  3. package/README.md +198 -1664
  4. package/bin/wab-init.js +223 -0
  5. package/examples/azure-dns-wab.js +83 -0
  6. package/examples/cloudflare-wab-dns.js +121 -0
  7. package/examples/cpanel-wab-dns.js +114 -0
  8. package/examples/dns-discovery-agent.js +166 -0
  9. package/examples/gcp-dns-wab.js +76 -0
  10. package/examples/governance-agent.js +169 -0
  11. package/examples/plesk-wab-dns.js +103 -0
  12. package/examples/route53-wab-dns.js +144 -0
  13. package/examples/safe-mode-agent.js +96 -0
  14. package/examples/wab-sign.js +74 -0
  15. package/examples/wab-verify.js +60 -0
  16. package/package.json +5 -5
  17. package/public/.well-known/wab.json +28 -0
  18. package/public/activate.html +368 -0
  19. package/public/adoption-metrics.html +188 -0
  20. package/public/api.html +1 -1
  21. package/public/azure-dns-integration.html +289 -0
  22. package/public/cloudflare-integration.html +380 -0
  23. package/public/cpanel-integration.html +398 -0
  24. package/public/css/styles.css +28 -0
  25. package/public/dashboard.html +1 -0
  26. package/public/dns.html +101 -172
  27. package/public/docs.html +1 -0
  28. package/public/gcp-dns-integration.html +318 -0
  29. package/public/growth.html +4 -2
  30. package/public/index.html +227 -31
  31. package/public/integrations.html +1 -1
  32. package/public/js/activate.js +145 -0
  33. package/public/js/auth-nav.js +34 -0
  34. package/public/js/dns.js +438 -0
  35. package/public/openapi.json +89 -0
  36. package/public/plesk-integration.html +375 -0
  37. package/public/premium.html +1 -1
  38. package/public/provider-onboarding.html +172 -0
  39. package/public/provider-sandbox.html +134 -0
  40. package/public/providers.html +359 -0
  41. package/public/registrar-integrations.html +141 -0
  42. package/public/robots.txt +12 -0
  43. package/public/route53-integration.html +531 -0
  44. package/public/shieldqr.html +231 -0
  45. package/public/sitemap.xml +6 -0
  46. package/public/wab-trust.html +200 -0
  47. package/public/wab-vs-protocols.html +210 -0
  48. package/public/whitepaper.html +449 -0
  49. package/sdk/auto-discovery.js +288 -0
  50. package/sdk/governance.js +262 -0
  51. package/sdk/index.js +13 -0
  52. package/sdk/package.json +2 -2
  53. package/sdk/safe-mode.js +221 -0
  54. package/server/index.js +144 -5
  55. package/server/migrations/007_governance.sql +106 -0
  56. package/server/migrations/008_plans.sql +144 -0
  57. package/server/migrations/009_shieldqr.sql +30 -0
  58. package/server/migrations/010_extended_trust.sql +33 -0
  59. package/server/models/adapters/mysql.js +1 -1
  60. package/server/models/adapters/postgresql.js +1 -1
  61. package/server/models/db.js +60 -1
  62. package/server/routes/admin-plans.js +76 -0
  63. package/server/routes/admin-premium.js +4 -2
  64. package/server/routes/admin-shieldqr.js +90 -0
  65. package/server/routes/admin-trust-monitor.js +83 -0
  66. package/server/routes/admin.js +289 -1
  67. package/server/routes/billing.js +16 -4
  68. package/server/routes/discovery.js +1933 -2
  69. package/server/routes/governance.js +208 -0
  70. package/server/routes/plans.js +33 -0
  71. package/server/routes/providers.js +650 -0
  72. package/server/routes/shieldqr.js +88 -0
  73. package/server/services/email.js +29 -0
  74. package/server/services/governance.js +466 -0
  75. package/server/services/plans.js +214 -0
  76. package/server/services/premium.js +1 -1
  77. package/server/services/provider-clients.js +740 -0
  78. package/server/services/shieldqr.js +322 -0
  79. package/server/services/ssl-inspector.js +42 -0
  80. package/server/services/ssl-monitor.js +167 -0
  81. package/server/services/stripe.js +18 -5
  82. package/server/services/vision.js +1 -1
  83. package/server/services/wab-crypto.js +178 -0
@@ -0,0 +1,96 @@
1
+ /**
2
+ * Demo3 — Safe Mode Agent
3
+ *
4
+ * Shows the difference between a domain that has WAB enabled (full trust,
5
+ * full execute) and one that doesn't (read-only / blocked).
6
+ *
7
+ * node examples/safe-mode-agent.js wab-site.com untrusted-site.com
8
+ *
9
+ * Or pass --policy=strict|standard|permissive to change the gate.
10
+ */
11
+
12
+ 'use strict';
13
+
14
+ const { WABSafeMode } = require('../sdk');
15
+
16
+ const args = process.argv.slice(2);
17
+ const flags = {};
18
+ const domains = [];
19
+ for (const a of args) {
20
+ if (a.startsWith('--')) {
21
+ const [k, v] = a.replace(/^--/, '').split('=');
22
+ flags[k] = v ?? true;
23
+ } else domains.push(a);
24
+ }
25
+ if (domains.length === 0) {
26
+ console.error('Usage: node examples/safe-mode-agent.js <domain1> [<domain2> ...] [--policy=standard]');
27
+ console.error(' [--api=https://your-wab.example.com]');
28
+ process.exit(2);
29
+ }
30
+
31
+ const safe = new WABSafeMode({
32
+ apiBase: flags.api || process.env.WAB_API_BASE || 'https://webagentbridge.com',
33
+ policy: flags.policy || 'standard',
34
+ });
35
+
36
+ const COLOR = {
37
+ reset: '\x1b[0m', dim: '\x1b[2m', bold: '\x1b[1m',
38
+ green: '\x1b[32m', yellow: '\x1b[33m', red: '\x1b[31m', cyan: '\x1b[36m',
39
+ };
40
+ function color(c, s) { return process.stdout.isTTY ? `${COLOR[c]}${s}${COLOR.reset}` : s; }
41
+ function levelColor(l) { return l >= 3 ? 'green' : l === 2 ? 'cyan' : l === 1 ? 'yellow' : 'red'; }
42
+
43
+ async function checkOne(d) {
44
+ const t0 = Date.now();
45
+ const v = await safe.evaluate(d, { live: !!flags.live });
46
+ const elapsed = Date.now() - t0;
47
+
48
+ console.log('');
49
+ console.log(color('bold', `── ${v.domain} ──────────────────────────────`));
50
+ console.log(`Level : ${color(levelColor(v.level), `L${v.level}`)} (${v.score_label} ${v.score})`);
51
+ console.log(`Verdict : ${color(v.verdict === 'allow' ? 'green' : v.verdict === 'restrict' ? 'yellow' : 'red', v.verdict.toUpperCase())}`);
52
+ console.log(`Execute : ${v.allow_execute ? color('green', '✓ allowed') : color('red', '✗ blocked')}`);
53
+ console.log(`Read : ${v.allow_read ? color('green', '✓ allowed') : color('red', '✗ blocked')}`);
54
+ console.log(`Reason : ${v.reason}`);
55
+ if (v.reasons && v.reasons.length) {
56
+ for (const r of v.reasons) {
57
+ const sev = r.severity === 'deny' ? 'red' : r.severity === 'restrict' ? 'yellow' : 'dim';
58
+ console.log(color('dim', ' · ') + color(sev, `[${r.severity}] ${r.code}`) + ' ' + (r.message || ''));
59
+ }
60
+ }
61
+ console.log(color('dim', ` (policy=${v.policy}, ${elapsed}ms)`));
62
+
63
+ // Simulate the agent acting under Safe Mode
64
+ try {
65
+ if (v.allow_execute) {
66
+ await safe.guardExecute(v.domain, async () => {
67
+ console.log(color('green', ` → Agent: executing full action on ${v.domain}`));
68
+ });
69
+ } else if (v.allow_read) {
70
+ await safe.guardRead(v.domain, async () => {
71
+ console.log(color('yellow', ` → Agent: read-only mode on ${v.domain}`));
72
+ });
73
+ } else {
74
+ console.log(color('red', ` → Agent: refusing to interact with ${v.domain}`));
75
+ }
76
+ } catch (err) {
77
+ console.log(color('red', ` → ${err.message}`));
78
+ }
79
+ }
80
+
81
+ (async () => {
82
+ console.log(color('bold', `WAB Safe Mode demo — policy=${safe.policy} api=${safe.apiBase}`));
83
+ for (const d of domains) {
84
+ try { await checkOne(d); } catch (e) { console.error(`Error checking ${d}: ${e.message}`); }
85
+ }
86
+ console.log('');
87
+
88
+ // Pick the most trusted target if multiple were given
89
+ if (domains.length > 1) {
90
+ const best = await safe.pickBest(domains);
91
+ if (best) {
92
+ console.log(color('bold', `Recommended target: `) + color(levelColor(best.level), best.domain) +
93
+ color('dim', ` (L${best.level}, score ${best.score})`));
94
+ }
95
+ }
96
+ })();
@@ -0,0 +1,74 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * wab-sign — generate Ed25519 keys and sign WAB discovery manifests.
4
+ *
5
+ * Usage:
6
+ * wab-sign keygen # print a new keypair (save private offline)
7
+ * wab-sign sign manifest.json key.priv # sign a manifest, write manifest.signed.json
8
+ * wab-sign txt <pubkey-b64> <endpoint> # print the matching _wab TXT line
9
+ *
10
+ * Examples:
11
+ * $ node wab-sign.js keygen > keys.json
12
+ * $ jq -r .private_key keys.json > key.priv
13
+ * $ node wab-sign.js sign wab.json key.priv
14
+ *
15
+ * $ node wab-sign.js txt <(jq -r .public_key keys.json) https://example.com/.well-known/wab.json
16
+ */
17
+
18
+ 'use strict';
19
+
20
+ const fs = require('fs');
21
+ const path = require('path');
22
+ const { generateKeyPair, signManifest, fingerprint } = require(
23
+ // try the bundled service first; fall back to a local copy if invoked from a downloads/ extract
24
+ fs.existsSync(path.join(__dirname, '..', 'server', 'services', 'wab-crypto.js'))
25
+ ? path.join(__dirname, '..', 'server', 'services', 'wab-crypto.js')
26
+ : './wab-crypto'
27
+ );
28
+
29
+ const [,, cmd, a1, a2] = process.argv;
30
+
31
+ function usage() {
32
+ console.error('Usage:');
33
+ console.error(' wab-sign keygen');
34
+ console.error(' wab-sign sign <manifest.json> <key.priv>');
35
+ console.error(' wab-sign txt <public-key-b64> <endpoint-url>');
36
+ process.exit(1);
37
+ }
38
+
39
+ if (!cmd) usage();
40
+
41
+ if (cmd === 'keygen') {
42
+ const kp = generateKeyPair();
43
+ process.stdout.write(JSON.stringify(kp, null, 2) + '\n');
44
+ process.stderr.write('\n[!] private_key is shown ONLY here. Save it offline immediately.\n');
45
+ process.stderr.write('[!] Publish public_key in your _wab DNS TXT as: pk=ed25519:' + kp.public_key + '\n');
46
+ process.exit(0);
47
+ }
48
+
49
+ if (cmd === 'sign') {
50
+ if (!a1 || !a2) usage();
51
+ const manifest = JSON.parse(fs.readFileSync(a1, 'utf8'));
52
+ const priv = fs.readFileSync(a2, 'utf8').trim();
53
+ const signed = signManifest(manifest, priv);
54
+ const out = a1.replace(/\.json$/, '') + '.signed.json';
55
+ fs.writeFileSync(out, JSON.stringify(signed, null, 2) + '\n');
56
+ console.log(`[OK] Signed manifest written: ${out}`);
57
+ console.log(`[OK] Signature key_id: ${signed.signature.key_id}`);
58
+ console.log(`[OK] Upload ${out} to https://${manifest.domain || '<your-domain>'}/.well-known/wab.json`);
59
+ process.exit(0);
60
+ }
61
+
62
+ if (cmd === 'txt') {
63
+ if (!a1 || !a2) usage();
64
+ const pub = a1.trim();
65
+ const endpoint = a2.trim();
66
+ if (!/^https:\/\//i.test(endpoint)) { console.error('endpoint must be HTTPS'); process.exit(1); }
67
+ const fp = fingerprint(pub);
68
+ console.log(`# _wab.${endpoint.replace(/^https?:\/\//,'').replace(/\/.*$/,'')} TXT record:`);
69
+ console.log(`v=wab1; endpoint=${endpoint}; pk=ed25519:${pub}`);
70
+ console.log(`# key_id (fingerprint): ${fp}`);
71
+ process.exit(0);
72
+ }
73
+
74
+ usage();
@@ -0,0 +1,60 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * wab-verify — full trust check on a domain's WAB DNS Discovery setup.
4
+ *
5
+ * Usage:
6
+ * wab-verify <domain> # full DNS + DNSSEC + signature trust report
7
+ * wab-verify --json <domain> # JSON output (for CI / scripts)
8
+ * wab-verify --strict <domain> # exit non-zero unless trust_score == 100
9
+ *
10
+ * Hits the public WAB Trust API at /api/discovery/trust/:domain.
11
+ * Override base URL with WAB_BASE_URL=https://your-instance.example.com
12
+ */
13
+
14
+ 'use strict';
15
+
16
+ const fetch = (() => { try { return require('node-fetch'); } catch { return globalThis.fetch; } })();
17
+
18
+ const args = process.argv.slice(2);
19
+ const json = args.includes('--json');
20
+ const strict = args.includes('--strict');
21
+ const domain = args.find(a => !a.startsWith('--'));
22
+ const BASE = process.env.WAB_BASE_URL || 'https://www.webagentbridge.com';
23
+
24
+ if (!domain) {
25
+ console.error('Usage: wab-verify [--json] [--strict] <domain>');
26
+ process.exit(2);
27
+ }
28
+
29
+ (async () => {
30
+ const r = await fetch(`${BASE}/api/discovery/trust/${encodeURIComponent(domain)}`);
31
+ if (!r.ok) { console.error(`HTTP ${r.status}`); process.exit(2); }
32
+ const data = await r.json();
33
+
34
+ if (json) {
35
+ process.stdout.write(JSON.stringify(data, null, 2) + '\n');
36
+ } else {
37
+ const c = data.checks || {};
38
+ const tick = (b) => b ? '✓' : '✗';
39
+ console.log(`\nWAB Trust Report — ${data.domain}`);
40
+ console.log('═'.repeat(50));
41
+ console.log(` Trust Score: ${data.trust_score}/100 [${data.trust_label.toUpperCase()}]`);
42
+ console.log(' ──────────────────────────────────────────────');
43
+ console.log(` ${tick(c.dns_resolved)} DNS _wab record present`);
44
+ console.log(` ${tick(c.dnssec_verified)} DNSSEC verified (AD flag)`);
45
+ console.log(` ${tick(c.has_public_key)} Public key in DNS (pk=${c.pk_algorithm || '—'})`);
46
+ console.log(` ${tick(c.https_endpoint && c.manifest_fetched)} HTTPS manifest reachable`);
47
+ console.log(` ${tick(c.signature_valid)} Manifest signature valid`);
48
+ console.log(' ──────────────────────────────────────────────');
49
+ if (data.public_key) console.log(` Key ID: ${data.public_key.fingerprint} (ed25519)`);
50
+ if (data.endpoint) console.log(` Endpoint: ${data.endpoint}`);
51
+ if (data.findings && data.findings.length) {
52
+ console.log('\n Findings:');
53
+ for (const f of data.findings) console.log(' • ' + f);
54
+ }
55
+ console.log('');
56
+ }
57
+
58
+ if (strict && data.trust_score < 100) process.exit(1);
59
+ process.exit(0);
60
+ })().catch(err => { console.error('[ERROR]', err.message); process.exit(2); });
package/package.json CHANGED
@@ -1,13 +1,14 @@
1
1
  {
2
2
  "name": "web-agent-bridge",
3
- "version": "3.3.0",
4
- "description": "Open AI↔Web protocol & agent platform: standardized command interface, sovereign browser, phone shield, DNS discovery, agent mesh, and unified API gateway for safe AI–website interaction",
3
+ "version": "3.4.0",
4
+ "description": "Open AI↔Web protocol & agent platform: standardized command interface, sovereign browser, ShieldQR trust verifier, SSL health monitor, zero-config adoption (Cloudflare/Vercel/Netlify/Next.js), DNS discovery, agent mesh, and unified API gateway for safe AI–website interaction",
5
5
  "author": "Web Agent Bridge <dev@webagentbridge.com>",
6
6
  "main": "server/index.js",
7
7
  "bin": {
8
8
  "web-agent-bridge": "./bin/cli.js",
9
9
  "wab": "./bin/cli.js",
10
- "wab-agent": "./bin/cli.js"
10
+ "wab-agent": "./bin/cli.js",
11
+ "wab-init": "./bin/wab-init.js"
11
12
  },
12
13
  "scripts": {
13
14
  "start": "node server/index.js",
@@ -74,9 +75,8 @@
74
75
  "express-rate-limit": "^7.4.1",
75
76
  "helmet": "^8.0.0",
76
77
  "jsonwebtoken": "^9.0.2",
77
- "nodemailer": "^8.0.3",
78
+ "nodemailer": "^8.0.7",
78
79
  "stripe": "^20.4.1",
79
- "uuid": "^10.0.0",
80
80
  "ws": "^8.20.0"
81
81
  },
82
82
  "devDependencies": {
@@ -0,0 +1,28 @@
1
+ {
2
+ "payload": {
3
+ "version": "wab1",
4
+ "type": "wab.trust",
5
+ "host": "www.webagentbridge.com",
6
+ "endpoint": "https://www.webagentbridge.com",
7
+ "issued_at": "2026-05-07T15:39:11.684Z",
8
+ "expires_at": "2027-05-07T15:39:11.684Z",
9
+ "capabilities": {
10
+ "discovery": true,
11
+ "shieldqr": true,
12
+ "governance": true,
13
+ "plans_api": "/api/plans",
14
+ "scan_api": "/api/shieldqr/scan"
15
+ },
16
+ "trust": {
17
+ "pk": "ed25519:sjxdiyuM+fnu2N6aLyk1VrDPkYgE5p0+pGb2sl3Y6hg=",
18
+ "ssl": {
19
+ "thumbprint": "420c036a9bc9ecf11292042e5bce9b82595497b81cbf051787e97318ed36d9da",
20
+ "expires": "2026-06-19T14:10:20.000Z",
21
+ "days_until_expiry": 42,
22
+ "issuer": "Let's Encrypt",
23
+ "status": "active"
24
+ }
25
+ }
26
+ },
27
+ "signature": "ed25519:S4GLDJCRNe1HR6lIYm0lUQqK1izP8BjbzU1n83pE/E+k6Zc6g/doOhd6OZNElhdAzwfczhut7LRuEgzn1oAxDw=="
28
+ }
@@ -0,0 +1,368 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en" dir="ltr">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>Activate WAB Discovery in One Click — Web Agent Bridge</title>
7
+ <meta name="description" content="Add one DNS TXT record and make your website instantly discoverable by AI agents. Step-by-step guide for Cloudflare, cPanel, GoDaddy, Namecheap and more.">
8
+ <link rel="preconnect" href="https://fonts.googleapis.com">
9
+ <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
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.2.0">
14
+ <style>
15
+ /* ─── Page-specific styles ─── */
16
+ .activate-hero {
17
+ padding: 120px 24px 60px;
18
+ text-align: center;
19
+ background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(99,102,241,0.18) 0%, transparent 70%);
20
+ }
21
+ .activate-hero h1 {
22
+ font-size: clamp(2rem, 5vw, 3.5rem);
23
+ font-weight: 900;
24
+ line-height: 1.1;
25
+ margin-bottom: 1.2rem;
26
+ }
27
+ .activate-hero .subtitle {
28
+ font-size: 1.2rem;
29
+ color: #94a3b8;
30
+ max-width: 640px;
31
+ margin: 0 auto 2rem;
32
+ }
33
+ .lang-toggle {
34
+ display: flex;
35
+ gap: 8px;
36
+ justify-content: center;
37
+ margin-bottom: 2.5rem;
38
+ }
39
+ .lang-toggle button {
40
+ padding: 8px 20px;
41
+ border-radius: 20px;
42
+ border: 1.5px solid #334155;
43
+ background: transparent;
44
+ color: #94a3b8;
45
+ cursor: pointer;
46
+ font-size: 0.9rem;
47
+ transition: all 0.2s;
48
+ }
49
+ .lang-toggle button.active {
50
+ background: linear-gradient(135deg, #6366f1, #8b5cf6);
51
+ border-color: transparent;
52
+ color: #fff;
53
+ font-weight: 600;
54
+ }
55
+ /* Steps */
56
+ .steps-section {
57
+ max-width: 860px;
58
+ margin: 0 auto;
59
+ padding: 0 24px 80px;
60
+ }
61
+ .steps-section h2 {
62
+ font-size: 1.8rem;
63
+ font-weight: 700;
64
+ margin-bottom: 2rem;
65
+ color: #e2e8f0;
66
+ }
67
+ .step-card {
68
+ background: rgba(30,41,59,0.7);
69
+ border: 1px solid rgba(99,102,241,0.2);
70
+ border-radius: 16px;
71
+ padding: 28px 32px;
72
+ margin-bottom: 24px;
73
+ position: relative;
74
+ overflow: hidden;
75
+ }
76
+ .step-card::before {
77
+ content: '';
78
+ position: absolute;
79
+ top: 0; left: 0;
80
+ width: 4px; height: 100%;
81
+ background: linear-gradient(180deg, #6366f1, #8b5cf6);
82
+ border-radius: 4px 0 0 4px;
83
+ }
84
+ .step-number {
85
+ display: inline-flex;
86
+ align-items: center;
87
+ justify-content: center;
88
+ width: 36px; height: 36px;
89
+ background: linear-gradient(135deg, #6366f1, #8b5cf6);
90
+ border-radius: 50%;
91
+ font-weight: 700;
92
+ font-size: 0.95rem;
93
+ margin-bottom: 12px;
94
+ }
95
+ .step-card h3 {
96
+ font-size: 1.15rem;
97
+ font-weight: 700;
98
+ margin: 0 0 10px;
99
+ color: #e2e8f0;
100
+ }
101
+ .step-card p {
102
+ color: #94a3b8;
103
+ margin: 0 0 16px;
104
+ line-height: 1.7;
105
+ }
106
+ .step-card .code-block {
107
+ background: #0f172a;
108
+ border: 1px solid #1e293b;
109
+ border-radius: 10px;
110
+ padding: 16px 20px;
111
+ font-family: 'JetBrains Mono', monospace;
112
+ font-size: 0.85rem;
113
+ color: #a5f3fc;
114
+ overflow-x: auto;
115
+ margin-top: 12px;
116
+ }
117
+ .step-card .code-block .label {
118
+ color: #64748b;
119
+ font-size: 0.78rem;
120
+ display: block;
121
+ margin-bottom: 6px;
122
+ }
123
+ .step-card .code-block .key { color: #f472b6; }
124
+ .step-card .code-block .val { color: #34d399; }
125
+ /* Screenshot */
126
+ .step-screenshot {
127
+ width: 100%;
128
+ border-radius: 10px;
129
+ border: 1px solid rgba(99,102,241,0.25);
130
+ margin-top: 16px;
131
+ }
132
+ /* Provider tabs */
133
+ .provider-tabs {
134
+ display: flex;
135
+ gap: 8px;
136
+ flex-wrap: wrap;
137
+ margin-bottom: 20px;
138
+ }
139
+ .provider-tab {
140
+ padding: 8px 16px;
141
+ border-radius: 8px;
142
+ border: 1px solid #334155;
143
+ background: transparent;
144
+ color: #94a3b8;
145
+ cursor: pointer;
146
+ font-size: 0.85rem;
147
+ transition: all 0.2s;
148
+ }
149
+ .provider-tab.active {
150
+ background: rgba(99,102,241,0.2);
151
+ border-color: #6366f1;
152
+ color: #a5b4fc;
153
+ }
154
+ .provider-content { display: none; }
155
+ .provider-content.active { display: block; }
156
+ /* Video section */
157
+ .video-section {
158
+ max-width: 860px;
159
+ margin: 0 auto;
160
+ padding: 0 24px 80px;
161
+ }
162
+ .video-section h2 {
163
+ font-size: 1.8rem;
164
+ font-weight: 700;
165
+ margin-bottom: 1.5rem;
166
+ color: #e2e8f0;
167
+ }
168
+ .video-wrapper {
169
+ background: #0f172a;
170
+ border: 1px solid rgba(99,102,241,0.25);
171
+ border-radius: 16px;
172
+ overflow: hidden;
173
+ aspect-ratio: 16/9;
174
+ display: flex;
175
+ align-items: center;
176
+ justify-content: center;
177
+ }
178
+ .video-wrapper video {
179
+ width: 100%;
180
+ height: 100%;
181
+ object-fit: cover;
182
+ }
183
+ /* Verifier CTA */
184
+ .verifier-cta {
185
+ background: linear-gradient(135deg, rgba(99,102,241,0.15), rgba(139,92,246,0.15));
186
+ border: 1px solid rgba(99,102,241,0.3);
187
+ border-radius: 20px;
188
+ padding: 48px 32px;
189
+ text-align: center;
190
+ max-width: 640px;
191
+ margin: 0 auto 80px;
192
+ }
193
+ .verifier-cta h2 {
194
+ font-size: 1.6rem;
195
+ font-weight: 700;
196
+ margin-bottom: 12px;
197
+ }
198
+ .verifier-cta p {
199
+ color: #94a3b8;
200
+ margin-bottom: 24px;
201
+ }
202
+ /* Badge */
203
+ .badge-row {
204
+ display: flex;
205
+ gap: 12px;
206
+ flex-wrap: wrap;
207
+ justify-content: center;
208
+ margin-bottom: 2rem;
209
+ }
210
+ .badge-img {
211
+ height: 28px;
212
+ }
213
+ /* RTL support */
214
+ html[dir="rtl"] .step-card::before {
215
+ left: auto; right: 0;
216
+ border-radius: 0 4px 4px 0;
217
+ }
218
+ html[dir="rtl"] .step-card {
219
+ text-align: right;
220
+ }
221
+ </style>
222
+ </head>
223
+ <body>
224
+ <!-- ═══════════ NAVBAR ═══════════ -->
225
+ <nav class="navbar" id="navbar">
226
+ <div class="container">
227
+ <a href="/" class="navbar-brand">
228
+ <div class="brand-icon">⚡</div>
229
+ <span>WAB</span>
230
+ </a>
231
+ <ul class="navbar-links">
232
+ <li><a href="/" data-i18n="nav_home">Home</a></li>
233
+ <li><a href="/integrations" data-i18n="nav_integrations">Integrations</a></li>
234
+ <li><a href="/dns" data-i18n="nav_dns">DNS Discovery</a></li>
235
+ <li><a href="/phone-shield" data-i18n="nav_phone">Phone Shield</a></li>
236
+ <li><a href="/sovereign" data-i18n="nav_sovereign">Sovereign</a></li>
237
+ <li><a href="/docs" data-i18n="nav_docs">Docs</a></li>
238
+ </ul>
239
+ <div class="navbar-actions">
240
+ <a href="/login" class="btn btn-ghost" data-wab-auth="guest">Sign In</a>
241
+ <a href="/dashboard" class="btn btn-ghost" data-wab-auth="signed-in" style="display:none">Dashboard</a>
242
+ <a href="/register" class="btn btn-primary btn-sm" data-wab-auth="guest">Get Started</a>
243
+ </div>
244
+ <button class="mobile-menu-btn">☰</button>
245
+ </div>
246
+ </nav>
247
+
248
+ <!-- ═══════════ HERO ═══════════ -->
249
+ <section class="activate-hero">
250
+ <div class="badge-row">
251
+ <img src="https://img.shields.io/badge/DNS%20Discovery-One--Click-6366f1?style=flat-square&logo=dns&logoColor=white" alt="One-Click DNS Discovery" class="badge-img">
252
+ <img src="https://img.shields.io/badge/Protocol-WAB%20v1-8b5cf6?style=flat-square" alt="WAB v1" class="badge-img">
253
+ <img src="https://img.shields.io/badge/Verified-Live%20on%20webagentbridge.com-10b981?style=flat-square" alt="Live Verified" class="badge-img">
254
+ </div>
255
+ <div class="lang-toggle">
256
+ <button id="btnEn" class="active" onclick="setActivateLang('en')">English</button>
257
+ <button id="btnAr" onclick="setActivateLang('ar')">العربية</button>
258
+ </div>
259
+ <h1 data-i18n="hero_title">Activate WAB Discovery<br><span class="gradient-text">in One Click</span></h1>
260
+ <p class="subtitle" data-i18n="hero_sub">Add a single DNS TXT record and make your website instantly discoverable by AI agents — no code changes required.</p>
261
+ <div style="display:flex;gap:12px;justify-content:center;flex-wrap:wrap;">
262
+ <a href="#steps" class="btn btn-primary btn-lg" data-i18n="cta_guide">View Setup Guide</a>
263
+ <a href="/dns" class="btn btn-secondary btn-lg" data-i18n="cta_verify">Live Verifier</a>
264
+ </div>
265
+ </section>
266
+
267
+ <!-- ═══════════ VIDEO ═══════════ -->
268
+ <section class="video-section">
269
+ <h2 data-i18n="video_title">Watch: Full Setup in 40 Seconds</h2>
270
+ <div class="video-wrapper">
271
+ <video controls poster="/img/dns-video-poster.jpg">
272
+ <source src="/videos/dns_discovery_demo.mp4" type="video/mp4">
273
+ <p data-i18n="video_fallback">Your browser does not support the video tag. <a href="/videos/dns_discovery_demo.mp4">Download the video</a>.</p>
274
+ </video>
275
+ </div>
276
+ </section>
277
+
278
+ <!-- ═══════════ STEPS ═══════════ -->
279
+ <section class="steps-section" id="steps">
280
+ <h2 data-i18n="steps_title">Step-by-Step Setup Guide</h2>
281
+
282
+ <!-- Step 1 -->
283
+ <div class="step-card">
284
+ <div class="step-number">1</div>
285
+ <h3 data-i18n="step1_title">Log In to Your DNS Provider</h3>
286
+ <p data-i18n="step1_desc">Sign in to your domain registrar or DNS hosting dashboard. Common providers include Cloudflare, cPanel, GoDaddy, and Namecheap. Navigate to the DNS Management or DNS Records section.</p>
287
+ <div class="provider-tabs">
288
+ <button class="provider-tab active" onclick="showProvider('cloudflare', this)">Cloudflare</button>
289
+ <button class="provider-tab" onclick="showProvider('cpanel', this)">cPanel</button>
290
+ <button class="provider-tab" onclick="showProvider('godaddy', this)">GoDaddy</button>
291
+ <button class="provider-tab" onclick="showProvider('namecheap', this)">Namecheap</button>
292
+ </div>
293
+ <div id="prov-cloudflare" class="provider-content active">
294
+ <p style="color:#94a3b8;font-size:0.9rem;" data-i18n="prov_cloudflare">Go to <strong>dash.cloudflare.com</strong> → Select your domain → Click <strong>DNS</strong> in the top navigation → Click <strong>+ Add record</strong>.</p>
295
+ </div>
296
+ <div id="prov-cpanel" class="provider-content">
297
+ <p style="color:#94a3b8;font-size:0.9rem;" data-i18n="prov_cpanel">Log in to cPanel → Scroll to <strong>Domains</strong> section → Click <strong>Zone Editor</strong> → Click <strong>Manage</strong> next to your domain → Click <strong>+ Add Record</strong>.</p>
298
+ </div>
299
+ <div id="prov-godaddy" class="provider-content">
300
+ <p style="color:#94a3b8;font-size:0.9rem;" data-i18n="prov_godaddy">Log in to <strong>godaddy.com</strong> → My Products → Click <strong>DNS</strong> next to your domain → Click <strong>Add New Record</strong>.</p>
301
+ </div>
302
+ <div id="prov-namecheap" class="provider-content">
303
+ <p style="color:#94a3b8;font-size:0.9rem;" data-i18n="prov_namecheap">Log in to <strong>namecheap.com</strong> → Domain List → Click <strong>Manage</strong> → Click <strong>Advanced DNS</strong> tab → Click <strong>Add New Record</strong>.</p>
304
+ </div>
305
+ </div>
306
+
307
+ <!-- Step 2 -->
308
+ <div class="step-card">
309
+ <div class="step-number">2</div>
310
+ <h3 data-i18n="step2_title">Add the TXT Record</h3>
311
+ <p data-i18n="step2_desc">Create a new DNS TXT record with exactly these values. Replace <code style="color:#a5f3fc">yourdomain.com</code> with your actual domain.</p>
312
+ <div class="code-block">
313
+ <span class="label">DNS TXT Record</span>
314
+ <span class="key">Type:</span> <span class="val">TXT</span><br>
315
+ <span class="key">Name:</span> <span class="val">_wab</span><br>
316
+ <span class="key">Value:</span> <span class="val">v=wab1; endpoint=https://yourdomain.com/.well-known/wab.json</span><br>
317
+ <span class="key">TTL:</span> <span class="val">Auto (3600)</span>
318
+ </div>
319
+ </div>
320
+
321
+ <!-- Step 3 -->
322
+ <div class="step-card">
323
+ <div class="step-number">3</div>
324
+ <h3 data-i18n="step3_title">Create the wab.json Capabilities File</h3>
325
+ <p data-i18n="step3_desc">Create the file <code style="color:#a5f3fc">/.well-known/wab.json</code> on your web server. This file describes your site's capabilities to AI agents.</p>
326
+ <div class="code-block">
327
+ <span class="label">/.well-known/wab.json</span>
328
+ {<br>
329
+ &nbsp;&nbsp;<span class="key">"version"</span>: <span class="val">"wab1"</span>,<br>
330
+ &nbsp;&nbsp;<span class="key">"name"</span>: <span class="val">"Your Site Name"</span>,<br>
331
+ &nbsp;&nbsp;<span class="key">"description"</span>: <span class="val">"What your site does"</span>,<br>
332
+ &nbsp;&nbsp;<span class="key">"endpoint"</span>: <span class="val">"https://yourdomain.com/.well-known/wab.json"</span>,<br>
333
+ &nbsp;&nbsp;<span class="key">"capabilities"</span>: [<span class="val">"browse"</span>, <span class="val">"api"</span>]<br>
334
+ }
335
+ </div>
336
+ </div>
337
+
338
+ <!-- Step 4 -->
339
+ <div class="step-card">
340
+ <div class="step-number">4</div>
341
+ <h3 data-i18n="step4_title">Verify Your Setup</h3>
342
+ <p data-i18n="step4_desc">DNS propagation takes a few minutes. Use the Live Verifier to confirm your record is active. The verifier queries DNS over HTTPS (DoH) — no data is sent to our servers.</p>
343
+ <div style="background:#0f172a;border:1px solid #1e293b;border-radius:10px;padding:20px;margin-top:12px;">
344
+ <div style="display:flex;gap:12px;align-items:center;flex-wrap:wrap;">
345
+ <input id="activateDomain" type="text" placeholder="yourdomain.com" style="flex:1;min-width:200px;padding:10px 16px;background:#1e293b;border:1px solid #334155;border-radius:8px;color:#f0f4ff;font-size:0.9rem;outline:none;">
346
+ <button id="activateVerifyBtn" style="padding:10px 24px;background:linear-gradient(135deg,#6366f1,#8b5cf6);border:none;border-radius:8px;color:#fff;font-weight:600;cursor:pointer;font-size:0.9rem;" data-i18n="verify_btn">Verify Now</button>
347
+ </div>
348
+ <div id="activateResult" style="margin-top:16px;font-family:'JetBrains Mono',monospace;font-size:0.82rem;display:none;"></div>
349
+ </div>
350
+ </div>
351
+ </section>
352
+
353
+ <!-- ═══════════ CTA ═══════════ -->
354
+ <div style="padding:0 24px;">
355
+ <div class="verifier-cta">
356
+ <h2 data-i18n="cta_title">Your Domain is Now AI-Ready</h2>
357
+ <p data-i18n="cta_desc">Once verified, AI agents using the WAB protocol can discover your site's capabilities automatically — no manual configuration needed on their end.</p>
358
+ <div style="display:flex;gap:12px;justify-content:center;flex-wrap:wrap;">
359
+ <a href="/dns" class="btn btn-primary" data-i18n="cta_full_guide">Full DNS Guide</a>
360
+ <a href="/docs" class="btn btn-secondary" data-i18n="cta_docs">Read the Docs</a>
361
+ </div>
362
+ </div>
363
+ </div>
364
+
365
+ <script src="/js/auth-nav.js"></script>
366
+ <script src="/js/activate.js"></script>
367
+ </body>
368
+ </html>