Aletura ยท API
Analyze contracts via the API
The same analysis as the web app, over HTTP: POST a file, get structured JSON back. The same quotas and file limits as the web interface apply.
Quick start
Four steps with curl. Every mutating call sends the session cookie plus the CSRF header.
Get the session and CSRF cookie
ShellSession + CSRFcurl -c cookies.txt https://aletura.eu/api/auth/session TOKEN=$(grep XSRF-TOKEN cookies.txt | awk '{print $NF}')Optional Sign in for the Individual quota
ShellAccount sessioncurl -b cookies.txt -c cookies.txt -H "X-XSRF-TOKEN: $TOKEN" \ -d "username=you@example.eu&password=your-password" \ https://aletura.eu/api/auth/loginAnalyze a contract
ShellMultipart uploadcurl -b cookies.txt -H "X-XSRF-TOKEN: $TOKEN" \ -F "file=@contract.pdf" \ https://aletura.eu/api/reviewsThe response is the structured result JSON. If the deployment asks for context confirmation, this call returns 400 โ then use
POST /api/reviews/prepareandPOST /api/reviews/preparations/{preparationId}/complete.Poll or cancel a running operation
ShellProgress lifecyclecurl -b cookies.txt -H "X-XSRF-TOKEN: $TOKEN" \ https://aletura.eu/api/progress/{operationId} # 200 with progress, 204 when done/unknown curl -b cookies.txt -H "X-XSRF-TOKEN: $TOKEN" -X DELETE \ https://aletura.eu/api/progress/{operationId} # cancel; the quota is refunded
Limits โ identical to the web app
- Guests: 1 successful operation per UTC day per anonymous device token (first request per hashed IP); a hashed-IP abuse guard per shared network still applies. Individual accounts: 3 per day. Each completed result allows 5 follow-up questions.
- Failed, cancelled or unusable operations are refunded automatically.
- One file: max 20 MB, up to 80 pages and at most 3 OCR pages in the active deployment (technical ceiling: 300 pages). Formats: PDF, DOCX, TXT. The uploader shows the live admission limits.
- Comparisons take 2โ3 files and count as one operation (
POST /api/comparisons/prepare); technical ceilings: 40 MB and 600 pages in total. - Quick clause check is bounded to the supplied text (max 20,000 characters) or one file up to 5 MB / 5 pages.
- Rate limits return HTTP 429 with a JSON error body.
OpenAPI / Swagger specification
The full machine-readable contract, including auth, parameters and error shapes:
Download openapi.json (Swagger)
Import it into Swagger UI, Postman or any OpenAPI client generator. The API version is 1.0.0; breaking changes would ship as a new version.
Privacy and persistence
Detected personal identifiers are masked locally before any model call; the model receives placeholders only. Uploads, extracted text and mappings are not persisted unless you explicitly save a result from a signed-in account. Analysis runs against the configured Mistral EU regional inference endpoint.

