-
Notifications
You must be signed in to change notification settings - Fork 13
/
README.txt
52 lines (40 loc) · 1.9 KB
/
README.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
FireEagle[http://fireeagle.yahoo.net] (FE) is a system providing centralized
management of user location information. FE allows 3rd party developers to
pdate and/or access user's location data.
http://fireeagle.yahoo.net/developer/documentation
== Installation
gem install fireeagle
== Usage
>> require 'fireeagle'
>> client = FireEagle::Client.new(
:consumer_key => "<consumer key>",
:consumer_secret => "<consumer secret>",
:access_token => "[access token]",
:access_token_secret => "[access token secret]")
==== With a User-specific OAuth Access Token
# update your location
>> client.update(:q => "punta del diablo, uruguay") # I wish
# query your location
>> user = client.user
=> #<FireEagle::User:0x1ca5e08 ... >
>> user.locations
=> [#<FireEagle::Location:0x1cdd9e8 ...>, #<FireEagle::Location:0x1cc8ffc ...>, ... ]
>> user.best_guess
=> #<FireEagle::Location:0x1cdd9e8 ...>
>> user.best_guess.name
=> "Punta del Diablo, Uruguay"
# lookup a location
>> locations = client.lookup(:q => "30022")
=> [#<FireEagle::Location:0x1cdd9e8 ...>, #<FireEagle::Location:0x1cc8ffc ...>, ...]
>> locations.first.name => "Alpharetta, GA 30022"
>> locations.first.place_id => "IrhZMHuYA5s1fFi4Qw"
== Authorization
Authorization is handled by OAuth. For more details about the OAuth
authorization flow and how it differs based on your application type, please
see http://fireeagle.yahoo.net/developer/documentation/authorizing
== Contributing
https://github.com/jnewland/fireeagle/tree/master. You know what to do.
Rubyforge Project Page:: http://rubyforge.org/projects/fireeagle
Author:: Jesse Newland (http://soylentfoo.jnewland.com) ([email protected][mailto:[email protected]])
Copyright:: Copyright (c) 2008 Jesse Newland. Portions[http://pastie.caboo.se/private/oevvkdzl0zrdkf8s7hetg] Copyright (c) 2008 Yahoo!
License:: Distributed under the same terms as Ruby