WP Manifestindependent plugin directory
manifest / ecommerce / brs-shipping-debug-display

BRS Shipping Debug Display

Show Shipping Debug Info on WooCommerce Cart

by Big Red SEO · github.com/bigredseo/brs-shipping-debug-display · website

0stars
1release downloads
0forks

Install

The author publishes release zips, so WP-CLI can install straight from GitHub:

wp plugin install https://github.com/bigredseo/brs-shipping-debug-display/releases/download/v1.0.4/brs-shipping-debug-display-1.0.4.zip

Readme

BRS Shipping Debug Display

BRS Shipping Debug Display is a standalone WooCommerce debugging plugin that adds an admin-only shipping debug panel to the cart page.

It is intended for developers, store owners, and site administrators who need to inspect how WooCommerce is calculating shipping packages, selected shipping methods, returned rates, product weights/dimensions, and carrier API responses when available.


What It Does

The plugin displays a formatted shipping debug panel on the WooCommerce cart page for users with WooCommerce management permissions.

The debug panel can show:

  • Current WooCommerce shipping packages
  • Destination data sent into the shipping calculation
  • Products included in each package
  • Product weight and dimensions
  • Shipping classes
  • Package contents cost
  • Returned WooCommerce shipping rates
  • Selected cart shipping method
  • Rate decision summary
  • Rates grouped by detected carrier
  • Carrier API request/response captures when available
  • Possible box/packing data if exposed by the shipping plugin

The panel is designed to be readable for admins and clients without dumping raw PHP arrays onto the page.


Supported Carriers / Methods

The plugin is not limited to one carrier. It displays whatever rates WooCommerce receives.

Carrier grouping currently attempts to identify:

  • UPS
  • FedEx
  • USPS
  • DHL
  • Other WooCommerce shipping methods

The plugin can also attempt to capture sanitized carrier API traffic for:

  • UPS
  • FedEx
  • USPS
  • DHL

Carrier API capture only works when the active shipping plugin sends requests through the WordPress HTTP API.


Requirements

  • WordPress
  • WooCommerce
  • PHP 7.4 or newer recommended
  • A WooCommerce cart page using standard WooCommerce shipping calculations

Installation

  1. Download or clone this repository.

  2. Upload the plugin folder to:

    /wp-content/plugins/brs-shipping-debug-display/
  3. Activate BRS Shipping Debug Display from the WordPress Plugins screen.

  4. Log in as an admin or WooCommerce manager.

  5. Add a product to the cart.

  6. View the cart page.

  7. Scroll below the cart totals to see the shipping debug panel.


Admin-Only Visibility

The debug panel is only shown to users who can manage WooCommerce.

The plugin checks for the WooCommerce capability:

manage_woocommerce

Customers and non-admin users should not see the debug output.


Rate Decision Summary

The Rate Decision Summary section shows how WooCommerce handled the available shipping rates for each package.

This section shows:

  • How many rates WooCommerce received
  • Which shipping method is selected
  • Which returned rate matched the selected method
  • Whether the selected rate was auto-selected because it was the only available rate
  • Whether the selected rate was chosen from multiple available rates
  • Other available rates when WooCommerce received more than one option
  • The rate source used by the debug plugin

Example:

Rates returned to WooCommerce: 1
Selected method: fedex:3:FEDEX_GROUND
Selected rate: FedEx Ground — $26.19
Selection status: Auto-selected because this was the only rate available to WooCommerce.

Carrier API Capture

The plugin attempts to capture sanitized carrier API request/response data when carrier plugins use WordPress HTTP functions such as:

wp_remote_get()
wp_remote_post()
wp_remote_request()

This may show carrier responses from plugins such as FedEx, UPS, USPS, or DHL shipping plugins.

However, this is not guaranteed. Some carrier plugins use direct cURL, SOAP clients, SDKs, custom request layers, or internal logging. In those cases, WooCommerce may still receive rates correctly, but this plugin may not be able to capture the raw carrier API request/response.

If the API capture section is empty, it may mean:

  • Rates were loaded from WooCommerce cache/session
  • The carrier plugin did not make a fresh API request during that page load
  • The shipping plugin does not use the WordPress HTTP API
  • The carrier plugin logs API details internally instead of exposing them to WordPress HTTP hooks

The Rates Returned to WooCommerce section is usually the more reliable section for confirming what WooCommerce actually received.


Debugging Dimensional Weight

This plugin is especially useful for debugging large, lightweight products where shipping rates are affected by dimensional weight.

For example, FedEx may rate a 3 lb product as a 25 lb package if the box dimensions trigger dimensional weight.

The debug output can help compare:

  • Product actual weight
  • Product dimensions
  • WooCommerce package data
  • Selected carrier rate
  • Carrier response notes such as dimensional weight usage
  • Billing weight returned by the carrier when visible

Privacy / Security Notes

This plugin is intended for temporary debugging.

The debug output may include shipping-related data such as:

  • Cart destination
  • Product names
  • Product IDs
  • Variation IDs
  • Product dimensions
  • Product weights
  • Shipping method IDs
  • Returned rate costs
  • Sanitized carrier API responses

The plugin attempts to redact sensitive API fields when carrier API data is captured. However, it should still be used carefully on production sites.

Recommended use:

  • Enable only when actively debugging shipping.
  • Disable when no longer needed.
  • Do not show the cart page debug panel to non-admin users.
  • Do not copy/paste raw API responses publicly without reviewing them first.

Files

Main plugin structure:

brs-shipping-debug-display/
├── brs-shipping-debug-display.php
├── includes/
│   ├── helpers.php
│   ├── package-debug.php
│   ├── http-capture.php
│   └── render.php
├── assets/
│   └── css/
│       └── shipping-debug-display.css
└── README.md

Notes for Developers

The plugin uses WooCommerce shipping package and rate hooks to gather debug data.

Important WooCommerce data points include:

WC()->shipping()->get_packages();
WC()->session->get( 'chosen_shipping_methods' );
WC()->session->get( 'shipping_for_package_0' );

The plugin also uses fallback logic to read cached WooCommerce package rates when rates were already calculated before the visible cart render.


Author / Maintainer

Developed and maintained by Big Red SEO.

This plugin was built as a WooCommerce debugging utility for inspecting cart shipping packages, returned rates, selected methods, and carrier API data when available.


License

GPLv2 or later.

Read the full README on GitHub →

Releases

TagPublishedAssetDownloads
v1.0.4 Jun 11, 2026 brs-shipping-debug-display-1.0.4.zip 1