Class Facebooker::Mobile
In: lib/facebooker/mobile.rb
Parent: Object

Methods

can_send   new   send  

Public Class methods

[Source]

# File lib/facebooker/mobile.rb, line 3
    def initialize(session)
      @session = session
    end

Public Instance methods

Used to determine whether the user identified by "uid" has enabled SMS for this application.

[Source]

# File lib/facebooker/mobile.rb, line 8
    def can_send(user)
      @session.post('facebook.sms.canSend', :uid => User.cast_to_facebook_id(user))
    end

Send the given message to the user. See wiki.developers.facebook.com/index.php/Mobile

[Source]

# File lib/facebooker/mobile.rb, line 14
    def send(user, message)
      @session.post('facebook.sms.send', 
        {:uid => User.cast_to_facebook_id(user), 
        :message => message}, false)
    end

[Validate]