Skip to main content

Metering API

Quick Start​

# List available operations
epilot metering

# Call an operation
epilot metering getCustomerMeters

Common Flags​

FlagDescription
-p key=valueSet a named parameter
-d '{...}'Request body JSON
-H 'Key: Value'Custom header
-t, --token <token>Bearer token for authentication
--profile <name>Use a named profile
-s, --server <url>Override server base URL
-i, --includeInclude response headers in output
--jsonOutput raw JSON (no formatting)
-v, --verboseVerbose output (show request details)
--jsonata <expr>JSONata expression to transform response
--definition <file>Override OpenAPI spec file/URL
--guidedPrompt for all parameters interactively
--no-interactiveDisable interactive prompts

Operations​

ECP

ECP Admin

getCustomerMeters​

Retrieves all meters related to a customer.

GET /v1/metering/meter

Sample Call

epilot metering getCustomerMeters

With JSONata filter:

epilot metering getCustomerMeters --jsonata 'data'
Sample Response
{
"data": [
{
"_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_title": "Example Entity",
"_org": "123",
"_tags": ["example", "mock"],
"_created_at": "2021-02-09T12:41:43.662Z",
"_updated_at": "2021-02-09T12:41:43.662Z",
"_schema": "meter",
"ma_lo_id": "A09-123",
"status": "active",
"meter_type": "three-phase-meter",
"tariff_type": "Peak load tariff",
"meter_number": "J-1093-1AK",
"sector": "power",
"location": [
{
"country": "Germany",
"city": "Koln",
"postal_code": 81475,
"street": "Melatengürtel",
"street_number": 71,
"additional_info": "5. Etage",
"_tags": ["billing", "delivery"]
}
],
"used_for": "Domestic Usage",
"manufacturer": "Energy One",
"calibration_date": "2022-10-10T00:00:00.000Z",
"contract": {
"$relation": [
{
"entity_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_slug": "contact"
}
]
},
"customer": {
"$relation": [
{
"entity_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_slug": "contact"
}
]
},
"journey_actions": {
"journey_id": "string",
"action_label": {
"en": "string",
"de": "string"
},
"slug": "string",
"rules": [
{
"entity": "string",
"attribute": "string",
"attribute_value": "string"
}
]
},
"last_reading": "2022-10-10T00:00:00.000Z",
"current_consumption": 100.5
}
]
}

getMetersByContractId​

Retrieves all meters related to a contract.

GET /v1/metering/contract/meters/{contract_id}

Parameters

NameInTypeRequiredDescription
contract_idpathstring (uuid)YesThe ID of the Contract.

Sample Call

epilot metering getMetersByContractId \
-p contract_id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot metering getMetersByContractId 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot metering getMetersByContractId -p contract_id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'data'
Sample Response
{
"data": [
{
"_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_title": "Example Entity",
"_org": "123",
"_tags": ["example", "mock"],
"_created_at": "2021-02-09T12:41:43.662Z",
"_updated_at": "2021-02-09T12:41:43.662Z",
"_schema": "meter",
"ma_lo_id": "A09-123",
"status": "active",
"meter_type": "three-phase-meter",
"tariff_type": "Peak load tariff",
"meter_number": "J-1093-1AK",
"sector": "power",
"location": [
{
"country": "Germany",
"city": "Koln",
"postal_code": 81475,
"street": "Melatengürtel",
"street_number": 71,
"additional_info": "5. Etage",
"_tags": ["billing", "delivery"]
}
],
"used_for": "Domestic Usage",
"manufacturer": "Energy One",
"calibration_date": "2022-10-10T00:00:00.000Z",
"contract": {
"$relation": [
{
"entity_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_slug": "contact"
}
]
},
"customer": {
"$relation": [
{
"entity_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_slug": "contact"
}
]
}
}
]
}

getMeter​

Retrieves the details of a meter.

GET /v1/metering/meter/{id}

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesThe ID of the meter.

Sample Call

