Gangway requires eWay credentials in the .env file
EWAY_USERNAME=username
EWAY_PASSWORD=password
require 'gangway'
# add a user
Gangway::Subscriber.add({email: '[email protected]',
subscriber_data: {first_name: 'Test', last_name: 'User'}, handler_id: 1})
# get subscriber data
Gangway::Subscriber.get({email: '[email protected]'})
# get subscription status
Gangway::Subscriber.subscription_status({email: '[email protected]'})
# change user's email
Gangway::Subscriber.change_email({old_email: '[email protected]', new_email: '[email protected]'})