revert_import
Revert a finished import by deleting the QuickBooks or Xero entries it created. Confirm before use, as this action is irreversible.
Instructions
Reverts a FINISHED or FINISHED_WITH_WARNINGS import — deletes the QuickBooks/Xero entries the import created, using their live SyncTokens. Status transitions FINISHED → REVERTING → REVERTED. Confirm with the user before calling — irreversible from their perspective.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| companyId | Yes | Company id from list_companies. | |
| importId | Yes | Import id from list_imports. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Import id. | |
| status | Yes | Lifecycle status (SCHEDULED, IN_PROGRESS, FINISHED, FINISHED_WITH_WARNINGS, FAILED, CANCELED, REVERTING, REVERTED). | |
| entityName | No | Entity type being imported. | |
| fileName | No | Uploaded file name. | |
| summary | No | Counts per result type. | |
| createdAt | No | ISO timestamp. | |
| finishedAt | No | ISO timestamp when reached terminal status, if applicable. |