Skip to content

review_resource_sync_pending

Review an EXPLICIT whole-sync, resource-type or typed named-resource selection using only Core reads. Bind stable IDs for existing resources and exact pending-create names for new resources; invalid/missing/duplicate selectors never become an unfiltered run. Audit template-only and variable secret-flag effects missing from Core's cached view. Variables/groups are excluded from filtered scope. Reject incomplete/truncated/unfaithful coverage, pending errors and deployment scope combinations that differ in Core 2.3.2 execution. When complete, retain full authoritative config/plan/source/reference evidence privately in the shared bounded ten-minute single-use store, returning an opaque review_reference and exact apply_binding for the later separately authorized apply. Refuse review authority on unsupported Core versions. Redacted display is never the comparison baseline. This performs zero Core mutations or RunSync, and does not prove an external source current or freeze final-read/execution races.

Availability

Available under the default capability policy

The instance’s tool selection and upstream Core permissions also apply. Some inputs require additional grants.

Effect annotations

  • readOnlyHint — true
  • destructiveHint — false
  • idempotentHint — false

Inputs

The registered schema gives field types, alternatives and declared bounds. The description and operator guides also cover checks applied at runtime.

selection
Required · Schema Selection
target
Required · Schema DetailInput
Show input JSON Schema
{
  "type": "object",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "additionalProperties": false,
  "properties": {
    "selection": {
      "$ref": "#/$defs/Selection"
    },
    "target": {
      "$ref": "#/$defs/DetailInput"
    }
  },
  "required": [
    "target",
    "selection"
  ],
  "$defs": {
    "DetailInput": {
      "additionalProperties": false,
      "oneOf": [
        {
          "required": [
            "id"
          ]
        },
        {
          "required": [
            "name"
          ]
        }
      ],
      "properties": {
        "id": {
          "description": "Exact stable resource ID returned by a list tool.",
          "pattern": "^[0-9a-fA-F]{24}$",
          "type": "string"
        },
        "name": {
          "description": "Exact, case-sensitive name within this family; never interpreted as an ID.",
          "minLength": 1,
          "pattern": "\\S",
          "type": "string"
        }
      },
      "type": "object"
    },
    "Kind": {
      "enum": [
        "server",
        "swarm",
        "stack",
        "deployment",
        "build",
        "repo",
        "builder",
        "alerter",
        "procedure",
        "action",
        "resource_sync"
      ],
      "type": "string"
    },
    "Selection": {
      "oneOf": [
        {
          "additionalProperties": false,
          "properties": {
            "kind": {
              "const": "whole_sync",
              "type": "string"
            }
          },
          "required": [
            "kind"
          ],
          "type": "object"
        },
        {
          "additionalProperties": false,
          "properties": {
            "kind": {
              "const": "resource_type",
              "type": "string"
            },
            "resource_type": {
              "$ref": "#/$defs/Kind"
            }
          },
          "required": [
            "kind",
            "resource_type"
          ],
          "type": "object"
        },
        {
          "additionalProperties": false,
          "properties": {
            "kind": {
              "const": "resources",
              "type": "string"
            },
            "resource_type": {
              "$ref": "#/$defs/Kind"
            },
            "targets": {
              "items": {
                "$ref": "#/$defs/DetailInput"
              },
              "type": "array"
            }
          },
          "required": [
            "kind",
            "resource_type",
            "targets"
          ],
          "type": "object"
        }
      ]
    }
  }
}

Output

The registered output schema covers structured results and tool errors.

