
Product
Announcing Precomputed Reachability Analysis in Socket
Socket’s precomputed reachability slashes false positives by flagging up to 80% of vulnerabilities as irrelevant, with no setup and instant results.
A robust, production-ready async client library for the FreeCap captcha solving service. Supports all captcha types including hCaptcha, FunCaptcha, Geetest, and more.
A robust, production-ready async client library for the FreeCap captcha solving service. Supports all captcha types including hCaptcha, FunCaptcha, Geetest, and more.
Install the package via NuGet Package Manager:
dotnet add package FreeCap.Client
Or via Package Manager Console:
Install-Package FreeCap.Client
using FreeCap.Client;
using FreeCap.Client.Models;
using FreeCap.Client.Enums;
// Using the main client
using var client = new FreeCapClient("your-api-key");
var task = new CaptchaTask
{
SiteKey = "a9b5fb07-92ff-493f-86fe-352a2803b3df",
SiteUrl = "discord.com",
RqData = "your-rq-data-here",
GroqApiKey = "your-groq-api-key"
};
var solution = await client.SolveCaptchaAsync(task, CaptchaType.HCaptcha);
Console.WriteLine($"Captcha solved: {solution}");
using FreeCap.Client;
// Quick hCaptcha solving
var solution = await FreeCapSolver.SolveHCaptchaAsync(
apiKey: "your-api-key",
siteKey: "a9b5fb07-92ff-493f-86fe-352a2803b3df",
siteUrl: "discord.com",
rqData: "your-rq-data-here",
groqApiKey: "your-groq-api-key"
);
// Quick FunCaptcha solving
var funcaptchaSolution = await FreeCapSolver.SolveFunCaptchaAsync(
apiKey: "your-api-key",
preset: FunCaptchaPreset.RobloxLogin
);
var task = new CaptchaTask
{
SiteKey = "your-site-key",
SiteUrl = "your-site-url",
RqData = "your-rq-data",
GroqApiKey = "your-groq-api-key",
Proxy = "http://user:pass@host:port" // Optional
};
var solution = await client.SolveCaptchaAsync(task, CaptchaType.HCaptcha);
var task = new CaptchaTask
{
Preset = FunCaptchaPreset.RobloxLogin,
ChromeVersion = "137", // 136 or 137
Blob = "undefined",
Proxy = "http://user:pass@host:port" // Optional
};
var solution = await client.SolveCaptchaAsync(task, CaptchaType.FunCaptcha);
var task = new CaptchaTask
{
Challenge = "your-challenge",
RiskType = RiskType.Slide, // Slide, Gobang, Icon, Ai
Proxy = "http://user:pass@host:port" // Optional
};
var solution = await client.SolveCaptchaAsync(task, CaptchaType.Geetest);
var task = new CaptchaTask
{
SiteKey = "your-site-key",
SiteUrl = "your-site-url",
Proxy = "http://user:pass@host:port" // Optional
};
var solution = await client.SolveCaptchaAsync(task, CaptchaType.CaptchaFox);
var task = new CaptchaTask
{
SiteKey = "your-site-key",
SiteUrl = "your-site-url",
Proxy = "http://user:pass@host:port" // Optional
};
var solution = await client.SolveCaptchaAsync(task, CaptchaType.DiscordId);
var task = new CaptchaTask
{
Proxy = "http://user:pass@host:port" // Optional
};
var solution = await client.SolveCaptchaAsync(task, CaptchaType.AuroNetwork);
var config = new ClientConfig
{
ApiUrl = "https://freecap.su", // Default API URL
RequestTimeout = TimeSpan.FromSeconds(30), // HTTP request timeout
MaxRetries = 3, // Maximum retry attempts
RetryDelay = TimeSpan.FromSeconds(1), // Base retry delay
DefaultTaskTimeout = TimeSpan.FromSeconds(120), // Task completion timeout
DefaultCheckInterval = TimeSpan.FromSeconds(3), // Status check interval
UserAgent = "Mozilla/5.0..." // Custom User-Agent
};
using var client = new FreeCapClient("your-api-key", config);
using Microsoft.Extensions.Logging;
using var loggerFactory = LoggerFactory.Create(builder =>
builder.AddConsole().SetMinimumLevel(LogLevel.Information));
var logger = loggerFactory.CreateLogger<FreeCapClient>();
using var client = new FreeCapClient("your-api-key", logger: logger);
using var httpClient = new HttpClient();
httpClient.DefaultRequestHeaders.Add("Custom-Header", "value");
using var client = new FreeCapClient("your-api-key", httpClient: httpClient);
The library provides specific exception types for different error scenarios:
try
{
var solution = await client.SolveCaptchaAsync(task, CaptchaType.HCaptcha);
}
catch (FreeCapValidationException ex)
{
// Invalid task configuration
Console.WriteLine($"Validation error: {ex.Message}");
}
catch (FreeCapTimeoutException ex)
{
// Task timed out
Console.WriteLine($"Timeout: {ex.Message}");
}
catch (FreeCapApiException ex)
{
// API error response
Console.WriteLine($"API error: {ex.Message}");
if (ex.StatusCode.HasValue)
Console.WriteLine($"Status code: {ex.StatusCode}");
}
catch (FreeCapException ex)
{
// Base FreeCap exception
Console.WriteLine($"FreeCap error: {ex.Message}");
}
// Create task
var taskId = await client.CreateTaskAsync(task, CaptchaType.HCaptcha);
// Check status manually
var result = await client.GetTaskResultAsync(taskId);
// Poll until completion with custom logic
while (true)
{
var status = await client.GetTaskResultAsync(taskId);
// Handle status...
await Task.Delay(5000); // Custom delay
}
using var cts = new CancellationTokenSource(TimeSpan.FromMinutes(5));
try
{
var solution = await client.SolveCaptchaAsync(
task,
CaptchaType.HCaptcha,
cancellationToken: cts.Token
);
}
catch (OperationCanceledException)
{
Console.WriteLine("Operation was cancelled");
}
This project is licensed under the GNU General Public License v3.0 - see the LICENSE file for details.
For issues and feature requests, please visit the GitHub repository.
Contributions are welcome! Please feel free to submit a Pull Request.
FAQs
A robust, production-ready async client library for the FreeCap captcha solving service. Supports all captcha types including hCaptcha, FunCaptcha, Geetest, and more.
We found that freecap.client demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Socket’s precomputed reachability slashes false positives by flagging up to 80% of vulnerabilities as irrelevant, with no setup and instant results.
Product
Socket is launching experimental protection for Chrome extensions, scanning for malware and risky permissions to prevent silent supply chain attacks.
Product
Add secure dependency scanning to Claude Desktop with Socket MCP, a one-click extension that keeps your coding conversations safe from malicious packages.