16bb195cb5
- Update CLAUDE.md: replace incorrect 'no XML doc on internal code' rule with the correct convention (XML doc on all public methods and non-trivial private/protected helpers) - Restore /// <summary> on FileDownloadController private helpers (HandleRangeRequest, StreamRangeAsync) - Add full XML doc to all service contracts: ICaptchaVerifier, IEmailSender, ICvMatcherService, IJobTextExtractor, IJobTokenService, IDocumentClassifier, IRagService, ITextChunker, ITextExtractor, IEmailTemplateService, ITemplateService - Add /// <summary> and /// <inheritdoc /> to all concrete service classes and their methods: RecaptchaVerifier, EmailApiEmailSender, SmtpEmailDispatcher, CvMatcherService, JobTextExtractor, JobTokenService, RagService, DocumentClassifier, TextChunker, TextExtractor, HtmlJobSearcher, CvSearchEmailSender, CvSearchJobTask, EmailTemplateService, DbTemplateService Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
22 lines
1.0 KiB
C#
22 lines
1.0 KiB
C#
using Api.Services.Contracts.Models;
|
|
|
|
namespace Api.Services.Contracts
|
|
{
|
|
/// <summary>
|
|
/// Verifies a reCAPTCHA token against the Google verification API.
|
|
/// </summary>
|
|
public interface ICaptchaVerifier
|
|
{
|
|
/// <summary>
|
|
/// Sends the token to the Google reCAPTCHA verification endpoint and
|
|
/// returns a verdict indicating success, score, and any failure reason.
|
|
/// </summary>
|
|
/// <param name="token">The reCAPTCHA token provided by the client.</param>
|
|
/// <param name="userIp">Optional remote IP address passed to Google for additional risk analysis.</param>
|
|
/// <param name="expectedAction">Optional action name to validate against the token's embedded action (v3 only).</param>
|
|
/// <param name="ct">Cancellation token.</param>
|
|
/// <returns>A <see cref="CaptchaVerdictModel"/> with the verification outcome.</returns>
|
|
Task<CaptchaVerdictModel> VerifyAsync(string token, string? userIp, string? expectedAction, CancellationToken ct);
|
|
}
|
|
}
|