Creates or updates the cost calculation configuration for a calculated bill version
Use this endpoint to define how the calculated bill derives its cost value. Options include copying from a source meter,
using a fixed value, applying a rate, or using a formula. At least one cost option is always required.
The operation is transactional.
Request Headers
| Header | Value | Required | Description |
|---|---|---|---|
| ECI-ApiKey | string | Yes | Your API key. See Authentication. |
| Content-Type | application/json | Yes | All requests must specify JSON content type, including the request body. |
Path Parameters
| Name | Description | Type | Required |
|---|---|---|---|
| accountId | Unique numeric identifier of the account | integer (int32) | Required |
| meterId | Unique numeric identifier of the meter | integer (int32) | Required |
| versionId | Unique numeric identifier of the calculated bill distribution version | integer (int32) | Required |
Request Body
CalculatedBillCostRequest
| Property | Description | Type | |||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| calendarizedCostCalculation | CalendarizedCalculationRequest | ||||||||||||||||||||||||||||||||||
|
CalendarizedCalculationRequest properties
|
|||||||||||||||||||||||||||||||||||
| copyCostFromMeter | CopyMeterRequest | ||||||||||||||||||||||||||||||||||
|
CopyMeterRequest properties
|
|||||||||||||||||||||||||||||||||||
| costCalculation | CalculationRequest | ||||||||||||||||||||||||||||||||||
|
CalculationRequest properties
|
|||||||||||||||||||||||||||||||||||
| fixedAmount | Use a fixed amount for bill cost Max scale of 2 NULL Valid Required (defined) Only one of UseCurrentMetersRateSchedule, FixedUnitCost, UnitCostMeterId, FixedAmount, CopyCostFromMeter, CostCalculation, CalendarizedCostCalculation can be set | number (double) | |||||||||||||||||||||||||||||||||
| fixedUnitCost | FixedUnitCostRequest | ||||||||||||||||||||||||||||||||||
|
FixedUnitCostRequest properties
|
|||||||||||||||||||||||||||||||||||
| unitCostMeterId | MeterId from where to get the unit cost Required (defined) Only one of UseCurrentMetersRateSchedule, FixedUnitCost, UnitCostMeterId, FixedAmount, CopyCostFromMeter, CostCalculation, CalendarizedCostCalculation can be set | integer (int32) | |||||||||||||||||||||||||||||||||
| useCurrentMetersRateSchedule | Apply the meter’s current rate when calculating bill cost “true” is the only valid value for this property One of ‘True’ Case sensitive Required (defined) Only one of UseCurrentMetersRateSchedule, FixedUnitCost, UnitCostMeterId, FixedAmount, CopyCostFromMeter, CostCalculation, CalendarizedCostCalculation can be set | boolean | |||||||||||||||||||||||||||||||||
Example Request Body
{ "calendarizedCostCalculation": { "sum": { "sumMeterIds": []
}
}, "copyCostFromMeter": { "meterId": 1, "percentage": 1.0
}, "costCalculation": { "subtract": { "subtractMeterGroupIds": [], "subtractMeterIds": []
}, "sum": { "sumMeterGroupIds": [], "sumMeterIds": []
}
}, "fixedAmount": 1.0, "fixedUnitCost": { "unitCost": 1.0, "unitId": 1
}, "unitCostMeterId": 1, "useCurrentMetersRateSchedule": false
}
Responses
200
OK
The request succeeded and the response body contains the requested data.
Response Body Parameters
CalculatedBillCostResponse
| Property | Description | Type | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| calendarizedCostCalculation | CalendarizedCalculationResponse | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
CalendarizedCalculationResponse properties
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| copyCostFromMeter | CopyFromMeterResponse | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
CopyFromMeterResponse properties
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| costCalculation | CalculationResponse | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
CalculationResponse properties
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| fixedAmount | Use a fixed amount for bill cost | number (double) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| fixedUnitCost | FixedAmountResponse | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
FixedAmountResponse properties
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| rateSchedule | RateChildResponse | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
RateChildResponse properties
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| unitCostFromMeter | MeterChild | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
MeterChild properties
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Example Response
{ "calendarizedCostCalculation": { "calendarizedSum": [
{ "active": false, "commodity": {}, "isCalculatedMeter": false, "isEsaCalculatedMeter": false, "isSplitChildMeter": false, "isSplitParentMeter": false, "meterCode": "string", "meterId": 1, "meterInfo": "string", "meterType": {}, "serialNumber": "string"
}
]
}, "copyCostFromMeter": { "meter": { "active": false, "commodity": {}, "isCalculatedMeter": false, "isEsaCalculatedMeter": false, "isSplitChildMeter": false, "isSplitParentMeter": false, "meterCode": "string", "meterId": 1, "meterInfo": "string", "meterType": {}, "serialNumber": "string"
}, "percentage": 1.0
}, "costCalculation": { "subtract": { "subtractMeterGroups": [], "subtractMeters": []
}, "sum": { "sumMeterGroups": [], "sumMeters": []
}
}, "fixedAmount": 1.0, "fixedUnitCost": { "amount": 1.0, "unit": { "unitCode": "string", "unitId": 1, "unitInfo": "string"
}
}, "rateSchedule": { "commodity": { "commodityCode": "string", "commodityIcon": {}, "commodityId": 1, "commodityInfo": "string"
}, "name": "string", "rateId": 1
}, "unitCostFromMeter": { "active": false, "commodity": { "commodityCode": "string", "commodityIcon": {}, "commodityId": 1, "commodityInfo": "string"
}, "isCalculatedMeter": false, "isEsaCalculatedMeter": false, "isSplitChildMeter": false, "isSplitParentMeter": false, "meterCode": "string", "meterId": 1, "meterInfo": "string", "meterType": { "meterTypeCode": "string", "meterTypeId": 1, "meterTypeInfo": "string"
}, "serialNumber": "string"
}
}