This is a gem for API wrapper of Zenti.com
Usage:
- Add this gem to you gem file
gem 'zenti' - Run
bundle install - Create this file
config/initializers/zenti.rband put this inside:Zenti.security_key = ENV['ZENTI_SECURITY_KEY'] - Set up that env variable.
- Test it with this with
type=sale:
method = 'post'
params = {:type=>"sale", :payment_token=>"00000000-000000-000000-000000000000", :amount=>3.0}
response = Zenti.request(method,params)
- For real usage, that
payment_tokenwill be the token generated by collect.js on front-end. - For other usages you need to check the params to be sent, please look into the API doc at https://zenti.com/developers/