Oyi
Ruby library for https://oyindonesia.com/ APIs
Installation
Add this line to your application's Gemfile:
gem 'oyi'
And then execute:
bundle install
Or install it yourself as:
gem install oyi
Development
Running the tests
rake spec
Generate Documentation
rake yard
Usage
Configure the client
For the request params and responses please refer https://api-docs.oyindonesia.com/
Oyi::Client.configure(api_url: 'url', api_username: 'username', api_key: 'api_key')
Account Methods
Get beneficiery account details
Oyi::Account.inquiry(params)
Disbursement Methods
Get beneficiary account details
Oyi::Disbursement.inquiry(params)
Start disbursing money to a specific amount
Oyi::Disbursement.remit(params)
Get status of a disbursement request
Oyi::Disbursement.remit_status(params)
Get partner balance
Oyi::Disbursement.balance
Create a scheduled disbursement
Oyi::Disbursement.schedule_remit(params)
Get the details of a scheduled remit
Oyi::Disbursement.schedule_remit_details(params)
Get a list of all scheduled remits
Oyi::Disbursement.list_scheduled_remit(params)
Delete a scheduled remit
Oyi::Disbursement.cancel_scheduled_remit(params)
Retry a scheduled remit
Oyi::Disbursement.retry_scheduled_remit(params)
Virtual Account Methods
Create a new VA number
Oyi::VirtualAccount.create(params)
Get VA details
Oyi::VirtualAccount.get(id)
Update existing VA
Oyi::VirtualAccount.update(id, params)
Get all VAs
Oyi::VirtualAccount.all(params)
Get all transactions for a VA
Oyi::VirtualAccount.transaction(id, params)
Acceptance Methods
Create a payment checkout URL
Oyi::Acceptance.payment_checkout(params)
Create a payment checkout URL with addtional details for invoicing
Oyi::Acceptance.create_invoice(params)
Get the status of a transaction
Oyi::Acceptance.status(params)
Delete a payment/invoice link
Oyi::Acceptance.delete(params)
Get the details of a payment/invoice link
Oyi::Acceptance.get(params)