launchpad-dev team mailing list archive
-
launchpad-dev team
-
Mailing list archive
-
Message #09711
Re: Problem using Launchpad API to retrieve the authenticated user
On 14/03/13 11:09, Chris Wilson wrote:
> There's a fair amount of code already in place, but only a part of it is
> involved in the OAuth workflow. The place where the request is being
> signed, and the place where I've been focusing most of my own debugging
> efforts, has been this file
>
> https://github.com/notgary/ObjectiveC-LaunchpadLib/blob/master/ObjectiveC-LaunchpadLib/Launchpad.m
>
> In here, on line 97, is a function called signRequest, which takes a
> pointer to a request object and inserts the Authorization header.
>
> The request is originally created in this file
>
> https://github.com/notgary/ObjectiveC-LaunchpadLib/blob/master/ObjectiveC-LaunchpadLib/LaunchpadFactory.m
>
> in the function called downloadJsonFromLaunchpad, where an unsigned GET
> request is set up after being passed the url to which it should be sent,
> in this case that's https://api.staging.launchpad.net/people/+me which
> is being passed in from the function called manufactureAuthenticatedUser
> on line 37 of this file
>
> https://github.com/notgary/ObjectiveC-LaunchpadLib/blob/master/ObjectiveC-LaunchpadLib/Factories/PersonFactory.m
>
> and that's where it all begins.
It all looks reasonable enough :(
What's the body of the 401 response? It should give some indication of
the problem, given that your request seems well-formed.
Also, although it won't be causing this authorisation issue, you're
missing an API version from the request URL. You'll want something like
https://api.staging.launchpad.net/devel/people/+me, for the devel API
version.
Attachment:
signature.asc
Description: OpenPGP digital signature
Follow ups
References
-
Problem using Launchpad API to retrieve the authenticated user
From: Chris Wilson, 2013-03-12
-
Re: Problem using Launchpad API to retrieve the authenticated user
From: William Grant, 2013-03-12
-
Re: Problem using Launchpad API to retrieve the authenticated user
From: Chris Wilson, 2013-03-12
-
Re: Problem using Launchpad API to retrieve the authenticated user
From: William Grant, 2013-03-13
-
Re: Problem using Launchpad API to retrieve the authenticated user
From: Chris Wilson, 2013-03-13
-
Re: Problem using Launchpad API to retrieve the authenticated user
From: Chris Wilson, 2013-03-13
-
Re: Problem using Launchpad API to retrieve the authenticated user
From: William Grant, 2013-03-13
-
Re: Problem using Launchpad API to retrieve the authenticated user
From: Chris Wilson, 2013-03-13
-
Re: Problem using Launchpad API to retrieve the authenticated user
From: William Grant, 2013-03-13
-
Re: Problem using Launchpad API to retrieve the authenticated user
From: Chris Wilson, 2013-03-14