Automattic\WooCommerce\Admin\API

Experiments::register_routes()publicWC 1.0

Register routes.

{} Это метод класса: Experiments{}

Хуков нет.

Возвращает

null. Ничего.

Использование

$Experiments = new Experiments();
$Experiments->register_routes();

Код Experiments::register_routes() WC 6.6.1

public function register_routes() {
	register_rest_route(
		$this->namespace,
		'/' . $this->rest_base . '/assignment',
		array(
			array(
				'methods'             => \WP_REST_Server::READABLE,
				'callback'            => array( $this, 'get_assignment' ),
				'permission_callback' => array( $this, 'get_item_permissions_check' ),
			),
			'schema' => array( $this, 'get_public_item_schema' ),
		)
	);
}