artifacts

Re-run the artifact's SQL under the caller's current org and business-unit scope

Runs synchronously and returns the artifact with its new status: fresh with a new snapshot, needs_reask when the saved SQL no longer runs, or failed for a transient error. The last result is kept in both failure cases. Returns 409 while a refresh of this artifact is already in flight.

post/v2/artifacts/{artifact_id}/refresh

Request

  • Base URL
    https://api.stuut.ai (the document declares no server; this is the origin it was published from)
  • Auth
    HTTP bearer

Path parameters

artifact_idstring uuid required

Response

Successful Response

idstring uuid required
titlestring required
kind'table' | 'chart' required

What an Ask Stuut artifact renders as.

status'resolving' | 'fresh' | 'refreshing' | 'failed' | 'needs_reask' required

Refresh state of an Ask Stuut artifact.

RESOLVING: just saved; a background job is looking up the SQL behind it, so whether this artifact can ever refresh is not known yet. FRESH: snapshot reflects the last successful run. REFRESHING: a rerun is in flight. FAILED: the last rerun errored for a transient reason; snapshot kept. NEEDS_REASK: no SQL could be found, or the saved SQL no longer runs (e.g. a model was renamed); the snapshot is kept and the user re-asks the question in a new chat. Refresh is offered only for FRESH, FAILED and REFRESHING.

questionstring required
totalRowsinteger nullable required
createdAtstring date-time required
updatedAtstring date-time required
lastRefreshedAtstring date-time nullable required
lastErrorstring nullable required
sourceChatIdstring uuid nullable required
sourceMessageIdstring uuid nullable required
sourcePartOrderinteger nullable required
snapshotobject required

Changes

No recorded changes to this operation across all 1 revision of this API.