Services relating to block_water_heaters of the Energy Asset Tool. This describes the relationship between a block and water_heater.

Supported Formats

json, xml

GET /api/v1/block_water_heaters/:id
Retrieve the block_water_heater with the specific ID.

Supported Formats

json, xml

Errors

Code Description
401 Unauthorized - ensure token is being passed with each service call.
404 Unsupported operation
500 Unspecified error on server.

Examples

<block-water-heater>
<block-id type="integer">3</block-id>
<created-at type="datetime">2013-06-28T17:01:43Z</created-at>
<id type="integer">2</id>
<updated-at type="datetime">2013-06-28T17:01:43Z</updated-at>
<water-heater-id type="integer">1</water-heater-id>
</block-water-heater>

GET /api/v1/blocks/:block_id/block_water_heaters
Retrieve all block_water_heaters belonging to the block.

Supported Formats

json, xml

Errors

Code Description
401 Unauthorized - ensure token is being passed with each service call.
404 Unsupported operation
500 Unspecified error on server.

Examples

response:  {"block_id":2,"created_at":"2013-09-04T21:21:59Z","id":2,"updated_at":"2013-09-04T21:21:59Z","water_heater_id":1}

POST /api/v1/blocks/:block_id/block_water_heaters
Create a new block_water_heater. This will associate the block_water_heater with the block and return a BlockWaterHeater object with unique ID assigned.

Also see Water Heaters belonging to the building that can be associated with this block..

Supported Formats

json, xml

Errors

Code Description
401 Unauthorized - ensure token is being passed with each service call.
404 Unsupported operation
500 Unspecified error on server.

Examples

{"water_heater_id":1}
<block_water_heater>
  <water-heater-id type="integer">1</water-heater-id>
</block_water_heater>

Params

Param name Description
water_heater_id
required

ID of Water Heater.

Validations:

  • Must be a Integer


PUT /api/v1/block_water_heaters/:id
Update an existing block_water_heater. Nothing is returned.

Supported Formats

json, xml

Errors

Code Description
401 Unauthorized - ensure token is being passed with each service call.
404 Unsupported operation
500 Unspecified error on server.

Params

Param name Description
water_heater_id
required

ID of Water Heater.

Validations:

  • Must be a Integer


DELETE /api/v1/block_water_heaters/:id
Delete the block_water_heater and disassociate it from the block. Nothing is returned.

Supported Formats

json, xml

Errors

Code Description
401 Unauthorized - ensure token is being passed with each service call.
404 Unsupported operation
500 Unspecified error on server.