SetAppProperties & preload_fql

Apr 14, 2010 at 2:27 AM

Hi,

The Admin.SetAppProperties method seems quite broken when used to try to set the preload_fql. The JSON generated does not match with what Facebook expects.

To work around this you can make the call directly:

var parameterList = new Dictionary<string, string> { { "method", "facebook.admin.setAppProperties" } };
parameterList.Add("properties", @"{ ""preload_fql"" : ""{\""friends\"" : {\""pattern\"": \"".*\"", \""query\"" : \""SELECT uid2 FROM friend WHERE uid1={*user*}\""} }"" }");
api.SendRequest<admin_setAppProperties_response>(parameterList);

Ideally the API would provide data structures and methods to build the preload_fql string of course, or at least not mangle the input before it sends it off.

Pascal.