ReviewOutput
apply_binding, expires_after_seconds, observed_core_version, plan, review_reference
AppError
candidates, correction, field, kind, message, operation, status
Show output JSON Schema
{
  "type": "object",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "anyOf": [
    {
      "$ref": "#/$defs/ReviewOutput"
    },
    {
      "$ref": "#/$defs/AppError"
    }
  ],
  "$defs": {
    "AppError": {
      "additionalProperties": false,
      "description": "Only application-owned messages and selected, nonsensitive metadata survive.",
      "properties": {
        "candidates": {
          "items": {
            "$ref": "#/$defs/Candidate"
          },
          "type": [
            "array",
            "null"
          ]
        },
        "correction": {
          "type": [
            "string",
            "null"
          ]
        },
        "field": {
          "type": [
            "string",
            "null"
          ]
        },
        "kind": {
          "$ref": "#/$defs/ErrorKind"
        },
        "message": {
          "type": "string"
        },
        "operation": {
          "type": "string"
        },
        "status": {
          "format": "uint16",
          "maximum": 65535,
          "minimum": 0,
          "type": [
            "integer",
            "null"
          ]
        }
      },
      "required": [
        "kind",
        "message",
        "operation"
      ],
      "type": "object"
    },
    "ApplyBinding": {
      "additionalProperties": false,
      "properties": {
        "selection": {
          "$ref": "#/$defs/ExecutionScope"
        },
        "sync_id": {
          "type": "string"
        }
      },
      "required": [
        "sync_id",
        "selection"
      ],
      "type": "object"
    },
    "Candidate": {
      "additionalProperties": false,
      "description": "A bounded ambiguity hint, never a raw upstream resource.",
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "name"
      ],
      "type": "object"
    },
    "Change": {
      "properties": {
        "action": {
          "$ref": "#/$defs/ChangeKind"
        },
        "details_omitted": {
          "type": "boolean"
        },
        "id": {
          "type": [
            "string",
            "null"
          ]
        },
        "name": {
          "type": [
            "string",
            "null"
          ]
        },
        "origin": {
          "type": "string"
        },
        "resource_type": {
          "anyOf": [
            {
              "$ref": "#/$defs/Kind"
            },
            {
              "type": "null"
            }
          ]
        },
        "secret_flag_after": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "secret_flag_before": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "template_after": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "template_before": {
          "type": [
            "boolean",
            "null"
          ]
        }
      },
      "required": [
        "resource_type",
        "id",
        "name",
        "action",
        "origin",
        "template_before",
        "template_after",
        "secret_flag_before",
        "secret_flag_after",
        "details_omitted"
      ],
      "type": "object"
    },
    "ChangeKind": {
      "enum": [
        "create",
        "update",
        "delete"
      ],
      "type": "string"
    },
    "Changes": {
      "properties": {
        "available": {
          "type": "boolean"
        },
        "excluded_by_selection": {
          "format": "uint",
          "minimum": 0,
          "type": "integer"
        },
        "items": {
          "items": {
            "$ref": "#/$defs/Change"
          },
          "type": "array"
        },
        "reported_total": {
          "format": "uint",
          "minimum": 0,
          "type": [
            "integer",
            "null"
          ]
        },
        "truncated": {
          "type": "boolean"
        }
      },
      "required": [
        "available",
        "reported_total",
        "excluded_by_selection",
        "items",
        "truncated"
      ],
      "type": "object"
    },
    "DefinitionSummary": {
      "properties": {
        "delete": {
          "type": "boolean"
        },
        "effective_delete": {
          "type": "boolean"
        },
        "include_resources": {
          "type": "boolean"
        },
        "include_user_groups": {
          "type": "boolean"
        },
        "include_variables": {
          "type": "boolean"
        },
        "managed": {
          "type": "boolean"
        },
        "match_tags": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "pending_alert": {
          "type": "boolean"
        },
        "resource_tag_filter_unrestricted": {
          "type": "boolean"
        },
        "source": {
          "$ref": "#/$defs/SourceSummary"
        },
        "truncated": {
          "type": "boolean"
        },
        "webhook_enabled": {
          "type": "boolean"
        },
        "webhook_secret_configured": {
          "type": "boolean"
        }
      },
      "required": [
        "source",
        "managed",
        "delete",
        "effective_delete",
        "include_resources",
        "match_tags",
        "resource_tag_filter_unrestricted",
        "include_variables",
        "include_user_groups",
        "pending_alert",
        "webhook_enabled",
        "webhook_secret_configured",
        "truncated"
      ],
      "type": "object"
    },
    "DeploymentDependency": {
      "properties": {
        "name": {
          "type": "string"
        },
        "resource_type": {
          "$ref": "#/$defs/Kind"
        }
      },
      "required": [
        "resource_type",
        "name"
      ],
      "type": "object"
    },
    "DeploymentIntent": {
      "properties": {
        "dependencies": {
          "items": {
            "$ref": "#/$defs/DeploymentDependency"
          },
          "type": "array"
        },
        "name": {
          "type": "string"
        },
        "reason": {
          "type": "string"
        },
        "resource_type": {
          "$ref": "#/$defs/Kind"
        }
      },
      "required": [
        "resource_type",
        "name",
        "reason",
        "dependencies"
      ],
      "type": "object"
    },
    "Deployments": {
      "properties": {
        "available": {
          "type": "boolean"
        },
        "items": {
          "items": {
            "$ref": "#/$defs/DeploymentIntent"
          },
          "type": "array"
        },
        "reported_total": {
          "format": "uint",
          "minimum": 0,
          "type": [
            "integer",
            "null"
          ]
        },
        "truncated": {
          "type": "boolean"
        }
      },
      "required": [
        "available",
        "reported_total",
        "items",
        "truncated"
      ],
      "type": "object"
    },
    "ErrorKind": {
      "description": "Stable public categories. No variant contains a raw upstream error.",
      "enum": [
        "invalid_arguments",
        "not_found",
        "ambiguous_target",
        "incomplete_resolution",
        "configuration",
        "authentication",
        "permission_denied",
        "timeout",
        "unreachable",
        "upstream",
        "invalid_response",
        "response_too_large",
        "capability_disabled",
        "unsupported_target",
        "stale_preview",
        "invalid_preview"
      ],
      "type": "string"
    },
    "ExecutionScope": {
      "oneOf": [
        {
          "additionalProperties": false,
          "properties": {
            "kind": {
              "const": "whole_sync",
              "type": "string"
            }
          },
          "required": [
            "kind"
          ],
          "type": "object"
        },
        {
          "additionalProperties": false,
          "properties": {
            "kind": {
              "const": "resource_type",
              "type": "string"
            },
            "resource_type": {
              "$ref": "#/$defs/Kind"
            }
          },
          "required": [
            "kind",
            "resource_type"
          ],
          "type": "object"
        },
        {
          "additionalProperties": false,
          "properties": {
            "kind": {
              "const": "resources",
              "type": "string"
            },
            "resource_type": {
              "$ref": "#/$defs/Kind"
            },
            "targets": {
              "items": {
                "$ref": "#/$defs/ResolvedTarget"
              },
              "type": "array"
            }
          },
          "required": [
            "kind",
            "resource_type",
            "targets"
          ],
          "type": "object"
        }
      ]
    },
    "Kind": {
      "enum": [
        "server",
        "swarm",
        "stack",
        "deployment",
        "build",
        "repo",
        "builder",
        "alerter",
        "procedure",
        "action",
        "resource_sync"
      ],
      "type": "string"
    },
    "PendingOutput": {
      "properties": {
        "apply_coverage_complete": {
          "type": "boolean"
        },
        "cached_status": {
          "type": "string"
        },
        "core_mutation_requests": {
          "format": "uint8",
          "maximum": 255,
          "minimum": 0,
          "type": "integer"
        },
        "coverage_gaps": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "errors": {
          "$ref": "#/$defs/PlanErrors"
        },
        "observation": {
          "type": "string"
        },
        "observation_errors": {
          "items": {
            "$ref": "#/$defs/AppError"
          },
          "type": "array"
        },
        "pending_deployments": {
          "$ref": "#/$defs/Deployments"
        },
        "resource_changes": {
          "$ref": "#/$defs/Changes"
        },
        "reviewed_status": {
          "type": [
            "string",
            "null"
          ]
        },
        "run_sync_requests": {
          "format": "uint8",
          "maximum": 255,
          "minimum": 0,
          "type": "integer"
        },
        "selection": {
          "anyOf": [
            {
              "$ref": "#/$defs/ExecutionScope"
            },
            {
              "type": "null"
            }
          ]
        },
        "settings": {
          "$ref": "#/$defs/DefinitionSummary"
        },
        "source": {
          "$ref": "#/$defs/SourceEvidence"
        },
        "sync": {
          "$ref": "#/$defs/SyncIdentity"
        },
        "user_group_changes": {
          "$ref": "#/$defs/Changes"
        },
        "user_groups_in_review_scope": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "variable_changes": {
          "$ref": "#/$defs/Changes"
        },
        "variables_in_review_scope": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "warnings": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "required": [
        "sync",
        "observation",
        "cached_status",
        "reviewed_status",
        "variables_in_review_scope",
        "user_groups_in_review_scope",
        "settings",
        "source",
        "resource_changes",
        "variable_changes",
        "user_group_changes",
        "pending_deployments",
        "errors",
        "selection",
        "apply_coverage_complete",
        "coverage_gaps",
        "observation_errors",
        "core_mutation_requests",
        "run_sync_requests",
        "warnings"
      ],
      "type": "object"
    },
    "PlanErrors": {
      "properties": {
        "details_omitted": {
          "type": "boolean"
        },
        "pending_deploy_error": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "pending_error": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "source_file_errors": {
          "format": "uint",
          "minimum": 0,
          "type": [
            "integer",
            "null"
          ]
        }
      },
      "required": [
        "pending_error",
        "pending_deploy_error",
        "source_file_errors",
        "details_omitted"
      ],
      "type": "object"
    },
    "ResolvedTarget": {
      "oneOf": [
        {
          "additionalProperties": false,
          "properties": {
            "id": {
              "type": "string"
            },
            "kind": {
              "const": "existing",
              "type": "string"
            },
            "name": {
              "type": "string"
            }
          },
          "required": [
            "kind",
            "id",
            "name"
          ],
          "type": "object"
        },
        {
          "additionalProperties": false,
          "properties": {
            "kind": {
              "const": "create",
              "type": "string"
            },
            "name": {
              "type": "string"
            }
          },
          "required": [
            "kind",
            "name"
          ],
          "type": "object"
        }
      ]
    },
    "ReviewOutput": {
      "properties": {
        "apply_binding": {
          "anyOf": [
            {
              "$ref": "#/$defs/ApplyBinding"
            },
            {
              "type": "null"
            }
          ]
        },
        "expires_after_seconds": {
          "format": "uint32",
          "minimum": 0,
          "type": "integer"
        },
        "observed_core_version": {
          "type": "string"
        },
        "plan": {
          "$ref": "#/$defs/PendingOutput"
        },
        "review_reference": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "required": [
        "plan",
        "review_reference",
        "apply_binding",
        "expires_after_seconds",
        "observed_core_version"
      ],
      "type": "object"
    },
    "SourceEvidence": {
      "properties": {
        "contents_omitted": {
          "type": "boolean"
        },
        "files_observed": {
          "format": "uint",
          "minimum": 0,
          "type": [
            "integer",
            "null"
          ]
        },
        "kind": {
          "type": "string"
        },
        "observation": {
          "type": "string"
        },
        "pending_git_revision": {
          "type": [
            "string",
            "null"
          ]
        },
        "proves_current_external_revision": {
          "type": "boolean"
        }
      },
      "required": [
        "kind",
        "pending_git_revision",
        "files_observed",
        "contents_omitted",
        "observation",
        "proves_current_external_revision"
      ],
      "type": "object"
    },
    "SourceSummary": {
      "properties": {
        "git": {
          "anyOf": [
            {
              "$ref": "#/$defs/SourceSummary2"
            },
            {
              "type": "null"
            }
          ]
        },
        "inline_content_configured": {
          "type": "boolean"
        },
        "kind": {
          "type": "string"
        },
        "linked_repo_id": {
          "type": [
            "string",
            "null"
          ]
        },
        "resource_path_count": {
          "format": "uint",
          "minimum": 0,
          "type": "integer"
        },
        "resource_paths": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "truncated": {
          "type": "boolean"
        }
      },
      "required": [
        "kind",
        "linked_repo_id",
        "git",
        "resource_paths",
        "resource_path_count",
        "inline_content_configured",
        "truncated"
      ],
      "type": "object"
    },
    "SourceSummary2": {
      "properties": {
        "branch": {
          "type": "string"
        },
        "configured_commit": {
          "type": [
            "string",
            "null"
          ]
        },
        "credential_reference_configured": {
          "type": "boolean"
        },
        "https": {
          "type": "boolean"
        },
        "provider": {
          "type": "string"
        },
        "repo": {
          "type": "string"
        }
      },
      "required": [
        "repo",
        "provider",
        "branch",
        "configured_commit",
        "https",
        "credential_reference_configured"
      ],
      "type": "object"
    },
    "SyncIdentity": {
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "name"
      ],
      "type": "object"
    }
  }
}

Operator guides

All built-in tools