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

# Generic ERP Connector

> Set up a generic ERP import integration and mapping.

## Overview

Use this guide when your source is SAP, Oracle, Dynamics, Acumatica, or another ERP without a
prebuilt mapping page. Start with a minimal required-field mapping, then add optional enrichment.

## Minimal Required Mapping

| Import module   | Required payload keys                                                                 |
| --------------- | ------------------------------------------------------------------------------------- |
| Catalog         | `products[].externalId`                                                               |
| Inventory       | `levels[].skuId`, `levels[].locationId`                                               |
| Suppliers       | `suppliers[].externalId`                                                              |
| Purchase Orders | `purchaseOrders[].externalPoNumber`, `supplierId`, `destinationLocationId`, `lines[]` |
| Orders          | `orders[].externalOrderId`, `lines[]`                                                 |
| Demand History  | `records[].skuId`, `locationId`, `weekStarting`                                       |

## Implementation Pattern

1. Extract source records into a staging table.
2. Transform fields into Better Data JSON payload shape.
3. POST batch payloads to `/api/import/*`.
4. Poll `/api/import/status/[jobId]` and retry failed rows.

## Transformation Tips

* Build stable external IDs and keep them immutable.
* Normalize location codes before sending payloads.
* Convert dates to ISO format (`YYYY-MM-DD` or full timestamp).
* Preserve numeric types for quantities and costs.
