WooCommerce Georgian Post International Shipping Method
Documentation for the Plug and Pay WooCommerce Georgian Post International Shipping Method plugin.
Requirements
Technical Requirements
- PHP: 7.4, 8.1, 8.2, or 8.3
- ionCube Loader: Required. For more details, check the ionCube Manual.
- WooCommerce: 3.6 or higher
Store Setup Prerequisites
- Currency: The plugin fetches rates from Gpost in GEL (Georgian Lari). It includes a currency converter (NBG or BOG) to automatically convert these rates into your store's base currency if you are not using GEL.
- Weights & Dimensions: All products must have weight and dimensions (length, width, height) defined to calculate box packing.
- Package Boxes: At least one package box must be defined in settings for the shipping calculator to work.
- Product Settings: Each product must have a Declaration Item assigned in the product shipping settings for customs purposes.
Technical Specification & Feature Support
| Feature | Supported |
|---|---|
| HPOS | ✅ |
| Shipping Zones | ✅ |
| Real-time Rates | ✅ |
| Parcel Registration | Manual |
| Label Printing | ✅ |
| Shipment Tracking | ✅ |
| Currency Converter | ✅ (NBG/BOG) |
| Box Packing | ✅ |
| Debug Mode | ✅ |
Setup
Global Settings
Go to WooCommerce > Settings > Shipping > Georgian Post to configure the global API settings:
- API username: Provided by Georgian Post.
- API password: Your Georgian Post API password.
- Currency converter: Choose between National Bank of Georgia, Bank of Georgia, or Disabled. Gpost returns shipping rates in GEL. If your store uses a different currency, this setting will automatically convert those GEL rates into your store's currency.
- Debug Log: Enable this to log API events for troubleshooting.
Package Boxes
Since this is an international shipping method, it requires pre-defined package boxes to calculate rates accurately.
- Go to WooCommerce > Settings > Shipping > Package boxes.
- Add your available shipping boxes with the following details:
- Ref. name: A descriptive name for the box.
- Outer Dimensions: Width, Length, and Height (cm).
- Inner Dimensions: Width, Length, and Height (cm).
- Empty weight: The weight of the box itself (kg).
- Max weight: The maximum weight the box can carry (kg).
Product Settings
For international shipping, customs declarations are mandatory.
- Edit a product (or variation).
- Go to the Shipping tab.
- Select the appropriate Declaration item from the dropdown. These items are fetched directly from the Georgian Post API.
- Ensure Weight and Dimensions are correctly set.
Shipping Zones
After configuring the global settings and package boxes, add the Georgian Post method to your desired shipping zones under WooCommerce > Settings > Shipping > Shipping zones.
Debugging
WooCommerce Shipping Debug Mode
When setting up or troubleshooting shipping rates, it is highly recommended to enable WooCommerce Shipping Debug Mode. This prevents WooCommerce from caching shipping rates, ensuring that every change you make to settings is reflected immediately.
To enable it:
- Go to WooCommerce > Settings > Shipping > Shipping options.
- Check the Enable debug mode box.
- Save changes.
Note: Remember to disable this once your store is live, as it can impact performance.
Features
Real-time Rate Calculation
The plugin uses a box-packing algorithm to determine which of your defined package boxes can fit the items in the cart. It then fetches real-time rates from the Georgian Post API based on the destination country, city, and packed box dimensions/weight.
Interactive City Selection
To ensure accurate shipping rates, the plugin dynamically fetches the official list of destination cities from the Georgian Post API based on the selected country during checkout. This ensures that customers select valid delivery locations and that the API returns correct pricing.
Parcel Registration
Store administrators can manually register parcels directly from the WooCommerce order details page. Once a shipping item is associated with the Georgian Post method, a Register button appears in the shipping items section of the order edit page.
Label Printing
After successful registration, a Print Label button becomes available to generate the shipping labels required for international post.
Shipment Tracking
Customers can view the real-time status of their shipment directly on the "View Order" page. The plugin fetches the latest routing information and status updates from Georgian Post.
Actions & Filters
plugandpay_gpost_shipping_method_rates
Type: filter When: After rates are fetched from Gpost API — controls the rates shown to the customer.
| Param | Type | Description |
|---|---|---|
$rates | array | Associative array of rates by ID |
// Free shipping for rate type 55.
add_filter(
'plugandpay_gpost_shipping_method_rates',
function( $rates ) {
if ( isset( $rates[55] ) ) {
$rates = [ $rates[55] ];
$rates[55]['Price'] = 0; // GEL !
}
return $rates;
},
100
);
WooCommerce Core Hooks
See General Shipping Hooks for standard filters like woocommerce_package_rates with examples (e.g., for free shipping based on cart total, city, or product ID).