Skip to main content

Upload a back-test CSV and enqueue the Monte-Carlo compute

POST 

/api/v1/performance/profiles/:objectType/:objectId/upload

Accepts a RealTest CSV as multipart/form-data in the file field, capped at 20MB and parsed in memory. A strategy has one slot (the trade list); an account has two and the caller must name which with kind: daily (the Date,Combined daily-returns file that drives the day-basis cone) or trades (the all-trades file that drives the trade-basis benchmark). There is no safe default for an account, so kind is required for one and ignored for a strategy (always trades). The parser follows the kind, not the object type. A malformed file is rejected 400 naming the offending row and column. On success the raw bytes are stored, an inputHash is computed over them, the profile plus the per-kind back-test input are upserted with status pending, and a Monte-Carlo job is enqueued. Re-uploading byte-identical content into the same slot when the profile is not in a failed state is a no-op (recomputed false, jobId null): the stored or in-flight compute already covers it.

Request​

Responses​

Profile upserted (or unchanged) with the enqueued job id.