mainwp-dashboard-lock category. Both use the mainwp/ namespace and report the settings saved on your MainWP Dashboard site.
These abilities require the Dashboard Lock release that includes Abilities API support. Earlier builds do not register them. Check ability discovery on your Dashboard before using these examples.
What You’ll Learn
- Check which Dashboard Lock protections have stored settings
- Read the stored redirect URL, exclusions, and IP allowlists
- Confirm whether HTTP Basic Authentication credentials are stored without exposing them
- Understand what these reads do not verify
Prerequisites
- WordPress 6.9 or later on the MainWP Dashboard site
- MainWP Dashboard with Abilities API support; use version 6.2 or later for the
input_jsonexample below - Dashboard Lock with Abilities API support, active and enabled in MainWP Dashboard
- An authenticated WordPress user with
manage_optionsand access to the Dashboard Lock Add-on
When to use these abilities
Use these reads to audit Dashboard Lock settings from scripts, monitoring tools, or AI assistants without opening MainWP > Add-ons > Security > Dashboard Lock. For example, you can confirm that a redirect URL and an IP allowlist are saved across several Dashboards. Both abilities only read the stored settings. They do not inspect.htaccess or .htpasswd files, so they cannot confirm that locks are applied on the server or that your server supports them. To change or remove locks, use the Dashboard Lock settings page.
Available Abilities
Both abilities are marked read-only, non-destructive, and idempotent. Discover their complete input and output schemas:
null, or send an empty object {}. Any input property, including site_id, is rejected. These abilities read Dashboard settings only and do not apply to Child sites.
Get Dashboard Lock Status
Ability:mainwp/get-dashboard-lock-status-v1Method: GET
Get Dashboard Lock Configuration
Ability:mainwp/get-dashboard-lock-configuration-v1Method: GET
List fields drop blank lines and surrounding whitespace. Each Basic Authentication object contains:
username_configured: a username is saved.credential_configured: both a username and a password are saved.
Errors
Other MainWP Dashboard permission errors can also be returned. See the Abilities API overview for details.
Related Resources
- Dashboard Lock Add-on - Configure and remove redirects, IP restrictions, and locks
- Abilities API Overview - Authentication, discovery, and request formats
- Application Passwords - Create credentials for API requests
