processPendingUsageInput  API is used to process Usage Inputs. On completion of the batch job, the user receives a batch job status email. 

You can process the usage inputs in two ways:

  • Process all the loaded usage inputs
  • Process an explicit set of usage inputs
APISignature
processPendingUsageInputstatic void processPendingUsageInput()

This API processes all the usage inputs with status as 'Loaded'.

Code Sample

Apttus_Billing.BillingService.processPendingUsageInput();
CODE



APISignature
processPendingUsageInputstatic void processPendingUsageInput(Set usageInputIDs)

This API processes usage inputs for all the usage inputs IDs with status as 'Loaded'. It accepts a Set of Usage Input IDs as input and checks the Usage Input Status for each Usage Input ID. It processes all the usage inputs with staus as 'Loaded'.

Request

Field

Type

Required?

Description

usageInputIDs

Set <Id>

No

Set of usage input IDs

Code Sample

Set<Id> usageInputIds = new Set<ID>{usageInput1.Id, usageInput2.Id};
Apttus_Billing.BillingService.processPendingUsageInput(usageInputIds);
CODE



APISignature
processPendingUsageInputstatic void processPendingUsageInput(Set usageInputIDs, Boolean processSynchronously)

This API processes usage inputs for all the usage inputs IDs with status as 'Loaded'. It accepts a Set of Usage Input IDs as input and checks the Usage Input Status for each Usage Input ID. It processes all the usage inputs with staus as 'Loaded'.If processSynchronously is set to true, the usage inputs are processed synchronously without any batch job. You can process only a maximum of 1000 usage inputs. If processSynchronously is set to false, the API will schedule a batch job to process all the given usage inputs.

Request

Field

Type

Required?

Description

usageInputIDs

Set <Id>

No

Set of usage input IDs

processSynchronouslyBooleanNoIndicates whether to process the Usage Inputs synchronously or asynchronously. The default value is false.


Code Sample

// To process Usage Inputs Synchronously
Set<ID> usageInputIDs = new Set<ID>(); //Max it can be 1000 IDs
Apttus_Billing.BillingService. processPendingUsageInput(usageInputIDs, true);
// To process Usage Inputs Asynchronously
Set<ID> usageInputIDs = new Set<ID>(); //Max it can be any number of IDs
Apttus_Billing.BillingService. processPendingUsageInput(usageInputIDs, false);
CODE