Skip to main content

Reset trading data (Tier 1)

POST 

/api/v1/user/reset-trading-data

Delete trading-related data for the caller's accounts of the chosen type, and fence those accounts against re-ingesting the deleted history on the next broker sync. This operation is irreversible.

Deletes: trades, executions, orders, positions, signals, balance snapshots, pending imports, ignored discrepancies, balance discrepancies, and broker activity history (AccountActivity), scoped to the accounts of the chosen type.

Preserves: user profile, subscription, broker connections, accounts, API keys, devices, strategies.

In the same transaction as the delete, every affected account's UTM start date is advanced to GREATEST(existing, now), so the next broker sync will not re-import what was just deleted as orphaned data. An account already fenced to a later date is left unchanged.

A preview must be taken first: this endpoint recomputes the delete-set row count server-side and requires confirmedRowCount to match exactly. A stale preview (the count has changed since it was taken) is rejected with 409 and nothing is written. When resetting a single type (paper or live), a cross-type reference from the other type onto the data about to be deleted also aborts with 409 before any write.

Request​

Responses​

Trading data reset successfully