Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save smholloway/51000b635d6d6331b719 to your computer and use it in GitHub Desktop.
Save smholloway/51000b635d6d6331b719 to your computer and use it in GitHub Desktop.
require 'toopher_api'
# Create an API object using your credentials
toopher = ToopherAPI.new("key", "secret")
# Authenticate a log in
auth_status = toopher.authenticate(pairing.id, 'my computer')
# Once they've responded you can then check the status
auth_status = toopher.get_authentication_status(auth_status.id)
if !auth_status.pending and auth_status.granted
# Success!
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment