Discussions

Ask a Question

Request: SmartCharge

Do you have plans on exposing the SmartCharge capabilities that you have in the app, through the API? I would love to be able to send a start charge request with optional options like ``` "endTime": "2024-10-04T07:00:00+02:00", "chargeKwh": 20, "fullyCharge": false, "smartChargePreference": [0.1, 0.1, 0.8] // \[co2, renewable, money] ``` Instead of having to rely on my own home cooked smart charging algorithms :) This would allow my smartcharge-start-buttons connected to home assistant to utilize your amazing algorithms without having to go through the app

New chargeID not recognised by 'stop charge'

Hello, apparently today the **chargeID** format changed, until yesterday the **chargeID** was a 8-digit number, and today it shows a 18-digit long one. ``` curl --request GET \ --url 'https://public-api.monta.com/api/v1/charges?chargePointId=2942448&page=0&perPage=1' \ --header 'accept: application/json' \ --header 'authorization: Bearer aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee' ``` ``` { "data": [ { "id": 628861823576030600, "chargePointId": xxxxxxx, "createdAt": "2024-10-01T07:52:22Z", "updatedAt": "2024-10-01T07:52:55Z", "cablePluggedInAt": "2024-10-01T07:52:22Z", "startedAt": "2024-10-01T07:52:23Z", "stoppedAt": null, "fullyChargedAt": null, "failedAt": null, "timeoutAt": null, "state": "paused", "consumedKwh": 0, "kwhLimit": null, "startMeterKwh": 7212.327, "endMeterKwh": 7212.327, "cost": 0, "price": 0, "priceLimit": null, "averagePricePerKwh": 0, "averageCo2PerKwh": 0, "averageRenewablePerKwh": 0, "failureReason": null, "stopReason": "", "note": null, "currency": { "identifier": "eur", "name": "Euros", "decimals": 2 }, "soc": null, "socLimit": null } ], "meta": { "itemCount": 1, "currentPage": 0, "perPage": 1, "totalPageCount": 475, "totalItemCount": 475 } } ``` That's fine, but the problem is that the new **chargeId** is not recognised when trying to stop it with the API. The request: ``` curl --request POST \ --url https://public-api.monta.com/api/v1/charges/628861823576030600/stop \ --header 'accept: application/json' \ --header 'authorization: Bearer aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee' ``` and the result: ``` { "status": "NOT_FOUND", "message": "Charge with ID `628861823576030600` not found.", "readableMessage": "Not Found", "errorCode": "RESOURCE_NOT_FOUND", "context": null } ``` Any idea? Thanks

Wallet transactions in the api

All transactions returns a positiv value. I will expect charges and subscriptions to be a minus value. Is this not an error? If not - how do I detect if it is an withdraw from the wallet? The App shows it correctly as a negative number.

Extended single charge info

It would be nice to have access to the hourly charged kWh in the public API. I see that it is already available in the partner API at this: <https://partner-api.monta.com/api/v1/charges/{chargeId}>, in array "kwhPerHour". Any plans on making this available for the public API also?

Retrieve a list of charges: only 10 elements per page

Hello, Regardless start date set and number of items per page, the API only returns 10 elements per page, so one needs to specify one by one the pages to retrieve.

Feature Request: add info to charges

In the app, there is a field 'notes' for charges, so one can add comments or extra information regarding that specific charge. I don't see the equivalent using the API. I am using the API control my charges and have my own integration with my car (Hyundai Kona) API. For example I keep a record of the odometer for each charge, that way I can monitor the consume. It would be great if I could add the odometer value to the charge, even in the 'notes' field. That way I can review it independently of having access to my local record.

Feauture request. Wallet

It would be nice to have information in the API corresponding to the actual amount of money in the wallet. The same information which is in the app showed in the Personal Wallet Thanks in advance

Retrieve a list of charges seems to be ignoring 'fromDate' argument

