mohan-devstack/magento2-paypal-rest-checkout

Standalone PayPal REST Orders v2 payment integration for Magento 2. No Magento_Paypal or SOAP/NVP dependency. Server-side redirect checkout with capture, refund, and admin transaction support.

Maintainers

Package info

github.com/mohan-devstack/magento2-paypal-rest-checkout

Type:magento2-module

pkg:composer/mohan-devstack/magento2-paypal-rest-checkout

Transparency log

Statistics

Installs: 2

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

1.0.0 2026-07-14 10:59 UTC

This package is auto-updated.

Last update: 2026-07-14 11:02:02 UTC


README

A standalone PayPal REST Orders v2 payment module for Magento 2. Uses only the modern REST API — no dependency on Magento_Paypal, SOAP, or the deprecated NVP/SOAP stack that PayPal is retiring.

Features

  • PayPal REST Orders v2 API (/v2/checkout/orders)
  • Server-side redirect checkout flow — no JS SDK required
  • Automatic invoice generation on successful capture
  • Online refunds (full and partial) via credit memo
  • Admin transaction detail page with PayPal capture information
  • Sandbox / Live toggle in admin config
  • No Magento_Paypal dependency

Requirements

  • Magento 2.4.4 or later
  • PHP 8.1 or later
  • PayPal REST API credentials (Client ID + Secret from developer.paypal.com)

Installation

Via Composer (recommended)

composer require mohan/magento2-paypal-rest-checkout
php bin/magento module:enable Mohan_PaypalRest
php bin/magento setup:upgrade
php bin/magento cache:clean

Manual

  1. Copy the module to app/code/Mohan/PaypalRest/
  2. Run:
    php bin/magento module:enable Mohan_PaypalRest
    php bin/magento setup:upgrade
    php bin/magento cache:clean

Configuration

Stores > Configuration > Mohan > PayPal REST Checkout

Field Description
Enabled Enable/disable the payment method
Payment Title Label shown at checkout (default: "PayPal")
Sort Order Position in the payment method list
Payment from Applicable Countries Restrict to specific countries
Use Sandbox Enable for testing; disable for production
Client ID From developer.paypal.com REST app
Client Secret From developer.paypal.com REST app

Checkout Flow

  1. Customer selects PayPal at checkout and clicks Place Order
  2. Magento creates the order in pending_payment state
  3. Module creates a PayPal Orders v2 order and redirects the customer to PayPal
  4. Customer approves on PayPal and is returned to the store
  5. Module captures the payment, generates an invoice, and moves the order to processing
  6. Order confirmation email is sent

Refunds

Full and partial refunds are processed via Sales > Orders > Credit Memo in the Magento admin. The module calls /v2/payments/captures/{id}/refund on PayPal automatically.

Support

License

OSL-3.0