Automattic\WooCommerce\Admin\Features\Blueprint

RestApi::get_queue_response_schema()publicWC 1.0

Get the schema for the queue endpoint.

Метод класса: RestApi{}

Хуков нет.

Возвращает

Массив.

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

$RestApi = new RestApi();
$RestApi->get_queue_response_schema();

Код RestApi::get_queue_response_schema() WC 9.7.1

public function get_queue_response_schema() {
	$schema = array(
		'$schema'    => 'http://json-schema.org/draft-04/schema#',
		'title'      => 'queue',
		'type'       => 'object',
		'properties' => array(
			'reference'             => array(
				'type' => 'string',
			),
			'process_nonce'         => array(
				'type' => 'string',
			),
			'settings_to_overwrite' => array(
				'type'  => 'array',
				'items' => array(
					'type' => 'string',
				),
			),
			'error_type'            => array(
				'type'    => 'string',
				'default' => null,
				'enum'    => array( 'upload', 'schema_validation', 'conflict' ),
			),
			'errors'                => array(
				'type'  => 'array',
				'items' => array(
					'type' => 'string',
				),
			),
		),
	);

	return $schema;
}