Anchorage API reference
    Preparing search index...
    PolicyDecision:
        | { allowed: true }
        | { allowed: false; reason: string } & (
            ConnectorDenialMetadata
            | { code?: undefined; details?: undefined }
        )

    Decision shape a policy evaluator returns. Defined here — the leaf module — so a seam that uses it imports no other seam for it.

    Type Declaration

    • { allowed: true }
      • allowed: true

        Allow the operation.

    • { allowed: false; reason: string } & (
          ConnectorDenialMetadata
          | { code?: undefined; details?: undefined }
      )
      • allowed: false

        Deny the operation.

      • reason: string

        The connector seam exposes this reason in ConnectorPolicyError and its audit record; keep inspected input out of it. PolicyEngine and createContentPolicyGate discard it.