> **Can't find what you're looking for?** Use `search_docs` on the docs MCP server at `https://ensforge.com/api/mcp` to find what you need.

# getWorkflow

Read saved workflow progress and submission references.

## Import

```ts
import { getWorkflow } from "@ensforge/core";
```

## Usage

:::code-group
```ts [index.ts]
import { getWorkflow } from "@ensforge/core";
import { config } from "./config";

const result = await getWorkflow(config, {
  workflowId: "saved-workflow-id",
});
```

```ts [config.ts]
// [!include ~/snippets/hca/config.ts]
```
:::

## Parameters

### workflowId

`string`

Existing saved workflow instance ID.

### walletClient

`WalletClient | undefined`

Viem wallet override. Defaults to the configured wallet resolver.

### account

`` `0x${string}` | Account | undefined ``

Wallet account override for the operation.

## Return Type

```ts
type GetWorkflowResult = Awaited<ReturnType<typeof getWorkflow>>;
```

Returns `WorkflowSnapshot`.

## Effect

Use `.effect` when composing the action in an Effect program. The success and error channels remain
fully typed.

```ts
import { Effect } from "effect";

const program = getWorkflow.effect(config, {
  workflowId: "saved-workflow-id",
});

type Success = Effect.Success<typeof program>;
type Failure = Effect.Error<typeof program>;

const result = await Effect.runPromise(program);
```

## Error

The Promise API rejects with the same typed failures exposed by the Effect error channel. Errors
have a stable `_tag`, `code`, and `message`; boundary errors retain their original `cause`.

See [Error Handling](/core/guides/error-handling).

## Related

* [`getWorkflow`](/sdk/api/workflows/get-workflow)
* [Guide](/core/guides/workflow-storage)
