PreSale Actions

When your pre-purchased credit goes below a certain threshold, you might want to be notified via email. This functionality can be very useful in order to keep your credit under control, prevent you from running out of it and, in case, refill the presale.

The sending of the email as a consequence of reaching a certain threshold is a Presale Action. A PreSale Action can be setup with the dedicated APIs.

Creating a new PreSaleAction resource

You can create and configure a PreSaleAction resource through the create PreSaleAction operation.

You will be able to set some parameters:

  • threshold (integer): the value under which the PreSaleAction is triggered
  • action_type (string): what kind of action to trigger (example: alert_email ). Currently only alert_mail is supported, but new actions will soon be available (automatic refill will be the next)
  • target (string): the target used by the action. In case of alert_email the target must be the email address that will receive the message
  • enabled (boolean): the trigger of the action is enabled or not
  • uuid (string): the action identifier

You can create and set many PreSale Actions resources.

To get the list of all the PreSale Actions and their current status, use the get PreSale Actions Collection API.

To get a specific PreSale Action resourse, use the get PreSale Action Item API specifying its uuid.