using System.Text.Json.Nodes;

namespace Eis.Application.Administration;

public sealed record AdminDocumentResult(
    int StatusCode,
    byte[]? Content,
    string? ContentType,
    string? FileName,
    JsonObject? Error);

public interface IAdminArrangementService
{
    Task<AdminEndpointResult> GetAsync(string sessionToken, CancellationToken cancellationToken);

    Task<AdminEndpointResult> PreviewAsync(
        string sessionToken,
        string examId,
        JsonObject body,
        CancellationToken cancellationToken);

    Task<AdminEndpointResult> ApplyAsync(
        string sessionToken,
        string examId,
        JsonObject body,
        CancellationToken cancellationToken);

    Task<AdminEndpointResult> RetiredSingleAsync(
        string sessionToken,
        CancellationToken cancellationToken);

    Task<AdminDocumentResult> ExportAsync(
        string sessionToken,
        string type,
        string examId,
        CancellationToken cancellationToken);
}
