I'm using the HueSDK_iOS and everything seems to work fine.
I have one simple question for which I cannot seem to find a simple answer. I want to test my app's functionality whenever a new user installs it.
I cannot find a proper way to de-authenticate my app from the bridge, so it will ask again to search for bridges etc and I can start over, to test everything.
I /did/ use :
cache = [PHBridgeResourcesReader readBridgeResourcesCache];
PHBridgeConfiguration *config = [cache bridgeConfiguration];
PHBridgeSendAPI *sendAPI = [[PHBridgeSendAPI alloc] init];
[sendAPI removeWhitelistEntryWithUsername:[config username] completionHandler:^(NSArray *errors) {
...
}];
and in the first time, it returns no errors, but I still am authenticated and can use the API , control lights etc, no notification arrives for disconnection or noLocalConnection.
If I run it again, I get an error: error = {\n address = \"/config/whitelist/_a_user_name\";\n description = \"resource, /config/whitelist/_a_user_name, not available\";\n type = 3;\n
(where a "_a_user_name" is the automatically generated username)
but I still keep being authenticated to the bridge. So it seems it does delete the username from the whitelist, but still everything works as if I was authenticated.
So the question is simple: How do I remove my app from the bridge so I can start over and test all the steps? (Pushlinking etc)
It appears it is a bug in the bridge software as I was informed by Philips API support. They asked me to wait for an update.