Hi,
You are correct requestSendMessage and requestShareApp require and ID or array of IDs. Internally these calls call FetchPersonRequest to get the person object and then send them to PostTo. Instead of using requestShareApp and requestSendMessage you can use directly postTo.
var message = opensocial.newMessage(content);
message.setField(opensocial.Message.Field.TITLE, subject);
message.setField(opensocial.Message.Field.TYPE, postType);
opensocial.Container.get().postTo(openSocialToken, message, person, callback_function);
where
openSocialToken: Valid open Social Token.
messange: opensocial.Message object,
person: recipient person object
callback_function: optional callback function.
There is just a small change on MyOpenSpace021.v07.js
on line 3260
_IFPC.call(
this.params_.panelId,
"postTo",
[MyOpenSpace.MySpaceContainer.OSToken, messageType, messageSubject, messageBody, personId, personImage, personName, personProfile],
this.params_.remoteRelay,
opt_callback,
this.params_.localRelay,
null);
MyOpenSpace.MySpaceContainer.OSToken needs to change to os_token
_IFPC.call(
this.params_.panelId,
"postTo",
[os_token, messageType, messageSubject, messageBody, personId, personImage, personName, personProfile],
this.params_.remoteRelay,
opt_callback,
this.params_.localRelay,
null);