Created
August 12, 2014 20:06
-
-
Save themoxman/50e50f7eb1b36e60be06 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "json" | |
require "nokogiri" | |
require "open-uri" | |
require "pry" | |
require "httparty" | |
response = HTTParty.get("http://api.meetup.com/2/rsvps?event_id=195138082&order=event&rsvp=yes&desc=false&offset=0&photo-host=public&format=json&page=500&fields=&sig_id=38456672&sig=c4193d8a8fa47590c330f861d061cc6bf3d0d7b0") | |
thing = response["results"].inject({}) do |memo, result| | |
first_name, last_name = result["member"]["name"].split(" ") | |
memo[last_name] = [first_name, result["member_photo"]["thumb_link"]] | |
memo | |
end.sort_by { |key, value| key.to_s } | |
require "pry" | |
binding.pry |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment