<!-- 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 — Analyzing Social Media Evidence

## gallery-dl

```bash
gallery-dl --dest ./output/ "https://platform.example/user/post/123"
gallery-dl --write-metadata --write-info-json "URL"
gallery-dl -o filename="{date:%Y%m%d}_{id}.{extension}" "URL"
```

| Flag | Description |
|------|-------------|
| `--dest` | Output directory |
| `--write-metadata` | Write metadata JSON alongside media |
| `--write-info-json` | Write extended info JSON |
| `-o` | Set option (filename template, etc.) |

## yt-dlp

```bash
yt-dlp --write-info-json --write-thumbnail --write-subs "URL"
yt-dlp -o "%(title)s.%(ext)s" --write-description "URL"
yt-dlp --list-formats "URL"
```

## ExifTool

```bash
exiftool -json image.jpg                   # Full metadata as JSON
exiftool -GPS* image.jpg                   # GPS coordinates
exiftool -DateTimeOriginal image.jpg       # Original capture time
exiftool -Make -Model image.jpg            # Camera info
exiftool -all= image.jpg                   # Strip all metadata
exiftool -r -json ./directory/             # Recursive JSON output
```

## wget — Site Mirroring

```bash
wget --mirror --convert-links --adjust-extension \
  --page-requisites --no-parent -P ./output/ "URL"
```

## monolith — Single-File Archiver

```bash
monolith "URL" -o page.html
monolith -I -o page.html "URL"   # Isolate (no external requests)
```

## Wayback Machine API

```bash
# Save a page
curl "https://web.archive.org/save/URL"

# Check if archived
curl "https://archive.org/wayback/available?url=URL"
```

## Hash Verification

```bash
sha256sum file.png > file.sha256
sha256sum -c file.sha256           # Verify
find ./evidence/ -type f -exec sha256sum {} \; > manifest.sha256
```
