Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
19 lines
571 B
Go
19 lines
571 B
Go
package port
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/google/uuid"
|
|
)
|
|
|
|
// TrustedSenders is the list of senders a mailbox has said it trusts.
|
|
//
|
|
// Mail from one of them is not filed as spam, which is what makes "this is not
|
|
// spam" mean something: before, moving a message out of Junk taught nothing and
|
|
// the next reply from the same person went straight back.
|
|
type TrustedSenders interface {
|
|
// IsTrusted reports whether the mailbox trusts this address, which is
|
|
// already lowercased.
|
|
IsTrusted(ctx context.Context, mailboxID uuid.UUID, address string) (bool, error)
|
|
}
|