Recreate Account Calculations Underlying a Savings Analysis
Use Account Cost Calculation requests to inspect the calculations underlying a savings analysis with specific detailLevel and groupBy settings.
Use Account Cost Calculation requests to inspect the calculations underlying a Savings Analysis with specific detailLevel and groupBy settings.
When reviewing a Savings Analysis, you might want to inspect the components that derive the bundled rates presented in the first-year forecast. Use Account Cost Calculation to observe the underlying data in greater detail. For a full validation workflow, see How to Validate Savings Analyses.
Send a POST request to one of the following endpoints to generate an underlying calculation for a Savings Analysis. This method lets you specify the detailLevel and groupBy fields in your request, which gives you the data granularity you need.
Using account ID:
POST /rest/v1/accounts/{accountId}/calculate/Using provider account ID:
POST /rest/v1/accounts/pid/{providerAccountId}/calculate/Recreate calculation workflow
- Identify the Savings Analysis inputs you want to inspect.
- Choose the account identifier.
- Set the calculation period.
- Pass the consumption and solar profiles explicitly.
- Set the tariff for the scenario you want to inspect.
- Choose
detailLevelandgroupByoptions. - Run the Account Cost Calculation and compare the result to the Savings Analysis.
Scenario: Full Switch account
An account that has conducted a full Savings Analysis will generally have default profiles set at the account level. The calculator uses properties and rates set at the account level. However, you can use the propertyInputs and rateInputs lists to override these defaults. When recreating Savings Analysis calculations, we strongly recommend setting includeDefaultProfile to false and passing in consumption and solar profiles directly to avoid unexpected behavior.
Step 1: Set the account URL
Update the POST URL with the appropriate identifier.
Step 2: Set the profile IDs
Update the placeholder values for the profiles in the POST body to align with the account. You can refer back to the response object in the Savings Analysis to identify the consumption and solar profiles.
Step 3: Set the tariff
Use the pre-solar masterTariffId when recreating the before-solar calculations. Use the post-solar masterTariffId when recreating the after-solar calculations.
Step 4: Verify the request structure
Verify the request structure before sending it:
- The
fromDateTimeandtoDateTimeparameters align with the Savings Analysis. You can observe one year of data or adjust these parameters to align with one month of the Savings Analysis. - The correct time zone value is set on
fromDateTimeandtoDateTime. An incorrect time zone can negatively influence the cost calculation. - The
operatorkey with a value of-must be present on the solar profile property object if stored as positive values in the corresponding profile (this is the standard approach). - The
autoBaselineanduseIntelligentBaseliningparameter values match the original Savings Analysis request.
Step 5: Send the request
Issue the POST request and observe the response. You can adjust detailLevel and groupBy to change the granularity of the returned data. Depending on the scenario, update the masterTariffId if a tariff change occurred as a result of the solar system implementation.
Request template:
POST /rest/v1/accounts/{yourAccountId}/calculate/{
"fromDateTime": "2024-08-01T00:00:00-05:00",
"toDateTime": "2024-09-01T00:00:00-05:00",
"includeDefaultProfile": "false",
"minimums": "true",
"detailLevel": "CHARGE_TYPE",
"groupBy": "ALL",
"fields": "EXT",
"masterTariffId": 3479298,
"autoBaseline": true,
"useIntelligentBaselining": true,
"propertyInputs": [
{
"keyName": "profileId",
"dataType": "STRING",
"dataValue": "{yourConsumptionProfileId}",
"scenarios": "before"
},
{
"keyName": "profileId",
"dataType": "STRING",
"dataValue": "{yourSolarProfileId}",
"scenarios": "after",
"operator": "-"
}
]
}Request field reference
| Field | Purpose |
|---|---|
fromDateTime / toDateTime | Sets the calculation period to inspect. |
includeDefaultProfile | Set to false when passing profiles explicitly. |
minimums | Controls whether minimum charges are included. |
detailLevel | Controls the level of charge detail returned. |
groupBy | Controls the aggregation level of the response. |
fields | Includes extended fields when set to EXT. |
masterTariffId | Sets the tariff used for the scenario calculation. |
autoBaseline | Should match the Savings Analysis setting. |
useIntelligentBaselining | Should match the Savings Analysis setting. |
propertyInputs[].profileId | Identifies the consumption or solar profile used in the calculation. |
operator: "-" | Subtracts solar production from consumption for the post-solar scenario. |
Compare the response
After the request succeeds, compare the returned costs, quantities, and line items against the Savings Analysis values for the same scenario and date range.
Check these fields first:
summary.totalCostsummary.adjustedTotalCostsummary.kWhitems[].chargeTypeitems[].rateAmountitems[].itemQuantityitems[].cost
If the recreated calculation does not match the Savings Analysis, confirm that the account, profiles, tariff, date range, time zone, autoBaseline, and useIntelligentBaselining values match the original analysis.
Summary
You can recreate the account-level calculations behind a Savings Analysis by passing the same account, profile, tariff, date range, and baselining inputs into Account Cost Calculation. Use detailLevel and groupBy to control how granularly you inspect the calculation response.
Updated 5 days ago
