service

@ApiStatus.Experimental
inline fun <SVC : Any> ScopedClient.service(): SVC

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

Example usage:

// Route a call into a named scope
client.scope("tenant-123").service<MyService>().process(payload)

Return

a proxy client to invoke the service

Type Parameters

SVC

the service class annotated with @Service

See also


inline fun <SVC : Any> Client.service(): SVC

Create a proxy client for a Restate service.

Example usage:

val greeter = client.service<Greeter>()
val response = greeter.greet("Alice")

Return

a proxy client to invoke the service

Type Parameters

SVC

the service class annotated with @Service