[ic] Verifone IPCharge
richard.siddall at elirion.net
Wed Mar 18 14:32:05 UTC 2009
Bill Carr wrote:
> I have taken your suggestion and have begun developing
> Business::OnlinePayment::IPCharge (requested my PAUSE ID and all).
> My question has to do with Interchange's
> Vend::Payment::BusinessOnlinePayment. There does not appear to be a
> way to pass additional parameters to BOP's content method from
> Interchange. In my case I am attempting the "Route onlinepayment
> setting value" method. Specifically for IPCharge we need to set the
> MERCHANTKEY and CLIENT_ID (a value different from the login name).
> IC's BOP wrapper has the parameters for BOP's content method hard
> coded. Any suggestions on how to get processor specific settings from
> IC to BOP?
I'm largely guessing here, after spending a few minutes looking at the
code for Vend::Payment::BusinessOnlinePayment, Business::OnlinePayment
itself, and a couple of Business::OnlinePayment processor modules.
My first assumption would be that MERCHANTKEY and CLIENT_ID are
analogous to a password and user name, and should be passed as the 'id'
and 'secret' parameters to the onlinepayment module, i.e. something like:
Route onlinepayment processor IPCharge
Route onlinepayment id my_client_id_value
Route onlinepayment secret my_merchantkey_value
These get passed to your module's 'content' method as the 'login' and
'password' hash entries, and you can then remap them to the the elements
required by IPCharge in various places, such as the map_fields,
remap_fields, or the submit method in your module.
Assuming that IPCharge actually requires more complex credentials than a
user name/id and password/key, then just pass the additional values:
Route onlinepayment client_id foo
It looks like these get passed to Business::OnlinePayment's new method
and wind up as attributes and methods on the Business::OnlinePayment
object, i.e. you can then use:
in methods like map_fields, remap_fields, or submit.
You may want to ask questions about which method is the best place in
your module to do the mapping on the Business::OnlinePayment e-mail
list: bop-devel at 420.am.
More information about the interchange-users