Created
January 15, 2013 14:25
-
-
Save plcstevens/4539012 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 'comufy' | |
connect = Comufy.connect(access_token: ENV["COMUFY_ACCESS_TOKEN"], expiry_token: Time.now.to_i + 1000000) | |
# or use a yaml file | |
# connect = Comufy.connect(yaml: "path/to/yaml/file") | |
# lets add a user to our facebook application! | |
# http://graph.facebook.com/THEIR_NAME will get you back their id | |
# tags are the data fields to enter for this user. | |
app_name = "NAME_OF_YOUR_APPLICATION" | |
user_id = "THEIR_FACEBOOK_ID" | |
tags = { 'dob' => '1978-10-01 19:50:48' } | |
# will return true when successful, otherwise it'll return false along with a logger.warn message! | |
puts connect.store_user(app_name, user_id, tags) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment