WordPress как на ладони
Недорогой хостинг для сайтов на WordPress: wordpress.jino.ru
функция не описана

WC_REST_Payment_Gateways_V2_Controller::get_items() public WC 1.0

Get payment gateways.

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

Хуков нет.

Возвращает

WP_Error/WP_REST_Response.

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

$WC_REST_Payment_Gateways_V2_Controller = new WC_REST_Payment_Gateways_V2_Controller();
$WC_REST_Payment_Gateways_V2_Controller->get_items( $request );
$request(WP_REST_Request) (обязательный)
Full details about the request.

Код WC_REST_Payment_Gateways_V2_Controller::get_items() WC 4.7.0

<?php
public function get_items( $request ) {
	$payment_gateways = WC()->payment_gateways->payment_gateways();
	$response         = array();
	foreach ( $payment_gateways as $payment_gateway_id => $payment_gateway ) {
		$payment_gateway->id = $payment_gateway_id;
		$gateway             = $this->prepare_item_for_response( $payment_gateway, $request );
		$gateway             = $this->prepare_response_for_collection( $gateway );
		$response[]          = $gateway;
	}
	return rest_ensure_response( $response );
}