<!-- Copyright (c) 2026 defconxt. All rights reserved. -->
<!-- Licensed under AGPL-3.0 — see LICENSE file for details. -->
<!-- NERF is a trademark of defconxt. -->
# API Reference — Implementing Email Sandboxing

## YARA Pre-Filtering

```bash
yara email_prefilter.yar attachment.doc
```

## Sandbox API (Generic)

```bash
# Submit sample
curl -X POST "$SANDBOX_URL/submit" -H "Authorization: Bearer $API_KEY" -F "file=@sample.exe"

# Check verdict
curl "$SANDBOX_URL/reports/$SHA256" -H "Authorization: Bearer $API_KEY" | jq '.verdict'
```

## URL Rewriting Verification

```bash
curl -sI "https://sandbox.example.com/v1/url?target=$BASE64_URL" | head -5
```

## Agent Script

```bash
node agent.js classify --file attachment.exe
node agent.js audit-policy --policy sandbox_policy.json
node agent.js hash --file sample.doc
```