epilot metering getMeter \
-p id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot metering getMeter 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot metering getMeter -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'data'
Sample Response
{
"data": {
"entity": {
"_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_title": "Example Entity",
"_org": "123",
"_tags": ["example", "mock"],
"_created_at": "2021-02-09T12:41:43.662Z",
"_updated_at": "2021-02-09T12:41:43.662Z",
"_schema": "meter",
"ma_lo_id": "A09-123",
"status": "active",
"meter_type": "three-phase-meter",
"tariff_type": "Peak load tariff",
"meter_number": "J-1093-1AK",
"sector": "power",
"location": [
{
"country": "Germany",
"city": "Koln",
"postal_code": 81475,
"street": "Melatengürtel",
"street_number": 71,
"additional_info": "5. Etage",
"_tags": ["billing", "delivery"]
}
],
"used_for": "Domestic Usage",
"manufacturer": "Energy One",
"calibration_date": "2022-10-10T00:00:00.000Z",
"contract": {
"$relation": [
{
"entity_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_slug": "contact"
}
]
},
"customer": {
"$relation": [
{
"entity_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_slug": "contact"
}
]
}
},
"journey_actions": {
"journey_id": "string",
"action_label": {
"en": "string",
"de": "string"
},
"slug": "string",
"rules": [
{
"entity": "string",
"attribute": "string",
"attribute_value": "string"
}
]
},
"relations": [
{
"_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_title": "Example Entity",
"_org": "123",
"_tags": ["example", "mock"],
"_created_at": "2021-02-09T12:41:43.662Z",
"_updated_at": "2021-02-09T12:41:43.662Z"
}
]
}
}

updateMeter​

Updates the details of a meter.

PATCH /v1/metering/meter/{id}

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesThe ID of the meter.

Request Body

Sample Call

epilot metering updateMeter \
-p id=123e4567-e89b-12d3-a456-426614174000 \
-d '{}'

Using positional args for path parameters:

epilot metering updateMeter 123e4567-e89b-12d3-a456-426614174000

Using stdin pipe:

cat body.json | epilot metering updateMeter -p id=123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot metering updateMeter -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'data'
Sample Response
{
"data": {
"_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_title": "Example Entity",
"_org": "123",
"_tags": ["example", "mock"],
"_created_at": "2021-02-09T12:41:43.662Z",
"_updated_at": "2021-02-09T12:41:43.662Z",
"_schema": "meter",
"ma_lo_id": "A09-123",
"status": "active",
"meter_type": "three-phase-meter",
"tariff_type": "Peak load tariff",
"meter_number": "J-1093-1AK",
"sector": "power",
"location": [
{
"country": "Germany",
"city": "Koln",
"postal_code": 81475,
"street": "Melatengürtel",
"street_number": 71,
"additional_info": "5. Etage",
"_tags": ["billing", "delivery"]
}
],
"used_for": "Domestic Usage",
"manufacturer": "Energy One",
"calibration_date": "2022-10-10T00:00:00.000Z",
"contract": {
"$relation": [
{
"entity_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_slug": "contact"
}
]
},
"customer": {
"$relation": [
{
"entity_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_slug": "contact"
}
]
}
}
}

getMeterCounters​

Retrieves all counters for a given meter.

GET /v1/metering/counter

Parameters

NameInTypeRequiredDescription
meter_idquerystring (uuid)Yes

Sample Call

epilot metering getMeterCounters \
-p meter_id=123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot metering getMeterCounters -p meter_id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'data'
Sample Response
{
"data": [
{
"_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_title": "Example Entity",
"_org": "123",
"_tags": ["example", "mock"],
"_created_at": "2021-02-09T12:41:43.662Z",
"_updated_at": "2021-02-09T12:41:43.662Z",
"_schema": "meter_counter",
"obis_number": "A-34",
"direction": "feed-in",
"transformer_ratio": 70,
"unit": "string",
"forecast_reading_value": 270,
"forecast_as_of": "2022-12-10T00:00:00.000Z",
"current_consumption": 240,
"last_reading": "2022-10-10T00:00:00.000Z",
"conversion_factor": 3,
"tariff_type": "ht"
}
]
}

