activitylog

package
v1.1.2 Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2026 License: Apache-2.0 Imports: 8 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterAll

func RegisterAll(server *mcp.Server, client *sdk.APIClient)

RegisterAll registers all Activity Log tools with the MCP server.

func RegisterContractTools

func RegisterContractTools(server *mcp.Server, client *sdk.APIClient)

func RegisterEventTools

func RegisterEventTools(server *mcp.Server, client *sdk.APIClient)

Types

type CompactError

type CompactError struct {
	HTTPStatus string   `json:"http_status,omitempty"`
	Messages   []string `json:"messages,omitempty"`
}

type CompactEvent

type CompactEvent struct {
	Time      string            `json:"time,omitempty"`
	Type      string            `json:"type,omitempty"`
	Action    string            `json:"action,omitempty"`
	Status    string            `json:"status,omitempty"`
	Message   string            `json:"message,omitempty"`
	URI       string            `json:"uri,omitempty"`
	RequestID string            `json:"request_id,omitempty"`
	QueueRef  int32             `json:"queue_ref_id,omitempty"`
	User      string            `json:"user,omitempty"`
	Service   string            `json:"service,omitempty"`
	SourceIP  string            `json:"source_ip,omitempty"`
	Initiator string            `json:"initiator,omitempty"`
	ParamSvc  string            `json:"param_service,omitempty"`
	ErrorCode string            `json:"error_code,omitempty"`
	Error     *CompactError     `json:"error,omitempty"`
	Resources []CompactResource `json:"resources,omitempty"`
}

CompactEvent is the flattened, deduplicated view of a single audit event. Field naming is snake_case to match the rest of the MCP tool responses.

type CompactOptions

type CompactOptions struct {
	IncludeStatusUpdates bool
	User                 *string
	EventTypes           []string
}

CompactOptions controls which events are included in the output.

type CompactResource

type CompactResource struct {
	Type   string   `json:"type,omitempty"`
	ID     string   `json:"id,omitempty"`
	Action []string `json:"action,omitempty"`
}

type CompactResponse

type CompactResponse struct {
	Events []CompactEvent `json:"events"`
	Total  int32          `json:"total"`
}

CompactResponse is the shape returned by list_activitylog_events. It strips guaranteed-redundant fields from the SDK response to reduce output tokens.

func Compact

func Compact(raw sdk.GetByContractResponse, inputContract int32, opts CompactOptions) CompactResponse

Compact projects a raw GetByContractResponse into CompactResponse. principal.identity.contractNumber equal to inputContract is dropped as redundant.

Jump to

Keyboard shortcuts

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