using CashLineERP.Contracts.Integration;

namespace CashLineERP.Application.Integration;

public interface IOutboxEventService
{
    IReadOnlyCollection<OutboxEventResponse> GetOutboxEvents(
        string? statusCode = null,
        string? sourceModuleCode = null);

    OutboxEventResponse? GetOutboxEvent(long outboxEventId);

    PublishOutboxBatchResultResponse PublishPendingEvents(PublishOutboxBatchRequest request);

    OutboxEventResponse MoveOutboxEventToDeadLetter(long outboxEventId, long actorUserId, DeadLetterQueueItemRequest request);

    OutboxEventResponse ReplayOutboxEvent(long outboxEventId, long actorUserId, ReplayDeadLetterQueueItemRequest request);
}
