nexi_xpay
Nexi XPay allows Drupal sites to accept online payments through Nexi Hosted Payment Page using configuration only. It provides a ready-to-use payment flow for site builders, with extensibility for developers who need to implement additional Nexi payment modes.
Features
This module provides a complete integration with Nexi XPay Hosted Payment Page for Drupal websites. Key features include:
- Ready-to-use Nexi Hosted Payment Page integration
- Secure redirection to Nexi checkout
- Automatic handling of payment return and cancellation
- Server-to-server payment notifications (notify)
- Reliable and idempotent payment status management
- User-friendly payment result pages
- Persistent payment transaction storage
- Support for both site builders and developers
The module is ideal when you need to accept online payments without building a custom checkout system or handling sensitive payment data directly.
Post-Installation
After installing and enabling the module:
- Go to Administration → Configuration → Web Services → Nexi XPay
- Configure the Nexi environment: Test (sandbox) or Production
- Enter the required Nexi credentials
Once configured, the module adds a new Nexi XPay transaction entity:
- Go to Content → Nexi XPay transactions
- Create a new transaction
- Share the generated payment link with users
No new content types or text formats are added. All interaction happens through standard Drupal administration pages.
Additional Requirements
This module requires:
- Drupal 11.3 or later
- PHP 8.3 or later
- HTTPS-enabled website
- A Nexi XPay account (required for production payments)
No external PHP libraries or SDKs are required.
Recommended modules/libraries
There are no required companion modules. The module works out of the box with Drupal core. Standard Drupal tools (permissions, theming, configuration overrides) can be used to tailor the integration to your site.
Similar projects
There are a number of Drupal modules that integrate payment gateways, including some that mention Nexi in their titles. It is useful to understand how the Hosted Payment Page (HPP) module differs from these, especially for site builders evaluating options.
Commerce Nexi and Commerce Nexi XPay
- Commerce Nexi is a payment gateway integration for Drupal Commerce that connects a Nexi payment method to the Drupal Commerce checkout system.
- Commerce Nexi XPay similarly integrates Nexi XPay into the Commerce checkout. It currently focuses on specific payment flows and is tightly coupled to the Commerce ecosystem.
Both modules are designed for Drupal Commerce stores and are not intended to be general-purpose payment building blocks outside of that context. They operate within the Commerce payment and checkout architecture and assume you are building a Commerce store.
Commerce Easy
Commerce Easy is an extension for Drupal Commerce that provides a fast checkout experience with support for multiple payment methods under the Nets Easy offering. It focuses on a specific set of payment providers and checkout behaviors within Commerce. As with the Commerce Nexi modules above, this solution is tied to the Commerce ecosystem and does not provide a site-builder-friendly, payment-agnostic base usable outside Commerce.
Why a Modular, Agnostic Approach Matters
The Hosted Payment Page module takes a different path, designed from the outset for flexibility and reuse:
- It does not depend on Drupal Commerce and can be used in any Drupal 11 site.
- The architecture separates core transaction and API concerns from specific payment flows, enabling site builders to configure and use HPP without writing or installing custom code.
- With appropriate extension modules, the same core infrastructure could support additional payment methods or flows in the future.
- The modular design makes it easier to maintain, extend, and reuse across different types of sites—commerce or otherwise.
This approach provides site builders with a consistent, UI-driven configuration experience, while still enabling developers to extend behavior where needed.
Supporting this Module
At the moment there are no formal funding or donation channels. Bug reports, feature requests, and contributions via the Drupal.org issue queue are welcome and appreciated.
Community Documentation
Full technical documentation, developer examples, and advanced usage are available in the project README:
- Programmatic transaction creation
- Pay URL generation
- Direct start payment flow
- Extensibility for additional payment methods
Additional documentation and examples may be added over time.