I recently made an app for Apple Watch that I want to port to Pebble. The app is simple, when opened on the Watch it requests the info to the iPhone app, that asks for location, gets the nearest POI and returns the info to the Watch; all of this is done via - (void)application:(UIApplication *)application handleWatchKitExtensionRequest:(NSDictionary *)userInfo reply:(void(^)(NSDictionary *replyInfo))reply
AppDelegate's method.
Is it possible to get this behavior on a Peeble app? I'm reading the docs and it says:
The session can only be opened from the phone app. This means that the iOS app has to start "talking" to the watch first in order to open the communications channel; the other way around is not possible.
So, if I understood correctly, the Pebble watchapp cannot request anything to the iPhone app, is the iPhone app the one which has to send the info to the Pebble watchapp. Is this correct?
Thank you so much.
Yes, that is correct for PebbleKit iOS.
On the other hand you can use PebbleKit JS, and build an app that utilizes AppMessage, and can get your location, talk to your POI api, etc.