TalMihr
TalMihr

Reputation: 1548

IOS - Sending http requests when application is in background after triggered from UNNotificationAction

Im using a notification content extensions with customized action (Accept, Dismiss). When pressing dismiss I'm trying to send an https request to my server. Keep getting -1009 error (The Internet connection appears to be offline).

Application is setup to use background modes.

Is it even possible to run any network calls in the background?

Upvotes: 3

Views: 159

Answers (1)

TalMihr
TalMihr

Reputation: 1548

My bad. The problem was calling the completionHandler without waiting for my rest response.

Upvotes: 2

Related Questions