Skip to content

Technical docs

Hasan Hasanzade edited this page Aug 21, 2024 · 7 revisions

How to add new async payment method

  1. Add payment method main class file in includes/payment-gateways. Follow the class structure and naming (Ctrl+C & Ctrl+V 😉) from other async payment methods (i.e. Credit Card). Shortcode, name, description should be defined in this file.
  2. Include that file in the init() method of plugin base class file - bp-plugin-woocommerce-api2.php. Then add it to $methods array in add_betterpayment_gateways().
  3. Generate, translate and compile strings used (name & description). As a result strings should be added to .pot file, then compiled into corresponding locale .po file.

I guess that's it :)

Clone this wiki locally