Skip to content

magnusfroste/marker-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Marker API

Simple REST API for PDF to Markdown conversion using Marker.

Designed for Easypanel deployment.

Deployment (Easypanel)

  1. Create new App in Easypanel
  2. Connect to this GitHub repo
  3. Build method: Dockerfile
  4. Port: 8001
  5. Memory: 4-8GB recommended

Environment Variables

Variable Default Description
TORCH_DEVICE cpu Device for ML models (cpu or cuda)

API Endpoints

POST /convert

Convert PDF to Markdown.

Request:

  • Content-Type: multipart/form-data
  • Body: file (PDF file)

Response:

{
  "markdown": "# Document Title\n\nContent...",
  "filename": "document.pdf"
}

GET /health

Health check endpoint.

Response:

{"status": "ok"}

Usage with AutoVersio

Set in AutoVersio environment:

OCR_SERVICE_URL=http://marker-api:8001

Replace marker-api with the internal hostname from Easypanel.

About

Marker API is a simple yet efficient REST service for converting PDFs to Markdown format leveraging the capabilities of [Marker](https://github.com/VikParuchuri/marker). Specifically tailored for **Easypanel** deployment, it provides developers with robust tools to seamlessly integrate document conversion in their applications.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors