# The document layer between your ERP and your tools

Source: https://arhivix.com/developers

Last reviewed: November 15, 2026. Facts checked against the app release of that day.

Arhivix is a document management system with REST API v1, signed webhooks and an MCP server, made by NOTIX DOO in Belgrade. It receives documents, reads them with OCR and AI, has a person confirm the values you mark for review, and passes the data to your ERP and tools.

It is hosted on AWS in the EU (Frankfurt and Dublin). A new business process is set up in the app as document types, flows and registers, so the code you write stays small: one receiver next to your ERP.

## Where Arhivix sits when documents carry the data

Supplier invoices, delivery notes, purchase orders, certificates and contracts arrive as PDFs and scans, while the ERP expects clean records. Arhivix takes the document side of that bridge, in six steps.

1. **Documents arrive.** By upload, from company email inboxes over Gmail, Microsoft 365 or IMAP, from a desktop scanner, from the phone camera, or from your own program through the API. Arhivix also takes documents from OneDrive, SharePoint, Google Drive, an Amazon S3 bucket or an Azure Blob container.
2. **Arhivix reads them.** OCR turns scans into text. A language model recognizes the document type and proposes the fields: supplier, buyer, tax IDs, amounts, VAT, dates and numbers on an invoice, or parties, dates, notice period, value and payment terms in a contract.
3. **A person confirms.** A read value is a proposal until its review rule is met. For each field of a document type you choose the rule: Automatic, Needs review or Must be confirmed. Reviewers compare the values with the original and confirm them field by field.
4. **The case moves.** A flow checks conditions, sends the document for approval to a person or a role, files it, adds it to a business dossier and tracks its deadline.
5. **Your code gets the message.** A flow step posts a signed message to your receiver, and the receiver reads the record through the REST API. Uploads, new documents, invoices and email also arrive as signed webhook events and in the change feed.
6. **The ERP stays the system of record.** Your receiver writes into the ERP through the import the ERP supports. When a flow needs proof that the ERP took the record, it requests an external confirmation and waits for your signed callback.

**The bridge in one picture**

1. **Your ERP**
   - Legacy ERP, accounting or line-of-business system
   - Stays the system of record
   - → Your receiver: The import your ERP supports
2. **Your receiver**
   - Verifies the signature
   - Reads the record through the API
   - Writes through the import your ERP supports
   - → Arhivix: Signed webhooks and REST API
3. **Arhivix**
   - Intake
   - OCR and AI reading
   - Confirmation by a person
   - Flows and approvals
   - Business dossiers
   - Storage, versions and audit log
   - → Tools and assistants: Webhooks, REST API and MCP
4. **Tools and assistants**
   - Microsoft Teams notifications
   - Zapier, Make, n8n and Power Automate through their webhook and HTTP steps
   - Claude, Claude Code and Codex over MCP

## Connecting a legacy ERP that has no API

The ERP stays as it is. Documents keep arriving the way they do today, and the ERP side of the bridge is your receiver and the import your ERP already supports.

- Email and scans: suppliers keep sending PDFs, and Arhivix reads them from the inbox, the scanner or the phone.
- A small receiver, your own middleware next to the ERP: it accepts signed webhooks or polls `GET /events`, reads the record through the API and writes it with the import the ERP itself provides, such as a file drop, a staging table or the SDK of its vendor.
- SAP Business One: you connect it in Settings through the SAP Service Layer, and every 15 minutes Arhivix reads business partners, items, warehouses, purchase orders, goods receipts and invoices from it.
- Tools with a webhook trigger and an HTTP step, such as Zapier, Make, n8n and Power Automate: they receive the event and read the record through the API.
- Microsoft Teams: a channel gets a message when an invoice is created, approved or rejected, when an invoice approval is requested or completed and when an exception is created.
- The other direction: a flow sends a signed message to your system and can wait for its signed confirmation before it goes on.
- E-invoices over Peppol: through your company's account with Storecove, a Peppol access point, Arhivix sends the invoices you issue (BIS Billing 3.0) and receives supplier invoices.

