我在不同的开发者框架
的网络上看到了很多这些错误{ “错误”:{ “message”:“无效的redirect_uri:应用程序配置不允许给定URL。”, “type”:“OAuthException”, “代码”:191 } }
我正在使用Mule ESB在墙上发表评论但收到此错误。我使用localhost和我的电脑的IP地址,但似乎没有任何作用。我在代理服务器后面,所以不确定这是不是问题。 Facebook似乎已经对应用程序页面的UI进行了操作,因为很多样本都引用了不再存在的页面。
如何让我的Facebook页面接受我的身份验证,然后使用Mule发布。
问候。
雅科。
答案 0 :(得分:0)
您是否正确配置了Facebook?他们倾向于每隔几个月改变他们的应用系统,所以任何例子通常都是过时的。以下适用于我的测试应用程序(只测试auth,不保存令牌):
FB App:
Settings
-> Basic
-> Add Platform
-> App on Facebook
-> Canvas URL: http://localhost:3000/
骡:
<facebook:config-with-oauth name="Facebook" appId="${id}" appSecret="${secret}" doc:name="Facebook">
<facebook:oauth-callback-config domain="localhost" localPort="3000" remotePort="3000"></facebook:oauth-callback-config>
</facebook:config-with-oauth>
<flow name="authorize">
<http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="3000" path="authorize"></http:inbound-endpoint>
<facebook:authorize config-ref="Facebook"></facebook:authorize>
</flow>
如果您的环境中有代理/端口转发,则应明确添加remotePort选项。我在虚拟机中运行我的Mule,它会在没有它的情况下产生无效的url错误。