@dallask/a11y-mcp-srv 1.0.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 (81) hide show
  1. package/LICENSE +21 -0
  2. package/NOTICE +9 -0
  3. package/README.md +1328 -0
  4. package/bin/server.js +8 -0
  5. package/dist/core/accessibility-runner.d.ts +123 -0
  6. package/dist/core/accessibility-runner.d.ts.map +1 -0
  7. package/dist/core/accessibility-runner.js +465 -0
  8. package/dist/core/accessibility-runner.js.map +1 -0
  9. package/dist/core/basic-auth.d.ts +35 -0
  10. package/dist/core/basic-auth.d.ts.map +1 -0
  11. package/dist/core/basic-auth.js +52 -0
  12. package/dist/core/basic-auth.js.map +1 -0
  13. package/dist/core/config.d.ts +44 -0
  14. package/dist/core/config.d.ts.map +1 -0
  15. package/dist/core/config.js +163 -0
  16. package/dist/core/config.js.map +1 -0
  17. package/dist/core/error-handler.d.ts +66 -0
  18. package/dist/core/error-handler.d.ts.map +1 -0
  19. package/dist/core/error-handler.js +305 -0
  20. package/dist/core/error-handler.js.map +1 -0
  21. package/dist/core/normalize-audit-result.d.ts +18 -0
  22. package/dist/core/normalize-audit-result.d.ts.map +1 -0
  23. package/dist/core/normalize-audit-result.js +118 -0
  24. package/dist/core/normalize-audit-result.js.map +1 -0
  25. package/dist/core/playwright-bootstrap.d.ts +21 -0
  26. package/dist/core/playwright-bootstrap.d.ts.map +1 -0
  27. package/dist/core/playwright-bootstrap.js +144 -0
  28. package/dist/core/playwright-bootstrap.js.map +1 -0
  29. package/dist/core/progress-streamer.d.ts +44 -0
  30. package/dist/core/progress-streamer.d.ts.map +1 -0
  31. package/dist/core/progress-streamer.js +160 -0
  32. package/dist/core/progress-streamer.js.map +1 -0
  33. package/dist/core/result-processor.d.ts +86 -0
  34. package/dist/core/result-processor.d.ts.map +1 -0
  35. package/dist/core/result-processor.js +475 -0
  36. package/dist/core/result-processor.js.map +1 -0
  37. package/dist/core/session-manager.d.ts +73 -0
  38. package/dist/core/session-manager.d.ts.map +1 -0
  39. package/dist/core/session-manager.js +243 -0
  40. package/dist/core/session-manager.js.map +1 -0
  41. package/dist/server.d.ts +10 -0
  42. package/dist/server.d.ts.map +1 -0
  43. package/dist/server.js +1439 -0
  44. package/dist/server.js.map +1 -0
  45. package/dist/tools/aggregate.d.ts +26 -0
  46. package/dist/tools/aggregate.d.ts.map +1 -0
  47. package/dist/tools/aggregate.js +340 -0
  48. package/dist/tools/aggregate.js.map +1 -0
  49. package/dist/tools/analysis.d.ts +68 -0
  50. package/dist/tools/analysis.d.ts.map +1 -0
  51. package/dist/tools/analysis.js +1199 -0
  52. package/dist/tools/analysis.js.map +1 -0
  53. package/dist/tools/audit.d.ts +38 -0
  54. package/dist/tools/audit.d.ts.map +1 -0
  55. package/dist/tools/audit.js +472 -0
  56. package/dist/tools/audit.js.map +1 -0
  57. package/dist/tools/comparison.d.ts +27 -0
  58. package/dist/tools/comparison.d.ts.map +1 -0
  59. package/dist/tools/comparison.js +499 -0
  60. package/dist/tools/comparison.js.map +1 -0
  61. package/dist/tools/export.d.ts +43 -0
  62. package/dist/tools/export.d.ts.map +1 -0
  63. package/dist/tools/export.js +746 -0
  64. package/dist/tools/export.js.map +1 -0
  65. package/dist/tools/filter.d.ts +26 -0
  66. package/dist/tools/filter.d.ts.map +1 -0
  67. package/dist/tools/filter.js +244 -0
  68. package/dist/tools/filter.js.map +1 -0
  69. package/dist/tools/session.d.ts +26 -0
  70. package/dist/tools/session.d.ts.map +1 -0
  71. package/dist/tools/session.js +228 -0
  72. package/dist/tools/session.js.map +1 -0
  73. package/dist/tools/visualize.d.ts +26 -0
  74. package/dist/tools/visualize.d.ts.map +1 -0
  75. package/dist/tools/visualize.js +942 -0
  76. package/dist/tools/visualize.js.map +1 -0
  77. package/dist/types/index.d.ts +792 -0
  78. package/dist/types/index.d.ts.map +1 -0
  79. package/dist/types/index.js +24 -0
  80. package/dist/types/index.js.map +1 -0
  81. package/package.json +69 -0
