Description

This function enables or disables BoxTrapper for an email account.

Examples 




$cpanel = new CPANEL(); // Connect to cPanel - only do this once.
$boxtrapper_status = $cpanel->api1('BoxTrapper', 'changestatus', array('user@example.com', 'enable') ); // Call the function.



my $cpliveapi = Cpanel::LiveAPI->new(); # Connect to cPanel - only do this once.
my $boxtrapper_status = $cpliveapi->api1('BoxTrapper', 'changestatus', ['user@example.com', 'enable'] ); # Call the function.

 


<cpanel Module="BoxTrapper::changestatus( $FORM('account','action') )">




cpapi1 --user=username BoxTrapper changestatus user@example.com enable



enabled




Parameters

ParameterTypeDescriptionPossible valuesExample
accountstring

Required

The account's email address.

A valid email address on the server.user@example.com
actionstring

Required

The desired action.

  • enable — Enables BoxTrapper.
  • disable — Disables BoxTrapper.

All other values disable BoxTrapper. 


enable

Returns

  • disabled — BoxTrapper is now disabled for the account.
  • enabled — BoxTrapper is now enabled for the account.