> For the complete documentation index, see [llms.txt](https://cachebox.ortusbooks.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cachebox.ortusbooks.com/advanced-usage/cache-reporting/creating-your-own-skins/reporthandler/action-commands.md).

# Action Commands

Each skin template can execute action commands. We have several already constructed into the tag that can execute if it detects an incoming `URL` variable called `URL.cbox_command`. So if your report exists in a page called monitor.cfm then just call that same page (via AJAX preferably) with some `URL` variables attached (See default skin example). Now, below are the ones we implement, but you can build as many as you like and place them in the page where you use the monitor tag or in the skin templates themselves; wherever they make sense to you.

The following are the commands built in to the reporting tag and the incoming URL variables it expects. Please note that the command is taken from the `URL.cbox_command` variable:

| Command           | URL Variables                                                                | Description                                                                                                               |
| ----------------- | ---------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------- |
| expireCache       | `url.cbox_cacheName`                                                         | Executes a `expireAll()` in the cache provider specified by the incoming cache name.                                      |
| reapCache         | `url.cbox_cacheName`                                                         | Executes a `reap()` in the cache provider specified in the incoming cache name                                            |
| delCacheEntry     | <p><code>url.cbox\_cacheName</code><br><code>url.cbox\_cacheEntry</code></p> | Deletes the passed in cache entry from the named provider                                                                 |
| clearAllEvents    | `url.cbox_cacheName`                                                         | Executes a `clearAllEvents()` in the cache provider specified in the incoming cache name(Must be a ColdBox enabled cache) |
| clearAllViews     | `url.cbox_cacheName`                                                         | Executes a `clearAllViews()` in the cache provider specified in the incoming cache name(Must be a ColdBox enabled cache)  |
| cacheBoxReapAll   | `none`                                                                       | Executes a `reapAll()` via the CacheBox Cache Factory                                                                     |
| cacheBoxExpireAll | `none`                                                                       | Executes a `expireAll()` via the CacheBox Cache Factory                                                                   |
| gc                | `none`                                                                       | Executes a suggestion to the JVM to produce a garbage collection                                                          |

> **Info** : If the tag detects an incoming command, it will execute it, reset the content and output a **true** to the response buffer.

**Sample Calls**

```javascript
GET monitor.cfm?cbox_command=gc
GET monitor.cfm?cbox_command=cacheBoxReapAll
GET monitor.cfm?cbox_command=delCacheEntry&cbox_cacheName=default&cbox_cacheEntry=testKey
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://cachebox.ortusbooks.com/advanced-usage/cache-reporting/creating-your-own-skins/reporthandler/action-commands.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
