List Backtest Jobs
List recent backtest jobs for the authenticated user, sorted by submitted_at descending.
Endpoint
GET /v1/backtest/jobs
Weight: 5
Authentication: Required (signed)
Query parameters
| Name | Type | Mandatory | Description |
|---|---|---|---|
status | enum | No | Filter to a single status: queued, running, done, failed, or cancelled. |
template_id | string | No | Restrict to jobs that ran a specific template. |
from | string (ISO 8601 UTC) | No | Lower bound on submitted_at (inclusive). |
to | string (ISO 8601 UTC) | No | Upper bound on submitted_at (exclusive). |
limit | integer | No | Page size, 1–100. Default 20. |
cursor | string | No | Opaque cursor returned by a previous call as next_cursor. |
Response
{
"data": [
{
"id": "bt_3c91ef",
"status": "done",
"config": {
"template_id": "tpl_grid",
"params": {
"grid_levels": 8,
"upper_price": "72000",
"lower_price": "60000"
},
"symbols": ["BTCUSDT"],
"timeframe": "1h",
"start": "2025-01-01T00:00:00Z",
"end": "2025-12-31T23:59:59Z",
"capital": "10000.00",
"leverage": 1,
"fee_model": "fixed_bps",
"fee_bps": "5"
},
"submitted_at": "2026-04-29T10:15:00Z",
"started_at": "2026-04-29T10:15:08Z",
"finished_at": "2026-04-29T10:17:42Z",
"progress": 1.0,
"result": {
"metrics": {
"sharpe": "1.84",
"sortino": "2.31",
"calmar": "1.12",
"max_drawdown": "-0.142",
"win_rate": "0.638",
"profit_factor": "1.92",
"cagr": "0.187",
"expected_value": "12.43",
"total_trades": 247,
"avg_trade_duration_seconds": 14820
}
},
"error": null
},
{
"id": "bt_88a210",
"status": "running",
"config": {
"template_id": "tpl_breakout",
"params": { "lookback": 24 },
"symbols": ["ETHUSDT"],
"timeframe": "15m",
"start": "2025-06-01T00:00:00Z",
"end": "2025-09-30T23:59:59Z",
"capital": "5000.00",
"leverage": 2,
"fee_model": "tiered_maker_taker"
},
"submitted_at": "2026-04-29T10:18:11Z",
"started_at": "2026-04-29T10:18:12Z",
"finished_at": null,
"progress": 0.62,
"result": null,
"error": null
}
],
"next_cursor": "eyJzdWJtaXR0ZWRfYXQiOiIyMDI2LTA0LTI4VDExOjAwOjAwWiJ9"
}
Response fields
| Field | Type | Description |
|---|---|---|
data | array<object> | Job summaries, newest first. |
data[].id | string | Job identifier. |
data[].status | enum | Current status. |
data[].config | object | The resolved job configuration (same shape as in Create Job). |
data[].submitted_at | string (ISO 8601) | When the job was accepted. |
data[].started_at | string (ISO 8601) | null | When the worker began processing. |
data[].finished_at | string (ISO 8601) | null | When the job reached a terminal state. |
data[].progress | number | Fractional progress in [0, 1]. |
data[].result | object | null | Job summary form: contains metrics only when status is done. The full equity_curve and trades arrays are omitted to keep responses small — call Get Result for those. |
data[].error | object | null | { "code", "message" } when status is failed. |
next_cursor | string | null | Pass back as cursor to fetch the next page. null when no more results. |
Errors
| HTTP | Code | Cause |
|---|---|---|
| 400 | INVALID_PARAMETER | Unknown status, malformed from/to, limit out of range, or invalid cursor. |
See Errors for shared error semantics.
Example
List the 10 most recent successful BTC grid backtests:
curl -X GET "https://api.pipai.example/v1/backtest/jobs?status=done&template_id=tpl_grid&limit=10" \
-H "X-PipAI-API-Key: $API_KEY" \
-H "X-PipAI-Timestamp: $TS" \
-H "X-PipAI-Signature: $SIG"
Walk pages with the cursor:
curl -X GET "https://api.pipai.example/v1/backtest/jobs?limit=50&cursor=$CURSOR" \
-H "X-PipAI-API-Key: $API_KEY" \
-H "X-PipAI-Timestamp: $TS" \
-H "X-PipAI-Signature: $SIG"