canonical: https://jentic.com/apis/aimlapi.com/aimlapi

# AIMLAPI

Jentic publishes the only available OpenAPI specification for AIMLAPI, keeping it validated and agent-ready. AIMLAPI exposes two purpose-built endpoints for document and image understanding: /ocr extracts text from a document image, and /vision analyses an image with vision features. Authentication uses an apiKey scheme (apiKeyAuth). The surface is intentionally narrow, suited to integrations that need OCR and vision analysis without adopting a full multi-modal LLM stack.

## For AI agents

Run OCR on documents and analyse images with vision features through two focused endpoints.

## Scope

Does not handle chat, embeddings, image generation, or audio - use for OCR and vision-feature image analysis only.

## Capabilities

- Extract text from a document image with POST /ocr
- Analyse an image with vision features through POST /vision
- Run OCR-and-vision pipelines without adopting a full LLM provider
- Pair structured OCR output with vision analysis on the same input image
- Authenticate every call via the apiKeyAuth scheme so the integration stays simple

## Use cases

### Invoice OCR Pipeline

Extract text from inbound invoice PDFs and images by sending them to /ocr. The response provides the extracted text, which can then be parsed into supplier, totals, and line items. The endpoint is purpose-built for OCR, so the integration code stays small and predictable.

Example prompt: POST each invoice image to /ocr and parse the returned text into a structured invoice record

### Image Understanding for Content Pipelines

Analyse images uploaded to a CMS or content moderation pipeline using /vision. The endpoint returns features about the image that downstream code can use for tagging, captioning, or moderation decisions. Combined with /ocr, the same vendor handles both textual and visual inputs.

Example prompt: POST a CMS upload to /vision and store the returned features alongside the asset for later search and moderation

### OCR Plus Vision for Mixed Inputs

Some inputs need both OCR and vision analysis - for example a product photo with a serial number embedded. Run /ocr to extract the serial and /vision to describe the product, then merge the results into a single record.

Example prompt: POST the same image to /ocr and /vision in parallel, then merge serial number with vision features into one record

### Agent-Driven Document and Image Triage via Jentic

An agent receives an upload, decides whether it is a document or a photo, and calls /ocr or /vision accordingly. Through Jentic the agent searches for the right operation, the AIMLAPI key is supplied from the vault, and the agent never sees the raw key.

Example prompt: Use Jentic search 'extract text from a document image', execute /ocr, and route non-document images to /vision instead

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| POST | /ocr | Perform OCR on a document |
| POST | /vision | Analyse an image with vision features |

## Key resources

- **OCR** — Extract text from a document image via /ocr
- **Vision** — Analyse an image with vision features via /vision

## Why Jentic

- **Setup:** Wiring AIMLAPI by hand means handling its api-key header, sending images to the OCR or vision endpoint, and writing your own retry logic. Through Jentic you install once, import AIMLAPI from the API Directory, store the key once, and your agent calls it.
- **Permission scoping:** AIMLAPI takes its image input in the request body, so scope your agent by operation: limit it to the operations it needs, such as /ocr for text extraction or /vision for image analysis, and leave out the one it does not use.
- **Credential handling:** Your AIMLAPI key is stored once, encrypted, by your own Jentic One instance and injected at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'extract text from a document image', and Jentic returns the matching AIMLAPI operation with its image input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **AI/ML API** — Broader AIMLAPI surface covering chat, embeddings, image generation, and audio
- **Cloudmersive OCR API** — Dedicated OCR provider with broader format support
- **Clarifai API** — Vision platform with classification and custom model training

## FAQ

### Why is there no official OpenAPI spec for AIMLAPI?

AIMLAPI does not publish an OpenAPI specification. Jentic generates and maintains this spec so that AI agents and developers can call AIMLAPI via structured tooling. It is validated against the live API and kept up to date. Get started with Jentic One, the self-hosted execution layer.

### What authentication does the AIMLAPI use?

An apiKey scheme called apiKeyAuth, sent on each request. Through Jentic the key is held in the vault and never enters the agent's context.

### Can I run OCR on a document image?

Yes. POST the document image to /ocr and the API returns the extracted text. For richer parsing, run a structured-data extractor over the returned text on your side.

### What are the rate limits for the AIMLAPI?

The OpenAPI spec does not declare explicit rate limits. The endpoint surface is narrow, so the practical limit is the provider's per-key quota - respect HTTP 429 responses and back off accordingly.

### How do I run image vision analysis through Jentic?

Run pip install jentic, search 'analyse an image with vision features', execute /vision with the image, and consume the returned analysis. Run it through Jentic One, the self-hosted execution layer.

### How does this differ from the broader AI/ML API spec?

This spec exposes the focused /ocr and /vision endpoints. The companion AI/ML API spec covers chat completions, embeddings, image generation, and audio. Pick this one for OCR and vision only.

### Can I limit what my agent is allowed to do with the AIMLAPI?

Yes. Because Jentic One is self-hosted, you set the rules that decide which AIMLAPI operations and credentials your agent may use. Since AIMLAPI takes its image input in the request body, you scope the agent by operation: grant only POST /ocr for text extraction, or only POST /vision for image analysis, and leave out the endpoint it does not need. Your API key is injected at execution time and never enters the agent's prompt or context.
