package outbox

import (
	"context"
	"time"

	"go.mongodb.org/mongo-driver/v2/bson"
)

// Store persists gateway outbox events.
type Store interface {
	Create(ctx context.Context, event *Event) error
	ListPending(ctx context.Context, limit int) ([]*Event, error)
	MarkSent(ctx context.Context, eventRef bson.ObjectID, sentAt time.Time) error
	MarkFailed(ctx context.Context, eventRef bson.ObjectID) error
	IncrementAttempts(ctx context.Context, eventRef bson.ObjectID) error
}
