/// <inheritdoc /> public async Task <VericallOtpRequestResult> SendOtp(string otpId, VericallOtpRequestBody body, CancellationToken token) { var requestBody = CreateJsonBody(body); var result = await PostAsync($"/otp/{otpId}", requestBody, token); result.EnsureSuccessStatusCode(); return(await DeserializeResponse <VericallOtpRequestResult>(result.Content)); }
public async Task SendOtpTest() { var service = new VericallOtpService { Authentication = _textFixture.Authentication }; var body = new VericallOtpRequestBody { MaxAttempt = 3, Duration = 10000, Length = 4, User = "******" }; var result = await service.SendOtp("ENTER-RANDOM-OTP-ID", body); Assert.NotNull(result); }
/// <inheritdoc /> public Task <VericallOtpRequestResult> SendOtp(string otpId, VericallOtpRequestBody body) { return(SendOtp(otpId, body, CancellationToken.None)); }