Automattic\WooCommerce\Internal\Admin\Settings\PaymentsProviders\WooPayments

WooPaymentsRestController::get_schema_properties_for_onboarding_step_actionprivateWC 1.0

Get the schema properties for an onboarding step action.

Method of the class: WooPaymentsRestController{}

No Hooks.

Returns

Array[]. The schema properties for an onboarding step action.

Usage

// private - for code of main (parent) class only
$result = $this->get_schema_properties_for_onboarding_step_action(): array;

WooPaymentsRestController::get_schema_properties_for_onboarding_step_action() code WC 10.7.0

private function get_schema_properties_for_onboarding_step_action(): array {
	return array(
		'type' => array(
			'type'        => 'string',
			'description' => esc_html__( 'The action type to determine how to use the URL.', 'woocommerce' ),
			'enum'        => array( WooPaymentsService::ACTION_TYPE_REST, WooPaymentsService::ACTION_TYPE_REDIRECT ),
			'context'     => array( 'view', 'edit' ),
			'readonly'    => true,
		),
		'href' => array(
			'type'        => 'string',
			'description' => esc_html__( 'The URL to use for the action.', 'woocommerce' ),
			'context'     => array( 'view', 'edit' ),
			'readonly'    => true,
		),
	);
}