You have no favorites... yet!
Use the Library tree on the left to select a Choreo to call from your gateway device.
Use the Library tree on the left to select a Choreo to call from your edge device via the gateway.
Library . Genability . PricingAndCalc . RunNewPriceCalculation
Calculate electricity costs based on a POSTed calculation criteria.
/*
TembooTask class placeholder
*/
/*
TembooTask header placeholder
*/
Since you've changed your device configuration, you'll need to tell us about this new device.
This feature is in experimental mode - pricing coming soon.
Send your code straight to a GitHub repository.
Your code will be visible by others in your repos. Keep credentials private by saving a Profile or commit code with Placeholder inputs.
The following files will be added to this repo:
You'll be able to edit and share your code from TI's CCS Cloud IDE.
The following will be sent to CCS Cloud:
/*
Your auto-generated code will appear here once you've configured your device above.
*/
/*
A header file containing your Temboo account information will appear here once you've
configured your device above.
*/
/*
Please log in to generate proxy server code for use with the JavaScript SDK.
*/
This Choreo calculates electricity costs based on a POSTed calculation criteria. The documentation for this Genability resource can be found here.
Here's an example of acceptable inputs:
AppID: {YOUR APP ID}
AppKey: {YOUR APP KEY}
The calculation criteria is entered, in JSON format, in the PostData variable. Here's an example JSON post request:
{ "fromDateTime" : "2011-12-01T00:00:00-05:00", "toDateTime" : "2011-12-01T01:00:00-05:00", "tariffInputs" : [ { "keyName" : "consumption", "fromDateTime" : "2011-12-01T00:00:00-0500", "toDateTime" : "2011-12-01T00:15:00-0500", "unit" : "kWh", "dataValue" : 2.2 }, { "keyName" : "consumption", "fromDateTime" : "2011-12-01T00:15:00-0500", "toDateTime" : "2011-12-01T00:30:00-0500", "unit" : "kWh", "dataValue" : 1.3 }, { "keyName" : "consumption", "fromDateTime" : "2011-12-01T00:30:00-0500", "toDateTime" : "2011-12-01T00:45:00-0500", "unit" : "kWh", "dataValue" : 0.6 }, { "keyName" : "consumption", "fromDateTime" : "2011-12-01T00:45:00-0500", "toDateTime" : "2011-12-01T01:00:00-0500", "unit" : "kWh", "dataValue" : 2.1 }, { "keyName" : "cityLimits", "fromDateTime" : "2011-12-01T00:00:00-0500", "toDateTime" : "2011-12-01T01:00:00-0500", "dataValue" : "Inside" } , { "keyName" : "connectionType", "fromDateTime" : "2011-12-01T00:00:00-0500", "toDateTime" : "2011-12-01T01:00:00-0500", "dataValue" : "Primary" } ] }
The following is a sample of the JSON information returned by this Choreo:
{ "status" : "success", "count" : 1, "type" : "CalculatedCost", "results" : [ { "masterTariffId" : 512, "tariffName" : "Residential Service", "fromDateTime" : "2011-12-01T00:00:00-05:00", "toDateTime" : "2011-12-01T01:00:00-05:00", "totalCost" : 0.326115, "accuracy" : 1.0, "items" : [ { "tariffRateId" : 2734, "tariffRateBandId" : 3258, "rateGroupName" : "Basic Service Charge", "rateName" : "Basic Service Charge", "fromDateTime" : "2011-12-01T00:00:00-05:00", "toDateTime" : "2011-12-01T01:00:00-05:00", "rateType" : "COST_PER_UNIT", "quantityKey" : "fixed", "itemQuantity" : 1.0, "itemCount" : 1, "cost" : 0.012097 }, { "tariffRateId" : 16959920, "tariffRateBandId" : 10139634, "rateGroupName" : "Demand Side Management Residential Schedule", "rateName" : "Demand Side Management Residential Schedule", "fromDateTime" : "2011-12-01T00:00:00-05:00", "toDateTime" : "2011-12-01T01:00:00-05:00", "rateType" : "PERCENTAGE", "quantityKey" : "fixed", "itemQuantity" : 1.0, "itemCount" : 1, "cost" : .000008 }, { "tariffRateId" : 2724, "tariffRateBandId" : 3248, "rateGroupName" : "Environmental Compliance Cost Recovery Schedule", "rateName" : "Environmental Compliance Cost Recovery Schedule", "fromDateTime" : "2011-12-01T00:00:00-05:00", "toDateTime" : "2011-12-01T01:00:00-05:00", "rateType" : "PERCENTAGE", "quantityKey" : "fixed", "itemQuantity" : 1.0, "itemCount" : 1, "cost" : .0000044 }, { "tariffRateId" : 16968759, "tariffRateBandId" : 10147863, "rateGroupName" : "Municipal Franchise Fee Schedule", "rateName" : "Municipal Franchise Fee Schedule", "fromDateTime" : "2011-12-01T00:00:00-05:00", "toDateTime" : "2011-12-01T01:00:00-05:00", "rateType" : "PERCENTAGE", "quantityKey" : "QUANTITY", "itemQuantity" : 1.0, "itemCount" : 1, "cost" : .0000013, "rateAmount" : 2.9109 }, { "tariffRateId" : 16959921, "tariffRateBandId" : 10139635, "rateGroupName" : "Nuclear Construction Cost Recovery Schedule", "rateName" : "Nuclear Construction Cost Recovery Schedule", "fromDateTime" : "2011-12-01T00:00:00-05:00", "toDateTime" : "2011-12-01T01:00:00-05:00", "rateType" : "PERCENTAGE", "quantityKey" : "fixed", "itemQuantity" : 1.0, "itemCount" : 1, "cost" : .0000028 }, { "tariffRateId" : 2735, "tariffRateBandId" : 3259, "rateGroupName" : "Energy Charges", "rateName" : "Winter Energy Charges", "fromDateTime" : "2011-12-01T00:00:00-05:00", "toDateTime" : "2011-12-01T01:00:00-05:00", "rateType" : "COST_PER_UNIT", "quantityKey" : "consumption", "itemQuantity" : 6.2, "itemCount" : 1, "cost" : 0.313925 }, { "tariffRateId" : 2737, "tariffRateBandId" : 3265, "rateGroupName" : "Minimum Charge", "rateName" : "Minimum Charge", "fromDateTime" : "2011-12-01T00:00:00-05:00", "toDateTime" : "2011-12-01T01:00:00-05:00", "rateType" : "COST_PER_UNIT", "quantityKey" : "minimum", "itemQuantity" : 1.0, "itemCount" : 1, "cost" : 0.0, "rateAmount" : 9.0 } ] } ] }
https://ACCOUNT_NAME.temboolive.com/callback/google
© 2025 Temboo, Inc Privacy Terms