实现Facebook的心愿教程应用程序没有自己的动作类型错误 [英] Implementing Facebook wishlist tutorial Application Does Not Own Action Type Error

查看:131
本文介绍了实现Facebook的心愿教程应用程序没有自己的动作类型错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我通过Facebook的收藏的应用程序为Android工作。当我尝试我的自定义对象添加到Facebook的图形API返回以下错误:

  {
     错误: {
      类型:OAuthExeption,
      消息:(#100)
     应用程序不拥有
     230752723668296动作类型
      }
     }
 

我一直没能找到有关此特定错误的任何具体文件。是否有任何的Facebook开发人员那里谁也许能帮助我除preT这一点。

我还要提到的是我已经有这个程序,无故障运行(我想复制它,所以我可以用了害怕失去工作,调整它)的工作示例。我试图改变动作的名称,但这个没什么区别。下面是Android的code其中它添加项目到Facebook的时间线的片段。但是,这是一小片的对所有的难题,因为有三面​​给这个项目(脸谱,我的服务器,和Android)

 公共无效addToTimeline(){
       对话框= ProgressDialog.show(Wishlist.this,,的getString(R.string.adding_to_timeline),真,真);
    / *
     *创建产品网址
     * /
       字符串PRODUCTURL = HOST_SERVER_URL + HOST_PRODUCT_URI;
       捆绑productParams =新包();
       productParams.putString(名,mProductName);
       productParams.putString(形象,mProductImageName);
       PRODUCTURL = PRODUCTURL +? + Uti​​l.en $ C $卷曲(productParams);

    捆绑wishlistParams =新包();

    如果(mPlacesAvailable){
        尝试 {
            wishlistParams.putString(地方,mPlacesJSONArray.getJSONObject(mPlacesListSpinner.getSelectedItemPosition())的getString(ID));
        }赶上(JSONException E){}
    }
    wishlistParams.putString(愿望清单,WISHLIST_OBJECTS_URL [mWishlistSpinner.getSelectedItemPosition());
    wishlistParams.putString(产品,PRODUCTURL);
    wishlistParams.putString(形象,mProductImageURL);
    //去做
    //把应用程序的命名空间和add_to这里的行动
    Utility.mAsyncRunner.request(ME / wishlisteight:adding_to,wishlistParams,POST,新addToTimelineListener(),NULL);
}
 

解决方案

我应该还提到,我已经有这个程序,无故障运行的工作示例(我试图复制它,所以我可以调整它与出害怕失去工作)

这动作是特定于应用程序ID。当你做你的code中的重复,你有没有使用相同的应用程序ID或创建一个新的?如果你创建了一个新的应用程序ID,您需要注册为行动,就像你做的第一个应用程序的新的应用程序。

I am working through the Facebook Wishlist app for Android. When I attempt to add my custom object to the Facebook graph the API returns the following error:

  {
     "error: {
      "type": "OAuthExeption",
      "message":"(#100)
     Application does not own
     230752723668296 action type"
      }
     }

I haven't been able to find any specific documentation on this particular error. Are there any Facebook developers out there who may be able to help me interpret this.

I should also mention that I already have a working example of this app running without errors (I am trying to duplicate it so I can tweak it with out fear of losing work). I have tried changing the name of the Action but this makes no difference. Below is the snippet of the Android code where it adds the item to the Facebook time line. This is however a small piece of the over all puzzle as there are three sides to this project (Facebook, My Server, and Android)

 public void addToTimeline() {
       dialog = ProgressDialog.show(Wishlist.this,    "",getString(R.string.adding_to_timeline), true, true);
    /*
     * Create Product URL
     */
       String productURL = HOST_SERVER_URL + HOST_PRODUCT_URI;
       Bundle productParams = new Bundle();
       productParams.putString("name", mProductName);
       productParams.putString("image", mProductImageName);
       productURL = productURL + "?" + Util.encodeUrl(productParams);

    Bundle wishlistParams = new Bundle();

    if(mPlacesAvailable) {
        try {
            wishlistParams.putString("place", mPlacesJSONArray.getJSONObject(mPlacesListSpinner.getSelectedItemPosition()).getString("id"));
        } catch (JSONException e) {}
    }
    wishlistParams.putString("wishlist", WISHLIST_OBJECTS_URL[mWishlistSpinner.getSelectedItemPosition()]);
    wishlistParams.putString("product", productURL);
    wishlistParams.putString("image", mProductImageURL);
    //TODO
    //put the app's namespace and 'add_to' action here
    Utility.mAsyncRunner.request("me/wishlisteight:adding_to", wishlistParams, "POST", new addToTimelineListener(), null);
}

解决方案

"I should also mention that I already have a working example of this app running without errors (I am trying to duplicate it so I can tweak it with out fear of losing work)"

That action is specific to an app id. When you made the duplicate of your code, did you use the same app id or create a new one? If you created a new app id, you will need to register actions for the new app just like you did with the first app.

这篇关于实现Facebook的心愿教程应用程序没有自己的动作类型错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