Skip to content

Реализация протокола автоматизации массовых выплат на Rails

License

Notifications You must be signed in to change notification settings

PNixx/yandex-kassa

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

YandexKassa

Installation

Add this line to your application's Gemfile:

gem 'yandex-kassa'

And then execute:

$ bundle

Or install it yourself as:

$ gem install yandex-kassa

Usage

require 'yandex_kassa'

# Initialize
yandex_kassa = YandexKassa::Deposition.new('demo.yamoney.ru:9094', "my.cer", "private.key", "deposit.cer")

request_params = {
		dstAccount: '410039303350',
		clientOrderId: 123,
		amount: amount,
		currency: 10643,
		agentId: 234,
		contract: 'payment_event'
}

# Test request
response = yandex_kassa.test_deposition(request_params)

# Make deposition
response = yandex_kassa.make_deposition(request_params)

# Requests with paymentParams
response = yandex_kassa.make_deposition(request_params, {pof_offerAccepted: 1, smsPhoneNumber: 79653457676})

About

Реализация протокола автоматизации массовых выплат на Rails

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages