> For the complete documentation index, see [llms.txt](https://docs.podigee.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.podigee.com/documentation/start-here/ai-agents/make-changes-safely/understand-durable-operations.md).

# Understand durable operations

Understand the states and recovery model for long-running Podigee agent operations.

A durable operation lets Podigee continue long-running or recoverable work outside one chat or network request.

## Operation states

| State              | Meaning                                                                  | User action                                                          |
| ------------------ | ------------------------------------------------------------------------ | -------------------------------------------------------------------- |
| `queued`           | Podigee accepted the work and has not started it yet.                    | Monitor the same operation.                                          |
| `running`          | Podigee is actively processing the work.                                 | Monitor it. Do not start a duplicate.                                |
| `waiting`          | The operation waits for another Podigee process or external state.       | Review the stage and continue monitoring.                            |
| `succeeded`        | The operation completed successfully.                                    | Verify the returned result.                                          |
| `failed_retryable` | The operation stopped at a condition that can allow a controlled resume. | Review the error, then preview and confirm one resume.               |
| `failed_terminal`  | The operation cannot continue.                                           | Preserve the error and complete the stated recovery or support path. |
| `cancelled`        | The operation was cancelled.                                             | Verify what completed before cancellation.                           |

The terminal states are `succeeded`, `failed_terminal`, and `cancelled`.

## What an operation records

An operation has a stable ID, type, state, stage, attempt count, timestamps, related Podigee IDs, result, and safe error details. Long imports can also report current item, total items, percentage, and current episode.

The operation keeps immutable provenance for the originating user, selected account, credential type, scopes, and contract version. A later authorized grant can become the execution authority, but it does not replace the recorded origin.

## Operations and conversations

Keep the operation ID when a conversation, terminal, or network connection ends. A new session can inspect the same operation when the current authorization represents the same user and account and has the required scope.

## Safety checkpoints

Background work checks current authorization at safe checkpoints. Revoking access stops new calls and causes running work to stop safely. Completed drafts or imported data are not erased merely because the authorization changed.

## Related tasks

* [Monitor a long-running operation](/documentation/start-here/ai-agents/make-changes-safely/monitor-a-long-running-operation.md)
* [Resume or cancel an operation](/documentation/start-here/ai-agents/make-changes-safely/resume-or-cancel-an-operation.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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.podigee.com/documentation/start-here/ai-agents/make-changes-safely/understand-durable-operations.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
