Documentation
Forge Pro
Developer Reference

Developer Reference


Constants

ConstantValueDescription
WCFORGE_PRO_VERSION1.0.0Plugin version
WCFORGE_PRO_PLUGIN_FILE__FILE__Main plugin file
WCFORGE_PRO_PLUGIN_DIRplugin_dir_path()Plugin directory
WCFORGE_PRO_PLUGIN_URLplugin_dir_url()Plugin URL
WCFORGE_PRO_REST_NAMESPACEwindcodex-forge/v1REST namespace (same as the free plugin)
WCFORGE_PRO_REST_ROUTE/mcpMCP route
WCFORGE_PRO_LICENSE_OPTIONwcforge_pro_license_keyLicense key option
WCFORGE_PRO_LICENSE_STATUS_OPTIONwcforge_pro_license_statusLicense status option

REST Routes

RouteMethodDescription
/wp-json/windcodex-forge/v1/mcpPOSTMCP JSON-RPC endpoint (Bearer token)
/wp-json/windcodex-forge/v1/oauth/registerPOSTDynamic client registration (10 per hour per IP)
/wp-json/windcodex-forge/v1/oauth/tokenPOSTToken exchange and refresh
/wcforge-oauth/authorizeGET/POSTConsent screen (rewrite rule)

Options

OptionDescription
wcforge_settingsAll settings (shared with Forge)
wcforge_pro_license_keyLicense key
wcforge_pro_license_statusCached license status

Notable keys in wcforge_settings:

KeyDefaultDescription
enabledtrueConnector master switch
read_onlyfalseStrip non-read-only tools
primitive_enabledsee ToolsPer-tool toggles
allow_direct_live_writesfalseExpose wp_write_file
backup_acknowledgedfalseRequired for wp_execute_php and admin login links
live_site_overridefalseAllow power tools on production-detected sites
live_site_override_locked_domain''Domain the override is locked to
requests_per_minute_limit12010-600
max_results_limit50List and query cap

Filters

FilterArgumentsDescription
wcforge_pro_ability_capability$capability (string), $tool_name (string)Change the capability required to run a tool through the Abilities API. Default manage_options
add_filter( 'wcforge_pro_ability_capability', function ( $capability, $tool_name ) {
    return 'manage_options';
}, 10, 2 );

WP-Cron

HookDescription
wcforge_pro_run_cli_jobRuns a queued background WP-CLI job. Scheduled with wp_schedule_single_event()

Filesystem Locations

PathDescription
wp-content/wcforge-pro-drafts/Sandbox draft area

Terminal Commands

wp forge status
wp forge snapshots [--limit=<n>]

WordPress Abilities API

On WordPress 6.9+, each tool is registered as an ability in the windcodex-forge category.

The MCP endpoint, the Abilities API, and the wp forge commands are the supported integration surfaces. Internal PHP classes are not a public API.