Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API error #243

Closed
netmatrixtech opened this issue Apr 10, 2024 · 5 comments
Closed

API error #243

netmatrixtech opened this issue Apr 10, 2024 · 5 comments
Labels
question Further information is requested

Comments

@netmatrixtech
Copy link

Describe Your Problem:
I've been using this Wyze plugin for a long time now but recently had to upgrade my networking equipment which inevitably ended up changing my HomeBridge IP due to introducing VLANs. I had also placed my Wyze Cam Pro v3's on a separate VLAN but that caused a lot of issues with numerous IoT devices and I reverted the cams to the same VLAN as HomeBridge. While all my other HomeBridge/HomeKit plugins are now working again with the new HomeBridge server IP, it seems I can't get the Wyze plugin to work again. I continually get API errors even after creating new API keys on the Wyze website, deleting, and reinstalling the plugin or even reverted to a previous revision. It doesn't seem to matter what I do I'm always getting these API errors now. Even removing and registering the plugin from within HomeKit doesn't work.
Any thoughts?
Thanks so much!! love ya work!
cheers

Tim

Logs:

[10/04/2024, 9:07:22 pm] [Wyze] Wyze API Error (2001): 'access token is error'
[10/04/2024, 9:07:22 pm] [Wyze] API response PerformRequest: {"url":"app/user/refresh_token","status":200,"data":{"ts":1712747242360,"code":"2002","msg":"RefreshTokenError","data":{}},"headers":{"date":"Wed, 10 Apr 2024 11:07:22 GMT","content-type":"application/json; charset=utf-8","content-length":"70","connection":"keep-alive","x-ratelimit-remaining":"298","x-ratelimit-reset-by":"Wed Apr 10 11:10:20 GMT 2024","cache-control":"no-cache","pragma":"no-cache","expires":"-1","server":"Microsoft-IIS/8.5","access-control-allow-headers":"Origin, X-Requested-With, Content-Type, Cache-Control, Accept, authorization, content-type","access-control-allow-methods":"POST,GET,OPTIONS","access-control-allow-origin":"*","x-aspnet-version":"4.0.30319","x-powered-by":"ASP.NET"}}
[10/04/2024, 9:07:22 pm] [Wyze] API rate limit remaining: 298. Expires in 177559ms
[10/04/2024, 9:07:22 pm] [Wyze] Wyze API Error (2002): 'RefreshTokenError'
[10/04/2024, 9:07:22 pm] [Wyze] Error getting devices: Error: Refresh Token could not be used to get a new access token. Error: Wyze API Error (2002) - RefreshTokenError

Show the Homebridge logs here, remove any sensitive information.


**Plugin Config:**

{
    "name": "Wyze",
    "username": "me@mofo.com",
    "password": "xxxxxxx",
    "keyId": "jxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
    "apiKey": "Txxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
    "refreshInterval": 60000,
    "hms": false,
    "showAdvancedOptions": true,
    "apiLogEnabled": true,
    "pluginLoggingEnabled": false,
    "lowBatteryPercentage": 30,
    "excludeMacAddress": false,
    "excludedeviceType": false,
    "_bridge": {
        "username": "0E:F8:5C:73:71:99",
        "port": 59060
    },
    "platform": "WyzeSmartHome"
}

Show your Homebridge config.json here, remove any sensitive information.

Screenshots:

Just the API errors really.

Environment:

  • Plugin Version: v0.5.46
  • Homebridge Version: v1.7.0 · [UI v4.56.1]]
  • Node.js Version: v20.12.1
  • NPM Version: <not sure
  • Operating System: Debian
@netmatrixtech netmatrixtech added the question Further information is requested label Apr 10, 2024
Copy link

Message that will be displayed on users' first issue

@jfarmer08
Copy link
Owner

You can try and delete the persist/wyze-UUID.json and then restart.

@netmatrixtech
Copy link
Author

Bloody brilliant.... thanks so much and appreciate your quick response.
cheers!

@Ogerbrow
Copy link

I think I am having this same issue. I see the solution and have searched for the persist/wyze-UUID.json to delete but have not been successful in finding it. Would you please tell me where I can locate it?

@jfarmer08
Copy link
Owner

jfarmer08 commented Aug 12, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants