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

Automattic\WooCommerce\Admin\API

ProductsLowInStock::get_items() public WC 1.0

Get low in stock products.

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

Хуков нет.

Возвращает

WP_REST_Response|WP_ERROR.

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

$ProductsLowInStock = new ProductsLowInStock();
$ProductsLowInStock->get_items( $request );
$request(WP_REST_Request) (обязательный)
request object.

Код ProductsLowInStock::get_items() WC 5.7.1

public function get_items( $request ) {
	$query_results = $this->get_low_in_stock_products(
		$request->get_param( 'page' ),
		$request->get_param( 'per_page' ),
		$request->get_param( 'status' )
	);

	// set images and attributes.
	$query_results['results'] = array_map(
		function( $query_result ) {
			$product                  = wc_get_product( $query_result );
			$query_result->images     = $this->get_images( $product );
			$query_result->attributes = $this->get_attributes( $product );
			return $query_result;
		},
		$query_results['results']
	);

	// set last_order_date.
	$query_results['results'] = $this->set_last_order_date( $query_results['results'] );

	// convert the post data to the expected API response for the backward compatibility.
	$query_results['results'] = array_map( array( $this, 'transform_post_to_api_response' ), $query_results['results'] );

	$response = rest_ensure_response( array_values( $query_results['results'] ) );
	$response->header( 'X-WP-Total', $query_results['total'] );
	$response->header( 'X-WP-TotalPages', $query_results['pages'] );

	return $response;
}