• File: AbilitiesRestBridge.php
  • Full Path: /home/slvgwrnz/public_html/wp-content/plugins/woocommerce/src/Internal/Abilities/AbilitiesRestBridge.php
  • Date Modified: 10/26/2026 10:38 AM
  • File size: 1007 B
  • MIME-type: text/x-php
  • Charset: utf-8
<?php
/**
 * Abilities REST Bridge class file.
 */

declare( strict_types=1 );

namespace Automattic\WooCommerce\Internal\Abilities;

use Automattic\WooCommerce\Internal\MCP\McpEndpointRemoval;

defined( 'ABSPATH' ) || exit;

/**
 * Formerly registered REST-derived abilities for the WooCommerce MCP endpoint.
 *
 * Kept so existing callers don't fatal. The methods do nothing except report incorrect usage.
 *
 * @deprecated 11.3.0 Removed along with the WooCommerce MCP endpoint. Use the WooCommerce abilities registered through the WordPress Abilities API.
 */
class AbilitiesRestBridge {

	/**
	 * Formerly hooked the REST-derived ability registration.
	 *
	 * @internal
	 *
	 * @deprecated 11.3.0
	 */
	final public static function init(): void {
		McpEndpointRemoval::doing_it_wrong( __METHOD__ );
	}

	/**
	 * Formerly registered the REST-derived abilities.
	 *
	 * @deprecated 11.3.0
	 */
	public static function register_abilities(): void {
		McpEndpointRemoval::doing_it_wrong( __METHOD__ );
	}
}