Automattic\WooCommerce\Internal\Abilities\Domain

OrderAddNote::get_input_schemaprivate staticWC 1.0

Get the ability input schema.

Method of the class: OrderAddNote{}

No Hooks.

Returns

Array.

Usage

$result = OrderAddNote::get_input_schema(): array;

OrderAddNote::get_input_schema() code WC 11.0.1

private static function get_input_schema(): array {
	return array(
		'type'                 => 'object',
		'properties'           => array(
			'id'            => array(
				'type'    => 'integer',
				'minimum' => 1,
			),
			'note'          => array(
				'type'        => 'string',
				'description' => __( 'Order note content. Safe HTML is allowed.', 'woocommerce' ),
				'minLength'   => 1,
				'pattern'     => '\S',
			),
			'customer_note' => array(
				'type'        => 'boolean',
				'description' => __(
					'Whether the note is visible to the customer. Defaults to false for a private/admin note.',
					'woocommerce'
				),
				'default'     => false,
			),
		),
		'required'             => array( 'id', 'note' ),
		'additionalProperties' => false,
	);
}