workflow

@ApiStatus.Experimental
inline fun <SVC : Any> ScopedClient.workflow(key: String): SVC

PREVIEW: Create a proxy client for a Restate workflow within the given scope.

Return

a proxy client to invoke the workflow

Parameters

key

the key identifying the specific workflow instance

Type Parameters

SVC

the workflow class annotated with @Workflow

See also


inline fun <SVC : Any> Client.workflow(key: String): SVC

Create a proxy client for a Restate workflow.

Example usage:

val wf = client.workflow<MyWorkflow>("wf-123")
val result = wf.run("input")

Return

a proxy client to invoke the workflow

Parameters

key

the key identifying the specific workflow instance

Type Parameters

SVC

the workflow class annotated with @Workflow