class Facebook::Messenger::Incoming::Payment::Payment

The payment portion of the payload.

Public Class Methods

new(payment) click to toggle source
# File lib/facebook/messenger/incoming/payment.rb, line 12
def initialize(payment)
  @payment = payment
end

Public Instance Methods

amount() click to toggle source

Return hash containing the information about amount of purchase.

# File lib/facebook/messenger/incoming/payment.rb, line 33
def amount
  @payment['amount']
end
payload() click to toggle source

Return String containing developer defined payload.

# File lib/facebook/messenger/incoming/payment.rb, line 17
def payload
  @payment['payload']
end
payment_credential() click to toggle source

Return hash containing the payment credential information.

# File lib/facebook/messenger/incoming/payment.rb, line 28
def payment_credential
  @payment['payment_credential']
end
shipping_option_id() click to toggle source

Return string containing option_id of selected shipping option.

# File lib/facebook/messenger/incoming/payment.rb, line 38
def shipping_option_id
  @payment['shipping_option_id']
end
user_info() click to toggle source

Return hash containing the requested information from user when they

click buy button.
# File lib/facebook/messenger/incoming/payment.rb, line 23
def user_info
  @payment['requested_user_info']
end