Skip to main content
Skip table of contents

Scenarios

Before using the functions on this page, you may find it useful to review the following information:

The list of all functions is here.

Description of this function

Get a list of scenarios within the current case as JSON

List of functions

  • /service/getScenarios

/service/getScenarios function – Get a list of scenarios in the currently selected case

Once a case is selected, the user can get a list of scenarios within that case by calling code similar to the following:

JS
function OnGetScenarios() {
    OnGetJson('/service/getscenarios', {});
}

A sample return from calling this function is as follows. The returned guid parameter only has a value if the corresponding scenario has been solved, and must be used for any subsequent API calls to obtain the results of that solve. If the guid is blank, it means that no results are available for that scenario (i.e., the user needs to first solve the case to get results).

JS
[
  {
    "scenarioName": "Keep super & Buy property",
    "guid": "5736d816-5ae3-4f7e-8727-52ffb154dc4b",
    "analysisYears": 20
  },
  {
    "scenarioName": "New SMSF w Property",
    "guid": "",
    "analysisYears": 20
  },
  {
    "scenarioName": "Basic cash flows",
    "guid": "",
    "analysisYears": 20
  }
]
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.