Lewebexy Partial COD with Razorpay for WooCommerce

Опис

Lewebexy Partial COD with Razorpay for WooCommerce adds a new payment
method at checkout that replaces plain Cash on Delivery. The customer
pays a small advance online via Razorpay (UPI, cards, netbanking), and
the remaining balance is collected as COD on delivery.

This helps store owners filter out fake or low-intent COD orders, since the
customer has already made a real payment before the order is confirmed.

Key features

  • Fixed amount (₹) or percentage-based advance — admin’s choice
  • Advance amount automatically capped so it never exceeds the order total
  • Works on both the classic (shortcode) checkout and the WooCommerce
    Cart & Checkout blocks
  • Razorpay payment signature verified server-side before any order is
    confirmed — never trusts the browser alone
  • Advance paid / COD balance due clearly shown on the admin order screen,
    customer order emails, and the order-received / My Account order view
  • HPOS (High-Performance Order Storage) compatible

Requirements

  • WooCommerce
  • A Razorpay account (test or live API keys)

Support

For support or custom requirements, contact Le Webexy Pvt. Ltd. at
https://lewebexy.com/

External services

This plugin requires a Razorpay account and connects to Razorpay
(„Razorpay Software Private Limited“) to process the online advance
payment. This is core functionality — without it, the plugin cannot
collect the advance payment that the plugin exists to collect.

What the service is and what it’s used for: Razorpay is a payment
gateway used to securely collect the advance payment amount from the
customer at checkout (via UPI, card, or netbanking), and to verify that
the payment was genuinely completed before the order is confirmed.

What data is sent, and when:

  • When a customer selects this payment method and proceeds to pay the
    advance, the plugin loads Razorpay’s checkout script from
    https://checkout.razorpay.com/v1/checkout.js to display the secure
    payment popup.
  • The plugin sends the order amount (advance only, not the full order
    total) and a receipt reference to Razorpay’s Orders API
    (https://api.razorpay.com/v1/orders) to create a payment order,
    using the store admin’s own Razorpay API keys (entered in
    WooCommerce Settings Payments this gateway’s settings — never
    hardcoded in the plugin).
  • The customer’s name, email, and phone number (already provided at
    checkout) are passed to Razorpay’s checkout popup to pre-fill the
    payment form, as permitted by Razorpay’s standard Checkout integration.
  • After payment, Razorpay returns a payment ID and signature, which the
    plugin verifies server-side against the store’s own Razorpay secret
    key before marking the order’s advance as paid. No card or bank
    details are ever handled or stored by this plugin — that happens
    entirely within Razorpay’s own hosted checkout.

Razorpay’s terms of service: https://razorpay.com/terms/
Razorpay’s privacy policy: https://razorpay.com/privacy/

This plugin does not track users for analytics or advertising purposes,
and does not send any data to any service other than Razorpay, and only
for orders where this payment method is actually used.

Постављање

  1. Upload the plugin ZIP via Plugins Add New Upload Plugin, or extract
    into /wp-content/plugins/.
  2. Activate the plugin. (Requires WooCommerce to be installed and active.)
  3. Go to WooCommerce Settings Payments this gateway’s settings.
  4. Enable it, choose Advance Type (Fixed / Percentage) and Advance Value.
  5. Enter your Razorpay Key ID and Key Secret.
  6. Disable WooCommerce’s default „Cash on delivery“ gateway so customers
    aren’t shown two similar payment options at checkout.

ЧПП

Does this work with the new WooCommerce block checkout?

Yes. The plugin registers with both the classic shortcode checkout and the
Cart & Checkout blocks.

What happens if the customer closes the Razorpay window without paying?

The order stays in „Pending payment“ status. The customer can retry payment
any time from My Account Orders Pay, and the same Razorpay order is
reused rather than creating a duplicate.

Can the advance amount exceed the order total?

No. The advance is automatically capped at the order total, so a fixed ₹100
advance on an ₹80 order only charges ₹80.

Is the Razorpay payment verified securely?

Yes. The plugin verifies Razorpay’s HMAC SHA256 payment signature
server-side before marking any order as paid. The client-side success
callback alone is never trusted.

Does this plugin track users?

No. It does not collect any analytics or tracking data. It only sends the
minimum data required to Razorpay to process the advance payment — see
„External services“ above.

Прегледи

Нема рецензија за овај додатак.

Сарадници и градитељи

„Lewebexy Partial COD with Razorpay for WooCommerce“ је софтвер отвореног кода. Следећи људи су допринели овом додатку.

Сарадници

Преведите „Lewebexy Partial COD with Razorpay for WooCommerce“ на свој језик.

Заинтересовани сте за градњу?

Прегледајте код, проверите SVN складиште или се пријавите на белешку градње преко RSS-а.

Белешка о изменама

1.0.2

  • Fixed missing script version on the Razorpay checkout.js enqueue call.
  • Cleaned up uninstall.php: prefixed variable name, documented
    phpcs:ignore justifications for the direct/interpolated queries
    (table names cannot be parameterized via $wpdb->prepare(), and a
    one-time uninstall cleanup has no caching to add).

1.0.1

  • Renamed for distinctiveness per WordPress.org review feedback.
  • Razorpay checkout.js and the payment-trigger script are now properly
    enqueued via wp_enqueue_script()/wp_localize_script() instead of
    inline tags.
  • Added „Requires Plugins: woocommerce“ header.
  • Documented Razorpay as an external service in this readme.

1.0.0

  • Initial release — Fixed/percentage advance via Razorpay, classic +
    block checkout support, signature verification, admin/customer order
    display, HPOS compatibility.