I’m trying to write a custom payment gateway to work with a vendor’s payment processor. They have only provided me with an endpoint to capture the payment whereas Drupal Commerce 2 works in two steps – auth and then capture. I realize that is actually better, but alas it seems my hands are tied here.
In the createPaymentMethod
method, I can read the whole credit card number, but by the time I get through to the createPayment
method, it only has the last 4 digits expecting the payment processor to have provided a key to pair with those.
Is it possible to access the whole credit card number in the createPayment
method without storing the whole thing in the database (something I absolutely won’t/can’t do).
Thanks!