generated from coulomb/repo-seed
Governed asset registry slice with asset creation, representations, metadata, lifecycle transitions, policy authorization, fail-closed denial, audit events, and version records
This commit is contained in:
@@ -70,3 +70,18 @@ class AuditEvent:
|
||||
}
|
||||
)
|
||||
|
||||
@classmethod
|
||||
def from_dict(cls, data: dict[str, Any]) -> "AuditEvent":
|
||||
return cls(
|
||||
event_id=data["event_id"],
|
||||
operation=data["operation"],
|
||||
target=data["target"],
|
||||
outcome=AuditOutcome(data["outcome"]),
|
||||
actor_id=data["actor_id"],
|
||||
correlation_id=data["correlation_id"],
|
||||
policy_decision=PolicyDecision.from_dict(data["policy_decision"])
|
||||
if data.get("policy_decision")
|
||||
else None,
|
||||
details=dict(data.get("details", {})),
|
||||
occurred_at=data["occurred_at"],
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user