Aloha
Aloha is a gem to access the web services
Installation
Add this line to your application's Gemfile:
gem 'aloha', git: 'git://github.com/bainur/aloha.git'
And then execute:
$ bundle install
Usage
The first, you create a variable eg. client
, for default setting without parameter like this:
client = Aloha::Soap.new
or with parameters :
eg. url = https://memberlinkWS.alohaenterprise.com/insightws/MemberLinkWS?wsdl
client = Aloha::Soap.new(
system_id: 'system ID',
company_id: 'company ID',
user_id: 'user ID',
account_password: 'password',
system_password: 'password',
wsdl_url: url)
Then, you can access for :
client.add_member_profile(
member_account_id: :integer,
card_number: :string,
first_name: :string,
last_name: :string,
company: :string,
date_of_birth: {
date: :string,
locale: :string
},
anniversary_date: {
date: :string,
locale: :string
},
drivers_license: :string,
address1: :string,
address2: :string,
city: :string,
state_province: :string,
country: :string,
postal_code: :string,
email_address: :string,
phone_number: :string,
other_phone_number: :string,
profile_exists: :boolean,
company_defined1: :string,
company_defined2: :string,
company_defined3: :string,
company_defined4: :string,
company_defined5: :string,
company_defined6: :string,
company_defined7: :string,
company_defined8: :string,
company_defined9: :string,
company_defined10: :string,
company_defined11: :string,
company_defined12: :string,
company_defined13: :string,
company_defined14: :string,
company_defined15: :string,
company_defined16: :string,
company_defined17: :string,
company_defined18: :string,
company_defined19: :string,
company_defined20: :string,
company_defined21: :string,
company_defined22: :string,
company_defined23: :string,
company_defined24: :string,
company_defined25: :string,
company_defined26: :string,
company_defined27: :string,
company_defined28: :string,
company_defined29: :string,
company_defined30: :string)
client.adjust_credit(
card_number: :string,
bpid: :integer,
adjustment_type: :string,
bp_credit: :integer,
reason: :string)
client.get_bonus_plan_history(
card_number: :string,
number_of_assignments: :integer,
number_of_days: :integer,
start_date: :string,
end_date: :string)
client.email_exists(email_address: :string)
client.get_card_number_by_email(
account_status: :string,
email_address: :string)
client.get_card_number_by_phone(
account_status: :string,
phone_number: :string)
client.get_card_status(card_number: :string)
client.get_member_profile(card_number: :string)
- Check card number by phone
client.phone_number_exists(phone_number: :string)
client.update_member_profile(
member_account_id: :integer,
card_number: :string,
first_name: :string,
last_name: :string,
company: :string,
date_of_birth: {
date: :string,
locale: :string
},
anniversary_date: {
date: :string,
locale: :string
},
drivers_license: :string,
address1: :string,
address2: :string,
city: :string,
state_province: :string,
country: :string,
postal_code: :string,
email_address: :string,
phone_number: :string,
other_phone_number: :string,
profile_exists: :boolean,
company_defined1: :string,
company_defined2: :string,
company_defined3: :string,
company_defined4: :string,
company_defined5: :string,
company_defined6: :string,
company_defined7: :string,
company_defined8: :string,
company_defined9: :string,
company_defined10: :string,
company_defined11: :string,
company_defined12: :string,
company_defined13: :string,
company_defined14: :string,
company_defined15: :string,
company_defined16: :string,
company_defined17: :string,
company_defined18: :string,
company_defined19: :string,
company_defined20: :string,
company_defined21: :string,
company_defined22: :string,
company_defined23: :string,
company_defined24: :string,
company_defined25: :string,
company_defined26: :string,
company_defined27: :string,
company_defined28: :string,
company_defined29: :string,
company_defined30: :string)
client.assign_forgotten_card(
card_number: :string,
claim_id: :string)
client.get_check_detail(
claim_id: :string,
store_id: :integer,
date_of_business: :string)
client.create_virtual_card(card_series: :string)
client.new_virtual_card(card_series: :string)
client.opt_out(card_number: :string)
client.phone_number_exists(phone_number: :string)
client.activate_new_card(batch_id: :integer)
client.create_new_card(
activate_card: :boolean,
batch_desc: :string,
batch_id: :integer,
card_series: :string,
number_of_cards: :integer,
numeric_sequence_type: :integer,
starting_card_number: :integer)
Contributing
- Fork it ( http://github.com/bainur/aloha/fork )
- Create your feature branch (
git checkout -b my-new-feature
)
- Commit your changes (
git commit -am 'Add some feature'
)
- Push to the branch (
git push origin my-new-feature
)
- Create new Pull Request