log_consent_event
Record data processing actions in a consent ledger for audit trail. Logs agent activity with classification and session details.
Instructions
Append a row to the consent_ledger table.
Call this whenever an agent processes data so there is an audit trail
of what was processed, when, and under what classification.
Args:
action: Short description — e.g. 'scan_document', 'anonymize_patient_data'.
data_classification: 'PUBLIC' | 'INTERNAL' | 'CONFIDENTIAL' | 'SENSITIVE'.
agent_slug: Which agent performed the action.
notes: Free-text context.
session_id: Current session identifier.Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| action | Yes | ||
| data_classification | No | PUBLIC | |
| agent_slug | No | ||
| notes | No | ||
| session_id | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |