docs: add per-tool API documentation and fix parity gaps

- Create 53 per-tool VitePress documentation pages with accurate
  parameters from Zod schemas, example requests, and response formats
- Add root llms.txt for LLM-friendly repo browsing
- Fix OpenAPI spec: add auth and 422 error schemas to
  edit-metadata/inspect and strip-metadata/inspect sub-routes
- Fix tool count inconsistency (52 -> 53) across landing site,
  e2e tests, and local docs
- Rename color-adjustments.ts to adjust-colors.ts to match tool ID
- Update VitePress sidebar with all 8 tool categories and top nav
This commit is contained in:
SnapOtter
2026-06-08 11:52:28 +08:00
parent ed177e7cc1
commit 7db6bb97da
62 changed files with 4490 additions and 15 deletions
+20 -1
View File
@@ -4300,6 +4300,12 @@ paths:
application/json:
schema:
$ref: "#/components/schemas/UnauthorizedError"
"422":
description: Failed to read image metadata
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/api/v1/tools/edit-metadata:
post:
@@ -4373,7 +4379,8 @@ paths:
tags: [Tools]
summary: Inspect metadata (ExifTool)
description: Read all metadata from an image using ExifTool. Returns all embedded EXIF, IPTC, XMP, and GPS fields.
security: []
security:
- bearerAuth: []
requestBody:
required: true
content:
@@ -4400,6 +4407,18 @@ paths:
application/json:
schema:
$ref: "#/components/schemas/Error"
"401":
description: Authentication required
content:
application/json:
schema:
$ref: "#/components/schemas/UnauthorizedError"
"422":
description: Failed to read image metadata
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
# ─── Batch ────────────────────────────────────────────────────────────────
@@ -35,8 +35,8 @@ const settingsSchema = z.object({
/**
* Build a 3x3 recomb matrix for color temperature + tint shift.
* Temperature: cool (blue) warm (orange) on the blue-orange axis.
* Tint: green magenta on the green-magenta axis.
* Temperature: cool (blue) <-> warm (orange) on the blue-orange axis.
* Tint: green <-> magenta on the green-magenta axis.
*/
function colorTempTintMatrix(
temp: number,
+1 -1
View File
@@ -2,6 +2,7 @@ import { TOOLS } from "@snapotter/shared";
import { eq } from "drizzle-orm";
import type { FastifyInstance } from "fastify";
import { db, schema } from "../../db/index.js";
import { registerColorAdjustments } from "./adjust-colors.js";
import { registerAiCanvasExpand } from "./ai-canvas-expand.js";
import { registerBarcodeRead } from "./barcode-read.js";
import { registerBeautify } from "./beautify.js";
@@ -9,7 +10,6 @@ import { registerBlurFaces } from "./blur-faces.js";
import { registerBorder } from "./border.js";
import { registerBulkRename } from "./bulk-rename.js";
import { registerCollage } from "./collage.js";
import { registerColorAdjustments } from "./color-adjustments.js";
import { registerColorBlindness } from "./color-blindness.js";
import { registerColorPalette } from "./color-palette.js";
import { registerColorize } from "./colorize.js";