request: ``` curl --request GET --url '<https://public-api.monta.com/api/v1/charges?chargePointId=zzzzzzz&fromDate=2024-04-23T06%3A58%3A04Z&page=0&perPage=10'> --header 'accept: application/json' --header 'authorization: Bearer xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx' ``` result: ``` { "data": [ { "id": iiiiiiii, "chargePointId": ccccccc, "createdAt": "2024-04-24T23:08:02Z", "updatedAt": "2024-04-25T05:38:45Z", "cablePluggedInAt": "2024-04-24T23:08:02Z", "startedAt": "2024-04-24T23:08:02Z", "stoppedAt": "2024-04-25T05:38:45Z", "fullyChargedAt": null, "failedAt": null, "timeoutAt": null, "state": "completed", "consumedKwh": 34.07, "kwhLimit": null, "startMeterKwh": 5141.459, "endMeterKwh": 5175.524, "cost": 2.81, "price": 0, "priceLimit": null, "averagePricePerKwh": 0, "averageCo2PerKwh": 0, "averageRenewablePerKwh": 0, "failureReason": null, "stopReason": "regular state change", "note": null, "currency": { "identifier": "eur", "name": "Euros", "decimals": 2 }, "soc": null, "socLimit": null }, { "id": iiiiiiii, "chargePointId": ccccccc, "createdAt": "2024-04-22T23:08:01Z", "updatedAt": "2024-04-23T06:58:04Z", "cablePluggedInAt": "2024-04-22T23:08:01Z", "startedAt": "2024-04-22T23:08:01Z", "stoppedAt": "2024-04-23T06:58:04Z", "fullyChargedAt": null, "failedAt": null, "timeoutAt": null, "state": "completed", "consumedKwh": 0.06, "kwhLimit": null, "startMeterKwh": 5141.403, "endMeterKwh": 5141.459, "cost": 0, "price": 0, "priceLimit": null, "averagePricePerKwh": 0, "averageCo2PerKwh": 0, "averageRenewablePerKwh": 0, "failureReason": null, "stopReason": "StoppedByUser", "note": null, "currency": { "identifier": "eur", "name": "Euros", "decimals": 2 }, "soc": null, "socLimit": null }, (...) { "id": iiiiiiii, "chargePointId": ccccccc, "createdAt": "2024-04-13T23:08:01Z", "updatedAt": "2024-04-14T06:58:06Z", "cablePluggedInAt": "2024-04-13T23:08:01Z", "startedAt": "2024-04-13T23:08:02Z", "stoppedAt": "2024-04-14T06:58:05Z", "fullyChargedAt": null, "failedAt": null, "timeoutAt": null, "state": "completed", "consumedKwh": 4.72, "kwhLimit": null, "startMeterKwh": 5055.616, "endMeterKwh": 5060.337, "cost": 0.68, "price": 0, "priceLimit": null, "averagePricePerKwh": 0, "averageCo2PerKwh": 0, "averageRenewablePerKwh": 0, "failureReason": null, "stopReason": "StoppedByUser", "note": null, "currency": { "identifier": "eur", "name": "Euros", "decimals": 2 }, "soc": null, "socLimit": null } ], "meta": { "itemCount": 10, "currentPage": 0, "perPage": 10, "totalPageCount": 31, "totalItemCount": 309 } } ``` It has been working fine until yesterday.
ANSWERED

Retrieve a list of charge points

