> ## Documentation Index
> Fetch the complete documentation index at: https://veryfront.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Xentral

> Access Xentral ERP sales orders, products, and customers, and import new sales orders into your Xentral instance

## At a glance

* **Availability**: Experimental ([how to enable](/cloud/integrations)).
* **Auth**: API key.
* **Connection**: The key from `XENTRAL_API_TOKEN` is sent as the `Bearer` prefixed `Authorization` header.
* **Docs**: [https://developer.xentral.com/reference/authentication](https://developer.xentral.com/reference/authentication)

## Credentials

Set these per environment. See [Connect an integration](/cloud/integrations).

| Variable            | Required | Description                                                                                                                               |
| ------------------- | -------- | ----------------------------------------------------------------------------------------------------------------------------------------- |
| `XENTRAL_API_TOKEN` | Yes      | Xentral Personal Access Token (PAT), sent as Authorization: Bearer header [Docs](https://developer.xentral.com/reference/authentication). |

## Setup

1. **Get a Xentral instance**: Sign up for a Xentral trial at [https://xentral.com](https://xentral.com). Your instance gets its own host like mycompany.xentral.biz - all API calls go to that host.
2. **Create a Personal Access Token**: In your Xentral instance, create a Personal Access Token (PAT) via the API token settings (see [https://help.xentral.com/hc/en-us/articles/22627542067740](https://help.xentral.com/hc/en-us/articles/22627542067740)). Grant read scopes for sales orders, products, and customers, plus create scope for sales orders if you want to import orders.
3. **Store the token**: Add XENTRAL\_API\_TOKEN to your .env file. It is sent as an Authorization: Bearer header on every request.
4. **Verify access**: Run the List Sales Orders tool with your instance host (e.g. mycompany.xentral.biz) as instanceHost.

* Every tool takes an instanceHost parameter - your instance subdomain such as mycompany.xentral.biz (custom domains are also supported)
* PAT scopes are granted per resource group (CRM, products, accounting, ...) with separate read/create/update/delete permissions
* Sales orders use the v1 API; products and customers use the newer v2 API endpoints
* List responses wrap results in a data array with pagination info in extra

Provider API reference: [https://developer.xentral.com](https://developer.xentral.com)

## Tools

| Tool               | Access | Description                                                                                                        |
| ------------------ | ------ | ------------------------------------------------------------------------------------------------------------------ |
| List Sales Orders  | Read   | List sales orders in the Xentral instance with optional filtering and pagination                                   |
| Get Sales Order    | Read   | Get a single sales order with its positions and financial details                                                  |
| List Products      | Read   | List products in the Xentral instance (v2 API) with optional filtering and pagination                              |
| List Customers     | Read   | List customers in the Xentral instance (v2 API) with optional filtering and pagination                             |
| Create Sales Order | Write  | Import a new sales order into Xentral with customer, financials, delivery, and order positions                     |
| Get Product        | Read   | Get a single product with full details (v2 API) after finding it via List Products                                 |
| Get Customer       | Read   | Get a single customer record with full details including addresses (v2 API) - useful before creating a sales order |

## Example prompts

* List my Xentral sales orders with status created or released and summarize them by customer and value.
* Find a product in Xentral by name or number and show its details.
* Create a new sales order in Xentral for a customer and products I specify.
