Eine Anfrage. Ein sauberes Dokument.
Senden Sie ein JPEG, PNG oder PDF an ScanKit und erhalten Sie einen perspektivisch korrigierten Scan für den nächsten Schritt in Ihrem Produkt. Entdecken Sie Anfrage, Antwort und Code unten.
POST /scan/cropTesten Sie ScanKit mit Ihrem Dokument.
Laden Sie ein JPEG, PNG oder PDF hoch, wählen Sie die gewünschte Ausgabe und sehen Sie direkt, welchen sauberen Scan ScanKit zurückgibt.
Input Image
Foto eines Dokuments auswählen oder aufnehmen
Result
Fertige Code-Snippets
Integrieren Sie Scan-Funktionen mit einem einfachen API-Aufruf in Ihre Anwendung. Die ScanKit-API unterstützt verschiedene Parameter für präzise Kontrolle über das Ergebnis.
curl -X POST https://api.scankit.io/scan/crop \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: multipart/form-data" \
-F "file=@/path/to/your/image.jpg" \
-F "output_width=1536" \
-F "filter=white" \
--output result.jpgcurl -X POST https://api.scankit.io/scan/crop \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: multipart/form-data" \
-F "file=@/path/to/your/image.jpg" \
-F "output_width=1536" \
-F "return_pdf=true" \
-F "ocr_lang=eng" \
--output result.pdfcurl -X POST https://api.scankit.io/scan/crop \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: multipart/form-data" \
-F "files=@/path/to/page1.jpg" \
-F "files=@/path/to/page2.jpg" \
-F "output_width=1536" \
-F "filter=white" \
-F "return_pdf=true" \
-F "ocr_lang=fra" \
--output result.pdfAPI Reference
Document Scanning
Upload an image to be cropped and optionally filtered. The result is returned as a binary JPEG file.
Parameters
No parameters
Request body
file * string($binary) | The image file to process. |
output_width integer($int32) | Specifies the desired width (in pixels) of the output image after cropping.
|
filter string | Specifies the filter applied to the image after cropping:
|
segment_count integer($int32) | Specifies the number of segments used to process curved or folded images.
|
return_pdf boolean | Determines the output format of the processed document:
|
ocr_lang string | Language for OCR text recognition when return_pdf is true:
|
Responses
| Code | Description | Links |
| 200 | Successfully processed and cropped image returned as a binary file. Media typeControls Accept header. | No links |
| 400 | Invalid parameters or unprocessable input file (no credits charged) Media type Examples | No links |
| 402 | Error: Insufficient credits (no credits charged) Media type | No links |
| 403 | Error: Authentication failed (no credits charged) Media type | No links |
| 429 | Error: Rate limit exceeded (no credits charged) Media type | No links |
| 500 | Internal server error. Contact support if the issue persists. | No links |