package/README.md ADDED
@@ -0,0 +1,1328 @@
1
+ # ♿ Accessibility MCP Server
2
+
3
+ A Model Context Protocol (MCP) server that provides conversational, actionable accessibility testing. This server exposes accessibility auditing tools that can be used by AI agents and chat interfaces.
4
+
5
+ ## ✨ Features
6
+
7
+ - **Conversational Results**: Results formatted for natural language understanding, not raw data
8
+ - **Session Management**: Reusable authenticated sessions for testing protected pages
9
+ - **Tag Filtering**: Filter results by specific WCAG levels (wcag2a, wcag2aa, wcag21a, etc.)
10
+ - **Educational Focus**: Tools that explain issues in plain language with code examples
11
+ - **Code-Level Fixes**: Actual before/after code examples, not just descriptions
12
+ - **Progress Updates**: Streaming progress for long-running batch operations
13
+ - **Smart Prioritization**: AI-powered issue prioritization with quick wins identification
14
+ - **Compliance Reports**: Automated VPAT/WCAG/ADA compliance documentation
15
+ - **Trend Tracking**: Historical data and predictions for accessibility improvements
16
+
17
+ ## 📋 Prerequisites
18
+
19
+ - **Node.js 18+** (for `npx` command)
20
+ - That's it! Everything else is handled automatically.
21
+
22
+ ## 🚀 Quick Start (Using Published Package)
23
+
24
+ ### Step 1: Add to Your MCP Client Configuration
25
+
26
+ Add this server to your MCP client configuration (e.g., Claude Desktop, Cursor):
27
+
28
+ #### Claude Desktop Configuration
29
+
30
+ Edit `~/Library/Application Support/Claude/claude_desktop_config.json` (macOS) or `%APPDATA%\Claude\claude_desktop_config.json` (Windows):
31
+
32
+ ```json
33
+ {
34
+ "mcpServers": {
35
+ "accessibility-audit": {
36
+ "command": "npx",
37
+ "args": ["-y", "@dallask/a11y-mcp-srv"]
38
+ }
39
+ }
40
+ }
41
+ ```
42
+
43
+ #### Cursor Configuration
44
+
45
+ Add to your Cursor MCP settings (`~/.cursor/mcp.json` or Cursor Settings → MCP):
46
+
47
+ ```json
48
+ {
49
+ "mcpServers": {
50
+ "accessibility-audit": {
51
+ "command": "npx",
52
+ "args": ["-y", "@dallask/a11y-mcp-srv"]
53
+ }
54
+ }
55
+ }
56
+ ```
57
+
58
+ ### Step 2: Restart Your MCP Client
59
+
60
+ Restart Claude Desktop or Cursor to load the new MCP server configuration.
61
+
62
+ ### Step 3: Start Using It!
63
+
64
+ That's it! You're ready to use all 25+ accessibility tools. The package will be automatically downloaded and cached by `npx` on first use.
65
+
66
+ **How it works:**
67
+ - `npx` automatically downloads and runs the package if needed
68
+ - The `-y` flag answers "yes" to prompts (non-interactive)
69
+ - Playwright browsers install automatically on first run
70
+ - No manual installation, building, or configuration needed!
71
+
72
+ ## ⚙️ Configuration (Environment Variables)
73
+
74
+ You can configure the server via your MCP client’s `env` section (e.g. Cursor MCP settings or Claude Desktop config). These options follow the same style as [joe-watkins/accessibility-testing-mcp](https://github.com/joe-watkins/accessibility-testing-mcp).
75
+
76
+ | Variable | Values | Default | Description |
77
+ |----------|--------|---------|-------------|
78
+ | `A11Y_ENGINE` | `axe`, `ace` | `axe` | Testing engine: **axe-core** (Deque) or **IBM Equal Access** (ACE). |
79
+ | `WCAG_LEVEL` | `2.0_A`, `2.0_AA`, `2.0_AAA`, `2.1_A`, `2.1_AA`, `2.1_AAA`, `2.2_A`, `2.2_AA`, `2.2_AAA` | `2.1_AA` | WCAG version and level used when the tool does not specify tags. |
80
+ | `BEST_PRACTICES` | `true`, `false` | `true` | Include best-practice rules (adds `best-practice` tag when no tags are provided). |
81
+ | `SCREEN_SIZES` | Comma-separated `WIDTHxHEIGHT` | `1280x1024` | Viewport size(s) for the browser (e.g. `1280x1024,320x640`). The first size is used for audits. |
82
+ | `HEADLESS_BROWSER` | `true`, `false` | `true` | Run the browser in headless mode; set to `false` to show the browser window. |
83
+
84
+ ### Example MCP config with env
85
+
86
+ **Cursor** (`~/.cursor/mcp.json` or Settings → MCP):
87
+
88
+ ```json
89
+ {
90
+ "mcpServers": {
91
+ "accessibility-audit": {
92
+ "command": "npx",
93
+ "args": ["-y", "@dallask/a11y-mcp-srv"],
94
+ "env": {
95
+ "A11Y_ENGINE": "axe",
96
+ "WCAG_LEVEL": "2.2_AA",
97
+ "BEST_PRACTICES": "true",
98
+ "SCREEN_SIZES": "1280x1024,320x640",
99
+ "HEADLESS_BROWSER": "true"
100
+ }
101
+ }
102
+ }
103
+ }
104
+ ```
105
+
106
+ **Claude Desktop** (`claude_desktop_config.json`):
107
+
108
+ ```json
109
+ {
110
+ "mcpServers": {
111
+ "accessibility-audit": {
112
+ "command": "npx",
113
+ "args": ["-y", "@dallask/a11y-mcp-srv"],
114
+ "env": {
115
+ "A11Y_ENGINE": "axe",
116
+ "WCAG_LEVEL": "2.2_AA",
117
+ "BEST_PRACTICES": "true",
118
+ "HEADLESS_BROWSER": "true"
119
+ }
120
+ }
121
+ }
122
+ }
123
+ ```
124
+
125
+ Tool parameters (e.g. `engine`, `tags`) override these defaults when provided in a request.
126
+
127
+ ## 🎉 Awesome Things You Can Do
128
+
129
+ ### 🔍 **Comprehensive Accessibility Auditing**
130
+ - **Audit any website** - Single URLs, multiple pages, or entire sites
131
+ - **Test protected pages** - Authenticated session management for login-protected content
132
+ - **Batch processing** - Test multiple URLs in parallel with progress tracking
133
+ - **WCAG compliance** - Check against WCAG 2.0, 2.1 (Levels A, AA, AAA) and best practices
134
+
135
+ ### 🎯 **Smart Prioritization & Quick Wins**
136
+ - **Identify critical blockers** - Find must-fix issues that block users
137
+ - **Quick wins detection** - Easy fixes with high impact
138
+ - **Intelligent prioritization** - Sort by impact, WCAG level, fixability, or user impact
139
+ - **Focus your efforts** - Know exactly what to fix first
140
+
141
+ ### 💻 **Code-Level Fixes**
142
+ - **Before/after code examples** - See exactly what needs to change
143
+ - **Copy-paste ready solutions** - Actual code, not just descriptions
144
+ - **Multiple formats** - Markdown, HTML, or JSON output
145
+ - **Specific fix suggestions** - Targeted solutions for each issue
146
+
147
+ ### 📚 **Educational Resources**
148
+ - **Plain language explanations** - Understand what each issue means
149
+ - **Why it matters** - Learn the user impact
150
+ - **How to fix** - Step-by-step guidance with examples
151
+ - **WCAG references** - Direct links to accessibility standards
152
+ - **Common mistakes** - Learn from typical errors
153
+
154
+ ### 📊 **Compliance & Reporting**
155
+ - **VPAT reports** - Generate Voluntary Product Accessibility Template documentation
156
+ - **WCAG compliance reports** - Detailed compliance breakdowns
157
+ - **ADA reports** - Americans with Disabilities Act compliance
158
+ - **Section 508 reports** - Federal accessibility compliance
159
+ - **Executive summaries** - High-level reports for stakeholders
160
+
161
+ ### 📈 **Tracking & Comparison**
162
+ - **Before/after comparison** - Track improvements over time
163
+ - **Trend analysis** - Historical data and predictions
164
+ - **Score tracking** - Monitor accessibility scores
165
+ - **Visual diffs** - See what changed between audits
166
+
167
+ ### 📤 **Export & Share**
168
+ - **CSV export** - Import into Excel for analysis
169
+ - **Excel export** - Professional reports with charts and formatting
170
+ - **JSON export** - For API integration and data processing
171
+ - **HTML reports** - Standalone web reports with visualizations
172
+ - **Dashboard generation** - Visual summaries with charts
173
+
174
+ ### 🔎 **Filtering & Search**
175
+ - **Filter by criteria** - Rule IDs, categories, impact levels, WCAG levels
176
+ - **Search issues** - Find specific problems quickly
177
+ - **Include/exclude modes** - Focus on what matters
178
+ - **Element type filtering** - Find issues in specific HTML elements
179
+
180
+ ### 📊 **Statistics & Aggregation**
181
+ - **Site-wide analysis** - Combine multiple audit results
182
+ - **Detailed statistics** - Breakdowns by category, impact, WCAG level
183
+ - **Aggregated summaries** - Overall site accessibility metrics
184
+ - **Grouping options** - Organize by URL, category, rule, or impact
185
+
186
+ ### 🎨 **Visualization**
187
+ - **Dashboards** - Visual summaries with key metrics
188
+ - **Charts** - Score trends and category breakdowns
189
+ - **Multiple formats** - Text, Markdown, HTML, JSON
190
+ - **Executive reports** - High-level summaries for stakeholders
191
+
192
+ ## 💡 Real-World Use Cases
193
+
194
+ ### For Developers
195
+ - Get code-level fixes for accessibility issues
196
+ - Learn accessibility concepts with educational explanations
197
+ - Integrate into CI/CD pipelines
198
+ - Export results for team sharing
199
+
200
+ ### For QA Teams
201
+ - Batch test multiple pages efficiently
202
+ - Track accessibility over time
203
+ - Generate compliance reports
204
+ - Compare before/after deployments
205
+
206
+ ### For Product Managers
207
+ - Executive summary reports
208
+ - Compliance documentation (VPAT, ADA)
209
+ - Dashboard visualizations
210
+ - Track accessibility scores over time
211
+
212
+ ### For Compliance Teams
213
+ - Generate VPAT reports automatically
214
+ - WCAG compliance documentation
215
+ - Section 508 compliance checks
216
+ - Detailed remediation plans
217
+
218
+ ## 🎬 Quick Usage Example
219
+
220
+ Once configured, you can immediately start using the accessibility tools in your AI assistant:
221
+
222
+ **Example: Audit a website**
223
+ ```
224
+ "Audit https://example.com for accessibility issues"
225
+ ```
226
+
227
+ **Example: Get quick fixes**
228
+ ```
229
+ "Show me quick fixes for the accessibility issues on cursor.com"
230
+ ```
231
+
232
+ **Example: Generate compliance report**
233
+ ```
234
+ "Generate a VPAT report for docs.atlan.com"
235
+ ```
236
+
237
+ **Example: Compare before/after**
238
+ ```
239
+ "Compare the accessibility of example.com before and after the redesign"
240
+ ```
241
+
242
+ The AI assistant will automatically use the appropriate tools to fulfill your requests!
243
+
244
+ ## 🛠️ Available Tools
245
+
246
+ ### Tier 1: Core Audit Tools
247
+
248
+ #### `audit_url` - Single URL Audit
249
+
250
+ Test a single URL for accessibility issues with conversational, actionable results.
251
+
252
+ **Inputs:**
253
+ - `url` (required): Full URL or relative path
254
+ - `domain` (optional): Base domain if URL is relative
255
+ - `tags` (optional): Array of accessibility tags to check (e.g., `["wcag2a", "wcag2aa", "wcag21a", "best-practice"]`). If not provided, all tags are checked.
256
+ - `waitForLoad` (optional): Wait strategy - `"networkidle"` (default) | `"load"` | `"domcontentloaded"`
257
+ - `timeout` (optional): Timeout in seconds (default: 30)
258
+
259
+ **Example:**
260
+ ```json
261
+ {
262
+ "url": "https://example.com",
263
+ "tags": ["wcag21aa"],
264
+ "timeout": 45
265
+ }
266
+ ```
267
+
268
+ **Output:** Structured JSON with summary, prioritized violations, WCAG compliance breakdown, quick fix suggestions, and conversational explanation.
269
+
270
+ #### `audit_multiple_urls` - Batch Audit
271
+
272
+ Test multiple URLs efficiently with progress updates.
273
+
274
+ **Inputs:**
275
+ - `urls` (required): Array of URLs or comma-separated string
276
+ - `domain` (optional): Base domain
277
+ - `tags` (optional): Array of accessibility tags
278
+ - `parallel` (optional): Number of parallel tests (default: 1)
279
+ - `continueOnError` (optional): Continue if one fails (default: true)
280
+
281
+ **Example:**
282
+ ```json
283
+ {
284
+ "urls": ["/home", "/about", "/contact"],
285
+ "domain": "https://example.com",
286
+ "tags": ["wcag2aa"],
287
+ "parallel": 2
288
+ }
289
+ ```
290
+
291
+ **Output:** Per-URL results, aggregated summary, and progress updates (streaming).
292
+
293
+ #### `audit_site` - Smart Site Audit
294
+
295
+ Intelligent site-wide audit with prioritization.
296
+
297
+ **Inputs:**
298
+ - `domain` (required): Base domain
299
+ - `tags` (optional): Array of accessibility tags. Applied to all pages.
300
+ - `strategy` (optional): `"critical"` | `"comprehensive"` | `"custom"` (default: `"comprehensive"`)
301
+ - `maxPages` (optional): Maximum pages to test (default: 50)
302
+ - `priorityPaths` (optional): Array of high-priority paths to test first
303
+
304
+ **Example:**
305
+ ```json
306
+ {
307
+ "domain": "https://example.com",
308
+ "strategy": "critical",
309
+ "priorityPaths": ["/", "/login", "/checkout"],
310
+ "tags": ["wcag21aa"],
311
+ "maxPages": 20
312
+ }
313
+ ```
314
+
315
+ **Output:** Prioritized results (critical pages first), site-wide score, and trend analysis if previous audits exist.
316
+
317
+ ### Tier 2: Session Management
318
+
319
+ #### `create_session` - Authenticated Session
320
+
321
+ Create a reusable authenticated session for testing protected pages.
322
+
323
+ **Inputs:**
324
+ - `domain` (required): Base domain
325
+ - `username` (required): Login username
326
+ - `password` (required): Login password
327
+ - `loginUrl` (optional): Custom login URL (default: `{domain}/login`)
328
+ - `loginSelectors` (optional): Custom selectors for login form:
329
+ - `usernameSelector` (default: `"input[type='email'], input[name='username'], input[id='username']"`)
330
+ - `passwordSelector` (default: `"input[type='password']"`)
331
+ - `submitSelector` (default: `"button[type='submit'], input[type='submit']"`)
332
+ - `sessionId` (optional): Custom session identifier (auto-generated if not provided)
333
+
334
+ **Example:**
335
+ ```json
336
+ {
337
+ "domain": "https://app.example.com",
338
+ "username": "user@example.com",
339
+ "password": "password123",
340
+ "loginUrl": "https://app.example.com/auth/login"
341
+ }
342
+ ```
343
+
344
+ **Output:**
345
+ - `sessionId`: Reusable session identifier
346
+ - `expiresAt`: Session expiration time (ISO 8601)
347
+ - `testUrl`: Test URL to verify session
348
+
349
+ **Differentiator**: Only MCP with reusable session management for authenticated pages.
350
+
351
+ #### `audit_with_session` - Authenticated Audit
352
+
353
+ Run an audit using an existing authenticated session.
354
+
355
+ **Inputs:**
356
+ - `sessionId` (required): Session from `create_session`
357
+ - `url` (required): URL to test (can be relative)
358
+ - `domain` (optional): Base domain
359
+ - `tags` (optional): Array of accessibility tags
360
+ - `waitForLoad` (optional): Wait strategy (default: `"networkidle"`)
361
+ - `timeout` (optional): Timeout in seconds (default: 30)
362
+
363
+ **Example:**
364
+ ```json
365
+ {
366
+ "sessionId": "session-abc123",
367
+ "url": "/dashboard",
368
+ "domain": "https://app.example.com",
369
+ "tags": ["wcag21aa"]
370
+ }
371
+ ```
372
+
373
+ **Output:** Same as `audit_url` but for authenticated pages.
374
+
375
+ ### Tier 3: Analysis & Reporting
376
+
377
+ #### `get_accessibility_score` - Calculate Score
378
+
379
+ Calculate accessibility score (0-100) with detailed breakdowns.
380
+
381
+ **Inputs:**
382
+ - `results` (required): Audit result object or URL string
383
+ - `weights` (optional): Custom weights for different issue types:
384
+ - `errors` (default: 10)
385
+ - `contrast` (default: 8)
386
+ - `alerts` (default: 5)
387
+ - `features` (default: 3)
388
+ - `structural` (default: 6)
389
+
390
+ **Example:**
391
+ ```json
392
+ {
393
+ "results": "https://example.com",
394
+ "weights": {
395
+ "errors": 15,
396
+ "contrast": 10
397
+ }
398
+ }
399
+ ```
400
+
401
+ **Output:**
402
+ - Overall score (0-100)
403
+ - Breakdown by category (contrast, navigation, forms, etc.)
404
+ - WCAG level compliance (A, AA, AAA)
405
+ - Trend if historical data available
406
+
407
+ #### `prioritize_issues` - Smart Prioritization
408
+
409
+ Intelligently prioritize issues, identifying quick wins and critical blockers.
410
+
411
+ **Inputs:**
412
+ - `results` (required): Audit result object
413
+ - `criteria` (optional): `"impact"` | `"wcag"` | `"fixability"` | `"user-impact"` (default: `"impact"`)
414
+ - `limit` (optional): Top N issues to return (default: 10)
415
+
416
+ **Example:**
417
+ ```json
418
+ {
419
+ "results": { /* audit result object */ },
420
+ "criteria": "fixability",
421
+ "limit": 5
422
+ }
423
+ ```
424
+
425
+ **Output:**
426
+ - Prioritized list with reasoning
427
+ - Quick wins (easy fixes with high impact)
428
+ - Critical blockers
429
+
430
+ #### `explain_issue` - Educational Tool
431
+
432
+ Explain what an accessibility issue means in plain language.
433
+
434
+ **Inputs:**
435
+ - `ruleId` (required): Accessibility rule ID (e.g., `"alt_missing"`, `"contrast"`, `"label_missing"`)
436
+ - `context` (optional): Additional context about the issue (HTML element, page URL, etc.)
437
+
438
+ **Example:**
439
+ ```json
440
+ {
441
+ "ruleId": "alt_missing",
442
+ "context": "Image on homepage hero section"
443
+ }
444
+ ```
445
+
446
+ **Output:**
447
+ - Plain language explanation
448
+ - Why it matters (user impact)
449
+ - How to fix (with code examples)
450
+ - WCAG reference
451
+ - Common mistakes
452
+
453
+ **Differentiator**: Educational focus - helps users learn accessibility.
454
+
455
+ #### `get_quick_fixes` - Actionable Fixes
456
+
457
+ Get specific fix suggestions with before/after code examples.
458
+
459
+ **Inputs:**
460
+ - `results` (required): Audit result object or URL string
461
+ - `format` (optional): `"markdown"` | `"html"` | `"json"` (default: `"json"`)
462
+ - `includeCode` (optional): Include code examples (default: true)
463
+
464
+ **Example:**
465
+ ```json
466
+ {
467
+ "results": "https://example.com",
468
+ "format": "markdown",
469
+ "includeCode": true
470
+ }
471
+ ```
472
+
473
+ **Output:**
474
+ - List of fixes with:
475
+ - Current code (if available)
476
+ - Fixed code
477
+ - Explanation
478
+ - Impact estimate
479
+
480
+ **Differentiator**: Code-level fixes, not just descriptions.
481
+
482
+ #### `generate_compliance_report` - Compliance Documentation
483
+
484
+ Generate compliance reports in various formats.
485
+
486
+ **Inputs:**
487
+ - `results` (required): Audit result object
488
+ - `format` (optional): `"VPAT"` | `"WCAG"` | `"ADA"` | `"Section508"` (default: `"WCAG"`)
489
+ - `level` (optional): `"A"` | `"AA"` | `"AAA"` (default: `"AA"`)
490
+ - `includeRemediation` (optional): Include fix suggestions (default: true)
491
+
492
+ **Example:**
493
+ ```json
494
+ {
495
+ "results": { /* audit result object */ },
496
+ "format": "VPAT",
497
+ "level": "AA",
498
+ "includeRemediation": true
499
+ }
500
+ ```
501
+
502
+ **Output:**
503
+ - Formatted compliance report
504
+ - WCAG mapping
505
+ - Remediation plan
506
+ - Executive summary
507
+
508
+ #### `get_wcag_compliance` - WCAG Status
509
+
510
+ Check WCAG compliance status with per-criterion breakdown.
511
+
512
+ **Inputs:**
513
+ - `results` (required): Audit result object or URL string
514
+ - `level` (optional): `"A"` | `"AA"` | `"AAA"` (default: `"AA"`)
515
+
516
+ **Example:**
517
+ ```json
518
+ {
519
+ "results": "https://example.com",
520
+ "level": "AA"
521
+ }
522
+ ```
523
+
524
+ **Output:**
525
+ - Compliance status (pass/fail/partial)
526
+ - Per-criterion breakdown
527
+ - Missing requirements
528
+ - Compliance percentage
529
+
530
+ ### Tier 4: Comparison & Tracking
531
+
532
+ #### `compare_accessibility` - Before/After Comparison
533
+
534
+ Compare two audits to track improvements.
535
+
536
+ **Inputs:**
537
+ - `before` (required): Previous audit result or URL
538
+ - `after` (required): Current audit result or URL
539
+ - `format` (optional): `"summary"` | `"detailed"` | `"diff"` (default: `"summary"`)
540
+
541
+ **Example:**
542
+ ```json
543
+ {
544
+ "before": "https://example.com/v1",
545
+ "after": "https://example.com/v2",
546
+ "format": "detailed"
547
+ }
548
+ ```
549
+
550
+ **Output:**
551
+ - Issues fixed
552
+ - Issues introduced
553
+ - Score improvement
554
+ - Remaining issues
555
+ - Visual diff (if applicable)
556
+
557
+ #### `track_accessibility` - Historical Tracking
558
+
559
+ Track accessibility over time with trend analysis.
560
+
561
+ **Inputs:**
562
+ - `url` (required): URL to track
563
+ - `timeframe` (optional): `"7d"` | `"30d"` | `"90d"` | `"all"` (default: `"30d"`)
564
+ - `metric` (optional): `"score"` | `"issues"` | `"wcag-compliance"` (default: `"score"`)
565
+
566
+ **Example:**
567
+ ```json
568
+ {
569
+ "url": "https://example.com",
570
+ "timeframe": "90d",
571
+ "metric": "score"
572
+ }
573
+ ```
574
+
575
+ **Output:**
576
+ - Historical data
577
+ - Trend visualization (text-based)
578
+ - Predictions
579
+ - Recommendations
580
+
581
+ ### Tier 5: Export & Data Management
582
+
583
+ #### `export_to_csv` - Export to CSV
584
+
585
+ Export audit results to CSV format for spreadsheet analysis, including metadata and violation rows.
586
+
587
+ **Inputs:**
588
+ - `results` (required): Audit result object or URL string
589
+ - `includeMetadata` (optional): Include test information and environment data (default: `true`)
590
+ - `includeViolations` (optional): Include detailed violation rows (default: `true`)
591
+ - `format` (optional): `"standard"` | `"detailed"` | `"minimal"` (default: `"standard"`)
592
+
593
+ **Example:**
594
+ ```json
595
+ {
596
+ "results": "https://example.com",
597
+ "format": "detailed",
598
+ "includeMetadata": true,
599
+ "includeViolations": true
600
+ }
601
+ ```
602
+
603
+ **Output:**
604
+ - CSV content as string with metadata section and violation rows
605
+ - Format type used
606
+ - Total issues count
607
+
608
+ **Use case**: Import into Excel, share with stakeholders, data analysis
609
+
610
+ #### `export_to_excel` - Export to Excel
611
+
612
+ Export audit results to Excel/XLSX format with formatting. Requires `xlsx` package.
613
+
614
+ **Inputs:**
615
+ - `results` (required): Audit result object or URL string
616
+ - `includeCharts` (optional): Generate charts for score trends and category breakdown (default: `false`)
617
+ - `formatting` (optional): Apply colors, headers, and styling (default: `true`)
618
+
619
+ **Example:**
620
+ ```json
621
+ {
622
+ "results": { /* audit result object */ },
623
+ "includeCharts": true,
624
+ "formatting": true
625
+ }
626
+ ```
627
+
628
+ **Output:**
629
+ - Excel file content (base64 encoded)
630
+ - Format type (`xlsx`)
631
+ - Total issues count
632
+
633
+ **Use case**: Professional reports, presentations, stakeholder sharing
634
+
635
+ **Note**: Requires `xlsx` package. Install with `npm install xlsx`.
636
+
637
+ #### `export_to_json` - Export to JSON
638
+
639
+ Export audit results as structured JSON with optional raw results.
640
+
641
+ **Inputs:**
642
+ - `results` (required): Audit result object or URL string
643
+ - `pretty` (optional): Pretty-print JSON (default: `true`)
644
+ - `includeRaw` (optional): Include raw accessibility engine results (default: `false`)
645
+
646
+ **Example:**
647
+ ```json
648
+ {
649
+ "results": "https://example.com",
650
+ "pretty": true,
651
+ "includeRaw": false
652
+ }
653
+ ```
654
+
655
+ **Output:**
656
+ - JSON string with audit results
657
+ - Pretty-print status
658
+ - Raw results inclusion status
659
+
660
+ **Use case**: API integration, data processing, backup
661
+
662
+ #### `export_to_html_report` - Generate HTML Report
663
+
664
+ Generate standalone HTML report with styling and optional visual charts.
665
+
666
+ **Inputs:**
667
+ - `results` (required): Audit result object or URL string
668
+ - `template` (optional): `"default"` | `"minimal"` | `"detailed"` (default: `"default"`)
669
+ - `includeCharts` (optional): Include visual charts (default: `true`)
670
+
671
+ **Example:**
672
+ ```json
673
+ {
674
+ "results": "https://example.com",
675
+ "template": "detailed",
676
+ "includeCharts": true
677
+ }
678
+ ```
679
+
680
+ **Output:**
681
+ - HTML string with embedded CSS/JS
682
+ - Template used
683
+ - Charts inclusion status
684
+
685
+ **Use case**: Web sharing, email reports, documentation
686
+
687
+ ### Tier 6: Filtering & Search
688
+
689
+ #### `filter_issues` - Filter Issues
690
+
691
+ Filter issues from audit results by various criteria (rule IDs, categories, impact levels, WCAG levels, etc.). Supports include/exclude modes.
692
+
693
+ **Inputs:**
694
+ - `results` (required): Audit result object
695
+ - `filters` (required): Object with filter criteria:
696
+ - `ruleIds` (optional): Array of rule IDs to include/exclude
697
+ - `categories` (optional): Array of categories (error, contrast, etc.)
698
+ - `impactLevels` (optional): Array of impact levels (`"critical"`, `"serious"`, `"moderate"`, `"minor"`)
699
+ - `wcagLevels` (optional): Array of WCAG levels (`"A"`, `"AA"`, `"AAA"`)
700
+ - `minCount` (optional): Minimum occurrence count
701
+ - `elementTypes` (optional): Filter by HTML element types (e.g., `["img", "input", "button"]`)
702
+ - `mode` (optional): `"include"` | `"exclude"` (default: `"include"`)
703
+
704
+ **Example:**
705
+ ```json
706
+ {
707
+ "results": { /* audit result object */ },
708
+ "filters": {
709
+ "impactLevels": ["critical", "serious"],
710
+ "wcagLevels": ["A", "AA"]
711
+ },
712
+ "mode": "include"
713
+ }
714
+ ```
715
+
716
+ **Output:**
717
+ - Filtered audit result object
718
+ - Original issue count
719
+ - Filtered issue count
720
+ - Filters applied
721
+
722
+ **Use case**: Focus on specific issue types, exclude false positives
723
+
724
+ #### `search_issues` - Search Issues
725
+
726
+ Search issues by text content, selector, XPath, or description. Supports case-sensitive and case-insensitive search.
727
+
728
+ **Inputs:**
729
+ - `results` (required): Audit result object
730
+ - `query` (required): Search query string
731
+ - `fields` (optional): Array of fields to search (`"description"`, `"element"`, `"xpath"`, `"selector"`, `"ruleId"`, `"userImpact"`, `"fix"`, `"all"`) (default: `["all"]`)
732
+ - `caseSensitive` (optional): Case-sensitive search (default: `false`)
733
+
734
+ **Example:**
735
+ ```json
736
+ {
737
+ "results": { /* audit result object */ },
738
+ "query": "missing alt",
739
+ "fields": ["description", "userImpact"],
740
+ "caseSensitive": false
741
+ }
742
+ ```
743
+
744
+ **Output:**
745
+ - Array of matching issues
746
+ - Total matches count
747
+ - Fields searched
748
+
749
+ **Use case**: Find specific issues, locate elements
750
+
751
+ ### Tier 7: Aggregation & Statistics
752
+
753
+ #### `aggregate_audit_results` - Aggregate Results
754
+
755
+ Combine and aggregate multiple audit results. Groups issues by URL, category, rule, or none, and provides aggregated summary statistics.
756
+
757
+ **Inputs:**
758
+ - `results` (required): Array of audit result objects
759
+ - `groupBy` (optional): `"url"` | `"category"` | `"rule"` | `"none"` (default: `"url"`)
760
+ - `includeSummary` (optional): Include aggregated summary statistics (default: `true`)
761
+
762
+ **Example:**
763
+ ```json
764
+ {
765
+ "results": [
766
+ { /* audit result 1 */ },
767
+ { /* audit result 2 */ }
768
+ ],
769
+ "groupBy": "category",
770
+ "includeSummary": true
771
+ }
772
+ ```
773
+
774
+ **Output:**
775
+ - Aggregated audit result with combined statistics
776
+ - Grouping strategy used
777
+ - Total results aggregated
778
+ - Grouped issues (if applicable)
779
+
780
+ **Use case**: Site-wide reports, batch analysis, trend identification
781
+
782
+ #### `get_statistics` - Generate Statistics
783
+
784
+ Generate detailed statistics from audit results with breakdowns by category, impact, WCAG level, or rule ID. Supports single or multiple audit results.
785
+
786
+ **Inputs:**
787
+ - `results` (required): Audit result object or array of audit results
788
+ - `breakdown` (optional): Array of breakdown dimensions (`"category"`, `"impact"`, `"wcag"`, `"rule"`) (default: all dimensions)
789
+
790
+ **Example:**
791
+ ```json
792
+ {
793
+ "results": [
794
+ { /* audit result 1 */ },
795
+ { /* audit result 2 */ }
796
+ ],
797
+ "breakdown": ["category", "impact", "wcag"]
798
+ }
799
+ ```
800
+
801
+ **Output:**
802
+ - Total issues count
803
+ - Average accessibility score
804
+ - WCAG compliance breakdown
805
+ - Statistics by category, impact, WCAG level, and rule ID
806
+ - Counts, percentages, and distributions
807
+
808
+ **Use case**: Dashboard data, reporting, analysis
809
+
810
+ ### Tier 8: Visualization & Reporting
811
+
812
+ #### `generate_dashboard` - Generate Dashboard
813
+
814
+ Create a visual dashboard summary of audit results with key metrics, charts, and summaries. Supports multiple formats and optional charts.
815
+
816
+ **Inputs:**
817
+ - `results` (required): Audit result object, array of audit results, URL string, or array of URL strings
818
+ - `format` (optional): `"text"` | `"markdown"` | `"html"` | `"json"` (default: `"markdown"`)
819
+ - `includeCharts` (optional): Include ASCII/text charts (default: `true`)
820
+
821
+ **Example:**
822
+ ```json
823
+ {
824
+ "results": ["https://example.com/page1", "https://example.com/page2"],
825
+ "format": "markdown",
826
+ "includeCharts": true
827
+ }
828
+ ```
829
+
830
+ **Output:**
831
+ - Formatted dashboard with key metrics, charts, and summaries
832
+ - Format used
833
+ - Total results processed
834
+
835
+ **Use case**: Quick overview, presentations, status reports
836
+
837
+ #### `generate_summary_report` - Generate Summary Report
838
+
839
+ Generate executive summary report with key findings and recommendations. Supports multiple formats and detail levels.
840
+
841
+ **Inputs:**
842
+ - `results` (required): Audit result object, array of audit results, URL string, or array of URL strings
843
+ - `format` (optional): `"text"` | `"markdown"` | `"html"` (default: `"markdown"`)
844
+ - `level` (optional): `"executive"` | `"detailed"` | `"technical"` (default: `"executive"`)
845
+
846
+ **Example:**
847
+ ```json
848
+ {
849
+ "results": "https://example.com",
850
+ "format": "markdown",
851
+ "level": "executive"
852
+ }
853
+ ```
854
+
855
+ **Output:**
856
+ - Summary report with key findings and recommendations
857
+ - Format used
858
+ - Detail level used
859
+ - Total results processed
860
+
861
+ **Use case**: Stakeholder communication, documentation
862
+
863
+ ## 🏷️ Supported Accessibility Tags
864
+
865
+ Filter results by specific WCAG levels or best practices:
866
+
867
+ - `wcag2a` - WCAG 2.0 Level A
868
+ - `wcag2aa` - WCAG 2.0 Level AA
869
+ - `wcag2aaa` - WCAG 2.0 Level AAA
870
+ - `wcag21a` - WCAG 2.1 Level A
871
+ - `wcag21aa` - WCAG 2.1 Level AA (most common requirement)
872
+ - `wcag21aaa` - WCAG 2.1 Level AAA
873
+ - `best-practice` - Best practice recommendations
874
+
875
+ **Example Usage:**
876
+ ```json
877
+ // Only check WCAG 2.1 AA compliance
878
+ {
879
+ "url": "https://example.com",
880
+ "tags": ["wcag21aa"]
881
+ }
882
+
883
+ // Check multiple WCAG levels
884
+ {
885
+ "url": "https://example.com",
886
+ "tags": ["wcag2a", "wcag2aa", "best-practice"]
887
+ }
888
+ ```
889
+
890
+ ## 📊 Result Format
891
+
892
+ All audit tools return structured results in the following format:
893
+
894
+ ```typescript
895
+ {
896
+ summary: {
897
+ totalIssues: number
898
+ score: number
899
+ wcagCompliance: { A: number, AA: number, AAA: number }
900
+ byCategory: Record<string, number>
901
+ byImpact: Record<string, number>
902
+ }
903
+ prioritizedIssues: Array<{
904
+ ruleId: string
905
+ impact: 'critical' | 'serious' | 'moderate' | 'minor'
906
+ description: string
907
+ wcagLevel: string
908
+ tags: string[] // Array of tags this violation matches
909
+ element: string
910
+ xpath: string
911
+ fix: {
912
+ current: string
913
+ suggested: string
914
+ explanation: string
915
+ }
916
+ userImpact: string
917
+ priority: number
918
+ }>
919
+ conversationalSummary: string
920
+ quickWins: Array<{
921
+ ruleId: string
922
+ description: string
923
+ impact: string
924
+ fix: string
925
+ }>
926
+ criticalBlockers: Array<{
927
+ ruleId: string
928
+ description: string
929
+ impact: string
930
+ }>
931
+ appliedFilters?: {
932
+ tags?: string[]
933
+ originalIssueCount?: number
934
+ }
935
+ }
936
+ ```
937
+
938
+ ## 📝 Usage Examples
939
+
940
+ ### Basic URL Audit
941
+
942
+ ```json
943
+ {
944
+ "tool": "audit_url",
945
+ "arguments": {
946
+ "url": "https://example.com",
947
+ "tags": ["wcag21aa"]
948
+ }
949
+ }
950
+ ```
951
+
952
+ ### Authenticated Audit Flow
953
+
954
+ **Step 1: Create Session**
955
+ ```json
956
+ {
957
+ "tool": "create_session",
958
+ "arguments": {
959
+ "domain": "https://app.example.com",
960
+ "username": "user@example.com",
961
+ "password": "password123"
962
+ }
963
+ }
964
+ ```
965
+
966
+ **Step 2: Audit Protected Page**
967
+ ```json
968
+ {
969
+ "tool": "audit_with_session",
970
+ "arguments": {
971
+ "sessionId": "<session-id-from-step-1>",
972
+ "url": "/dashboard",
973
+ "tags": ["wcag21aa"]
974
+ }
975
+ }
976
+ ```
977
+
978
+ ### Batch Audit with Progress
979
+
980
+ ```json
981
+ {
982
+ "tool": "audit_multiple_urls",
983
+ "arguments": {
984
+ "urls": ["/home", "/about", "/contact", "/products"],
985
+ "domain": "https://example.com",
986
+ "parallel": 2,
987
+ "tags": ["wcag2aa"]
988
+ }
989
+ }
990
+ ```
991
+
992
+ ### Get Quick Fixes
993
+
994
+ ```json
995
+ {
996
+ "tool": "get_quick_fixes",
997
+ "arguments": {
998
+ "results": "https://example.com",
999
+ "format": "markdown",
1000
+ "includeCode": true
1001
+ }
1002
+ }
1003
+ ```
1004
+
1005
+ ### Compare Before/After
1006
+
1007
+ ```json
1008
+ {
1009
+ "tool": "compare_accessibility",
1010
+ "arguments": {
1011
+ "before": "https://example.com/v1",
1012
+ "after": "https://example.com/v2",
1013
+ "format": "detailed"
1014
+ }
1015
+ }
1016
+ ```
1017
+
1018
+ ### Generate Compliance Report
1019
+
1020
+ ```json
1021
+ {
1022
+ "tool": "generate_compliance_report",
1023
+ "arguments": {
1024
+ "results": { /* audit result object */ },
1025
+ "format": "VPAT",
1026
+ "level": "AA",
1027
+ "includeRemediation": true
1028
+ }
1029
+ }
1030
+ ```
1031
+
1032
+ ### Export to CSV
1033
+
1034
+ ```json
1035
+ {
1036
+ "tool": "export_to_csv",
1037
+ "arguments": {
1038
+ "results": "https://example.com",
1039
+ "format": "detailed",
1040
+ "includeMetadata": true,
1041
+ "includeViolations": true
1042
+ }
1043
+ }
1044
+ ```
1045
+
1046
+ ### Export to Excel
1047
+
1048
+ ```json
1049
+ {
1050
+ "tool": "export_to_excel",
1051
+ "arguments": {
1052
+ "results": { /* audit result object */ },
1053
+ "includeCharts": true,
1054
+ "formatting": true
1055
+ }
1056
+ }
1057
+ ```
1058
+
1059
+ ### Export to JSON
1060
+
1061
+ ```json
1062
+ {
1063
+ "tool": "export_to_json",
1064
+ "arguments": {
1065
+ "results": "https://example.com",
1066
+ "pretty": true,
1067
+ "includeRaw": false
1068
+ }
1069
+ }
1070
+ ```
1071
+
1072
+ ### Generate HTML Report
1073
+
1074
+ ```json
1075
+ {
1076
+ "tool": "export_to_html_report",
1077
+ "arguments": {
1078
+ "results": "https://example.com",
1079
+ "template": "detailed",
1080
+ "includeCharts": true
1081
+ }
1082
+ }
1083
+ ```
1084
+
1085
+ ### Filter Issues
1086
+
1087
+ ```json
1088
+ {
1089
+ "tool": "filter_issues",
1090
+ "arguments": {
1091
+ "results": { /* audit result object */ },
1092
+ "filters": {
1093
+ "impactLevels": ["critical", "serious"],
1094
+ "wcagLevels": ["A", "AA"]
1095
+ },
1096
+ "mode": "include"
1097
+ }
1098
+ }
1099
+ ```
1100
+
1101
+ ### Search Issues
1102
+
1103
+ ```json
1104
+ {
1105
+ "tool": "search_issues",
1106
+ "arguments": {
1107
+ "results": { /* audit result object */ },
1108
+ "query": "missing alt",
1109
+ "fields": ["description", "userImpact"],
1110
+ "caseSensitive": false
1111
+ }
1112
+ }
1113
+ ```
1114
+
1115
+ ### Aggregate Audit Results
1116
+
1117
+ ```json
1118
+ {
1119
+ "tool": "aggregate_audit_results",
1120
+ "arguments": {
1121
+ "results": [
1122
+ { /* audit result 1 */ },
1123
+ { /* audit result 2 */ }
1124
+ ],
1125
+ "groupBy": "category",
1126
+ "includeSummary": true
1127
+ }
1128
+ }
1129
+ ```
1130
+
1131
+ ### Get Statistics
1132
+
1133
+ ```json
1134
+ {
1135
+ "tool": "get_statistics",
1136
+ "arguments": {
1137
+ "results": [
1138
+ { /* audit result 1 */ },
1139
+ { /* audit result 2 */ }
1140
+ ],
1141
+ "breakdown": ["category", "impact", "wcag"]
1142
+ }
1143
+ }
1144
+ ```
1145
+
1146
+ ### Generate Dashboard
1147
+
1148
+ ```json
1149
+ {
1150
+ "tool": "generate_dashboard",
1151
+ "arguments": {
1152
+ "results": ["https://example.com/page1", "https://example.com/page2"],
1153
+ "format": "markdown",
1154
+ "includeCharts": true
1155
+ }
1156
+ }
1157
+ ```
1158
+
1159
+ ### Generate Summary Report
1160
+
1161
+ ```json
1162
+ {
1163
+ "tool": "generate_summary_report",
1164
+ "arguments": {
1165
+ "results": "https://example.com",
1166
+ "format": "markdown",
1167
+ "level": "executive"
1168
+ }
1169
+ }
1170
+ ```
1171
+
1172
+ ## 🐛 Error Handling
1173
+
1174
+ The server includes comprehensive error handling:
1175
+
1176
+ - **Graceful degradation**: Partial results on batch failures
1177
+ - **Clear error messages**: Human-readable error descriptions
1178
+ - **Retry logic**: Automatic retries for transient failures
1179
+ - **Validation**: Input validation with helpful error messages
1180
+
1181
+ Common error scenarios:
1182
+ - Invalid URLs or unreachable pages
1183
+ - Session expiration (for authenticated audits)
1184
+ - Timeout errors (configurable)
1185
+ - Invalid tag combinations
1186
+
1187
+ ## 🏗️ Project Structure
1188
+
1189
+ ```
1190
+ a11y-mcp-srv/
1191
+ ├── src/
1192
+ │ ├── server.ts # Main MCP server entry point
1193
+ │ ├── tools/ # Tool implementations
1194
+ │ │ ├── audit.ts # Core audit tools
1195
+ │ │ ├── session.ts # Session management
1196
+ │ │ ├── analysis.ts # Analysis & reporting
1197
+ │ │ ├── comparison.ts # Comparison tools
1198
+ │ │ ├── export.ts # Export tools (CSV, Excel, JSON, HTML)
1199
+ │ │ ├── filter.ts # Filtering and search tools
1200
+ │ │ ├── aggregate.ts # Aggregation and statistics tools
1201
+ │ │ └── visualize.ts # Visualization and dashboard tools
1202
+ │ ├── core/ # Core accessibility functionality
1203
+ │ │ ├── accessibility-runner.ts # Accessibility execution
1204
+ │ │ ├── session-manager.ts # Session handling
1205
+ │ │ ├── result-processor.ts # Result formatting
1206
+ │ │ ├── error-handler.ts # Error handling
1207
+ │ │ └── progress-streamer.ts # Progress updates
1208
+ │ └── types/ # TypeScript types
1209
+ ├── dist/ # Compiled JavaScript
1210
+ ├── wave.min.js # Accessibility engine script (required)
1211
+ ├── package.json
1212
+ ├── tsconfig.json
1213
+ └── README.md
1214
+ ```
1215
+
1216
+ ## 🔨 Local Development (Optional)
1217
+
1218
+ If you want to contribute or modify the code, you can set up a local development environment:
1219
+
1220
+ ### Prerequisites for Local Development
1221
+
1222
+ - Node.js 18+
1223
+ - npm or yarn
1224
+
1225
+ ### Setup Steps
1226
+
1227
+ 1. **Clone the repository**
1228
+ ```bash
1229
+ git clone <repository-url>
1230
+ cd a11y-mcp-srv
1231
+ ```
1232
+
1233
+ 2. **Install dependencies**
1234
+ ```bash
1235
+ npm install
1236
+ ```
1237
+
1238
+ 3. **Install Playwright browsers**
1239
+ ```bash
1240
+ npx playwright install --with-deps chromium
1241
+ ```
1242
+
1243
+ 4. **Build the project**
1244
+ ```bash
1245
+ npm run build
1246
+ ```
1247
+
1248
+ 5. **Verify accessibility script**
1249
+ - Ensure `wave.min.js` is present in the project root
1250
+
1251
+ ### Running Locally
1252
+
1253
+ **Development Mode (with watch)**
1254
+ ```bash
1255
+ npm run dev
1256
+ ```
1257
+
1258
+ **Production Mode**
1259
+ ```bash
1260
+ npm start
1261
+ ```
1262
+
1263
+ **Testing**
1264
+ - `npm test` – run unit and integration tests (watch mode)
1265
+ - `npm run test:run` – run all tests once
1266
+ - `npm run test:coverage` – run tests with coverage
1267
+ - `npm run test:e2e` – build and run E2E tests (real MCP server over stdio via `@modelcontextprotocol/sdk` Client)
1268
+
1269
+ ### Using Local Version in MCP Client
1270
+
1271
+ If you want to use the local version instead of the published package:
1272
+
1273
+ ```json
1274
+ {
1275
+ "mcpServers": {
1276
+ "accessibility-audit": {
1277
+ "command": "node",
1278
+ "args": ["/absolute/path/to/a11y-mcp-srv/dist/server.js"]
1279
+ }
1280
+ }
1281
+ }
1282
+ ```
1283
+
1284
+ **Note**: Use absolute paths in your configuration.
1285
+
1286
+ ## 🔑 Key Differentiators
1287
+
1288
+ 1. **Zero Setup Required** - Just add config and use! No installation, building, or manual setup needed
1289
+ 2. **Conversational Interface** - Results formatted for natural language understanding
1290
+ 3. **Session Management** - Only MCP with reusable authenticated sessions for protected pages
1291
+ 4. **Educational Focus** - `explain_issue` teaches accessibility concepts, not just reports problems
1292
+ 5. **Code-Level Fixes** - Actual before/after code examples, not just descriptions
1293
+ 6. **Progress Updates** - Streaming progress for long-running batch operations
1294
+ 7. **Smart Prioritization** - AI-powered issue prioritization with quick wins identification
1295
+ 8. **Compliance Reports** - Automated VPAT/WCAG/ADA/Section 508 documentation
1296
+ 9. **Tag Filtering** - Filter by specific WCAG levels to reduce noise and focus on what matters
1297
+ 10. **25+ Tools** - Comprehensive suite covering auditing, analysis, reporting, export, and more
1298
+
1299
+ ## Attribution
1300
+
1301
+ This project is derived from [alii13/accessibility-mcp-server](https://github.com/alii13/accessibility-mcp-server), which is licensed under the [MIT License](LICENSE). The original copyright notice and license are preserved in this distribution. See the [NOTICE](NOTICE) file for details.
1302
+
1303
+ ## 📄 License
1304
+
1305
+ MIT License - feel free to use in your projects!
1306
+
1307
+ ## 🚀 Releasing
1308
+
1309
+ Releases are automated with [semantic-release](https://github.com/semantic-release/semantic-release) and run on **push or merge to any `release/*` branch**.
1310
+
1311
+ - **Branch**: Push or merge to a branch matching `release/*` (e.g. `release/1.x`, `release/2.0`).
1312
+ - **Version**: Determined from commit messages (e.g. `fix:`, `feat:`, `BREAKING CHANGE:`).
1313
+ - **Artifacts**: GitHub Release is created; `CHANGELOG.md` and `package.json` are updated and pushed back to the branch.
1314
+ - **npm**: If you publish to npm, add an `NPM_TOKEN` secret in the repo settings (Settings → Secrets and variables → Actions). The workflow uses it to publish after a successful release.
1315
+
1316
+ Local dry run (no publish): `npx semantic-release --dry-run`. Note: dry-run may fail locally if no `release/*` branch exists on the remote, since semantic-release validates branches against the repo; in CI it runs only when the workflow is triggered by a push to `release/*`.
1317
+
1318
+ ## 🤝 Contributing
1319
+
1320
+ Contributions are welcome! Please ensure all code follows the existing style and includes appropriate tests.
1321
+
1322
+ ## 🆘 Support
1323
+
1324
+ For issues, questions, or contributions, please open an issue on the repository.
1325
+
1326
+ ---
1327
+
1328
+ **Happy accessibility testing! ♿✨**