getCounterDetails​

Retrieves the details of a meter counter.

GET /v1/metering/counter/{counter_id}

Parameters

NameInTypeRequiredDescription
counter_idpathstringYesThe ID of the counter.

Sample Call

epilot metering getCounterDetails \
-p counter_id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot metering getCounterDetails 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot metering getCounterDetails -p counter_id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'data'
Sample Response
{
"data": {
"_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"_title": "Example Entity",
"_org": "123",
"_tags": ["example", "mock"],
"_created_at": "2021-02-09T12:41:43.662Z",
"_updated_at": "2021-02-09T12:41:43.662Z",
"_schema": "meter_counter",
"obis_number": "A-34",
"direction": "feed-in",
"transformer_ratio": 70,
"unit": "string",
"forecast_reading_value": 270,
"forecast_as_of": "2022-12-10T00:00:00.000Z",
"current_consumption": 240,
"last_reading": "2022-10-10T00:00:00.000Z",
"conversion_factor": 3,
"tariff_type": "ht"
}
}

createMeterReading​

Inserts a new meter reading.

POST /v1/metering/reading

Request Body (required)

Sample Call

epilot metering createMeterReading

With request body:

epilot metering createMeterReading \
-d '{
"value": 240,
"read_by": "John Doe",
"reason": "",
"meter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"counter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"direction": "feed-in",
"timestamp": "2022-10-10T00:00:00.000Z",
"source": "ECP",
"status": "valid",
"external_id": "string",
"remark": "Customer reported unusual consumption",
"metadata": {
"registration_id": "1234567890",
"business_unit": "ABC"
},
"note": "string",
"unit": "string"
}'

Using stdin pipe:

cat body.json | epilot metering createMeterReading

With JSONata filter:

epilot metering createMeterReading --jsonata 'data'
Sample Response
{
"data": {
"value": 240,
"read_by": "John Doe",
"reason": "",
"meter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"counter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"direction": "feed-in",
"timestamp": "2022-10-10T00:00:00.000Z",
"source": "ECP",
"status": "valid",
"external_id": "string",
"remark": "Customer reported unusual consumption",
"metadata": {
"registration_id": "1234567890",
"business_unit": "ABC"
},
"note": "string",
"unit": "string"
}
}

createMeterReadings​

Inserts multiple meter readings at once. Limited to 100 readings per request.

POST /v1/metering/readings

Parameters

NameInTypeRequiredDescription
asyncquerybooleanNoDon't wait for the reading to become available in GetReadings API. Useful for large migrations
activity_idquerystring (ulid)NoActivity to include in event feed
skip_validationquerybooleanNoWhen set to true, all validations will be skipped and the system will allow the reading to be created.

If set to false or not provided, the system performs the following validations: Validation Rule |

Request Body (required)

Sample Call

epilot metering createMeterReadings

With request body:

epilot metering createMeterReadings \
-d '{
"readings": [
{
"value": 240,
"read_by": "John Doe",
"reason": "",
"meter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"counter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"direction": "feed-in",
"timestamp": "2022-10-10T00:00:00.000Z",
"source": "ECP",
"status": "valid",
"external_id": "string",
"remark": "Customer reported unusual consumption",
"metadata": {
"registration_id": "1234567890",
"business_unit": "ABC"
},
"note": "string",
"unit": "string"
}
]
}'

Using stdin pipe:

cat body.json | epilot metering createMeterReadings

With JSONata filter:

epilot metering createMeterReadings --jsonata 'data'
Sample Response
{
"data": [
{
"value": 240,
"read_by": "John Doe",
"reason": "",
"meter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"counter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"direction": "feed-in",
"timestamp": "2022-10-10T00:00:00.000Z",
"source": "ECP",
"status": "valid",
"external_id": "string",
"remark": "Customer reported unusual consumption",
"metadata": {
"registration_id": "1234567890",
"business_unit": "ABC"
},
"note": "string",
"unit": "string"
}
]
}

createPortalMeterReadings​

