REST API Documentation

Every FileForge utility is exposed as a clean multipart HTTP endpoint—no API keys required for moderate public usage.

Base URL https://gittop.top
Max Payload 25 MB
Content Type multipart/form-data

Response Headers

Binary processing endpoints stream the processed file directly in the response body alongside useful diagnostic headers:

  • X-Original-Size — Total input size in bytes
  • X-Processed-Size — Output file size in bytes
  • X-Saved-Percent — Percentage size reduction
  • X-Process-Ms — Server processing latency in milliseconds
  • X-Output-Filename — Suggested output filename

Quick curl Examples

1. Compress an Image

curl -sS -X POST https://gittop.top/api/image/compress \
  -F "files=@photo.jpg" \
  -F "quality=75" \
  -F "maxWidth=1920" \
  -o photo-compressed.jpg

2. Convert WebP to PNG

curl -sS -X POST https://gittop.top/api/image/convert \
  -F "files=@banner.webp" \
  -F "format=png" \
  -o banner.png

3. Merge Multiple PDFs

curl -sS -X POST https://gittop.top/api/pdf/merge \
  -F "files=@chapter1.pdf" \
  -F "files=@chapter2.pdf" \
  -o combined.pdf

4. Extract PDF Page Range

curl -sS -X POST https://gittop.top/api/pdf/split \
  -F "file=@report.pdf" \
  -F "mode=extract" \
  -F "pages=1-3, 7" \
  -o excerpt.pdf

5. Inspect PDF Metadata (JSON)

curl -sS -X POST https://gittop.top/api/pdf/inspect \
  -F "file=@document.pdf" | jq .

6. Live Telemetry & Health

curl -sS https://gittop.top/healthz
curl -sS https://gittop.top/api/stats