rubyQRpay
Installation
Add this line to your application's Gemfile:
gem 'rubyqrpay'
And then execute:
$ bundle
Or install it yourself as:
$ gem install rubyqrpay
Usage
transaction_information = {
agregator_id: 'rubyQRpay',
merchant_account_32: {
service_code_erip: '123456',
payer_unique_id: '123456789',
payer_number: '--',
amount_edit_possibility: true,
},
merchant_account_33: {
service_producer_code: '123',
service_code: '--',
outlet: '--',
order_code: '--'
},
merchant_category_code: 2934,
currency: 933,
amount: 10.05,
convenience_indicator: 1,
fixed_fee: 0.01,
percentage_fee: 12.0,
country: 'BY',
merchant_name: 'Ivan Ivanov',
merchant_city: 'Minsk',
postal_code: '123456',
additional_data: {
bill_number: '--',
mobile_number: '--',
store_label: "OOO \"rubyQRpay\"",
loyalty_number: '***',
reference_label: '***',
customer_label: '--',
terminal_label: '--',
purpose_of_transaction: '***',
consumer_data_request: 'AME'
},
merchant_information_language: {
language_reference: 'ru',
name_alternate: 'Иван Иванов',
city_alternate: 'Минск'
}
}
url = 'https://pay.raschet.by#'
payload = Rubyqrpay::Generator.generate_payload(transaction_information)
base64 = Rubyqrpay::Generator.generate_png(url, payload)
License
The gem is available as open source under the terms of the MIT License.