package connectsrv

import (
	"errors"
	"fmt"
)

// Edge-level error values wrapped in Connect status codes. Domain outcomes are
// not here — they ride back in the ExecuteResponse result_code.
var (
	errRateLimited    = errors.New("rate limit exceeded")
	errInternal       = errors.New("internal error")
	errMissingToken   = errors.New("missing session token")
	errInvalidSession = errors.New("invalid or expired session")
	errUpdateRequired = errors.New("client too old, update required")
)

// errUnknownMessageType reports an unregistered message type.
func errUnknownMessageType(msgType string) error {
	return fmt.Errorf("unknown message type %q", msgType)
}