Inserts multiple meter readings at once for a given meter. Limited to 2 readings per request.

POST /v1/metering/readings/{meter_id}

Parameters

NameInTypeRequiredDescription
meter_idpathstringYesThe ID of the meter.

Request Body (required)

Sample Call

epilot metering createPortalMeterReadings \
-p meter_id=123e4567-e89b-12d3-a456-426614174000

With request body:

epilot metering createPortalMeterReadings \
-p meter_id=123e4567-e89b-12d3-a456-426614174000 \
-d '{
"readings": [
{
"value": 240,
"read_by": "John Doe",
"reason": "",
"meter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"counter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"direction": "feed-in",
"timestamp": "2022-10-10T00:00:00.000Z",
"source": "ECP",
"status": "valid",
"external_id": "string",
"remark": "Customer reported unusual consumption",
"metadata": {
"registration_id": "1234567890",
"business_unit": "ABC"
},
"note": "string",
"unit": "string"
}
]
}'

Using positional args for path parameters:

epilot metering createPortalMeterReadings 123e4567-e89b-12d3-a456-426614174000

Using stdin pipe:

cat body.json | epilot metering createPortalMeterReadings -p meter_id=123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot metering createPortalMeterReadings -p meter_id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'data'
Sample Response
{
"data": [
{
"value": 240,
"read_by": "John Doe",
"reason": "",
"meter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"counter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"direction": "feed-in",
"timestamp": "2022-10-10T00:00:00.000Z",
"source": "ECP",
"status": "valid",
"external_id": "string",
"remark": "Customer reported unusual consumption",
"metadata": {
"registration_id": "1234567890",
"business_unit": "ABC"
},
"note": "string",
"unit": "string"
}
]
}

batchWriteMeterReadings​

Upserts/Deletes multiple meter readings at once. Limited to 100 readings per request.

POST /v2/metering/readings

Parameters

NameInTypeRequiredDescription
asyncquerybooleanNoDon't wait for the reading to become available in GetReadings API. Useful for large migrations
skip_validationquerybooleanNoWhen set to true, all validations will be skipped and the system will allow the reading to be created.

If set to false or not provided, the system performs the following validations: Validation Rule | | activity_id | query | string (ulid) | No | Activity to include in event feed |

Request Body (required)

Sample Call

epilot metering batchWriteMeterReadings

With request body:

epilot metering batchWriteMeterReadings \
-d '{
"identifiers": ["string"],
"readings": [
{
"value": 240,
"read_by": "John Doe",
"reason": "",
"meter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"counter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"direction": "feed-in",
"timestamp": "2022-10-10T00:00:00.000Z",
"source": "ECP",
"status": "valid",
"external_id": "string",
"remark": "Customer reported unusual consumption",
"metadata": {
"registration_id": "1234567890",
"business_unit": "ABC"
},
"note": "string",
"unit": "string",
"operation": "create"
}
]
}'

Using stdin pipe:

cat body.json | epilot metering batchWriteMeterReadings

With JSONata filter:

epilot metering batchWriteMeterReadings --jsonata 'data'
Sample Response
{
"data": [
{
"value": 240,
"read_by": "John Doe",
"reason": "",
"meter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"counter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"direction": "feed-in",
"timestamp": "2022-10-10T00:00:00.000Z",
"source": "ECP",
"status": "valid",
"external_id": "string",
"remark": "Customer reported unusual consumption",
"metadata": {
"registration_id": "1234567890",
"business_unit": "ABC"
},
"note": "string",
"unit": "string"
}
]
}

createMeterReadingFromSubmission​

Creates a reading from a journey submission.

POST /v1/metering/reading/submission

Request Body (required)

Sample Call

epilot metering createMeterReadingFromSubmission

With request body:

