dailymile-client

Example usage:

dailymile = DailymileClient.new(CONSUMER_KEY, CONSUMER_SECRET, :token => '', :secret => '')

# get a specific entry
dailymile.entry(1)

# get the public feed
dailymile.entries :page => 2

# get the user's entries
dailymile.entries("ben")

# get friends of the given user
dailymile.friends("ben")

# get the info for a user
dailymile.user "ben"

# post a workout
dailymile.authenticated_user.post_workout("hill repeats. tough stuff!", 
                                          :duration => 30.minutes, :type => 'running', 
                                          :distance => { :value => 5.5, :units => 'miles' })

# post a note
dailymile.authenticated_user.post_workout "think today is a rest day!"

# you and friends feed for the authenticated user
dailymile.authenticated_user.entries

Note on Patches/Pull Requests

  • Fork the project.

  • Make your feature addition or bug fix.

  • Add tests for it. This is important so I don’t break it in a future version unintentionally.

  • Commit, do not mess with rakefile, version, or history. (if you want to have your own version, that is fine but

    bump version in a commit by itself I can ignore when I pull)
    
  • Send me a pull request. Bonus points for topic branches.

Copyright © 2009 lostinpatterns. See LICENSE for details.