Automattic\WooCommerce\Admin\API\Reports\Export

Controller::get_export_collection_params()protectedWC 1.0

Get the query params for collections.

Method of the class: Controller{}

No Hooks.

Return

Array.

Usage

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

Controller::get_export_collection_params() code WC 7.3.0

protected function get_export_collection_params() {
	$params                = array();
	$params['report_args'] = array(
		'description'       => __( 'Parameters to pass on to the exported report.', 'woocommerce' ),
		'type'              => 'object',
		'validate_callback' => 'rest_validate_request_arg', // @todo: use each controller's schema?
	);
	$params['email']       = array(
		'description'       => __( 'When true, email a link to download the export to the requesting user.', 'woocommerce' ),
		'type'              => 'boolean',
		'validate_callback' => 'rest_validate_request_arg',
	);
	return $params;
}