The ERP remains the system of record. Arhivix reads, checks and routes the documents, and your code passes the results on.

## What you get instead of building a document pipeline

Calling a language model on a PDF is the small part. A bridge to an ERP also needs intake, confirmation by a person (human in the loop), approvals, a place for the original and an audit trail of every decision. Those parts work in Arhivix today.

**Parts of the bridge and where they live in Arhivix**

| Part of the bridge | What Arhivix does | Where your code meets it |
| --- | --- | --- |
| Intake | Upload, company email inboxes, scanner, phone camera and connected sources such as OneDrive, SharePoint, Google Drive, Amazon S3 and Azure Blob. | `POST /nodes/{id}/upload`: multipart, up to 200 MiB. |
| Reading | OCR, proposed fields and 22 recognized document types. | `GET /nodes/{id}/metadata` returns `ocr_status`, the classification with `doc_type`, a summary and tags, and the extracted invoice details. |
| Confirmation | Smart Inbox shows a suggested path and the AI confidence, and a person approves or rejects. Read values are confirmed field by field under the review rule you set. | Register values carry a status such as `confirmed` or `proposed`, and the flow condition “Is confirmed” guards the steps on its yes branch. |
| Approvals | Chains of up to five people or roles, in order, with a deadline and escalation to a role. The person who started the processing and earlier approvers are left out of the later stages. | Inside Arhivix, in the Business approvals queue. The flow goes on by itself after the decision. |
| Business case | Business dossiers with a checklist of required documents, tracked subjects, expected documents and registers. | `POST /document-pipelines/registers/{id}/query` returns the rows of a register. The documents of tracked subjects are readable through the API as well. |
| Storage and audit trail | Versions, permissions per workspace and folder, and an audit log that records API actions with the key that made them. | `GET /nodes/{id}/versions` and `GET /nodes/{id}/download`. |

> Your own document types can use 22 value types, among them Table, List, Linked record and Calculated value.

## How a business case is modeled in Arhivix

Every business process is made of the same parts: a subject with data, evidence, rules, a state and allowed actions. In Arhivix that is a business dossier, a case management model whose parts carry very different processes.

**One model, two processes**

| Part of the case | In Arhivix | Supplier qualification | Project handover |
| --- | --- | --- | --- |
| Subject | A dossier with a kind, a business key, a period, an owner and a due date. | One supplier. | One project. |
| Evidence | Documents accepted against a checklist. Each is recorded with its content hash and its validity date. | Company registration, the required certificate and insurance. | As-built documentation, operating manuals, warranties and certificates, inspection and test records. |
| Links | Linked record fields, registers and tracked subjects: a partner, a piece of equipment, a property or a kind you define. | The partner and its certificates. | The property and its equipment. |
| Rules | Required items with a minimum count and an expiry check, a review rule per field, and flow conditions with 18 operators. | The certificate and the insurance must be valid. | Every group needs at least one document. |
| State | Collecting, Awaiting review, Ready for final package, Archived. | The same four states. | The same four states. |
| Actions | Request missing documents through a secure upload link, accept or reject each document, confirm the collection, send for approval, notify, send data to another system. | Ask the supplier for a renewed certificate. | Ask the contractor for the missing manuals. |
| Outcome | A confirmed collection, a decision history with the action, the reason and the person, and a final ZIP package. | A qualified supplier, with proof. | A handover package. |

> Both examples are ready templates in the app, next to Monthly client documents (sales invoices, purchase invoices and bank statements).

## Why the next process is configuration, not a new project

Between the first process and the second, the engine stays the same. What changes are definitions: document types, flows and registers, and the dossier template the process follows. Your team sets them in the app, under Document processing, and your receiver keeps working.

