Heading Analysis
DescriptionThis API uses machine learning models and inspects whether the text below each heading is related to the heading content or not. It covers the following Issue IDs:
Issue ID: cr_heading_unrelated
Definition
The content immediately following a heading identified by machine learning is possibly unrelated to the topic or purpose.
User Impact
Blind screen reader users rely on headings to navigate page content. When headings are misleading and do not reflect the topic or purpose, users can become disoriented and have difficulty navigating the page. Users with learning differences may also have difficulty understanding page content when headings are unrelated to content.
Recommendation
Provide clear and descriptive headings that accurately describe the immediatley following content.
Success Criterion
2.4.6 Headings and Labels (Level AA)
Related Success Criteria (if applicable):
1.3.1 Info and Relationships (Level A)
More details can be found at Understanding Success Criterion 2.4.6.
Request
URLURL
Response
Response BodyResponse Body
200 OK
The Success response contains categories
that aggregate all the Error and Alert related issues.
{
"categories": {
"alert": {
"count": 1,
"description": "Alerts",
"items": {
"cr_heading_unrelated": {
"count": 1,
"description": "Possibly unrelated heading",
"id": "cr_heading_unrelated",
"level": "AA",
"xpaths": [
"/html[1]/body[1]/div[1]/a[1]"
]
}
}
}
},
"statistics": {
"allitemcount": 1,
"pageurl": "http://www.abc.com",
"time": 5.13,
"totalelements": 60
},
"status": {
"httpstatuscode": 200,
"success": "True"
}
}
Errors
Bad Request, missing something, or the request body wasn’t correct.