Using OAuth with Scribe on Android

大城市里の小女人 提交于 2019-12-03 00:32:28

I solved the problem it was something stupid in the end. I had edited my code to save the access secret and the the access token but had forgotten to re-login when testing my app on my phone. This resulted in the code which saved the parts of the token was not being reached.

I still have a problem using the invite call in the LinkedIn API

invite.setOnClickListener(new Button.OnClickListener() 
        {
            public void onClick (View v) 
            {
                inviteXml = inviteCreator.inviteString(to, subj, body, authName, authValue);
                nameField.setText(inviteXml);
                titleField.setText("");


                call = "http://api.linkedin.com/v1/people/~/mailbox";
                request = new OAuthRequest(Verb.GET, call);
                request.addPayload(inviteXml);
                service.signRequest(accessToken, request);
                response = request.send();

                invite.setVisibility(View.GONE);
            }
        });

I'm not sure if this is the correct way to add the XML string to the call. The LinkedIn API doesn't specify how it is to be added. Has anyone any experience with this?

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!