<?php

declare(strict_types=1);

namespace App\Framework\ErrorReporting;

use Throwable;

/**
 * Interface for error reporting services
 *
 * Provides comprehensive error reporting with context enrichment
 */
interface ErrorReporterInterface
{
    /**
     * Report an error from Throwable
     */
    public function reportThrowable(
        Throwable $throwable,
        string $level = 'error',
        array $context = []
    ): string;

    /**
     * Report a manual error
     */
    public function reportError(
        string $level,
        string $message,
        array $context = [],
        ?Throwable $exception = null
    ): string;

    /**
     * Report an error with full context
     */
    public function report(ErrorReport $report): string;

    /**
     * Get error report by ID
     */
    public function getReport(string $reportId): ?ErrorReport;

    /**
     * Get recent error reports
     */
    public function getRecentReports(int $limit = 100, int $offset = 0): array;
}