The API seems /api/v1/charge-points multiple charges even though there is only one in the app. It looks it like return chargers without a ´serialNumber´. Might be previously unsuccessful added chargers. This is the response i am receiving. ´´´json ```json Response { "data": [ { "id": 2256635, "createdAt": "2022-11-11T21:04:32Z", "updatedAt": "2022-12-12T10:16:02Z", "serialNumber": null, "name": "Garage", "visibility": "private", "maxKW": 11, "maxKw": 11, "type": "ac", "note": null, "state": "passive", "location": { .... }, "connectors": [ { "identifier": "type2", "name": "Type 2" } ], "lastMeterReadingKwh": null, "cablePluggedIn": false, "brandName": "Zaptec", "modelName": "Zaptec - Go", "firmwareVersion": null }, { "id": 2570439, "createdAt": "2022-12-12T10:12:50Z", "updatedAt": "2022-12-12T10:17:09Z", "serialNumber": null, "name": "Garage", "visibility": "private", "maxKW": 20, "maxKw": 20, "type": "ac", "note": null, "state": "passive", "location": { .... }, "connectors": [ { "identifier": "type2", "name": "Type 2" } ], "lastMeterReadingKwh": null, "cablePluggedIn": false, "brandName": "Zaptec", "modelName": "Zaptec - Go", "firmwareVersion": null }, { "id": 2570441, "createdAt": "2022-12-12T10:15:32Z", "updatedAt": "2022-12-12T10:16:38Z", "serialNumber": null, "name": "Garage", "visibility": "private", "maxKW": 11, "maxKw": 11, "type": "ac", "note": null, "state": "passive", "location": { .... }, "connectors": [ { "identifier": "type2", "name": "Type 2" } ], "lastMeterReadingKwh": null, "cablePluggedIn": false, "brandName": "Zaptec", "modelName": "Zaptec - Go", "firmwareVersion": null }, { "id": 2570442, "createdAt": "2022-12-12T10:17:50Z", "updatedAt": "2022-12-12T10:19:57Z", "serialNumber": null, "name": "Garage", "visibility": "private", "maxKW": 11, "maxKw": 11, "type": "ac", "note": null, "state": "passive", "location": { .... }, "connectors": [ { "identifier": "type2", "name": "Type 2" } ], "lastMeterReadingKwh": null, "cablePluggedIn": false, "brandName": "Zaptec", "modelName": "Zaptec - Go", "firmwareVersion": null }, { "id": 2570443, "createdAt": "2022-12-12T10:20:36Z", "updatedAt": "2022-12-12T11:13:31Z", "serialNumber": null, "name": "Garage", "visibility": "private", "maxKW": 11, "maxKw": 11, "type": "ac", "note": null, "state": "passive", "location": { .... }, "connectors": [ { "identifier": "type2", "name": "Type 2" } ], "lastMeterReadingKwh": null, "cablePluggedIn": false, "brandName": "Zaptec", "modelName": "Zaptec - Go", "firmwareVersion": null }, { "id": 2570463, "createdAt": "2022-12-12T11:18:32Z", "updatedAt": "2022-12-12T11:25:23Z", "serialNumber": null, "name": "garage", "visibility": "private", "maxKW": 11, "maxKw": 11, "type": "ac", "note": null, "state": "passive", "location": { .... }, "connectors": [ { "identifier": "type2", "name": "Type 2" } ], "lastMeterReadingKwh": null, "cablePluggedIn": false, "brandName": "Zaptec", "modelName": "Zaptec - Go", "firmwareVersion": null }, { "id": 2570470, "createdAt": "2022-12-12T11:26:31Z", "updatedAt": "2024-03-05T14:52:10Z", "serialNumber": "ZAP11111", "name": "Garage", "visibility": "private", "maxKW": 10.8, "maxKw": 10.8, "type": "ac", "note": null, "state": "busy-scheduled", "location": { .... }, "connectors": [ { "identifier": "type2", "name": "Type 2" } ], "lastMeterReadingKwh": null, "cablePluggedIn": true, "brandName": "Zaptec", "modelName": "Zaptec - Go", "firmwareVersion": "2.3.1.2" } ], "meta": { "itemCount": 7, "currentPage": 0, "perPage": 10, "totalPageCount": 1, "totalItemCount": 7 } } ``` ´´´
ANSWERED

Unable to view my charger, just got moved to the norlys solution.

Hi Today my charger was moved to the "Norlys Opladning 2.0" flavor of Monta, and thereby moved to a team controlled by them. Today I also planned to give up waiting for the official HomeAssistant integration, and make my own, but after I am authenticated , GET charge-points gives me just an empty list in return. ``` { "data": [], "meta": { "itemCount": 0, "currentPage": 0, "perPage": 10, "totalPageCount": 0, "totalItemCount": 0 } } ``` Using my browser I can see the charge-point just fine, both in the old portal and the new Monta hub, and it also shows up on the app, both Norlys Opladning 2.0 and the ol' faithful Monta app, so I should have access. When I try to guess the ID of my charger (there's really only two numbers I can find) and ask specifically about that, I get a message telling me that user 5004 does not have access to the charge point. ``` { "status": "FORBIDDEN", "message": "User with ID `50xx` has no access to Charge Point with ID `274xxx`.", "readableMessage": "Forbidden", "errorCode": "ACCESS_FORBIDDEN", "context": null } ``` If I GET charge-transactions I can see a list of transactions too long to paste in here, so something appears to be working. I found an [https://docs.public-api.monta.com/discuss/649546ae60e41400410e52e2]\(earlier discussion about non-personal chargers not being visible via this API) from 8 months ago, but it also looked like the limitation was lifted at that point. I was really hoping to keep the same openness after the switch as before, so I hope this is me doing something wrong and not a limitation in the API, and that someone can point me to what my problem is.