Skip to main content

RPC

View as Markdown

This page lists the Rust SDK names for RPCs. The doc comment of each API gives its parameters, defaults, and errors. Read them in the Rust SDK API reference.

API names​

TaskRust APIDex behavior
Define an RPC handlerRpc, bound to a Flow method with RpcList::function, function_without_input, procedure, or procedure_without_input in Flow::rpcsFlow definition
Set the durable RPC nameThe name argument of Rpc::new. It has no default.Flow definition
Set the RPC timeouttimeout of RpcRPC timeout
Lock Attributes for the whole calllock of RpcLocks
Request transactional reads and writes without locksis_transactional of RpcTransactional RPCs
Load AttributeMap values and Channel messagesload_attribute_map, load_attribute_map_instance, load_channel, load_channel_map, and load_channel_map_instance of RpcSelective state loading
Return the output and start next StepsRpcResult, with RpcResult::thenRPCs
Cancel running StepsRpcResult::cancel_stepCancel running Steps
Let a person invoke the RPC from Dex WebNot available in the Rust SDK.Actions
Invoke the RPC from a ClientClient::invoke_rpc and Client::invoke_rpc_without_inputInvoke an RPC
Lock or load map instances chosen at call timeRpcInvokeOptions, with Client::invoke_rpc_with_optionsRuntime-selected map instances

Example​

Example: examples/rust/src/primitives/rpc/flow.rs