michaelwoods / onstar2mqtt

OnStarJS wrapper for MQTT
MIT License
107 stars 40 forks source link

API flaking out? #260

Closed jquinby closed 1 year ago

jquinby commented 1 year ago

I've been getting some timeouts pretty consistently for awhile now, running 1.5.4 in a docker container for the HA integration. Was wondering if the GM API is just flaky as all get out or if there's something that's been changed on their end preventing access.

Here's what I'm seeing in the docker log; VIN is redacted.

info: Vehicle request status {"status":"success"}                                                                                                                             
info: Connecting to MQTT {"config":{"username":"","will":{"payload":"false","retain":true,"topic":"homeassistant/VIN/available"}},"url":"mqtt://10.0.1.54:1883"}
info: Connected to MQTT                                                                                                                                                       
info: Subscribed to command topic {"topic":"homeassistant/VIN/command"}                                                                                         
info: Requesting diagnostics                                                                                                                                                  
error: Error {"error":{"message":"Command Timeout","request":{"body":"{\"diagnosticsRequest\":{\"diagnosticItem\":[\"LAST TRIP FUEL ECONOMY\",\"ENERGY EFFICIENCY\",\"HYBRID B
ATTERY MINIMUM TEMPERATURE\",\"EV ESTIMATED CHARGE END\",\"LIFETIME ENERGY USED\",\"EV BATTERY LEVEL\",\"EV PLUG VOLTAGE\",\"HOTSPOT CONFIG\",\"ODOMETER\",\"HOTSPOT STATUS\",
\"LIFETIME EV ODOMETER\",\"CHARGER POWER LEVEL\",\"EV PLUG STATE\",\"EV CHARGE STATE\",\"TIRE PRESSURE\",\"AMBIENT AIR TEMPERATURE\",\"LAST TRIP DISTANCE\",\"INTERM VOLT BATT
 VOLT\",\"GET COMMUTE SCHEDULE\",\"EV SCHEDULED CHARGE START\",\"VEHICLE RANGE\"]}}","contentType":"application/json; charset=UTF-8","headers":{},"method":1,"url":"https://ap
i.gm.com/api/v1/account/vehicles/VIN/commands/diagnostics"},"response":{"data":{"commandResponse":{"requestTime":"2023-03-20T17:33:12.128Z","status":"inProgress
","type":"diagnostics","url":"https://api.gm.com/api/v1/account/vehicles/VIN/requests/30862447338"}},"headers":{"connection":"keep-alive","content-type":"applic
ation/json;charset=UTF-8","date":"Mon, 20 Mar 2023 17:33:12 GMT","push-response":"Rejected 30","request-context":"appId=cid-v1:a7e19842-5b19-4b47-a9cf-85cc6e87a746","transfer
-encoding":"chunked"},"status":202,"statusText":"Accepted"},"stack":"Error: Command Timeout\n    at RequestService.<anonymous> (/app/node_modules/onstarjs/dist/index.js:570:3
5)\n    at Generator.next (<anonymous>)\n    at fulfilled (/app/node_modules/onstarjs/dist/index.js:32:58)\n    at process.processTicksAndRejections (node:internal/process/ta
sk_queues:95:5)"}} 

The GM app continues to work, as far as I can tell. Anyone else, or just me?

stamanf commented 1 year ago

I have the same problem since yesterday. Plus if I try to manually go in my onstar account, I get a 404 error. Onstar tech support is useless.

Any clues ?

tbclark3 commented 1 year ago

I started getting errors today, and the docker app crashes consistently after returning a 404 error. My Android app is also still working.

BigThunderSR commented 1 year ago

The Docker app crashing is due to a new build needing to be published with onstarjs 2.3.18 with the new keys because the existing keys were expired by GM.

You can use my build until @michaelwoods updates his build.

tbclark3 commented 1 year ago

That solved the problem. Your build works beautifully. Thank you!

stamanf commented 1 year ago

Solved my issue as well. Thanks !!!!

michaelwoods commented 1 year ago

v1.5.5 tagged with latest onstarjs