Services Credits Apex Actions

The following Apex actions are available for use with services credits. For more information about Apex actions, see the Salesforce Help.

Services Credits Apex Actions
Category Apex Action Apex Class Purpose
Services Credits Adjust Services Credits on Milestones ServiceCrdtsServiceActionAdjCreditsForMS

Adjusts the services credits allocated to the specified milestones by the given amounts.

Note:

You cannot adjust the services credits for the same milestone multiple times in one request. The action throws an error if this occurs.

Services Credits Allocate Services Credits to Milestones ServiceCrdtsServiceActionAllocCredsForMS Allocates services credits to milestones when milestone IDs are valid. This method returns allocation IDs. If any of the records are invalid, the allocation process fails for all the records.
Services Credits Expire Services Credits Customer Purchases ServiceCreditsServcActionExpirePurchases Expires available services credits that remain on services credits customer purchase records where the expiry date is in the past. For each purchase ID, a result object is returned. If the expiry process is successful, the result object contains the newly created allocation ID. For any records that could not be expired, the result object contains an error message.