Project

ebanx

0.02
No commit activity in last 3 years
No release in over 3 years
EBANX is the market leader in e-commerce payment solutions for International Merchants selling online to Brazil
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

Runtime

>= 0
~> 2.0.2
 Project Readme

EBANX Ruby gem Build Status Code Climate Test Coverage

Gem to communicate with EBANX.

Documentation: https://developers.ebanx.com/

Installation

Add this line to your application's Gemfile, and bundle it:

gem 'ebanx'
$ bundle

Or install it yourself as:

$ gem install ebanx

Usage

Auth

Ebanx.tap do |e|
  e.integration_key = '<<< Your integration key >>>'
  e.test_mode       = true
end

Create a new Boleto using Direct API

response = Ebanx.do_direct(
  operation: 'request',
  mode: 'full',
  payment: {
    name: 'João da Silva',
    email: 'joao@mailinator.com',
    currency_code: 'USD',
    amount_total: 100.50,
    merchant_payment_code: Random.rand(10000000000),
    payment_type_code: 'boleto',
    person_type: 'personal',
    document: '13326724691',
    birth_date: '01/01/1980',
    zipcode: '70000-000',
    address: 'Rua Brasil',
    street_number: '1',
    city: 'Brasília',
    state: 'DF',
    country: 'br',
    phone_number: '6130001111',
    due_date: (Time.now + 86400).strftime('%d/%m/%Y')
  }
)

Automated Tests

We use minitest for testing this Gem.

rake test

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request