Web Service Documentation / Categories / Meter Services / Get Meter Consumption Data

Get Meter Consumption Data

Updated on August 14, 2017

Description

This web service retrieves consumption data for a specific meter. The meter must already be shared with you. The consumption data is returned in sets of 120. An optional date range can specified to return a certain set of consumption records.

Version

22.0

HTTP Method

GET

Resource URL

/meter/(meterId)/consumptionData?page=(page)&startDate=(YYYY-MM-DD)&endDate=(YYYY-MM-DD)

Header

Field Name Value Comments
Authorization Basic credentials

Authorization Required

Yes

Parameters

Parameter Name Description
endDate Optional. Indicates the end date of a custom date range to retrieve consumption data. Must be a valid date formatted as YYYY-MM-DD.
meterId Id to the meter
page Optional. Indicates the page number set of results to retrieve. This is typically omitted on the initial call and is provided if the results are paginated.
startDate Optional. Indicates the start date of a custom date range to retrieve consumption data. Must be a valid date formatted as YYYY-MM-DD.

XML Schemas

Request/Response Schema Name
Request None
Response meterConsumptionData.xsd

Example Request

The following example retrieves consumption information for a meter that has an id of 100. If you want to just retrieve consumption records that cover a date range of January 1st, 2011 to December 31st, 2011 then the following URL parameters should be provided: startDate=2011-01-01&endDate=2011-12-31

GET  /meter/100/consumptionData

Example Responses

The following example returns the first set of 120 consumption records for a meter that is metered and provides a link to the next set. For example purposes, assume that over 120 records are returned.

<?xml version="1.0" encoding="UTF-8"?>
<meterData>
    <meterConsumption estimatedValue="false">
        <id>-19</id>
        <audit>
            <createdBy>DUNAYT</createdBy>
            <createdByAccountId>-14</createdByAccountId>
            <createdDate>2012-05-25T09:59:06-04:00</createdDate>
            <lastUpdatedBy>DUNAYT</lastUpdatedBy>
            <lastUpdatedByAccountId>-14</lastUpdatedByAccountId>
            <lastUpdatedDate>2012-05-26T09:59:06-04:00</lastUpdatedDate>
        </audit>
        <startDate>2011-07-09</startDate>
        <endDate>2011-08-08</endDate>
        <usage>638021</usage>
    </meterConsumption>
    <meterConsumption estimatedValue="false">
        <id>-18</id>
        <audit>
            <createdBy>DUNAYT</createdBy>
            <createdByAccountId>-14</createdByAccountId>
            <createdDate>2012-05-25T09:59:06-04:00</createdDate>
                <lastUpdatedBy>DUNAYT</lastUpdatedBy>
            <lastUpdatedByAccountId>-14</lastUpdatedByAccountId>
            <lastUpdatedDate>2012-05-25T09:59:06-04:00</lastUpdatedDate>
        </audit>
        <startDate>2011-06-09</startDate>
        <endDate>2011-07-09</endDate>
        <usage>625291</usage>
    </meterConsumption>
    <meterConsumption estimatedValue="false">
        <id>-17</id>
        <audit>
            <createdBy>DUNAYT</createdBy>
            <createdByAccountId>-14</createdByAccountId>
            <createdDate>2012-05-25T09:59:06-04:00</createdDate>
            <lastUpdatedBy>DUNAYT</lastUpdatedBy>
            <lastUpdatedByAccountId>-14</lastUpdatedByAccountId>
            <lastUpdatedDate>2012-05-25T09:59:06-04:00</lastUpdatedDate>
        </audit>
        <startDate>2011-05-10</startDate>
        <endDate>2011-06-09</endDate>
        <usage>610219</usage>
    </meterConsumption>

    ...

    <links>
        <link httpMethod="get" link="/meter/100/consumptionData?page=2" linkDescription="next page"/>
    </links>
</meterData>

The following example returns the first set of 120 delivery records for a meter that is set up for bulk delivery and provides a link to the next set. For example purposes, assume that over 120 records are returned.

<?xml version="1.0" encoding="UTF-8"?>
<meterData>
    <meterDelivery estimatedValue="false">
        <id>-40</id>
        <audit>
            <createdBy>DUNAYT</createdBy>
            <createdByAccountId>-14</createdByAccountId>
            <createdDate>2012-05-25T09:59:06-04:00</createdDate>
            <lastUpdatedBy>DUNAYT</lastUpdatedBy>
            <lastUpdatedByAccountId>-14</lastUpdatedByAccountId>
            <lastUpdatedDate>2012-05-26T09:59:06-04:00</lastUpdatedDate>
        </audit>
        <deliveryDate>2010-02-22</deliveryDate>
        <quantity>1400</quantity>
    </meterDelivery>
    <meterDelivery estimatedValue="false">
        <id>-43</id>
        <audit>
            <createdBy>DUNAYT</createdBy>
            <createdByAccountId>-14</createdByAccountId>
            <createdDate>2012-05-25T09:59:06-04:00</createdDate>
            <lastUpdatedBy>DUNAYT</lastUpdatedBy>
            <lastUpdatedByAccountId>-14</lastUpdatedByAccountId>
            <lastUpdatedDate>2012-05-25T09:59:06-04:00</lastUpdatedDate>
        </audit>
        <deliveryDate>2011-01-05</deliveryDate>
        <quantity>1000</quantity>
    </meterDelivery>
    <meterDelivery estimatedValue="false">
        <id>-41</id>
        <audit>
            <createdBy>DUNAYT</createdBy>
            <createdByAccountId>-14</createdByAccountId>
            <createdDate>2012-05-25T09:59:06-04:00</createdDate>
            <lastUpdatedBy>DUNAYT</lastUpdatedBy>
            <lastUpdatedByAccountId>-14</lastUpdatedByAccountId>
            <lastUpdatedDate>2012-05-25T09:59:06-04:00</lastUpdatedDate>
        </audit>
        <deliveryDate>2010-03-15</deliveryDate>
        <quantity>800</quantity>
    </meterDelivery>

    ...

    <links>
        <link httpMethod="get" link="/meter/101/consumptionData?page=2" linkDescription="next page"/>
    </links>
</meterData>
LIVE