I was able to fix this problem by enabling App Sandbox for my app in Xcode. In addition to this setting, other steps are outlined here.
App Sandbox
Xcode