MediaAnalyzer

Docs

Describe and sort a photo and video library from the terminal, the browser, DiskPush, or your own code.

CLI quickstart

Install, sign in once in your browser, then scan a folder. Big libraries are what the CLI is for.

$curl -fsSL https://mediaanalyzer.pro/install.sh | sh

Or with npm: npm i -g @profullstack/mediaanalyzer

mediaanalyzer login            # opens your browser; approve, and you're signed in
mediaanalyzer scan ~/Pictures   # previews, uploads, live dashboard, results saved locally
mediaanalyzer apply ~/Pictures  # shows the plan; add --yes to write descriptions and move files
mediaanalyzer undo ~/Pictures   # puts every moved file back

scan shrinks each file on your machine (videos become one contact sheet of frames, using ffmpeg if it is installed) and uploads only those previews. Re-running a scan skips files already done. Pick a tier with --tier standard|premium|byok.

Applying results

apply writes <file>.description.txt next to each file and moves both into <folder>/<category>/. It prints the plan and changes nothing until you pass --yes. Every move is recorded in .mediaanalyzer/undo-*.json inside the scanned folder, and undo reverses the last apply. Use --no-move to only write descriptions, or --out <dir> to sort into another folder.

Folders

The model picks exactly one folder per file from your list. Edit it under Folders or pass --folders pets,travel,receipts for one scan. Nested names like kids/soccer become nested directories. other is always included.

Your own model

Under Providers, connect an Anthropic key, or any OpenAI-compatible endpoint: OpenAI, OpenRouter, Together, or your own Ollama or vLLM. Keys are stored encrypted. BYOK scans cost $0.20 per 1,000 files on our side; your provider bills the model.

DiskPush

In DiskPush, enable the MediaAnalyzer plugin, select files or folders in the local pane, and choose Analyze media. It signs in with the same browser flow as the CLI.

API reference

Base URL https://mediaanalyzer.pro. Authenticate with an API key from API keys as Authorization: Bearer ma_key_.... Errors are { "error": { "code", "message" } }; a 402 means not enough credit.

GET/api/v1/meAccount, balance, folders, tiers, connected providers
GET/api/v1/scansYour scans, newest first
POST/api/v1/scansCreate a scan: { name, tier, provider_key_id?, categories? }
GET/api/v1/scans/:idOne scan with per-folder counts
POST/api/v1/scans/:id/filesQueue up to 50 files (multipart: meta + file0..fileN)
GET/api/v1/scans/:id/filesResults, paged: ?after=<id>&limit=500&status=done
GET/api/v1/scans/:id/exportAll results as CSV, or ?format=json
POST/api/v1/scans/:id/cancelStop files that have not started
DELETE/api/v1/scans/:idDelete a scan and its results
GET / PUT/api/v1/foldersRead or replace your folder list
curl -s https://mediaanalyzer.pro/api/v1/scans \
  -H "Authorization: Bearer $MEDIAANALYZER_KEY" \
  -H "content-type: application/json" \
  -d '{"name":"Holiday","tier":"standard"}'

curl -s https://mediaanalyzer.pro/api/v1/scans/$SCAN/files \
  -H "Authorization: Bearer $MEDIAANALYZER_KEY" \
  -F 'meta=[{"client_ref":"a1","name":"IMG_1.jpg","rel_path":"2024/IMG_1.jpg"}]' \
  -F file0=@IMG_1.jpg

The CLI and DiskPush sign in with OAuth 2.1 (authorization code + PKCE, loopback redirect) at /oauth/authorize and /api/v1/oauth/token; refresh tokens rotate on every use.