epilot metering createMeterReadingFromSubmission \
-d '{
"org_id": "123",
"entity": {
"_org": "123",
"meterReadings": [
{
"meterId": "string",
"readings": [
{
"counterId": "string",
"direction": "feed-in",
"unit": "string",
"value": 240
}
],
"readingValue": 240,
"readingDate": "2022-10-10T10:10:00.000Z",
"readBy": "John Doe",
"reason": "",
"maloId": "A09-123",
"obisNumber": "A-34",
"readingUnit": "string",
"meterType": "one_tariff",
"feedInValue": 240,
"feedOutValue": 240,
"htValue": 240,
"ntValue": 240
}
]
}
}'

Using stdin pipe:

cat body.json | epilot metering createMeterReadingFromSubmission

With JSONata filter:

epilot metering createMeterReadingFromSubmission --jsonata 'message'
Sample Response
{
"message": "Successfully Processed"
}

getAllowedReadingForMeter​

Get allowed reading for the given meter

GET /v1/metering/allowed/reading/{meter_id}

Parameters

NameInTypeRequiredDescription
meter_idpathstringYesThe ID of the meter.
timestampquerystringNoIf not provided, the system will default to now.

Sample Call

epilot metering getAllowedReadingForMeter \
-p meter_id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot metering getAllowedReadingForMeter 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot metering getAllowedReadingForMeter -p meter_id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'data'
Sample Response
{
"data": [
{
"counter_id": "string",
"min_value": 0,
"max_value": 0
}
]
}

createReadingWithMeter​

Creates a reading along with a meter.

POST /v1/metering/reading/with-meter

Request Body (required)

Sample Call

epilot metering createReadingWithMeter

With request body:

epilot metering createReadingWithMeter \
-d '{
"ma_lo_id": "A09-123",
"meter_id": "string",
"obis_number": "A-34",
"unit": "string",
"direction": "feed-in",
"tariff_type": "ht",
"value": 240,
"read_by": "John Doe",
"reason": "",
"timestamp": "2022-10-10T10:10:00.000Z",
"source": "ECP"
}'

Using stdin pipe:

cat body.json | epilot metering createReadingWithMeter

With JSONata filter:

epilot metering createReadingWithMeter --jsonata 'data'
Sample Response
{
"data": {
"value": 240,
"read_by": "John Doe",
"reason": "",
"meter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"counter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"direction": "feed-in",
"timestamp": "2022-10-10T00:00:00.000Z",
"source": "ECP",
"status": "valid",
"external_id": "string",
"remark": "Customer reported unusual consumption",
"metadata": {
"registration_id": "1234567890",
"business_unit": "ABC"
},
"note": "string",
"unit": "string"
}
}

getReadingsByInterval​

Retrieves all readings specified in an interval.

GET /v1/metering/reading/{meter_id}/{counter_id}

Parameters

NameInTypeRequiredDescription
meter_idpathstringYesThe ID of the meter.
counter_idpathstringYesThe ID of the counter.
start_datequerystringNoIf not provided, the system will default to 2000-01-01.
end_datequerystringNoIf not provided, the system will default to today's date.
directionquery"feed-in" | "feed-out"No
sizequerynumberNoReturns the first n results after the specified offset (from).

If this value is provided as -1, then it returns all results at once. | | from | query | number | No | | | type | query | "cumulative" | "relative" | Yes | Since meter readings are cumulative, users may need to request actual consumptions, which are the difference between consecutive measurements. If this value is provided as "cumulative", then actual re | | sort | query | "asc" | "desc" | No | If this value is provided as "asc", then the results will be sorted by the timestamp field in ascending order. If this value is provided as "desc", then the results will be sorted by the timestamp fie |

Sample Call

epilot metering getReadingsByInterval \
-p meter_id=123e4567-e89b-12d3-a456-426614174000 \
-p counter_id=123e4567-e89b-12d3-a456-426614174000 \
-p type=example

Using positional args for path parameters:

epilot metering getReadingsByInterval 123e4567-e89b-12d3-a456-426614174000 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot metering getReadingsByInterval -p meter_id=123e4567-e89b-12d3-a456-426614174000 -p counter_id=123e4567-e89b-12d3-a456-426614174000 -p type=example --jsonata 'results[0]'
Sample Response
{
"results": [
{
"value": 240,
"read_by": "John Doe",
"reason": "",
"meter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"counter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"direction": "feed-in",
"timestamp": "2022-10-10T00:00:00.000Z",
"source": "ECP",
"status": "valid",
"external_id": "string",
"remark": "Customer reported unusual consumption",
"metadata": {
"registration_id": "1234567890",
"business_unit": "ABC"
},
"note": "string",
"unit": "string"
}
],
"hits": 120,
"firstRecordCreatedAt": "2022-10-01T20:00:00.000Z"
}

updateMeterReading​

Updates a meter reading.

PUT /v1/metering/reading/{meter_id}/{counter_id}

Parameters

NameInTypeRequiredDescription
meter_idpathstringYesThe ID of the meter entity.
counter_idpathstringYesThe ID of the counter entity.
timestampquerystringYesThe timestamp when the reading was created.

Request Body (required)

Sample Call

epilot metering updateMeterReading \
-p meter_id=123e4567-e89b-12d3-a456-426614174000 \
-p counter_id=123e4567-e89b-12d3-a456-426614174000 \
-p timestamp=2022-10-01T20:00:00.000Z

With request body:

epilot metering updateMeterReading \
-p meter_id=123e4567-e89b-12d3-a456-426614174000 \
-p counter_id=123e4567-e89b-12d3-a456-426614174000 \
-p timestamp=2022-10-01T20:00:00.000Z \
-d '{
"value": 240,
"read_by": "John Doe",
"reason": "string",
"meter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"counter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"direction": "feed-in",
"timestamp": "2022-10-10T00:00:00.000Z",
"source": "ECP",
"status": "valid",
"external_id": "string",
"remark": "Customer reported unusual consumption",
"metadata": {
"registration_id": "1234567890",
"business_unit": "ABC"
}
}'

Using positional args for path parameters:

epilot metering updateMeterReading 123e4567-e89b-12d3-a456-426614174000 123e4567-e89b-12d3-a456-426614174000

Using stdin pipe:

cat body.json | epilot metering updateMeterReading -p meter_id=123e4567-e89b-12d3-a456-426614174000 -p counter_id=123e4567-e89b-12d3-a456-426614174000 -p timestamp=2022-10-01T20:00:00.000Z

With JSONata filter:

epilot metering updateMeterReading -p meter_id=123e4567-e89b-12d3-a456-426614174000 -p counter_id=123e4567-e89b-12d3-a456-426614174000 -p timestamp=2022-10-01T20:00:00.000Z --jsonata 'data'
Sample Response
{
"data": {
"value": 240,
"read_by": "John Doe",
"reason": "",
"meter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"counter_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"direction": "feed-in",
"timestamp": "2022-10-10T00:00:00.000Z",
"source": "ECP",
"status": "valid",
"external_id": "string",
"remark": "Customer reported unusual consumption",
"metadata": {
"registration_id": "1234567890",
"business_unit": "ABC"
},
"note": "string",
"unit": "string"
}
}

deleteMeterReading​

Deletes a meter reading.

DELETE /v1/metering/reading/{meter_id}/{counter_id}

Parameters

NameInTypeRequiredDescription
meter_idpathstringYesThe ID of the meter entity.
counter_idpathstringYesThe ID of the counter entity.
timestampquerystringYesThe timestamp when the reading was created.

Sample Call

epilot metering deleteMeterReading \
-p meter_id=123e4567-e89b-12d3-a456-426614174000 \
-p counter_id=123e4567-e89b-12d3-a456-426614174000 \
-p timestamp=2022-10-01T20:00:00.000Z

Using positional args for path parameters:

epilot metering deleteMeterReading 123e4567-e89b-12d3-a456-426614174000 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot metering deleteMeterReading -p meter_id=123e4567-e89b-12d3-a456-426614174000 -p counter_id=123e4567-e89b-12d3-a456-426614174000 -p timestamp=2022-10-01T20:00:00.000Z --jsonata 'data'
Sample Response
{
"data": {
"meterId": "string",
"counterId": "string",
"timestamp": "2022-10-01T20:00:00.000Z"
}
}