Skip to content

Audits

The audits system provides two levels of evaluation: a fast instant audit that returns a single score, and a full audit that runs a comprehensive analysis and delivers results by email.

Audit Levels

TypeEndpointTurnaroundOutput
InstantPOST /api/audits/instantUnder 10 secondsNumeric score + top issues
FullPOST /api/audits/full2-5 minutesDetailed report delivered by email

Both endpoints accept a URL or uploaded prototype reference. The instant audit is suitable for CI/CD integration. The full audit is for design reviews and stakeholder reporting.

Endpoints

POST /api/audits/instant JWT

Run a quick accessibility audit and return a score

Analyzes the target URL for common accessibility violations and returns a score with the top issues found. Designed to complete in under 10 seconds.

Request body

{
"url": "https://staging.example.com/checkout",
"viewport": {
"width": 1440,
"height": 900
},
"checkCategories": ["contrast", "keyboard", "aria", "images"]
}
FieldTypeRequiredDescription
urlstringYesPublicly accessible URL to audit
viewportobjectNoBrowser viewport dimensions. Defaults to { width: 1280, height: 800 }.
checkCategoriesarray of stringsNoLimit checks to these categories. Defaults to all.

Available check categories

CategoryWhat it checks
contrastText and UI component color contrast ratios (WCAG AA/AAA)
keyboardFocus order, keyboard trappability, skip links
ariaARIA roles, labels, and landmark usage
imagesAlt text presence and quality
formsLabel associations, error identification, autocomplete
headingsHeading hierarchy and presence

Response

{
"success": true,
"data": {
"auditId": "audit_instant_001",
"url": "https://staging.example.com/checkout",
"score": 74,
"grade": "C",
"topIssues": [
{
"issueId": "i_001",
"category": "contrast",
"severity": "critical",
"element": "button.checkout-cta",
"description": "Contrast ratio is 2.8:1. Minimum required is 4.5:1 for normal text.",
"wcagCriteria": "1.4.3"
},
{
"issueId": "i_002",
"category": "images",
"severity": "serious",
"element": "img.product-thumbnail",
"description": "Image has no alt attribute.",
"wcagCriteria": "1.1.1"
},
{
"issueId": "i_003",
"category": "keyboard",
"severity": "moderate",
"element": "div.custom-dropdown",
"description": "Interactive element is not keyboard accessible.",
"wcagCriteria": "2.1.1"
}
],
"issueCounts": {
"critical": 1,
"serious": 3,
"moderate": 5,
"minor": 4
},
"completedAt": "2026-03-16T10:00:07Z"
},
"error": null,
"metadata": null
}

Score grades

ScoreGrade
90-100A
80-89B
70-79C
60-69D
Below 60F
POST /api/audits/full JWT

Run a full accessibility audit and deliver results by email

Performs a comprehensive audit covering all WCAG 2.1 Level AA criteria. The report is generated asynchronously and emailed to the requesting user when complete.

Request body

{
"url": "https://staging.example.com",
"crawl": true,
"maxPages": 10,
"viewport": {
"width": 1440,
"height": 900
},
"reportTitle": "Staging - Full Accessibility Audit",
"recipientEmails": ["designer@example.com", "pm@example.com"]
}
FieldTypeRequiredDescription
urlstringYesStarting URL for the audit
crawlbooleanNoWhether to follow internal links and audit multiple pages. Defaults to false.
maxPagesintegerNoMaximum pages to audit when crawl is true. Defaults to 5, max 50.
viewportobjectNoBrowser viewport dimensions
reportTitlestringNoTitle shown on the delivered report
recipientEmailsarray of stringsNoAdditional email addresses to send the report to. The requesting user is always included.

Response

The endpoint responds immediately with a job ID. The audit runs in the background.

{
"success": true,
"data": {
"auditJobId": "auditjob_001",
"url": "https://staging.example.com",
"crawl": true,
"maxPages": 10,
"status": "queued",
"estimatedCompletionMinutes": 3,
"reportDeliveredTo": [
"requester@example.com",
"designer@example.com",
"pm@example.com"
],
"queuedAt": "2026-03-16T10:00:00Z"
},
"error": null,
"metadata": null
}

Email report contents

The delivered report includes:

  • Overall accessibility score and grade
  • Per-page score breakdown (when crawl is true)
  • Full issue list grouped by category and severity
  • WCAG 2.1 criteria reference for each issue
  • Annotated screenshots for critical and serious issues
  • Prioritized remediation recommendations

Status values for auditJobId

Poll GET /api/audits/:auditJobId (when available) or wait for the email. Status transitions: queued > running > complete or failed.