docs: section-prefix tool API endpoints

This commit is contained in:
SnapOtter
2026-06-21 00:12:59 +08:00
parent b052241c92
commit 9f0b43271c
161 changed files with 404 additions and 402 deletions
+4 -4
View File
@@ -8,7 +8,7 @@ AI-powered background removal with optional effects (blur, shadow, gradient, cus
## API Endpoint
`POST /api/v1/tools/remove-background`
`POST /api/v1/tools/image/remove-background`
**Processing:** Asynchronous (returns 202, poll `/api/v1/jobs/{jobId}/progress` for status via SSE)
@@ -36,7 +36,7 @@ AI-powered background removal with optional effects (blur, shadow, gradient, cus
## Example Request
```bash
curl -X POST http://localhost:1349/api/v1/tools/remove-background \
curl -X POST http://localhost:1349/api/v1/tools/image/remove-background \
-F "file=@photo.jpg" \
-F 'settings={"backgroundType":"transparent","edgeRefine":2,"outputFormat":"png"}'
```
@@ -80,7 +80,7 @@ data: {"phase":"processing","stage":"Removing background...","percent":50}
## Effects Endpoint (Phase 2)
`POST /api/v1/tools/remove-background/effects`
`POST /api/v1/tools/image/remove-background/effects`
Re-applies background effects without re-running the AI model. Uses cached mask and original from Phase 1.
@@ -111,7 +111,7 @@ Re-applies background effects without re-running the AI model. Uses cached mask
### Example Request
```bash
curl -X POST http://localhost:1349/api/v1/tools/remove-background/effects \
curl -X POST http://localhost:1349/api/v1/tools/image/remove-background/effects \
-F 'settings={"jobId":"a1b2c3d4-...","filename":"photo.jpg","backgroundType":"color","backgroundColor":"#FF5500","outputFormat":"png"}'
```