1. **Choose the job.** The setup wizard asks what Arhivix should do: incoming invoices from email, contracts and deadlines, service records or your own document. Nothing is turned on until you confirm.
2. **Show an example.** Describe the document type or drop sample documents, and the type assistant proposes its fields. You review the proposal before anything is saved.
3. **Test, then publish.** A type is tested on a document with known values, and only the tested version is published. Every version stays in the history.
4. **Draw the flow.** The flow builder has 24 step types: approval, conditions, routing by several rules, filing, labels, dossiers, notifications, deadlines and reminders, register lookups, parallel paths, sub-flows, sending data to another system and requesting an external confirmation.
5. **Reuse the setup.** Business templates save the type, register, view and widget definitions as a JSON file that you import wherever you need the same setup. Imported types stay drafts until they are checked on a sample.

### What Arhivix remembers

- Where a supplier's documents go: after a person has filed documents with the same supplier tax ID into the same archive group three times, new documents from that supplier are filed there automatically.
- How a document type is read: “Remember for this document type” saves where a field is found or what it means into a new version of the type, used once that version is tested and published.
- The words your documents use: a note per field on where to find it and what it means, and remembered phrases for choice options.
- The rules your people set: filing rules by vendor, document type or category, email rules and flows.
- Every decision: corrections and decisions stay in the history, with the person and the reason.

This memory belongs to your company and is kept as rules, mappings and type versions. Customer data is not used to train AI models, and the DPA states it.

## REST API v1: authentication, limits, uploads and errors

- **Base path:** `/v1/api/v1`, where both `v1` parts belong to the path. One API for every region: the company comes from the key.
- **Authentication:** `Authorization: Bearer <key>` or `X-API-Key: <key>`. Keys start with `ak_live_`.
- **Keys:** An Administrator or the built-in Developer role creates them in Settings, Developer API. A key has a name, permissions per area, a rate limit, an optional expiry date and an optional IP allowlist, and it is shown once.
- **Access model:** A key is its own service identity. Permissions limit the operations, company roles decide which resources the key reaches, and a new key starts with zero resource access until a person reviews it.
- **Rate limit:** Per key, from 10 to 10,000 requests per minute, 1,000 by default. Responses carry `X-RateLimit-Limit`, `X-RateLimit-Remaining` and `X-RateLimit-Reset`.
- **Writes:** Every write carries an `Idempotency-Key` header. A completed result replays for seven days, so a retry is safe.
- **Uploads:** `multipart/form-data`, up to 200 MiB, with the `X-Arhivix-Request-SHA256` header: the SHA-256 of the exact request body. An upload queues OCR by itself.
- **Results:** `GET /nodes/{id}/metadata` returns `ocr_status`, the classification with `doc_type`, category, a summary and tags, and the extracted invoice details. `GET /nodes/{id}/text` returns the OCR text page by page.
- **Registers:** `POST /document-pipelines/registers/{id}/query` returns the values read for your own document types. Each value carries a status, such as `confirmed` or `proposed`, and a filter can ask for one status.
- **Lists:** Keyset pagination: `limit` from 1 to 100 and the cursor from `meta.pagination.next_cursor`.
- **Change feed:** `GET /events` returns events oldest first, from the same log that feeds the webhooks.
- **Search:** `GET /search`, with filters by document type, category and workspace.
- **Errors:** One shape for every error: `error`, `message` and `meta.request_id`. Send `X-Request-ID` to match your logs with ours.
- **Reference:** An OpenAPI 3.1 description, JSON Schemas for the webhook events and client examples in Go and JavaScript. We send them on request.

Upload a scan and read what Arhivix proposed. `BASE_URL` ends with `/v1/api/v1`.

```bash
# Upload a document into a folder. The digest covers the exact multipart body.
boundary="bridge-example-boundary"
body="$(mktemp)"
{
  printf -- '--%s\r\nContent-Disposition: form-data; name="file"; filename="invoice.pdf"\r\nContent-Type: application/octet-stream\r\n\r\n' "$boundary"
  cat invoice.pdf
  printf '\r\n--%s--\r\n' "$boundary"
} > "$body"

curl --fail-with-body -sS \
  -H "Authorization: Bearer $API_KEY" \
  -H "Idempotency-Key: invoice-4471-upload" \
  -H "X-Arhivix-Request-SHA256: $(sha256sum "$body" | awk '{print $1}')" \
  -H "Content-Type: multipart/form-data; boundary=$boundary" \
  --data-binary "@$body" \
  "$BASE_URL/nodes/$FOLDER_ID/upload"

# OCR and reading start by themselves. Read the result with the id from the response:
curl --fail-with-body -sS \
  -H "Authorization: Bearer $API_KEY" \
  "$BASE_URL/nodes/$NODE_ID/metadata"
```

