我正在尝试在后端发送apprequest,这是我正在尝试执行的代码,但它总是返回'Mogli :: Client :: HTTPException'错误。我的问题是(1)我可以在后端进行吗? (2)我应该获得什么样的许可? (3)使用apprequest_create的正确方法是什么?
谢谢你,以下是我正在尝试使用的代码:
friend = Mogli::User.find(friend_facebook_id.to_i, current_facebook_client)
friend.apprequests_create(
Mogli::AppRequest.new(
:link=>"callback url",
:to => {:id => friend_facebook_id, :name => friend_facebook_name},,
:message=>"Try 1"))
以下是应用程序跟踪:
/Library/Ruby/Gems/1.8/gems/mogli-0.0.30/lib/mogli/client.rb:215:in `raise_error_if_necessary'
/Library/Ruby/Gems/1.8/gems/mogli-0.0.30/lib/mogli/client.rb:151:in `map_data'
/Library/Ruby/Gems/1.8/gems/mogli-0.0.30/lib/mogli/client.rb:116:in `post'
/Library/Ruby/Gems/1.8/gems/mogli-0.0.30/lib/mogli/model.rb:113:in `apprequests_create'