workflow
EXPERIMENTAL API: Simple API to invoke a Restate Workflow from the ingress.
Create a proxy client that allows calling workflow methods directly and synchronously, returning just the output (not wrapped in Response). This is the recommended approach for straightforward request-response interactions.
Client client = Client.connect("http://localhost:8080");
var workflowProxy = client.workflow(OrderWorkflow.class, "order-123");
OrderResult result = workflowProxy.start(new OrderRequest(...));
Content copied to clipboard
For advanced use cases requiring asynchronous request handling, access to Response metadata, or invocation options (such as idempotency keys), use workflowHandle instead.
Return
a proxy client to invoke the workflow
Parameters
clazz
the workflow class annotated with Workflow
key
the key identifying the specific workflow instance