Trigger an accessibility scan
const url = 'https://api.overwatch.weareheavy.dev/v1/sites/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/a11y-scan';const options = {method: 'POST', headers: {'x-api-key': '<x-api-key>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.overwatch.weareheavy.dev/v1/sites/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/a11y-scan \ --header 'x-api-key: <x-api-key>'Start just the accessibility render pass over the already-persisted page set — no re-crawl. Same permissions as triggering a crawl.
- 202 Accepted — a scan was started (
started: true). - 200 OK — a no-op: a crawl or scan is already in flight, or there
is no persisted page set yet (
started: false).
Authorizations
Section titled “ Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “ Path Parameters ”The site’s UUID.
Responses
Section titled “ Responses ”Nothing was started (busy, or no page set yet).
The result of triggering a crawl.
object
true if a new crawl was started, false if one was already running.
Live crawl state from the crawler. Unlike persisted records, these are camelCase counters describing the in-progress run.
object
URLs currently leased and being checked.
URLs waiting in the frontier to be leased.
The adaptive in-flight window size.
Example
{ "status": { "state": "seeding" }}A new accessibility scan was started.
The result of triggering a crawl.
object
true if a new crawl was started, false if one was already running.
Live crawl state from the crawler. Unlike persisted records, these are camelCase counters describing the in-progress run.
object
URLs currently leased and being checked.
URLs waiting in the frontier to be leased.
The adaptive in-flight window size.
Example
{ "status": { "state": "seeding" }}Missing or invalid credentials.
object
A human-readable error message.
Example
{ "error": "invalid api key"}The caller’s role or key scope does not allow this action.
object
A human-readable error message.
Example
{ "error": "only owners and admins can edit site settings"}No site with that id is visible to the caller.
object
A human-readable error message.
Example
{ "error": "site not found"}The Accessibility app is not enabled for this site.
object
A human-readable error message.
Example
{ "error": "accessibility scanning is not enabled for this site"}