Versions in this module Expand all Collapse all v0 v0.3.0 Aug 18, 2026 v0.2.0 Aug 6, 2026 Changes in this version + const BackoffBase + const BackoffMax + const DefaultRetentionDays + const DefaultTimeout + const DeliveryConcurrency + const DrainBatch + const HeaderDelivery + const HeaderEvent + const HeaderSignature + const HeaderTimestamp + const MaxAttempts + const SignatureVersion + var ErrPrivateAddress = errors.New(...) + func Backoff(attempts int) time.Duration + func Sign(secret []byte, timestamp int64, payload []byte) string + type Client struct + func NewClient(timeout time.Duration, rt GuardedTransport) *Client + func (c *Client) Deliver(ctx context.Context, url string, secret []byte, d Delivery) (int, error) + type Config struct + Logger *slog.Logger + Observer Observer + RetentionDays int + Timeout time.Duration + Transport GuardedTransport + type Delivery struct + Event string + ID uuid.UUID + Payload []byte + type Emitter interface + Emit func(ctx context.Context, workspaceID uuid.UUID, event string, data map[string]any) + type GuardedTransport interface + type Observer interface + ObserveWebhookDelivery func(outcome, status string) + type Service struct + func NewService(pool *pgxpool.Pool, cfg Config) *Service + func (s *Service) Drain(ctx context.Context) error + func (s *Service) Emit(ctx context.Context, workspaceID uuid.UUID, event string, data map[string]any) + func (s *Service) Pending(ctx context.Context) (int64, error) + func (s *Service) PurgeFinished(ctx context.Context) (int64, error) + func (s *Service) RetentionDays() int