Call Imports
DELETE
/api/v1/call-import-schemas/{schema_id}

Delete a schema.

By default refuses with 409 when any CallImport row still references the schema (matches the ON DELETE RESTRICT FK behavior); the user must either delete the dependent batches first, migrate them to a different schema, or retry with ?force=true to detach them in one shot.

force=true is safe for completed batches: every batch keeps its own parameter_mapping snapshot, and downstream rendering (detail page, evaluation export) already handles a NULL schema_id gracefully. Batches still in the staged uploaded state will need a fresh schema before they can be imported - the existing import endpoint already enforces that.

Authorization

AuthorizationBearer <token>

JWT access token. Use: Authorization: Bearer .

In: header

Path Parameters

schema_id*Schema Id
Formatuuid

Query Parameters

force?Force

When true, detach this schema from any CallImport batches that reference it (sets call_imports.schema_id = NULL) before deleting the schema row. Use this to drop a schema whose batches you want to keep — already-imported batches keep working via their snapshotted parameter_mapping, while staged-but-not-yet-imported batches will need a new schema picked before they can be imported.

Defaultfalse

Header Parameters

Authorization?string|null
X-API-Key?string|null
X-EFFICIENTAI-API-KEY?string|null
X-Workspace-Id?string|null

Response Body

application/json

curl -X DELETE "https://example.com/api/v1/call-import-schemas/497f6eca-6276-4993-bfeb-53cbbbba6f08"
Empty

Community & contact

  1. Found a bug or have a feature request? Open a GitHub issue.
  2. Join our Discord for faster replies!