audit

package
v1.10.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 4, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Entry

type Entry struct {
	ID        string         `json:"id"`
	Actor     string         `json:"actor"`
	Action    string         `json:"action"`
	Resource  string         `json:"resource"`
	Details   map[string]any `json:"details,omitempty"`
	Timestamp time.Time      `json:"timestamp"`
}

Entry represents a single audit log record for a mutating API action.

type Filter

type Filter struct {
	Actor    string
	Action   string
	Resource string
	Limit    int
}

Filter controls which entries are returned by Query.

type Logger

type Logger interface {
	Log(ctx context.Context, entry Entry) error
	Query(ctx context.Context, filter Filter) ([]Entry, error)
}

Logger is the interface for recording and querying audit log entries.

Directories

Path Synopsis
Package dynamostore implements audit.Logger backed by DynamoDB via the generic dynamostore package.
Package dynamostore implements audit.Logger backed by DynamoDB via the generic dynamostore package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL