Class: PayPalSDK::Operations::MassPay
- Defined in:
- lib/ruby-paypal-extended/operations/mass_pay.rb
Overview
Represents the MassPay operation
Instance Attribute Summary collapse
-
#amounts ⇒ Object
Returns the value of attribute amounts.
-
#currency_code ⇒ Object
Returns the value of attribute currency_code.
-
#email_subject ⇒ Object
Returns the value of attribute email_subject.
-
#notes ⇒ Object
Returns the value of attribute notes.
-
#receiver_identifiers ⇒ Object
Returns the value of attribute receiver_identifiers.
-
#receivertype ⇒ Object
Returns the value of attribute receivertype.
-
#unique_ids ⇒ Object
Returns the value of attribute unique_ids.
Instance Method Summary collapse
-
#initialize(opts) ⇒ MassPay
constructor
Creates a new MassPay operation.
Methods inherited from Operation
Constructor Details
#initialize(opts) ⇒ MassPay
Creates a new MassPay operation.
receiver_identifiers
- An array of identifiers for the receivers, either
email addresses or paypal IDs. As specified in the docs, they must all be
one or the other.
amounts
- An array of numeric values representing the amounts to send to each recipient. receivertype
- Must be either “UserID” or “EmailAddress”. Defaults to EmailAddress currency_code
- The 3 letter currency code email_subect
- Subject of the email that will be sent to everyone unique_ids
- An array of unique identifiers to attach to each transaction. Optional notes
- An array of notes to attach to each transaction. Optional
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 |
# File 'lib/ruby-paypal-extended/operations/mass_pay.rb', line 30 def initialize(opts) opts = { :receivertype => "EmailAddress", :currency_code => "USD" }.merge(opts) @receiver_identifiers = opts[:receiver_identifiers] @amounts = opts[:amounts] @receivertype = opts[:receivertype] @currency_code = opts[:currency_code] @email_subject = opts[:email_subject] @unique_ids = opts[:unique_ids] @notes = opts[:notes] @n_recip = @receiver_identifiers.size check_arity end |
Instance Attribute Details
#amounts ⇒ Object
Returns the value of attribute amounts.
12 13 14 |
# File 'lib/ruby-paypal-extended/operations/mass_pay.rb', line 12 def amounts @amounts end |
#currency_code ⇒ Object
Returns the value of attribute currency_code.
14 15 16 |
# File 'lib/ruby-paypal-extended/operations/mass_pay.rb', line 14 def currency_code @currency_code end |
#email_subject ⇒ Object
Returns the value of attribute email_subject.
15 16 17 |
# File 'lib/ruby-paypal-extended/operations/mass_pay.rb', line 15 def email_subject @email_subject end |
#notes ⇒ Object
Returns the value of attribute notes.
17 18 19 |
# File 'lib/ruby-paypal-extended/operations/mass_pay.rb', line 17 def notes @notes end |
#receiver_identifiers ⇒ Object
Returns the value of attribute receiver_identifiers.
11 12 13 |
# File 'lib/ruby-paypal-extended/operations/mass_pay.rb', line 11 def receiver_identifiers @receiver_identifiers end |
#receivertype ⇒ Object
Returns the value of attribute receivertype.
13 14 15 |
# File 'lib/ruby-paypal-extended/operations/mass_pay.rb', line 13 def receivertype @receivertype end |
#unique_ids ⇒ Object
Returns the value of attribute unique_ids.
16 17 18 |
# File 'lib/ruby-paypal-extended/operations/mass_pay.rb', line 16 def unique_ids @unique_ids end |