in woocommerce you can activate the payment items via toggle. this is build with ajax.
In chrome browser, network tab i can see the payload object which was send to "wp-admin/admin-ajax.php"
{
action: woocommerce_toggle_gateway_enabled
security: 33212389b2
gateway_id: cheque
}
Is it possible in wordpress directly access the action "woocommerce_toggle_gateway_enabled" via php and set the value?