Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ActionLog ¶
type ActionLog struct {
Timestamp time.Time
AgentIDHash string
Method string
Direction string
Success bool
LatencyMs float64
PayloadSize int
AuthStatus string
ErrorCode string
IPAddress string
}
ActionLog represents a single intercepted message log entry.
type DB ¶
type DB struct {
// contains filtered or unexported fields
}
DB wraps a SQLite connection.
func Open ¶
Open opens (or creates) a SQLite database at path, enables WAL mode, and runs migrations.
func (*DB) Purge ¶
Purge deletes log entries older than retentionDays days. Returns the number of rows deleted.
func (*DB) QueryLogs ¶
func (db *DB) QueryLogs(opts QueryOptions) ([]ActionLog, error)
QueryLogs returns log entries matching opts, ordered newest-first.
func (*DB) SchemaVersion ¶
SchemaVersion returns the current schema version (for diagnostics).
Click to show internal directories.
Click to hide internal directories.