gitops.diff ​
Preview pending changes for a GitOpsApplication (read-only diff)
Preview what the next reconcile of a GitOpsApplication would change, read-only.
Resolves the tracked revision, renders the manifest set, and computes a server-side dry-run diff against the live cluster. Never applies, never prunes, never records a sync run — safe on any application.
Inputs:
- organization_uuid: calling org (required).
- application_uuid: the GitOpsApplication to preview (required).
Outputs:
- status: synced | out_of_sync.
- commit_sha: the resolved revision the preview was computed against.
- is_synced: True when the cluster already matches the desired manifests.
- result: the k8s.manifest.diff_set report — out_of_sync[] entries each carry live + desired objects for a field-level / YAML diff.
Composes: data.gitops.application.get, github.refs.resolve, github.code.get_tree, github.code.get_blob, k8s.manifest.diff_set.
Overview ​
| Property | Value |
|---|---|
| Workflow type | Atomic |
| Library | App-gitops |
| Version | 1.0 |
Input Schema ​
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
organization_uuid | uuid | Yes | — | — |
application_uuid | uuid | Yes | — | — |
Output Schema ​
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
application_uuid | uuid | No | — | — |
status | string | No | — | synced |
commit_sha | string | No | — | — |
resolved_ref | string | No | — | — |
manifest_count | integer | No | — | — |
is_synced | boolean | No | — | — |
result | json | No | — | k8s.manifest.diff_set output (out_of_sync with live/desired objects, in_sync_count, is_synced) |
failure_reason | string | No | — | — |
failure_type | string | No | — | — |
failed_action | string | No | — | — |
failed_at_state | string | No | — | — |
failed_step | string | No | — | — |
failed_layer | string | No | — | — |
error | string | No | — | — |
error_type | string | No | — | — |
States ​
| State | Initial | Terminal | Success | Auto-advance | Description |
|---|---|---|---|---|---|
pending | Yes | No | — | preview | — |
completed | No | Yes | Yes | — | — |
failed | No | Yes | No | — | — |
State Diagram ​
Transitions ​
| From | Action | To | Description |
|---|---|---|---|
pending | preview | completed | — |
* (any state) | fail | failed | — |
API Usage ​
bash
POST /api/workflows/start
Content-Type: application/json
{
"workflow_type": "gitops.diff",
"initial_data": {
"organization_uuid": "value",
"application_uuid": "value"
}
}