## Signed webhooks

You add a webhook address in the app, under Settings, Developer API, Webhooks: a public HTTPS address, with all events or the ones you select. The signing secret is shown once. To notify your system only about confirmed data, put the step “Send data to another system” after the condition “Is confirmed” in a flow.

- **Events:** `document.created`, `file.uploaded`, `email.received`, `invoice.created`, `invoice.updated`, `invoice.deleted`, `invoice.approved`, `invoice.rejected`, `invoice.storno`, `approval.requested`, `approval.completed`, `exception.created`, `exception.resolved`, `despatch_advice.created`, `despatch_advice.received`.
- **From a flow:** The step “Send data to another system” posts a signed message with the document link to the destination you configured. “Request external confirmation” waits for a signed callback from your system.
- **Payload:** Small on purpose: the event id, the event name, the time, the company and the id, type and name of the record. The receiver reads the record through the API.
- **Signature:** `X-Arhivix-Signature` holds `sha256=` and the HMAC-SHA256 of `X-Arhivix-Timestamp`, a dot and the raw request body, keyed with your secret. Refuse a timestamp that is more than 300 seconds off.
- **Delivery:** Any 2xx response acknowledges. A failed delivery is retried after 1 minute, 5 minutes, 30 minutes, 2 hours, 8 hours, 24 hours and 36 hours: eight attempts over about 70 hours.
- **Duplicates:** Delivery is at least once. Deduplicate on the event `id` or on `X-Arhivix-Delivery`.
- **Delivery log:** Each delivery shows its attempts, the HTTP code, the payload and the last response of your endpoint, with Retry and Resend. You can send a test event with one click.

The body of a `file.uploaded` event.

```json
{
  "id": "evt_653a9632df26297d6d685aebb8e553fc779785cb260ed6002c4bd0d2d2e1556d",
  "event": "file.uploaded",
  "schema_version": 1,
  "schema": "https://arhivix.com/schemas/webhooks/v1/file.uploaded.schema.json",
  "occurred_at": "2026-08-10T09:00:00Z",
  "timestamp": "2026-08-10T09:00:00Z",
  "company_id": "company_example",
  "data": {
    "id": "node_example",
    "event_id": "workflow_occurrence_example",
    "target_type": "node",
    "name": "receipt.pdf",
    "triggered_by": "user_example"
  }
}
```

Signature check in Node.js. Verify the raw bytes first, parse the JSON after.

```javascript
import { createHmac, timingSafeEqual } from 'node:crypto';

// rawBody:   the request body as a Buffer, captured before JSON parsing
// timestamp: header X-Arhivix-Timestamp
// signature: header X-Arhivix-Signature
export function verifyWebhook({ rawBody, timestamp, signature, secret }) {
  const now = Math.floor(Date.now() / 1000);
  const match = /^sha256=([a-f0-9]{64})$/.exec(signature ?? '');
  if (!/^[0-9]+$/.test(timestamp ?? '') || Math.abs(now - Number(timestamp)) > 300 || !match) {
    return false;
  }
  const expected = createHmac('sha256', secret)
    .update(timestamp, 'utf8')
    .update('.', 'utf8')
    .update(rawBody)
    .digest();
  const supplied = Buffer.from(match[1], 'hex');
  return supplied.length === expected.length && timingSafeEqual(supplied, expected);
}
```

## MCP: assistants and agents on your company documents

Arhivix runs a hosted MCP server at `https://mcp.arhivix.com/mcp`. You add the address to your client, sign in to Arhivix in the browser and approve access for one company. There is no API key to copy.

