WordPress at Your Fingertips
function is not described

WP_REST_Server::get_max_batch_size() protected WP 5.6.0

Gets the maximum number of requests that can be included in a batch.

{} It's a method of the class: WP_REST_Server{}

Hooks from the method
Return

Int. The maximum requests.

Usage

// protected - for code of main (parent) or child class
$result = $this->get_max_batch_size();

Changelog

Since 5.6.0 Introduced.

Code of WP_REST_Server::get_max_batch_size() WP 5.7.2

<?php
protected function get_max_batch_size() {
	/**
	 * Filters the maximum number of REST API requests that can be included in a batch.
	 *
	 * @since 5.6.0
	 *
	 * @param int $max_size The maximum size.
	 */
	return apply_filters( 'rest_get_max_batch_size', 25 );
}