---
title: "RPC"
description: "This page lists the Go SDK names for RPCs."
canonical_url: "https://docs.superdurable.io/reference/go/rpc/"
source: "docs/reference/go/rpc.mdx"
locale: "en"
---

# RPC

This page lists the Go SDK names for [RPCs](https://docs.superdurable.io/concepts/primitives/rpc.md).
The doc comment of each API gives its parameters, defaults, and errors. Read
them in the [Go SDK API reference](https://docs.superdurable.io/reference/go.md#api-reference).

<a id="api-names"></a>

## API names

| Task                                                 | Go API                                                                                                                                         | Dex behavior                                                                                                                   |
| ---------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------ |
| Define an RPC handler                                | **DefineRPC** with a bound Flow method, returned from **GetRPCs**                                                                              | [Flow definition](https://docs.superdurable.io/reference/go/flow.md#flow-definition)                                           |
| Set the durable RPC name                             | **Name** of **RPCOptions**. It defaults to the Go method name.                                                                                 | [Flow definition](https://docs.superdurable.io/reference/go/flow.md#flow-definition)                                           |
| Set the RPC timeout                                  | **Timeout** of **RPCOptions**                                                                                                                  | [RPC timeout](https://docs.superdurable.io/reference/server/runtime-data.md#rpc-timeout)                                       |
| Lock Attributes for the whole call                   | **LockAttributes** of **RPCOptions**                                                                                                           | [Locks](https://docs.superdurable.io/reference/server/runtime-data.md#attribute-locks)                                         |
| Request transactional reads and writes without locks | **IsTransactional** of **RPCOptions**                                                                                                          | [Transactional RPCs](https://docs.superdurable.io/reference/server/runtime-data.md#transactional-reads-and-writes)             |
| Load AttributeMap values and Channel messages        | **LoadAttributeMaps**, **LoadAttributeMapInstances**, **LoadChannels**, **LoadChannelMaps**, and **LoadChannelMapInstances** of **RPCOptions** | [Selective state loading](https://docs.superdurable.io/reference/server/runtime-data.md#load-collection-state)                 |
| Return the output and start next Steps               | **RPCResult**, with **Output** and **NextSteps**                                                                                               | [RPCs](https://docs.superdurable.io/reference/server/runtime-data.md#rpcs)                                                     |
| Cancel running Steps                                 | **RPCResult.CancelSteps**                                                                                                                      | [Cancel running Steps](https://docs.superdurable.io/reference/server/runtime-data.md#cancel-running-steps)                     |
| Let a person invoke the RPC from Dex Web             | **Action** of **RPCOptions**, with **DefineAction**                                                                                            | [Actions](https://docs.superdurable.io/reference/web/dex-web.md#actions)                                                       |
| Invoke the RPC from a Client                         | **Client.InvokeRPC**                                                                                                                           | [Invoke an RPC](https://docs.superdurable.io/reference/server/runtime-client.md#invoke-an-rpc)                                 |
| Lock or load map instances chosen at call time       | **RPCInvokeOptions**, with **Client.InvokeRPCWithOptions**                                                                                     | [Runtime-selected map instances](https://docs.superdurable.io/reference/server/runtime-data.md#runtime-selected-map-instances) |

<a id="example"></a>

## Example

Example: [examples/go/primitives/rpc/workflow.go](https://github.com/superdurable/dex/tree/main/examples/go/primitives/rpc/workflow.go)
