On-site payment gateways allow the customer to enter credit card details directly on the site. The details might be safely tokenized before they reach the server (Braintree, Stripe, etc) or they might be transmitted directly to the server (PayPal Payments Pro).
createPaymentMethod()and attached to the customer and the order.
createPayment(), which charges the provided payment method and creates a payment.
To create an On-site payment gateway, you'll want to start by creating a custom module, configuration schema, payment plugin, and configuration form methods, as described in the Getting started documentation for creating payment gateways.
Next, implement your gateway's
createPayment() method, as described in the Creating payments documentation.
Then continue with the Stored payment methods documentation to implement the required
deletePaymentMethod methods. If your payment gateway supports updating payment methods, you will also want to implement the
SupportsUpdatingStoredPaymentMethodsInterface interface and its
If your payment gateway supports authorizations, voids, or refunds, read the Authorizations, voids, and refunds documentation for an overview and example code.
Finally, if your payment gateway supports IPNs, read the Handling an IPN documentation for an overview and examples of IPN handling by existing payment gateways.
Found errors? Think you can improve this documentation? edit this page