- **Clients:** Claude as a custom connector, Claude Code and Codex, with ready commands in the app.
- **Sign-in:** OAuth with PKCE and dynamic client registration.
- **Who approves:** An Administrator or a person with the Developer role, for one company.
- **Reading:** Search and read are always included: documents, metadata, invoices, items, partners, automations and users that the role of the approver allows.
- **Changes:** “Allow changes” is optional and covers drives, folders, uploads, items, partners, automations and drafts. Issuing and sending stay with people.
- **Control:** The connection gets its own key, with limited access, its own request limit and an expiry date. It is listed under Settings, Developer API, API keys, where you can revoke it at once.

The same address works in every client.

```bash
# Claude Code
claude mcp add --transport http --scope user arhivix "https://mcp.arhivix.com/mcp"

# Codex
codex mcp add arhivix --url "https://mcp.arhivix.com/mcp"
codex mcp login arhivix
```

## Hosting, storage and use of your data

- **Hosting:** AWS in the EU (Frankfurt and Dublin).
- **Encryption:** AES-256 at rest and TLS in transit.
- **AI and your data:** Customer data is not used to train AI models. The DPA states it.
- **Your bucket as a source:** Arhivix reads new documents from your Amazon S3 bucket, through a read-only role in your AWS account, or from your Azure Blob container.
- **Your own storage:** Enterprise supports bring your own storage: the bucket stays in your account, under your keys and your jurisdiction, while Arhivix keeps processing, indexing and serving the documents through the same API.
- **Isolation:** The company comes from the key, so a key reaches the data of one company.
- **Audit trail:** API actions are written to the audit log with the service identity and the key, and the log can be exported.

The full picture is on the [Security](https://arhivix.com/security) page.

## Questions developers ask

### Can I send PDFs to a language model myself instead of using a document layer?

You can, and the model call is the small part. Before a value may reach an ERP, somebody has to receive the document, confirm what was read, approve it, keep the original with its versions and record who decided what. Arhivix does those parts, so your code is left with the ERP side.

### How do I keep an unconfirmed value out of the ERP?

Set the review rule of the field to Must be confirmed, and put the condition “Is confirmed” before the step that sends data to another system, so only the confirmed branch notifies your receiver. The receiver then reads the values from a register, where each value carries its status, such as `confirmed`.

### Which documents does Arhivix read?

It recognizes 22 document types, among them invoices, contracts, delivery notes, credit notes, bank statements, certificates, warranties and offers. For any other document, such as a purchase order or a service record, you define your own type and choose its fields.

### Does Arhivix learn from corrections, and is a model trained on my documents?

It remembers what your people confirm: where the documents of a supplier go, where a field is found on a document type, which words mean which option. That memory is kept as the rules and type versions of your company. Customer data is not used to train AI models, and the DPA states it.

### What happens if my receiver is down?

Arhivix retries a failed delivery after 1 minute, 5 minutes, 30 minutes, 2 hours, 8 hours, 24 hours and 36 hours: eight attempts over about 70 hours. The delivery log keeps every attempt, with Retry and Resend, and the change feed `GET /events` lets your code catch up.

### How do I avoid processing the same event twice?

Delivery is at least once, so deduplicate on the event `id` or on `X-Arhivix-Delivery`. Writes to the API carry an `Idempotency-Key`, and a completed result replays for seven days.

### Can AI agents work with our documents?

Yes. The hosted MCP server at `https://mcp.arhivix.com/mcp` connects Claude, Claude Code and Codex after a sign-in in the browser. Reading follows the role of the person who approved the connection. Changes are optional and stop before issuing and sending, which stay with people.

### Where is the data stored?

On AWS in the EU (Frankfurt and Dublin), encrypted at rest with AES-256. Enterprise customers can keep the documents in their own S3-compatible bucket, under their own keys.

### How do I start?

Create an account on the free plan and add a few real documents to see how Arhivix reads them. REST API v1 and signed webhooks are included in every paid plan, and keys are created in Settings, Developer API. Ask us for the OpenAPI reference when you create your first key.
