Skip to main content

Bulk-Downloading Accessibility Reports for AI-Powered Sites

This article walks through a small Python script that automatically downloads the accessibility report for every site on your account that has the AI-Powered add-on enabled — instead of downloading each report one by one from the dashboard.

What the script does

  1. Calls the Sites endpoint to pull the full list of sites on your account.

  2. Filters that list down to only the sites where addons.aiPowered is true.

  3. For each matching site, requests the accessibility report, which returns a link to the report PDF.

  4. Downloads the PDF from that link and saves it locally.

Reports are saved into a reports/ folder, named after each site's domain (e.g. example.com.pdf).

Requirements

  • Python 3.9+

  • The requests library (pip install requests)

  • Your account ID and API key (see below)

Before you run it

Open the script and fill in your own credentials near the top of the file:

USER_ID = "YOUR_ACCOUNT_ID" #your account 
ID API_KEY = "YOUR_API_KEY" # from your dashboard (Dev Resource)
  • Account ID: found in your dashboard under embed code data-account field.

  • API Key: found in your dashboard under Dev Resources.

⚠️ Treat your API key like a password. Don't commit it to source control or share it in screenshots.

Running the script

From a terminal, in the same folder as the script:

python download_userway_reports.py

You'll see progress printed to the terminal as each site is processed:

Found 3 aiPowered site(s): example.com, shop.example.com, blog.example.com  Fetching report for example.com ... saved -> reports/example.com.pdf Fetching report for shop.example.com ... saved -> reports/shop.example.com.pdf Fetching report for blog.example.com ... saved -> reports/blog.example.com.pdf

If a site has no AI-Powered add-on enabled, it's simply skipped — only sites with addons.aiPowered == true are included.

Notes & troubleshooting

  • Rate limiting: the script waits 1.5 seconds between each site's download to avoid hitting API rate limits. You can adjust this via the DELAY_SECONDS variable if needed.

  • No sites found: if you see No aiPowered sites found., double check that the add-on is actually enabled on at least one site in your account.

  • HTTP errors: if a request fails, the script prints the HTTP status code and a snippet of the response body, which is usually enough to diagnose the issue (e.g. invalid API key, invalid host, etc.).

  • File format: reports are saved based on the file type returned by the server — typically .pdf.

Confirmed working

This script has been tested and confirmed working by a customer for bulk-downloading reports across multiple AI-Powered sites on their account.

If you have any questions, you can reach our support team at desk@support.userway.org

Did this answer your question?