Hi Sairam,

Please don't select "orkut" in step 1. Please read my earlier mail on what
to do at that step.

Sachin

On Tue, Nov 10, 2009 at 8:03 AM, sairam <smartsai...@gmail.com> wrote:

>
> hi ,
>       I am trying to access the api provided by orkut using oauth
> playground tool similar to what carlos has done.
> I went through the link which was sent by you and we followed the
> steps using our own domain... the thing upto which we can do is we can
> able to get consumer key and consumer secret and the place where we
> stuck now is
>
>  while managing our domain i came accross a step where it asks for
> target url path prefix. i provided http://mydomain/authsub (here my
> domain indicates our registed domain). i saved that and tried testing
> authsub registration through the link provided .
>
> but grant access failed with the following error mess:
> Not Found
> The requested URL /authsub was not found on this server.
>
> But still I was able to succeed in oauth playground by selecting
> google base in step1 and got the response for step 6.
> Again when I tried to get request token by selecting orkut in step1,
> by providing the consumer key, secret the following error
> message  :HTTP/1.1 400 Bad Request error message came.
>
>
>
> Thanks,
> Sairam
>
>
>
> On Nov 10, 4:15 am, los <carlo...@gmail.com> wrote:
> > Ahhhh, that was it!
> >
> > This step ought to be be made more clear in the documentation.
> >
> > Thanks a lot!  U da man!!  :)
> >
> > -Carlos
> >
> > On Nov 9, 9:26 am, Sachin Shenoy <therealsac...@gmail.com> wrote:
> >
> > > Hi Carlos,
> >
> > > You need to get 3-legged oauth consumer key / secret. Please follow
> > > instructions from the below URL.
> >
> > >http://code.google.com/apis/accounts/docs/RegistrationForWebAppsAuto..
> ..
> >
> > > The one you are using will only allow you to make 2-legged oauth calls.
> >
> > > Regards,
> > > <
> http://code.google.com/apis/accounts/docs/RegistrationForWebAppsAuto....>
> > > Sachin
> >
> > > On Fri, Nov 6, 2009 at 2:43 AM, los <carlo...@gmail.com> wrote:
> >
> > > > Hi Sachin,
> >
> > > > Thanks for the feedback.  That playground is a nice tool to know
> > > > about.
> >
> > > > So I followed your instructions like this:
> >
> > > > 1. On panel 1 I enteredhttp://sandbox.orkut.gmodules.com/social/rpc
> > > > (I corrected the spelling mistake on the word "social")
> > > > 2. On panel 2 I set oauth_signature_method to HMAC-SHA1
> > > > 3  Set oauth_consumer_key to orkut.com:121212121212   (I am using
> > > > 121212... as an example, I set the actual value in my test)
> > > > 4. Set consumer secret to abcdefabcedfabcdef (Again abcdef... is just
> > > > an example I set my correct secret in the test)
> > > > 5. clicked Request token on panel 3
> >
> > > > I got a 400 response, with the result of "Consumer is not registered:
> > > > orkut.com:121212121212"
> >
> > > > So now I'm thinking that just because I have a consumer key and
> secret
> > > > it doesn't necessarily mean I can make requests to that provider?
> >
> > > > All I did to get the key & secret was create a hello world
> > > > mygadget.xml file and uploaded it to app engine.  Then went to
> > > >https://www.google.com/gadgets/directory/verifyandentered the url of
> > > > my xml file, verified it was mine by updating the xml file with the
> > > > token and voila...I got my consumer key and secret.
> >
> > > > Feels like I'm just missing a simple detail somewhere.  Any ideas
> what
> > > > I'm missing here?
> >
> > > > Thanks,
> >
> > > > Carlos
> >
> > > > On Nov 5, 7:32 am, Sachin Shenoy <therealsac...@gmail.com> wrote:
> > > > > Hi Carlos,
> >
> > > > > Before using opensocial java client library, I would suggest you
> using
> > > > oauth
> > > > > playground for testing out your authentication part.
> >
> > > > >http://googlecodesamples.com/oauth_playground/
> >
> > > > > Here are the values you need to set.
> >
> > > > > panel(1)
> > > > > scope (input your own):
> http://sandbox.orkut.gmodules.com/socail/rpc
> >
> > > > > panel(2)
> > > > > hmac_signature_method:
> > > > > HMAC-SHA1
> > > > > Fill in the oauth_consumer_key and secret, and then go ahead with
> > > > "Request
> > > > > Token", "Authorize" and "Access Token".
> >
> > > > > Once that is through you should be able to do run some simple
> requests
> > > > from.
> >
> > > > > panel (6)
> > > > > Set "application/json", method "POST", and body as
> > > > {'method':'people.get'}
> > > > > and click execute.
> >
> > > > > Once you succeed here it should be easier for you to figure out
> what the
> > > > > opensocial library is doing differently.
> >
> > > > > Regards,
> > > > > Sachin
> >
> > > > > On Thu, Nov 5, 2009 at 3:17 PM, los <carlo...@gmail.com> wrote:
> >
> > > > > > I'm trying to write a new java webapp and want it to display a
> user's
> > > > > > activities.  I'd like to have this work with orkut to start out,
> but
> > > > > > hopefully would like to integrate with other opensocial
> containers
> > > > > > such as linkedin, myspace, etc...  I'm currently using the
> opensocial
> > > > > > java client in my development.
> >
> > > > > > Right now I'm struggling trying to understand how to redirect the
> user
> > > > > > to orkut from my webapp so he can login if necessary add the
> > > > > > application to their profile, and then redirect this person back
> to my
> > > > > > webapp so that I can fetch the activities in the background and
> > > > > > display it on my app.
> >
> > > > > > I've noticied that the OpenSocialProvider.ORKUT is defined as:
> >
> > > > > > ORKUT(null, null, null, "http://www.orkut.com/social/rest/";,
> > > > > >      "http://www.orkut.com/social/rpc/";, "orkut.com",
> > > > > >      BodySigningMethod.SIGN_BODY_HASH, true),
> >
> > > > > > so there are no urls for requesting a token, authenticating url
> and
> > > > > > getting the access token.  So I started using the
> > > > > > OpenSocialProvider.GOOGLE (since it has actual values for those
> urls
> > > > > > defined) in my code as follows.
> >
> > > > > >        OpenSocialProvider provider = OpenSocialProvider.GOOGLE;
> > > > > >        final OpenSocialClient client = new OpenSocialClient
> > > > > > (provider);
> > > > > >
>  client.setProperty(OpenSocialClient.Property.CONSUMER_SECRET,
> > > > > > CONSUMER_SECRET);
> > > > > >        client.setProperty(OpenSocialClient.Property.CONSUMER_KEY,
> > > > > > "igoogle.com:1212121212121212");
> > > > > >        OpenSocialLoginInfo loginInfo = new OpenSocialLoginInfo();
> > > > > >        session.setAttribute(OPEN_SOCIAL_CLIENT, client);
> > > > > >        try {
> > > > > >            Token token = OpenSocialOAuthClient.getRequestToken
> > > > > > (client, provider);
> > > > > >            session.setAttribute("token_secret", token.secret);
> > > > > >            String loginUrl =
> OpenSocialOAuthClient.getAuthorizationUrl
> > > > > > (provider, token, callbackUrl);
> > > > > >            ....
> > > > > >        } catch (Exception e) {
> > > > > >            e.printStackTrace();
> > > > > >        }
> >
> > > > > > However, I always get the following exception:
> >
> > > > > > Exception in thread "main" java.io.IOException: Container
> returned
> > > > > > status 400 "Server returned HTTP response code: 400 for URL:
> >
> > > > > >
> https://www.google.com/accounts/OAuthGetRequestToken?scope=http%3A%2F.
> > > > ..
> > > > > > "
> > > > > >        at org.opensocial.client.OpenSocialHttpClient.send
> > > > > > (OpenSocialHttpClient.java:118)
> > > > > >        at org.opensocial.client.OpenSocialHttpClient.send
> > > > > > (OpenSocialHttpClient.java:89)
> > > > > >        at org.opensocial.client.OpenSocialHttpClient.execute
> > > > > > (OpenSocialHttpClient.java:74)
> > > > > >        at org.opensocial.client.OpenSocialHttpClient.execute
> > > > > > (OpenSocialHttpClient.java:45)
> > > > > >        at org.opensocial.client.OpenSocialHttpClient.execute
> > > > > > (OpenSocialHttpClient.java:1)
> > > > > >        at
> net.oauth.client.OAuthClient.invoke(OAuthClient.java:243)
> > > > > >        at
> net.oauth.client.OAuthClient.invoke(OAuthClient.java:143)
> > > > > >        at
> > > > > >
> net.oauth.client.OAuthClient.getRequestToken(OAuthClient.java:101)
> > > > > >        at
> org.opensocial.client.OpenSocialOAuthClient.getRequestToken
> > > > > > (OpenSocialOAuthClient.java:170)
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Orkut Developer Forum" group.
To post to this group, send email to opensocial-orkut@googlegroups.com
To unsubscribe from this group, send email to 
opensocial-orkut+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/opensocial-orkut?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to