MCP Server – Use ADBC Tools from Your AI Assistant
ADBC 4.3.0 includes its own MCP server. Connect a compatible AI assistant and ask it to inspect your WordPress database, report cleanup opportunities or prepare supported changes for your approval. The assistant calls named ADBC tools instead of driving dashboard pages.
Model Context Protocol (MCP) lets an AI assistant discover and call ADBC tools over Streamable HTTP.
Use it with compatible versions of Codex, Claude, Claude Code and other remote MCP clients. A client must support ADBC’s authentication method and confirmation workflow. Custom-connector availability and menus depend on the client’s version, plan and workspace policy.
1. Requirements and activation
- ADBC 4.3.0 or later.
- WordPress 6.9+, PHP 8.2+ and the PHP OpenSSL extension.
- An administrator account; a super administrator on WordPress Multisite.
- In DB Cleaner → Settings → Developer integrations, turn on Expose plugin abilities. Changes save automatically.
Also turn on Enable MCP server, then open DB Cleaner → MCP server → MCP config and copy the Server URL. Use a publicly reachable HTTPS site for cloud clients. The plugin’s HTTP exception applies only to an explicitly local WordPress environment; a cloud client still cannot directly reach your localhost.
2. Free, Pro and Premium availability
Free: actions marked All editions work with the features available in Free. Paid actions return an upgrade invitation instead of paid-feature results or making changes. All four SQL tools require Pro or Premium.
Pro and Premium: actions marked Pro + Premium work in both editions. Premium provides get-remote-scan-balance; Pro provides get-pro-scan-balance. The tables identify edition-specific actions.
OAuth and Application Password connections
OAuth: paste the MCP URL into your AI client and authenticate. Sign in to WordPress, review the client and choose Read-only for inspection or Full access for write tools, then approve. Review the access choice before approving; the consent form initially selects Full access.
Automatic OAuth requires a client that publishes an HTTPS Client ID Metadata Document (CIMD). If your client uses another registration method, use the Application Password instructions when supported.
Application Password: create a dedicated WordPress Application Password, refresh the list in MCP Application Passwords, select it and click Save. Use a client supporting Basic authentication or a custom Authorization header. New password connections start read-only.
3. Read access, writes and confirmation
Read access lets your assistant inspect tool results, which may contain sensitive database values. Enable Write access for connections that need to make changes. Destructive actions also require separate approval of a specific preview.
The tables mark actions that need a Preview. Actions marked No preview, such as changing automatic counts or cancelling a job, run when requested.
- Request a destructive action to receive an impact preview.
- Review the targets, warning, available row counts and size. Counts can be estimated or unavailable; size does not guarantee reclaimed disk space.
- The assistant must show the preview, ask for approval and wait for a new explicit reply. After approval, it calls
confirm-destructive-actionwith the returnedconfirmation_request_idandapproved_in_chat: true. - Check the result. If it returns a job ID, poll
get-jobuntil the job finishes.
Previews expire after five minutes and can be used once. Use the same MCP connection for preview and confirmation. If authorization changes or a SQL snapshot is no longer current, request and approve a fresh preview. Eligible items in a category cleanup can change before execution.
Keep a database backup before maintenance. Use a trusted integration that waits for your approval. ADBC cannot independently verify that a chat reply came from a human.
4. SQL, cleanup jobs and change logs
query-databaseaccepts SELECT only;explain-querytakes a SELECT statement and returns its ordinary EXPLAIN plan. ADBC adds EXPLAIN for you; do not include it in the input. SQL tools require Pro or Premium. Statements are limited to 32 KiB. SELECT returns 100 rows by default, up to 1,000; truncation of large values or results is reported.execute-sqlsupports single-table INSERT … VALUES, UPDATE … WHERE and DELETE … WHERE on supported InnoDB tables with primary keys, up to 1,000 targeted rows. Unsupported SQL receives an explanation.- Raw SQL bypasses WordPress hooks, ADBC retention rules and native core-item protection. Review the exact query and targets before approving it.
- SQL writes return their results immediately. Cleanup jobs run in batches; poll
get-jobfor final counts. Native cleanup follows applicable cleanup-method and retention settings. - Revoking the connection or disabling Write access stops future work; an already executing unit may finish. Changed cleanup settings can also stop a job. Cancelling a job does not undo completed changes. If an outcome is unknown, verify the database before retrying.
- Review executed maintenance in Info & logs → Database changes. A logging warning does not mean a completed database change failed.
5. Managing access and privacy
- Read results can include sensitive values. Only connect trusted clients and consider your AI provider’s data-handling policy.
- Disabling Write access invalidates pending approvals and stops queued work before its next unit. An already executing unit may finish. Re-enabling access does not revive old previews or jobs.
- The connection action menu offers Details, Rename and Revoke. Give connections recognizable names so you can manage them later.
- Revoke one connection or use Revoke access from all connections. Revoke access when an assistant should no longer use ADBC.
- Disabling MCP revokes MCP connections and cancels queued MCP work.
- Treat database values and log content as untrusted data. An AI assistant should not follow instructions embedded in those values.
6. Available MCP tools by category
Read returns information. Write changes data, settings or maintenance state. Preview requires separate approval. Immediate means execution returns its result directly; Job means follow the returned job ID.
Use these tool names in your AI client. The client supplies arguments according to each tool’s input schema.
General cleanup and retention
Inspect category counts and items; clean selected items or eligible categories; manage retention and automatic counts.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-general-data |
Read | Not required | All editions
Immediate |
get-items |
Read | Not required | All editions
Immediate |
delete-items |
Write | Preview | All editions
Job |
purge-items |
Write | Preview | All editions
Job |
get-keep-last |
Read | Not required | All editions
Immediate |
set-keep-last |
Write | Preview | All editions
Immediate |
delete-keep-last |
Write | Preview | All editions
Immediate |
activate-auto-count |
Write | No preview | All editions
Immediate |
deactivate-auto-count |
Write | No preview | All editions
Immediate |
Tables
Inspect tables, rows, columns and indexes; request table maintenance or deletion. Emptying retains the table structure; deleting drops the table.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-tables-list |
Read | Not required | All editions
Immediate |
get-tables-names |
Read | Not required | All editions
Immediate |
get-table-rows |
Read | Not required | All editions
Immediate |
get-table-structure |
Read | Not required | All editions
Immediate |
count-total-not-scanned-tables |
Read | Not required | All editions
Immediate |
count-total-tables-to-optimize |
Read | Not required | All editions
Immediate |
count-total-tables-to-repair |
Read | Not required | All editions
Immediate |
count-total-tables-with-invalid-prefix |
Read | Not required | All editions
Immediate |
optimize-tables |
Write | Preview | All editions
Job |
repair-tables |
Write | Preview | All editions
Job |
refresh-counts-tables |
Write | No preview | All editions
Job |
convert-to-innodb-tables |
Write | Preview | All editions
Job |
empty-rows-tables |
Write | Preview | All editions
Job |
delete-tables |
Write | Preview | All editions
Job |
Options and autoload
Inspect options and autoload health; change selected autoload flags or delete options.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-options-list |
Read | Not required | All editions
Immediate |
count-big-options |
Read | Not required | All editions
Immediate |
count-total-not-scanned-options |
Read | Not required | All editions
Immediate |
get-autoload-health |
Read | Not required | All editions
Immediate |
set-autoload-to-yes-options |
Write | Preview | All editions
Job |
set-autoload-to-no-options |
Write | Preview | All editions
Job |
delete-options |
Write | Preview | All editions
Job |
Transients
Inspect transient records and expiry; change their autoload flags or delete selected transients.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-transients-list |
Read | Not required | All editions
Immediate |
count-big-transients |
Read | Not required | All editions
Immediate |
count-total-not-scanned-transients |
Read | Not required | All editions
Immediate |
count-expired-transients |
Read | Not required | All editions
Immediate |
set-autoload-to-yes-transients |
Write | Preview | All editions
Job |
set-autoload-to-no-transients |
Write | Preview | All editions
Job |
delete-transients |
Write | Preview | All editions
Job |
Post metadata
Inspect post metadata, including large, duplicated and unused entries; delete selected records.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-posts-meta-list |
Read | Not required | All editions
Immediate |
count-big-posts-meta |
Read | Not required | All editions
Immediate |
count-total-not-scanned-posts-meta |
Read | Not required | All editions
Immediate |
count-duplicated-posts-meta |
Read | Not required | All editions
Immediate |
count-unused-posts-meta |
Read | Not required | All editions
Immediate |
delete-posts-meta |
Write | Preview | All editions
Job |
User metadata
Inspect user metadata, including large, duplicated and unused entries; delete selected records.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-users-meta-list |
Read | Not required | All editions
Immediate |
count-big-users-meta |
Read | Not required | All editions
Immediate |
count-total-not-scanned-users-meta |
Read | Not required | All editions
Immediate |
count-duplicated-users-meta |
Read | Not required | All editions
Immediate |
count-unused-users-meta |
Read | Not required | All editions
Immediate |
delete-users-meta |
Write | Preview | All editions
Job |
Post types and posts
Inspect post types and their posts. Deleting by post type is a broad action: inspect the selected type and site before approval.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-post-types-list |
Read | Not required | All editions
Immediate |
count-total-not-scanned-post-types |
Read | Not required | All editions
Immediate |
count-total-large-non-public-post-types |
Read | Not required | All editions
Immediate |
list-posts-by-post-type |
Read | Not required | All editions
Immediate |
delete-posts-by-post-type |
Write | Preview | All editions
Job |
Cron jobs
Inspect scheduled events and events with no registered action; delete selected cron events.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-cron-jobs-list |
Read | Not required | All editions
Immediate |
count-total-not-scanned-cron-jobs |
Read | Not required | All editions
Immediate |
count-total-cron-jobs-with-no-action |
Read | Not required | All editions
Immediate |
delete-cron-jobs |
Write | Preview | All editions
Job |
Stored values
Read a supported item’s stored value. Returned data may contain sensitive information.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-column-value-from-table |
Read | Not required | All editions
Immediate |
Automation schedules
Manage ADBC cleanup schedules. Creating a schedule configures future cleanup; it does not mean that cleanup has already run. Automation event logs require Pro/Premium.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
list-tasks |
Read | Not required | All editions
Immediate |
get-task |
Read | Not required | All editions
Immediate |
create-task |
Write | Preview | All editions
Immediate |
update-task |
Write | Preview | All editions
Immediate |
delete-task |
Write | Preview | All editions
Immediate |
get-task-events-log |
Read | Not required | Pro + Premium
Immediate |
clear-task-events-log |
Write | Preview | Pro + Premium
Immediate |
SQL database tools
Read database context, run a supported SELECT, inspect its ordinary EXPLAIN plan, or preview a restricted SQL write. All four tools require Pro/Premium.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-database-context |
Read | Not required | Pro + Premium
Immediate |
query-database |
Read | Not required | Pro + Premium
Immediate |
explain-query |
Read | Not required | Pro + Premium
Immediate |
execute-sql |
Write | Preview | Pro + Premium
Immediate |
Settings and diagnostics
Read diagnostics and manage supported operational settings.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-setting |
Read | Not required | All editions
Immediate |
update-settings |
Write | Preview | All editions
Immediate |
get-system-information |
Read | Not required | All editions
Immediate |
get-all-schedule-frequencies |
Read | Not required | All editions
Immediate |
Logs
Read supported plugin and WordPress logs, or clear the ADBC debug log.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-logs-content |
Read | Not required | All editions
Immediate |
clear-logs-content |
Write | Preview | All editions
Immediate |
Database analytics
Read database/table history. The lightweight last-week summary is available in all editions; analytics charts and the analytics summary require Pro/Premium.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-last-week-database-size-for-free-version |
Read | Not required | All editions
Immediate |
get-database-chart-data-by-day |
Read | Not required | Pro + Premium
Immediate |
get-database-chart-data-by-month |
Read | Not required | Pro + Premium
Immediate |
get-tables-chart-data-by-day |
Read | Not required | Pro + Premium
Immediate |
get-tables-chart-data-by-month |
Read | Not required | Pro + Premium
Immediate |
get-last-week-database-size |
Read | Not required | Pro + Premium
Immediate |
Plugins, themes and activity
List addons, inspect activity, or clear the entire activity history. Clearing is never restricted to the currently displayed filters.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-addons-list |
Read | Not required | Pro + Premium
Immediate |
get-addons-activity-timeline |
Read | Not required | Pro + Premium
Immediate |
clear-addons-activity |
Write | Preview | Pro + Premium
Immediate |
Existing scans and ownership corrections
Check existing scan data and manually correct ownership. No tool starts a local or remote scan. Premium and Pro use different balance tools.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
is-scan-exists |
Read | Not required | Pro + Premium
Immediate |
get-remote-scan-balance |
Read | Not required | Premium only
Immediate |
get-pro-scan-balance |
Read | Not required | Pro only
Immediate |
edit-scan-results-tables |
Write | Preview | Pro + Premium
Immediate |
edit-scan-results-options |
Write | Preview | Pro + Premium
Immediate |
edit-scan-results-transients |
Write | Preview | Pro + Premium
Immediate |
edit-scan-results-posts-meta |
Write | Preview | Pro + Premium
Immediate |
edit-scan-results-users-meta |
Write | Preview | Pro + Premium
Immediate |
edit-scan-results-post-types |
Write | Preview | Pro + Premium
Immediate |
edit-scan-results-cron-jobs |
Write | Preview | Pro + Premium
Immediate |
Licensing
Inspect, activate, refresh or deactivate the paid plugin license.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-license-status |
Read | Not required | Pro + Premium
Immediate |
activate-license |
Write | No preview | Pro + Premium
Immediate |
refresh-license |
Write | No preview | Pro + Premium
Immediate |
deactivate-license |
Write | Preview | Pro + Premium
Immediate |
Background jobs and final confirmation
Read job progress, cancel future work, or execute an approved preview. A cancellation does not undo completed changes.
| Action | Access | Confirmation | Edition / execution |
|---|---|---|---|
get-job |
Read | Not required | All editions
Immediate |
cancel-job |
Write | No preview | All editions
Immediate |
confirm-destructive-action |
Write | Final approval | All editions
Runs approved action |