Operation Lifecycle
An operation is one declared action that Merulan offers through one or more Surfaces. Reading a Record or starting a Run uses that operation's contract on every Surface that offers it. Follow its call through admission, result, and readback when an effect is unclear.
Topology
The stages run in this order.
| Stage | What happens | Owner |
|---|---|---|
| Declaration | The operation states its input, result, errors, and permission before any call exists | API and each operation's reference page |
| Admission | Merulan checks the credential, the Workspace, the permission, and the Governance rules | Security, Tags, policy, and field access |
| Decision | The operation decides its result once | The Capability that owns the operation |
| Result | The caller receives one result, one declared error, or an internal fault | Each operation's reference page |
| Readback | An unclear effect is read back before any retry | The Capability that owns the effect |
Declaration
An operation has a contract before anyone calls it. The contract says if it reads or writes. It names the input, result, errors, permission, and Surfaces that offer it.
All callers use that one contract. The Console, API, SDK, CLI, MCP, and Infrastructure as Code each send a call to it. A Surface may add a check. It can never remove or replace one the operation declared. It may offer an operation or leave it out. It cannot change what the operation means. The operation reference lists its Surfaces under Available through.
Admission
Admission decides if the call may run the operation. Security checks run first. Governance checks then inspect any value that needs a purpose or carries a Tag. Admission also runs each check the operation or its Surface adds. Protected operation work starts only after admission passes.
Security states the order of the security checks and the repair for each refusal they return. Tags, policy, and field access states the order of its own checks and the repair for a refused purpose or Tag.
Decision and result
An admitted call reaches its decision once. The operation uses its input and what the caller may see. Every Surface that offers it applies the same operation contract and checks.
The caller receives one result, one declared error, or an internal fault. A result holds only values the caller may see. A field withheld by a Tag stays withheld on every Surface. Access reviews and audit states where a reviewer inspects the resulting evidence.
Readback
An operation can return before an outside effect is known. The other system may accept the effect without finishing it. Its answer may also fail to arrive. The result says whether the effect was accepted, or its outcome is unknown.
The operation names the status or reconcile operation that reads it back before a retry. A supported retry keeps the effect's identity and checks the current result before work repeats.
Traversal
Start from the stage where your call stopped:
| Where the call stopped | Continue to |
|---|---|
| Refused before it ran | Security |
| Refused on a value it tried to read | Tags, policy, and field access |
| Returned a declared error | The operation's reference page, under Errors |
| Stopped for a person to decide | Reviews and repair |
| Retried with the same request key | The operation's reference page, under Durable identity |
Related
- Company Model names the Capability that owns each part of the company an operation reads or changes.
- Surfaces explains how each Surface reaches the same operation contract.
- API shows the first call and the shape every response follows.