Skip to main content
JavaScript
Smile.earningRules.get().then(
  (earningRules) => {
    // Handle the earning rules collection
  }
);
This async method retrieves a list of all earning rules for the account. This method always makes an API call to fetch the latest data.
For the best performance, we suggest preloading earning rules and then using the Smile.earningRules.preloaded() method.

Returns

This method returns a Promise that: If the method is improperly invoked, the Promise will be rejected.