namespace Api.Services.Contracts;
///
/// Manages one-time job search tokens and the sessions they trigger.
///
public interface IJobTokenService
{
///
/// Creates a new single-use job search token linked to the given CV document and user.
/// The token expires after the number of days configured in JobSearch:TokenExpiryDays.
///
/// Identifier of the indexed CV document.
/// Email address of the user who will receive the results.
/// Preferred language for result emails (e.g. "en", "ro").
/// Job search keywords extracted by the LLM during the match call.
/// Candidate location extracted from the CV (e.g. "Cluj-Napoca, Romania"). Null if not available.
/// Cancellation token.
///
/// The generated token ID to embed in the one-click job search link,
/// or null when no job providers are currently enabled (link should be suppressed).
///
Task CreateTokenAsync(string cvDocumentId, string email, string language, IReadOnlyList keywords, string? location, CancellationToken ct);
///
/// Validates the token and, if valid, marks it as used and creates a Pending job search session.
///
/// The token ID from the one-click link.
/// Cancellation token.
///
/// One of the StartJobSearchStatus string constants:
/// Started, AlreadyUsed, Expired, or NotFound.
///
Task TriggerStartAsync(string tokenId, CancellationToken ct);
}