How do you programmatically enable a payment method? I have enabled the payment method module I want to use.  I am using Authorize.net.

However, by default it is disabled in the Payment methods listing.  

In my module, I want to enable the payment method module for use when my module is installed.
Just update the rules_config entity.

$config = rules_config_load('name_of_your_rules_config');
$config-&gt;active = 1;
$config-&gt;save();


If you are not sure what the name of your rules config entity is run:

$configs = entity_load('rules_config');
foreach($configs as $config) {
  dpm($config, $config-&gt;name);
}


This will list all rule config entities that you have.