Skip to Content
Fusee Docs
API reference

API at a glance

Generated from api/spec.json by api/gen.py; do not edit. Every operation has one name, one argument order and one option set, written in each language's case. api/check.py checks the SDKs against it.

Definitions

OperationArgumentsOptionsRustTypeScriptPythonGoJava
workflowname, fnversion, input, output, timeout, concurrencyWorkflowRef::newworkflowworkflowDefineworkflow
signalnameschemaSignal::newsignalsignalSignalsignal
querynameschemaQuery::newqueryqueryQueryquery
updatenameschemaUpdate::newupdateupdateUpdateupdate
objectname, handlersversionEngine::object_type(name).exclusive(..)objectobjectObjectobject
sharedhandlerObjectType::sharedsharedsharedSharedshared
  • workflow: A workflow type: a plain value, apart from any engine. Pass it to Engine.open({ workflows }), engine.start, ctx.child. The options form is workflow(name, options, fn).
  • signal: A signal's name and payload type. A plain string works wherever a definition does.
  • query: A query's name, argument and result types.
  • update: An update's name, argument and result types.
  • object: A keyed object type. Handlers are exclusive unless wrapped in shared().
  • shared: Marks an object handler as shared: it reads state and runs beside other shared calls.

Engine and Client (one interface)

OperationArgumentsOptionsRustTypeScriptPythonGoJava
startworkflow, id, inputidPolicy, timeout, version, delay, at, attributesstartstartstartStartstart
runidrunrunrunRunrun
signalWithStartworkflow, id, input, signal, valueidPolicy, timeout, versionsignal_with_startsignalWithStartsignal_with_startSignalWithStartsignalWithStart
updateWithStartworkflow, id, input, update, argidPolicy, timeout, version, updateIdupdate_with_startupdateWithStartupdate_with_startUpdateWithStartupdateWithStart
objecttype, keyobjectobjectobjectObjectobject
schedulename, spec, workflow, inputscheduleschedulescheduleScheduleschedule
schedulesEngine::list_schedulesschedulesschedulesSchedulesschedules
listtype, status, version, startedAfter, startedBefore, attributes, limit, pageSizeEngine::list_wherelistlistListlist
completetoken, valueEngine::completecompletecompleteCompletecomplete
failtoken, failurefailfailfailFailfail
debounceworkflow, key, inputwindow, maxWait, dedupWindow, eventIddebouncedebouncedebounceDebouncedebounce
batchworkflow, key, eventmaxEvents, maxWait, dedupWindow, eventIdbatchbatchbatchBatchbatch
closecloseclosecloseCloseclose
  • run: A handle; makes no call.
  • schedule: Creates or updates the schedule. spec: { cron, every, timezone, overlap, catchupWindow, jitter, paused }.
  • schedules: schedules.get(name), schedules.list().

Engine only

OperationArgumentsOptionsRustTypeScriptPythonGoJava
opendir, url, durability, workflows, objects, shards, workers, module, profile, serializer, codec, keepHistory, recordStacks, onExhausted, retention, telemetry, loggeropenopenopenOpenopen
limitname, speclimitlimitlimitLimitlimit
limitslimitslimitslimitsLimitslimits
serveport, host, token, uiConfig::http / http::serveserveserveServeserve
onevent, handlerlog::set_hookononOnon
metricsmetricsmetricsmetricsMetricsmetrics
  • open: No arguments: FUSEE_DIR, else FUSEE_URL (a client), else ./fusee-data.
  • limit: spec: { concurrent, perSecond }.
  • serve: Serves the HTTP API (and the UI) from its own thread.
  • on: Events: stuck, waitingForCode.

A run

