Vai al contenuto

Maho 26.5.0: new PayPal, AI in the core and PHP attributes instead of XML

26.5.0 brings PayPal on the new SDK, EU VAT validation, PHP attributes for routing and observers, a multi-provider AI module and an image editor.

26.5.0 is a release with several new things, spread over three fronts: payments, the way code is written, and the tools around the store. Here are the ones that change the daily work.

Payments: PayPal on the new SDK

The PayPal module was rewritten on the PayPal v6 SDK and offers three payment methods: Standard Checkout with the PayPal and Pay Later buttons, Advanced Checkout with card fields hosted by the provider, where card data never touches the store server, and Vault for a saved payment method. The lifecycle is complete: authorize, authorize and capture, partial or full capture, partial or full refund, void, and reading the transaction.

Buttons can sit in the checkout, the cart and the product page, and the Pay Later message appears on product and cart pages, hiding itself when the product is out of stock. Saved methods get their own page, My Account > Saved Payment Methods, and work in admin order creation too. To check the configuration there are the Test Connection and Register Webhook buttons, and for local development the ./maho paypal:webhook:simulate command.

The old Mage_Paypal is gone and the maho_paypal alias became plain paypal.

EU VAT numbers validated live

VAT validation checks the format for more than 30 countries, the European Union, the United Kingdom, Switzerland and Norway included, and for European countries it verifies the number online against VIES. Results are cached, with a configurable lifetime and 24 hours by default, and when VIES does not answer a store can choose to accept a number that is formally valid. The check runs on field blur and on country change, in the admin and on the storefront, one-page checkout included.

Less XML: routing, observers and cron as PHP attributes

Routing moves to Symfony Routing with #[Route] attributes, with automatic area detection from the controller, the admin frontName resolved at runtime, an HTTP method allow list and named routes for URL generation. XML routing keeps working and is evaluated first, so existing customisations are not touched.

Observers and cron jobs are declared as PHP attributes too, compiled at build time with no per-request cost, and they still respect rewrites. A cron job that fails no longer stops the others. For modules written with XML there are migration commands and a health check, and the admin cache page has a Recompile PHP Attributes button.

AI in the core

The Maho_Ai module brings seven providers (OpenAI, Anthropic, Google, Mistral, OpenRouter, Ollama and a generic OpenAI-compatible bridge), three capabilities (chat, embeddings and image generation, depending on the provider), an async job queue with retries and stuck-task recovery, vector storage for embeddings and a set of guardrails: blocked prompt injection patterns, a configurable blocklist, output sanitising and personal data detection. The admin has pages for tasks, usage, reindex and configuration.

Tools for developers

Maho_Intelligence adds an MCP server with eleven tools for agents (aliases, rewrites, events, the merged configuration, modules, layout, cron, tables and ACL) and an LSP server for editors, with completion inside Mage::getModel() and friends, go to definition from the alias to the file, hover with the rewrite chain and diagnostics on unresolved aliases. They start with ./maho dev:mcp:start and ./maho dev:lsp:start, and the official plugins for PhpStorm, VS Code and Zed are published, or in publication, in their registries.

Image editor in the browser

The media library editor is plain JavaScript and includes crop, resize, rotate, adjustments, annotations, redaction, frame and background removal with an AI model that runs locally, on WebGPU where available. The model is downloaded once and stays in the browser cache, so images never leave the store server. The editor loads only when it is opened.

Upgrading to 26.5.0

After the install or the update, run composer dump-autoload, which generates the compiled routing and attribute artefacts. A store using PayPal configures the method on the new module, and customisations on the old module alias move to the new name. The full 26.5.0 release notes remain the source for the details.

Text prepared with the help of AI and checked against the source before publication. It can still contain mistakes: if you find one, report it.Read the manifesto

Source: Release 26.5.0

Does your store still sell?

Tell us where you are starting from: we reply with a first assessment, no strings attached.

Ask for the store assessment