ChartnautDocs

Get a run's status, progress and summary

GET/runs/{run_id}
Base URL
https://api.chartnaut.com/v1
Auth
Bearer key
Operation ID
getRun

Path parameters#

run_idstringRequired
Example run_01J9ZK3Q8C4

Query parameters#

waitinteger

Block up to this many seconds for the run to finish.

Default 00 to 30

Responses#

200OKapplication/json

The run has finished (succeeded, failed or cancelled).

object · Run
idstring
kindstring · ScriptKind
One of indicator definition study
scriptstring

The resolved ref that ran (vwap-reclaim@3), or inline.

instrumentstring

The instrument's display symbol (short in /instruments).

Example NAS100
timeframestring · Timeframe
One of 1m 5m 15m 30m 1h 2h 4h 1d 1w 1mo
windowobject

The resolved window after clamping.

Show fields
fromstring (date-time)
tostring (date-time)
settingsobject
statusstring · RunStatus
One of queued running succeeded failed cancelled
progressobject
Show fields
pctnumber
0 to 100
phasestring
Example collecting
failureobjectNullable
Show fields
kindstring · FailureKind

Why a run failed. retryable on the run says whether trying again can help.

One of script plan_limit out_of_coverage data_not_ready timeout cancelled internal
messagestring
retryableboolean
diagnosticsarray of object · Diagnostic
Show item fields
severitystringRequired
One of error warning
codestring
Example link.unresolved_import
messagestringRequired
pathstring
lineinteger
settingstring

The setting a finding is about, if any.

summaryobjectNullable

Small, always inline once finished. indicator: {bars, outputs:{id:{last, min, max, count}}, warnings?, errors?} definition: {bars, events_total, events_kept?, by_event:{id:count}, warnings?, errors?} study: {events_processed} errors are runtime errors on some bars; the run still produced results.

consolearray of objectNullable

The first 50 console lines the script printed. null until the run has finished, or when it printed nothing.

Show item fields
levelstring
messagestring
timestring (date-time)
usageobject
Show fields
barsinteger

Bars evaluated, warmup and dependencies included.

compute_unitsnumber
app_urlstring (uri)Nullable

Study runs only; indicator and definition runs are not stored in the app.

results_expire_atstring (date-time)
created_atstring (date-time)
started_atstring (date-time)Nullable
finished_atstring (date-time)Nullable
202Acceptedapplication/json

The run is still queued or running (after wait, if given). Poll again.

object · Run
idstring
kindstring · ScriptKind
One of indicator definition study
scriptstring

The resolved ref that ran (vwap-reclaim@3), or inline.

instrumentstring

The instrument's display symbol (short in /instruments).

Example NAS100
timeframestring · Timeframe
One of 1m 5m 15m 30m 1h 2h 4h 1d 1w 1mo
windowobject

The resolved window after clamping.

Show fields
fromstring (date-time)
tostring (date-time)
settingsobject
statusstring · RunStatus
One of queued running succeeded failed cancelled
progressobject
Show fields
pctnumber
0 to 100
phasestring
Example collecting
failureobjectNullable
Show fields
kindstring · FailureKind

Why a run failed. retryable on the run says whether trying again can help.

One of script plan_limit out_of_coverage data_not_ready timeout cancelled internal
messagestring
retryableboolean
diagnosticsarray of object · Diagnostic
Show item fields
severitystringRequired
One of error warning
codestring
Example link.unresolved_import
messagestringRequired
pathstring
lineinteger
settingstring

The setting a finding is about, if any.

summaryobjectNullable

Small, always inline once finished. indicator: {bars, outputs:{id:{last, min, max, count}}, warnings?, errors?} definition: {bars, events_total, events_kept?, by_event:{id:count}, warnings?, errors?} study: {events_processed} errors are runtime errors on some bars; the run still produced results.

consolearray of objectNullable

The first 50 console lines the script printed. null until the run has finished, or when it printed nothing.

Show item fields
levelstring
messagestring
timestring (date-time)
usageobject
Show fields
barsinteger

Bars evaluated, warmup and dependencies included.

compute_unitsnumber
app_urlstring (uri)Nullable

Study runs only; indicator and definition runs are not stored in the app.

results_expire_atstring (date-time)
created_atstring (date-time)
started_atstring (date-time)Nullable
finished_atstring (date-time)Nullable
ErrorAny other statusapplication/json

Error.

object · Error
errorobjectRequired
Show fields
codestringRequired

Stable. Branch on this, never on message.

One of unauthorized forbidden_scope plan_limit not_found version_conflict script_invalid in_use out_of_coverage unknown_instrument ambiguous_instrument unsupported_timeframe run_not_finished rate_limited busy invalid_request forbidden conflict not_in_library confirmation_required not_shared not_installable not_implemented authorization_pending slow_down access_denied expired_token internal
messagestringRequired
detailsobject
docs_urlstring (uri)
request_idstring