OperationArgumentsOptionsRustTypeScriptPythonGoJava
signalsignal, valuesignalsignalsignalSignalsignal
queryquery, argqueryqueryqueryQueryquery
updateupdate, argidupdateupdateupdateUpdateupdate
resultresultresultresultResultresult
statusstatusstatusstatusStatusstatus
describedescribedescribedescribeDescribedescribe
cancelreasoncancelcancelcancelCancelcancel
terminatereasonterminateterminateterminateTerminateterminate
resetbeforeStepreapplySignals, versionresetresetresetResetreset
retryretryretryretryRetryretry
resumeresumeresumeresumeResumeresume
streamnamefrom, waitstreamstreamstreamStreamstream
  • describe: The summary and the journal as a typed union of records.
  • retry: Resets a failed run to before its failed step.
  • resume: Runs a paused step again with a fresh set of attempts.

An object's key

OperationArgumentsOptionsRustTypeScriptPythonGoJava
callhandler, argidcallcallcallCallcall
sendhandler, argidsendsendsendSendsend
statestatestatestateStatestate
describedescribedescribedescribeDescribedescribe
deletedeletedeletedeleteDeletedelete

A schedule

OperationArgumentsOptionsRustTypeScriptPythonGoJava
pausepausepausepausePausepause
resumeresumeresumeresumeResumeresume
triggertriggertriggertriggerTriggertrigger
backfillfrom, tobackfillbackfillbackfillBackfillbackfill
describedescribedescribedescribeDescribedescribe
deletedeletedeletedeleteDeletedelete

Workflow context

OperationArgumentsOptionsRustTypeScriptPythonGoJava
stepname, fnretry, timeout, heartbeatTimeout, readOnly, limit, priority, fairnessKey, fairnessWeight, output, threadstepstepstepStepstep
sleepname, durationsleepsleepsleepSleepsleep
sleepUntilname, atCtx::sleep_untilsleepUntilsleep_untilSleepUntilsleepUntil
waitForsignaltimeoutwait_forwaitForwait_forWaitForwaitFor
childworkflow, id, inputparentClose, timeoutchildchildchildChildchild
startChildworkflow, id, inputparentClose, timeoutstart_childstartChildstart_childStartChildstartChild
signalWorkflowid, signal, valuesignal_workflowsignalWorkflowsignal_workflowSignalWorkflowsignalWorkflow
cancelWorkflowidreasoncancel_workflowcancelWorkflowcancel_workflowCancelWorkflowcancelWorkflow
objecttype, keyCtx::objectobjectobjectObjectobject
onQueryquery, handleron_queryonQueryon_queryOnQueryonQuery
onUpdateupdate, handlervalidateon_updateonUpdateon_updateOnUpdateonUpdate
awaitCompletionname, sendretry, timeoutawait_completionawaitCompletionawait_completionAwaitCompletionawaitCompletion
compensatename, fnretry, timeoutcompensatecompensatecompensateCompensatecompensate
continueAsNewinputversioncontinue_as_newcontinueAsNewcontinue_as_newContinueAsNewcontinueAsNew
patchedidpatchedpatchedpatchedPatchedpatched
deprecatePatchiddeprecate_patchdeprecatePatchdeprecate_patchDeprecatePatchdeprecatePatch
setAttributesattributesset_attributessetAttributesset_attributesSetAttributessetAttributes
streamnamestreamstreamstreamStreamstream
nowCtx::now_msnownowNownow
randomrandomrandomrandomRandomrandom
uuiduuiduuiduuidUUIDuuid
alloperationsfutures::join! (Rust's own)allallAllall
raceoperationsfutures::select! (Rust's own)raceraceRacerace
  • step: fn may take the step context s.
  • awaitCompletion: send(cb) receives { token, url }.
  • compensate: Registers a step that runs, newest first, if the workflow fails or is cancelled.

Step context

OperationArgumentsOptionsRustTypeScriptPythonGoJava
heartbeatprogressctx.heartbeatheartbeatheartbeatHeartbeatheartbeat
progressctx.progressprogressprogressProgressprogress
streamnamectx.streamstreamstreamStreamstream

Errors

The same codes in every SDK; each has a page in errors.md.

On this page