Overview
The topropay module integrates with Drupal Commerce 2 as a Payment Gateway plugin and can be used standalone on a custom checkout form. It follows Drupal coding standards and ships with PHPUnit tests, so it survives core upgrades without surprises.
What you get
- Drupal Commerce 2 PaymentGateway plugin
- PSR-4 service container — no global state
- PHPUnit kernel tests bundled (drupal-test-traits)
- Configuration export-friendly (CMI / config sync)
Install in 3 steps
-
Install via Composer
composer require drupal/topropay then drush en topropay. Composer is the supported install path on Drupal 10+.
-
Add a payment gateway
Commerce → Configuration → Payment gateways → Add. Pick topropay, paste your keys, choose the routing strategy.
-
Verify the webhook route
The module exposes /payment/notify/topropay automatically. Confirm a sandbox event reaches it with a 200.