Documentation
¶
Overview ¶
Package abusewatch is the read seam between the /site API and the Enterprise abuse detector (ADR 0026): core knows only this interface and ee implements it, so neither imports the other. A nil Watch, or an unlicensed instance, shows no warning.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Warning ¶
type Warning struct {
Domain string
// Metric is "complaint" or "bounce".
Metric string
// Rate is 0–1.
Rate float64
}
Warning is a Sending domain in the detector's warning tier.
type Watch ¶
type Watch interface {
// Warning is the Workspace's warning at now, or nil when it is in no warning tier
// (exempt and suspended Workspaces are never in one).
Warning(ctx context.Context, s *ent.Scoped, ws *ent.Workspace, now time.Time) (*Warning, error)
}
Watch reads a Workspace's standing with the detector.
Click to show internal directories.
Click to hide internal directories.