> For the complete documentation index, see [llms.txt](https://docs.stackai.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.stackai.com/technical-reference/interfaces-and-conversations/interface-errors-and-reconnection-behavior.md).

# Interface Errors and Reconnection Behavior

An interface error can come from input validation, access, a workflow failure, or a disconnected response. Identify the affected stage before asking the user to retry.

![Check the original execution before resubmitting](https://1957915746-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSQ1Sgy933krTyK0S4JpP%2Fuploads%2FByxXUSHgOAMPApxgG5Lj%2Finterface-errors-and-reconnection-behavior.png?alt=media)

Authenticated v2 recovery pattern. If creation timed out before returning an ID, do not assume nothing ran: reconcile the operation before resubmitting, especially when it can change an external system.

<details>

<summary>Copy the example</summary>

```http
# If creation returned a run ID, keep it after disconnecting.
GET /v2/runs/{run_id}

# queued / running -> continue following this run
# paused           -> display the pending response request
# succeeded        -> inspect the existing result
# failed           -> inspect the error before retrying
# cancelled        -> report the final cancelled state
```

</details>

## Before you begin

The interface error and the related run ID where available.

## Key concepts

| Term           | Definition                                                                                                                              |
| -------------- | --------------------------------------------------------------------------------------------------------------------------------------- |
| Timeout        | A limit on how long a particular client or operation waits. It does not always establish that execution or an external write stopped.   |
| Streaming      | Delivery of incremental events or text while work is running. Updates are not the same as a completed answer.                           |
| Run            | One execution of a project. Use its run ID to retrieve that execution’s state, input, output, and errors.                               |
| Reconciliation | Checking the run or destination to determine whether an uncertain operation completed. Do this before retrying a write after a timeout. |
| Retry          | A repeated attempt after a failed or uncertain operation. It can repeat external changes; use it only when the result is understood.    |

## Recover from an interface error

1. Check whether the request created a run.
2. Inspect input errors, access settings, and the run’s failing step.
3. Restore the connection or correct the cause, then check the original run before resubmitting.

The interface recovers without unnecessarily repeating work.

## Behavior and limitations

Reloading a page does not necessarily cancel the active run. Resubmission can repeat provider writes. Display a clear error state rather than keeping a permanent loading indicator. A disconnected stream and a failed workflow are different conditions.

## Related resources

[Interface Inputs and Output Mapping](https://docs.stackai.com/technical-reference/interfaces-and-conversations/interface-inputs-and-output-mapping.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.stackai.com/technical-reference/interfaces-and-conversations/interface-errors-and-reconnection-behavior.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
