
# BugSack / BugGrabber Bridge

ApiVault can mirror future Lua errors into the ApiVault Error Inbox and Bug Advisor by chaining the WoW error handler.

## Commands

```text
/av bugsack
/av buggrabber
/av errormirror
/av errorhandler
```

## How it works

ApiVault uses the standard WoW error handler chain:

```text
current error handler -> ApiVault mirror -> previous handler
```

If BugSack/BugGrabber has already installed an error handler, ApiVault stores it as the previous handler and calls it after capturing the error.

This means BugSack can keep receiving the error while ApiVault also records it.

## What it captures

```text
- Future Lua errors after ApiVault is loaded and the bridge is installed
- Error message
- stack trace when debugstack is available
- addon name parsed from Interface/AddOns/... path
- file and line where detectable
```

## What it does not do

```text
- Does not assume BugSack internals
- Does not read BugSack saved history
- Does not import old errors already in BugSack
- Does not execute external code
- Does not add protected/secure execution
```

If BugGrabber/BugSack source/API is supplied later, a specific history-import adapter can be added.
