Sha256: dd16d9a6ffe6cf3d1b5f7f17dd3d5c20547625f05af35a3cfff2cf2dcf0e719f
Contents?: true
Size: 1.64 KB
Versions: 1
Compression:
Stored size: 1.64 KB
Contents
# YooKassa API Ruby Client [![Yookassa](https://circleci.com/gh/paderinandrey/yookassa.svg?style=svg)](https://circleci.com/gh/paderinandrey/yookassa) [![Gem Version][gem-badger]][gem] [![License](https://img.shields.io/github/license/paderinandrey/yookassa.svg)](https://github.com/paderinandrey/yookassa) [gem-badger]: https://img.shields.io/gem/v/yookassa.svg?style=flat&color=blue [gem]: https://rubygems.org/gems/yookassa ## Installation Add this line to your application's Gemfile: ```ruby gem 'yookassa' ``` And then execute: $ bundle Or install it yourself as: $ gem install yookassa ## Usage ```ruby # Payment client = Yookassa::Payment.new(shop_id: 'shop_id', api_key: 'api_key') payment = { amount: { value: 100, currency: 'RUB' }, capture: true, confirmation: { type: 'redirect', return_url: return_url } } client.create(payment: payment) client.get_payment_info(payment_id: '12345') client.capture(payment_id: '12345') client.cancel(payment_id: '12345') # Refund client = Yookassa::Refund.new(shop_id: 'shop_id', api_key: 'api_key') client.create(payload: payload) client.get_refund_info(payment_id: '12345') ``` ## Contributing Everyone is encouraged to help improve this project. Here are a few ways you can help: - [Report bugs](https://github.com/paderinandrey/yookassa/issues) - Fix bugs and [submit pull requests](https://github.com/paderinandrey/yookassa/pulls) - Write, clarify, or fix documentation - Suggest or add new features ## License The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
yookassa-0.1.0 | README.md |