Permalink
Browse files

installation instructions

  • Loading branch information...
mLewisLogic committed May 1, 2012
1 parent 427c354 commit 4b7be0e0c726b55997da72b204fbc55b4129f9fb
Showing with 23 additions and 12 deletions.
  1. +23 −12 README.md
View
@@ -22,24 +22,35 @@ Dependencies:
* httplib2
* simplejson (optional)
+## Installation
+
+ pip install foursquare
+
+or
+
+ easy_install foursquare
+
+Depending upon your system and virtualenv settings, these may require sudo permissions.
+
+
## Usage
### Authentication
# Construct the client object
client = foursquare.Foursquare(client_id='YOUR_CLIENT_ID', client_secret='YOUR_CLIENT_SECRET', redirect_uri='http://fondu.com/oauth/authorize')
-
+
# Build the authorization url for your app
auth_uri = client.oauth.auth_url()
Redirect your user to the address *auth_uri* and let them authorize your app. They will then be redirected to your *redirect_uri*, with a query paramater of code=XX_CODE_RETURNED_IN_REDIRECT_XX. In your webserver, parse out the *code* value, and use it to call client.oauth.get_token()
# Interrogate foursquare's servers to get the user's access_token
access_token = client.oauth.get_token('XX_CODE_RETURNED_IN_REDIRECT_XX')
-
+
# Apply the returned access token to the client
client.set_access_token(access_token)
-
+
# Get the user's data
user = client.users()
@@ -116,7 +127,7 @@ Note: endpoint methods map one-to-one with foursquare's endpoints
users.setpings()
users.unfriend()
users.update()
-
+
venues()
venues.add()
venues.categories()
@@ -133,13 +144,13 @@ Note: endpoint methods map one-to-one with foursquare's endpoints
venues.flag()
venues.marktodo()
venues.proposeedit()
-
+
checkins()
checkins.add()
checkins.recent()
checkins.addcomment()
checkins.deletecomment()
-
+
tips()
tips.add()
tips.search()
@@ -148,7 +159,7 @@ Note: endpoint methods map one-to-one with foursquare's endpoints
tips.markdone()
tips.marktodo()
tips.unmark()
-
+
lists()
lists.add()
lists.followers()
@@ -163,22 +174,22 @@ Note: endpoint methods map one-to-one with foursquare's endpoints
lists.unfollow()
lists.update()
lists.updateitem()
-
+
photos()
photos.add()
-
+
settings()
settings.all()
settings.set()
-
+
specials()
specials.search()
specials.flag()
-
+
events()
events.categories()
events.search()
-
+
multi()
## Improvements

0 comments on commit 4b7be0e

Please sign in to comment.