Sign inSign up

digitalenvironments/hawki-toolkit-file-converter

By digitalenvironments

Updated about 1 month ago

Image
0

5.3K

digitalenvironments/hawki-toolkit-file-converter repository overview

PDF Text Extraction API

A lightweight, containerized API for extracting and cleaning text from PDF files using PyMuPDF and FastAPI.

Features

  • Extract clean text from PDF documents via HTTP endpoint
  • Simple REST API interface
  • Secured with API key authentication

Quick Start

docker run --rm -d -p 8001:80 -e F_API_KEY="Your-secret-api-key" digitalenvironments/hawki-toolkit-file-converter:latest

A word on updating

If you are trying to update to the "latest" version of the "latest" tag, ensure you pull first, before starting the container:

docker pull digitalenvironments/hawki-toolkit-file-converter:latest

Docker Compose Example

services:
  file-converter:
    image: digitalenvironments/hawki-toolkit-file-converter:latest
    ports:
      - "8001:8001"
    environment:
      - F_API_KEY=Your-secret-api-key
    restart: unless-stopped
    healthcheck:
      test: [ "CMD", "curl", "-f", "http://localhost:8001/health" ]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 40s

Usage Example

curl -X POST http://localhost:8001/extract \
-H "Authorization: Bearer Your-secret-api-key" \
-F "file=@/path/to/your/document.pdf"
--output [Filename].zip

Note: Always use double quotes around the file parameter.

Tag summary

Content type

Image

Digest

sha256:2c990c3bc

Size

607.2 MB

Last updated

about 1 month ago

docker pull digitalenvironments/hawki-toolkit-file-converter