nitaybz / homebridge-sensibo-ac

Homebridge plugin for Sensibo - Smart AC Control
GNU General Public License v3.0
71 stars 15 forks source link

Rate limit hit due to lack of gzip encoding support #140

Closed nadavge closed 4 months ago

nadavge commented 4 months ago

Tried turning the AC, and got the following error:

[6/29/2024, 11:15:03 PM] [SensiboAC] Creating GET request to Sensibo API ---> [6/29/2024, 11:15:03 PM] [SensiboAC] https://home.sensibo.com/api/v2/users/me/pods?fields=id,acState,measurements,remoteCapabilities,room,temperatureUnit,productModel,location,occupancy,smartMode,motionSensors,filtersCleaning,serial,pureBoostConfig,homekitSupported [6/29/2024, 11:15:03 PM] [SensiboAC] ERROR: Request failed with status code 429 [6/29/2024, 11:15:03 PM] [SensiboAC] { status: 429, message: 'API Limit exceeded. Use "Accept-Encoding: gzip" to increase the rate limit.' } [6/29/2024, 11:15:03 PM] [SensiboAC] <<<< ---- Refresh State FAILED! ---- >>>> [6/29/2024, 11:15:03 PM] [SensiboAC] Will try again in 85 seconds...

Assuming a usage of "gzip" will solve the problem.

benwebbbenwebb commented 4 months ago

Hi @nadavge

Based on feedback in other issues, including #132 and #138, version 2.5, which has just been released out of Alpha, should also help reduce the occurrence of this issue.

Either way, I've merged PR #137 in the master for the next release (v2.6).