Restate Typescript SDK
Preparing search index...
@restatedev/restate-sdk
createServiceHandler
Variable createServiceHandler
Const
createServiceHandler
:
<
O
,
I
=
void
>
(
opts
:
ServiceHandlerOpts
<
I
,
O
>
,
fn
:
(
ctx
:
Context
,
input
:
I
)
=>
Promise
<
O
>
,
)
=>
I
extends
void
?
(
ctx
:
Context
)
=>
Promise
:
(
ctx
:
Context
,
input
:
I
)
=>
Promise
<
O
>
= handlers.handler
Type Declaration
<
O
,
I
=
void
>
(
opts
:
ServiceHandlerOpts
<
I
,
O
>
,
fn
:
(
ctx
:
Context
,
input
:
I
)
=>
Promise
<
O
>
,
)
:
I
extends
void
?
(
ctx
:
Context
)
=>
Promise
:
(
ctx
:
Context
,
input
:
I
)
=>
Promise
<
O
>
Create a service handler.
Type Parameters
O
I
=
void
Parameters
opts
:
ServiceHandlerOpts
<
I
,
O
>
additional configuration
fn
:
(
ctx
:
Context
,
input
:
I
)
=>
Promise
<
O
>
the actual handler code to execute
Returns
I
extends
void
?
(
ctx
:
Context
)
=>
Promise
:
(
ctx
:
Context
,
input
:
I
)
=>
Promise
<
O
>
Settings
Member Visibility
Protected
Inherited
External
Theme
OS
Light
Dark
Restate Typescript SDK
Loading...
Create a service handler.