# API Endpoints - Document Classification

Welcome to the Extracta LABS **Document Classification API**. This section guides you through all available endpoints designed to help you classify uploaded documents into user-defined types and optionally extract structured data from them.

Whether you're automating invoice routing, separating receipts from contracts, or identifying CVs, this API gives you precise control over classification and downstream processing.

## What is Document Classification?

Document Classification is the process of automatically assigning a document to a predefined category — such as an Invoice, Receipt, or Purchase Order — based on its content.

You define the categories (called [Document Types](/document-classification-api/classification-details/document-types.md)), provide keywords, and optionally link them to extraction templates. Once classified, the document can automatically be parsed for structured data.

## 🔌 Available Endpoints

The Extracta LABS Classification API includes the following endpoints:

<table data-full-width="false"><thead><tr><th width="271">Endpoint</th><th width="128">Type</th><th>Page</th></tr></thead><tbody><tr><td><code>/createClassification</code></td><td><mark style="color:green;"><code>POST</code></mark></td><td><a data-mention href="/pages/MnkNsxZcjciNT5fYlGNi">/pages/MnkNsxZcjciNT5fYlGNi</a></td></tr><tr><td><code>/viewClassification</code></td><td><mark style="color:green;"><code>POST</code></mark></td><td><a data-mention href="/pages/Be6wluHqDorg6GoCfbTj">/pages/Be6wluHqDorg6GoCfbTj</a></td></tr><tr><td><code>/updateClassification</code></td><td><mark style="color:orange;"><code>PATCH</code></mark></td><td><a data-mention href="/pages/cAfD0cB3isMF3hw2QtFG">/pages/cAfD0cB3isMF3hw2QtFG</a></td></tr><tr><td><code>/deleteExtraction</code></td><td><mark style="color:red;"><code>DELETE</code></mark></td><td><a data-mention href="/pages/Y3K0Cvza86r3bOdI7I1V">/pages/Y3K0Cvza86r3bOdI7I1V</a></td></tr><tr><td><code>/deleteBatch</code></td><td><mark style="color:red;"><code>DELETE</code></mark></td><td><a data-mention href="/pages/serjMgy3W6uoxxDDxY0w">/pages/serjMgy3W6uoxxDDxY0w</a></td></tr><tr><td><code>/deleteFiles</code></td><td><mark style="color:red;"><code>DELETE</code></mark></td><td><a data-mention href="/pages/Hdcz2jJdYtPtLcyKnzhO">/pages/Hdcz2jJdYtPtLcyKnzhO</a></td></tr><tr><td><code>/uploadFiles</code></td><td><mark style="color:green;"><code>POST</code></mark></td><td><a data-mention href="/pages/zn54GLEg771P5xbceEE5">/pages/zn54GLEg771P5xbceEE5</a></td></tr><tr><td><code>/getResults</code></td><td><mark style="color:green;"><code>POST</code></mark></td><td><a data-mention href="/pages/nxZid73okKPSXLrz14f2">/pages/nxZid73okKPSXLrz14f2</a></td></tr></tbody></table>

Each page covers detailed request and response formats.

## 🧩 Document Types & Auto-Extraction

In classification, you define `documentTypes` with:

* A `name` and `description`
* A list of `uniqueWords` to guide classification
* (Optionally) an `extractionId` to enable automatic structured data extraction if a match is found

Learn how to define these properly in the [Document Types](/document-classification-api/classification-details/document-types.md) page.

## 📘 Navigating the Documentation

Each endpoint in this section includes:

* **Request Parameters:** Fields you can send in the API call
* **Response Objects:** What to expect back
* **Examples:** Realistic payloads to speed up integration

This structure ensures you can build confidently, whether you're uploading 10 documents or 10,000.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.extracta.ai/document-classification-api/api-endpoints-document-classification.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
