OpenAPI 3.0.32026-08-1963193297.5 KB

a567add0c3f5

erp-imports

validateErpImport

Choose the use case to read this file with, and start the validate phase. Callable from PENDING, READY and FAILED — so a wrong choice is corrected by calling this again with a different use case, rather than re-uploading. Each call replaces any previous verdict. Any other status returns 409.

post/v2/erp/imports/{importId}:validate

Path parameters

importIdstring required

Request body

integration_idstring required
use_case_slugstring required

An inbound use case's slug, unique within its integration.

Response

Validation started

import_idstring required

imp_{ULID} — time-ordered, also used as the job's correlation_id.

org_idstring required
created_bystring
integration_idstring

The integration owning the chosen use case. Absent until the first :validate.

use_case_slugstring

The inbound use case whose mapping drives both phases. Absent until the first :validate, and MUTABLE — re-validating with a different use case replaces it.

format'csv' | 'xlsx' required
status'PENDING' | 'VALIDATING' | 'READY' | 'PROCESSING' | 'IMPORTED' | 'FAILED' | 'CANCELLING' | 'CANCELLED' required

PENDING → VALIDATING → READY → PROCESSING → IMPORTED, with FAILED reachable from any working status, and CANCELLING → CANCELLED reachable from VALIDATING or PROCESSING via :abort. Only IMPORTED and CANCELLED are terminal. READY and FAILED both accept a further :validate, which is how a wrong use case is corrected without re-uploading the file. IMPORTED means every row was handed to the platform, not that the platform finished — per-row outcomes live in monitoring, filtered by correlation_id. A file that fails validation is FAILED with error.code = VALIDATION_BLOCKED. READY is legitimately idle for as long as the user takes to confirm, so it carries no running work and never goes stale. CANCELLING is transient and cooperative: the abort has been recorded but the worker only notices at its next batch boundary. Rows already published stay published — a stop is not a rollback.

correlation_idstring

Scopes this run in monitoring. Always equal to import_id.

activity_idstring
created_atstring date-time required
updated_atstring date-time required