Contributors: mariovalney
Donate link: https://github.com/mariovalney/shipping-loggi-for-woocommerce
Tags: woocommerce, api, loggi, shipping, mariovalney
Requires at least: 5.0
Tested up to: 5.6
Requires PHP: 7.3
Stable tag: 1.2.0
License: GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Shipping via motorcycle courier with Loggi
A plugin to integrate Loggi with WooCommerce.
WooCommerce is a awesome plugin used by 5+ million WordPress websites to create e-commerce.
Easy and quick!
Activate "Shipping Loggi for WooCommerce".
After that, add Loggi as shipping method and insert your credentials.
You can translate Shipping Loggi for WooCommerce to your language.
We would be grateful for a review here.
WooCommerce - 5.0
This plugin was created without any encouragement from Loggi. Loggi is a registered mark.
The developers of this plugin haven't any connection with Loggi. This plugin was created based on Loggi's documentation and we are not responsible for any estimation problem.
First
- Install WooCommerce and activate it.
Next
- Install "Shipping Loggi for WooCommerce" by plugins dashboard.
Or
- Upload the entire
shipping-loggi-for-woocommerce
folder to the/wp-content/plugins/
directory.
Then
- Activate the plugin through the 'Plugins' menu in WordPress.
We'll send all data about height, width, length and weight to Loggi and receive all the calculated packages.
Loggi is only able to receive two packages by estimation. This way, if you deactivate the "Try to Merge Boxes" option 20 itens will generate 10 delivery estimations.
Loggi has the limit of 55x55x55cm and 20kg.
By default we'll consider all products that need shipping, but you can use Shipping Classes to filter the method to one or more shipping classes or for products with none shipping class.
By default every item of order will be one package and we'll send all data to Loggi.
Loggi will receive two items by time and check if they can be sent in 1 or 2 deliveries. For example, two items with 20x20x20 will be sent in one travel, because they are less than the limit of 55x55x55. But two items with 40x40x40 will result in two deliveries (double of cost).
If you activate this option we'll try to agrupate items by our own way before send data to Loggi as they can handle only 2 packages by request.
Make sure all cart items can be sent by Loggi. You can check logs.
We get the value from Loggi in seconds and change to hours (rounding up).
If your package will be divided in more than one estimation we use the bigger value.
No problem. You can add "additional time" to your operation. Just setting how much hours you'll need for it.
Sure! You can show the days you will delivery with Loggi.
Don't forget to check Loggi support about working date and time.
You should use the filter 'slfw_rate_delivery_time_text' to write your own message.
Your e-mail and API Key from Loggi.
If you do not know your API Key, you can insert your password and will try to retrieve it. Learn more.
Every Loggi integration needs a shop. So you should request one for Loggi Support and select it on shipping settings.
You can have one Loggi integration for every shop if you can send items from multiple cities.
We should request Loggi to retrieve a estimation. It takes 2 seconds in average by our testings.
To avoid taking this time every time you load your cart we'll save this value and request only after 5 minutes. This value is unique by cart and destination so we will request Loggi again if you change any product, variation, quantity or any detail from destination.
In checkout page we'll request Loggi always to avoid any misvalue in the order totals.
Well... This is a developer friendly plugin. So we have a lot of hooks to be used.
Actions:
- slfw_before_get_admin_options_html
Filters for Form Fields:
- slfw_form_fields_after_main
- slfw_form_fields_after_api
Filters for Shipping Method:
- slfw_pickup_address
- slfw_format_address
- slfw_rate_additional_time
- slfw_rate_delivery_time_text
- slfw_use_session_on_estimation
Filters for Rate:
- slfw_calculate_shipping_rate: You can change the rate args before add to cart or return empty to remove it.
Filter for Log:
- slfw_log_message
Filter for API:
- slfw_api_request_args: You can change all requests to api.
- slfw_api_retrieve_api_key
- slfw_api_retrieve_all_shops
- slfw_api_retrieve_order_estimation
They are well documented on respective calls and you owe me a beer.
Yes! Visit GitHub repository.
- Added estimation to WooCommerce Session to improve performance.
- Added log on success.
- Fixed weight unit hardcoded.
- It's alive!
It's alive!