Archive Order Notes for WooCommerce (micro plugin) – Lifetime Doc. and FAQ

Back to Archive Order Notes for WooCommerce (micro plugin)

Support

How to request technical support?

If the issue you need technical support with is not covered on this page, click the link next to the license key in the plugin settings, then submit a ticket with your request.

Where do I report security vulnerabilities found in this plugin?

You can report security bugs through the Patchstack Vulnerability Disclosure Program. The Patchstack team helps validate, triage, and handle any security vulnerabilities. Report a security vulnerability.

Licensing

How to transfer the license to another domain?

You should ask for the domain change in your customer area, next to the original order details.

After you receive our reply confirming that the license key is free, go to the old website settings, remove the key, and save. Then go to the new website settings, insert the same key, and save. If you cloned the website, the license key is in the database; you need to remove it, save, insert it again, and save again.

General operation

Introduction

In this documentation, we refer to “order notes” or “comments” depending on the context. This is because, although the plugin processes only “order notes” by default, a developer filter allows overriding this behavior and processing other types of WordPress comments. For most users, you should read “comments” as “order notes”.

Getting started guide

Install the plugin and go to WooCommerce > Settings > General > Archive Order Notes for WooCommerce. Insert the provided license code to activate it.

Define if the order notes should be archived or permanently deleted, and the age of order notes to process.

The plugin uses WooCommerce’s bundled Action Scheduler and runs an action every hour, honoring the settings and processing 500 comments per run.

Accessing archived order notes

Archived order notes will be loaded on the order edit screen alongside non-archived notes. For now, archived customer order notes are not displayed in the order details under “My Account”.

Archive or delete order notes (comments) with WP-CLI

If you have a lot of guest orders and want to assign them all to registered customers, you can use our WP-CLI command to do so:

wp nakedcat-archive-order-notes archive

This is what will happen:

  • The “Archive or delete” setting will be honored;
  • The “Process older than” setting will be honored;
  • 500 comments will be processed, unless this default is overridden by the nakedcat_archive_order_notes_woo_comments_per_run filter or by the --limit argument;

You can override the number of comments to archive or delete. The default is 500.

wp nakedcat-archive-order-notes archive --limit=1000

You can also count how many comments are eligible for archiving or deletion according to the plugin settings:

wp nakedcat-archive-order-notes count

If you want to archive/delete all order notes (according to the plugin settings), you can first count them and then use the --limit argument to process them all.

Available developer hooks

The included technical support does not include the usage of these hooks.

Filter: nakedcat_archive_order_notes_woo_enable_logging

Allows disabling the plugin logging at WooCommerce > Status > Logs.
The default is true.
Parameters: $enable_logging
Return: bool

Filter: nakedcat_archive_order_notes_woo_comments_per_run

Allows overriding the number of comments processed per run of the scheduled task or the WP CLI command.
The default is 500.
Parameters: $comments_per_run
Return: integer

Filter: nakedcat_archive_order_notes_woo_optimize_interval

Allows overriding the interval between runs of the comments tables optimization.
The default is 259200seconds (72 hours).
Parameters: $seconds
Return: integer

Filter: nakedcat_archive_order_notes_woo_comments_types

Allows adding other comment types to the archiving/deletion processing. By default, only order notes are processed, which is the plugin’s goal. Use at your own risk.
The default is array( 'order_notes' ).
Parameters: $comment_types
Return: array

Action: nakedcat_archive_order_notes_woo_process_comments

Internal hook to run a batch of comments archiving or deletion. You can pass the number of comments to process and whether the action is being called from WP CLI. Not intended for use by 3rd party developers. Use at your own risk.
Parameters: $limit, $wpcli