NEW: Should table creation fail during install, ask user if they have privileges to do so.
Improved: Prevent any further admin redirects if CoCart database failed to create.
Improved: Products API response for viewing a single variation to match all other product types with exceptions to certain fields not required.
Improved: Creation of CoCart database table and check it exists before attempting to do it again when CoCart updates.
Tweaked: Getting Started page by splitting upgrade information to a new sub-section called “Upgrade CoCart” with sub-menu shortcut.
Tweaked: WC Admin Notes for upgrading CoCart and 6 things to do with the products API.
What to do before testing!
If you have been using CoCart Products add-on, make sure you have the latest version of it installed before updating to this release to prevent crashing your site. Otherwise best to deactivate the add-on first.
Database changes
This release does not introduce any changes to the database.
If you discover any bugs during the testing process, please let me know by logging a report on the GitHub repository. There I can manage it better and get on the issue asap.
A new setup wizard is introduced that will help prepare the environment for a headless setup.
To help WooCommerce stores that are already selling, an option to transfer current sessions is available. This simply copies over all carts in the database to CoCart’s session table. Once completed it will remove them from WooCommerce session table to save database space.
If you are using multiple domains for your headless setup, CoCart Cors plugin will be installed and activated in the background. Upon completing the setup wizard, you will be presented with options on what you can do next.
You can if you wish ignore the setup wizard completely or run it again at any time from the CoCart menu.
CoCart Products add-on now merged and introducing API v2 with a new option to view single products by SKU. This gives users a great start to their development.
The product response is cleaner and better than before by including shortcuts for adding items to the cart or viewing other products connected.
Additional product support such as subscription data will remain in CoCart Pro only.
What to do before testing!
If you have been using CoCart Products add-on, make sure you have the latest version of it installed before updating to this release to prevent crashing your site. Otherwise best to deactivate the add-on first.
New Cart API route introduced that allows developers to add custom callbacks to update the cart for any possibility. See example.
No cache control has been added to the headers to help prevent CoCart from being cached at all so results return quicker.
If you discover any bugs during the testing process, please let me know by logging a report on the GitHub repository. There I can manage it better and get on the issue asap.
This release fixes a few minor bugs and tidies up the code a little more. This is the final release candidate before launching real soon.
What’s New since CoCart v3 RC 2?
NEW: Added PUT to Access-Control-Allow-Methods
Fixed: Undefined cart_key.
Fixed: Undefined object property ID.
Fixed: Check $user_id is not empty.
Fixed: Passed the product ID & quantity values for add to cart message that is finally added to cart to return the message correctly, specifically for variable products.
Improved: Various inline docs here and there.
Removed: Various lines of code not used any more to clean it up.
Testing
If you discover any bugs during the testing process, please let me know by logging a report on the GitHub repository. There I can manage it better and get on the issue asap.
I’m hoping now this release candidate is the last one but again, any remaining feedback you provide testing this release candidate is most appreciated.
What’s New since CoCart v3 RC 1?
NEW: Compatible with WP-GraphQL WooCommerce.
As both CoCart and WP-GraphQL WooCommerce extension use their own session handler, there was a clash.
With this release a condition has been added to check if a graphql request was being made in an area that CoCart also shares.
Now both plugins can work side by side.
NEW: Added notice for when item is removed from cart.
Fixed: Authentication with login API. Incorrect permission check used.
Localization: Added missing translator notes.
Testing
If you discover any bugs during the testing process, please let me know by logging a report on the GitHub repository. There I can manage it better and get on the issue asap.
Yes I did. The release post got delayed as I found a few other bugs while writing the documentation. Read the previous post so you have the full log on the new additions and corrections.
CoCart v3 is so close to launching now. Any remaining feedback you provide testing this release candidate is most appreciated.
What’s New since CoCart v3 Beta 4?
New: Added success notice for when a simple or variable product was added to cart.
Fixed: Authenticating on any API while requesting cart key.
Fixed: Product validation for adding grouped products.
Fixed: Response when requesting to return items after adding a grouped product.
Improved: Response returned when removing an item already removed from cart.
Improved: Response returned when restoring an item already restored to the cart.
Tweaked: All links pointing to CoCart.xyz
Updated: Getting started page.
Documentation
The documentation for v3 is now ready for API v2. You will find a section called breaking changes that will explain differences between the two API versions.
You can use the upgrade guide to help with the routes.
Node.js is now the default language tab and the menu navigation has been improved.
While there is still a lot to document, (mostly filters, I added way to many for v3) you can see all the options that are available for the new API version.
If you need help with any of it or you spot an error in the documentation, let me know via the live chat.
Testing
If you discover any bugs during the testing process, please let me know by logging a report on the GitHub repository. There I can manage it better and get on the issue asap.
CoCart v3 is just around the corner so any remaining feedback you provide testing this beta that needs solving before releasing a release candidate is most appreciated.
What’s New since CoCart v3 Beta 3?
NEW: Added login route to help with customer flow.
Improved: Check cart is completely empty not just the cart contents.
Improved: Product title now returns in status when item is removed from cart.
Corrected: Redirect to current page when hiding admin notice.
Added: Schema for count items API.
Added: Option to keep removed items in session when clearing the cart.
Deprecated: cocart_return_empty_cart filter.
Fixed: Install date value when product review notice loads for the user.
Fixed: Validation of variable product.
Fixed: Product validation failing before adding to cart to return error response.
Fixed: Formatting variation data for custom option.
Fixed: Issue with a non-numeric value encountered.
Fixed: Session failing returned response if cart is empty.
Fixed: Cart source when cart was first created no longer updates.
Merged: Changes added in CoCart v2.9.2
Moved: Deleting cart API under session API for admins only.
Tweaked: Cart response now returns empty only if no cart exists or the cart is completely cleared. This allows for only removed items left in session to be returned to the cart without issues.
Dev: Forked get_customer_unique_id() from WooCommerce session handler for backwards compatibility. Introduced to help with unit tests in WooCommerce since version 5.3. Not needed for CoCart but best to have it and not need it than not have it and need it.