[swx] flickr api keys, secrets and tokens (Hans Elgelid)
Aidann Bowley
aidann at ukgateway.net
Thu Oct 25 12:31:54 PDT 2007
Sorry for breaking the thread - had subscribed in digest mode. Changed now.
Aral,
no problem. I ran round in circles for ages with both the Explorer and then
when I'd been using phpFlickr instead the setToken method.
Hans,
Very sorry, one more thing I should have added if you're doing all this with
phpFlickr (Aral, if you're updating your docs, please add this too). Once
you've got your api key and secret, before you go to getToken.php, in Flickr
you should also update the Callback URL field for the relevant key in Flickr
here. You'll need to click 'edit details', then you'll find it near the
bottom
http://www.flickr.com/services/api/keys/
Put the address for your copy of auth.php (not sure if it'll work with your
localhost address). Then when getToken goes to Flickr it knows where to
validate against for your secret and key and thus knows you're okay to
proceed.
Not really sure about the authGetFrob.
Cheerio for now,
Aidann
=========================
Thanks for telling about auth.php and getToken.php in the phpFlickr
library .
After adding my api key and shared secret and browsing to:
http://localhost/swx/php/lib/phpFlickr/getToken.php
I get redirected to the url entered when signing up at Flickr followed
by a frob, looking something like:
http://mysite.com/?frob=7215576083917047-896834e23f0049f-14877455&extra=%2Fswx%2Fphp%2Flib%2FphpFlickr%2FgetToken.php
Recognising this and perhaps know the solution?
Since the subject of this thread is spot on I continue the token hunt...
I'm trying to use the authentication protocol descibed in method
authGetFrob() in Flickr.php
authGetFrob() works fine and returns a frob
authGetUrl(frob) works fine and returns an url which when pasted
into a browser takes me to my Flickr acount where I'm asked to accept
that my application uses Flickr.
authGetToken(frob) shows in SWX Data Analyser: message=Invalid Frob
code=108 error=true
I'm using the same frob returned from authGetFrob() which seemed to be
OK since authGetUrl(frob) is working.
Any ideas?
/Hans
More information about the swx
mailing list