Rust Client
Blazingly fast Rust client for Gender-API.com providing memory-safe and efficient gender detection for systems programming. Our specialized API delivers 99.5% accuracy in under 100ms, perfect for high-performance applications and embedded systems. The client is built with zero-cost abstractions and follows Rust best practices for safety and concurrency. Unlike generic AI models that are slow and resource-heavy, our API is 10x-90x faster with 9-34% better accuracy. Ideal for CLI tools, web servers, and performance-critical applications. Access over 9 million names across 150+ countries with intelligent fallback. Start free with 100 monthly API calls. Production-ready and GDPR compliant.
use reqwest::header::AUTHORIZATION;
use serde::{Deserialize, Serialize};
use std::error::Error;
// Add to Cargo.toml:
// [dependencies]
// reqwest = { version = "0.11", features = ["json"] }
// tokio = { version = "1", features = ["full"] }
// serde = { version = "1.0", features = ["derive"] }
#[derive(Serialize)]
struct Request<'a> {
first_name: &'a str,
}
#[derive(Deserialize, Debug)]
struct Response {
gender: String,
probability: f64,
}
#[tokio::main]
async fn main() -> Result<(), Box<dyn Error>> {
let api_key = "YOUR_API_KEY"; // Get your key at https://gender-api.com/en/account/auth-tokens
let client = reqwest::Client::new();
let resp: Response = client
.post("https://gender-api.com/v2/gender/by-first-name")
.header(AUTHORIZATION, format!("Bearer {api_key}"))
.json(&Request { first_name: "Theresa" })
.send()
await?
.json()
await?;
println!("Gender: {}", resp.gender);
println!("Probability: {}", resp.probability);
Ok(())
}
اكتشاف احترافي للجنس لتطبيقاتك
Gender-API.com يقدّم لك تحديد جنس الاسم بمستوى مؤسسي وبدقة 99.5% عبر أكثر من 150 دولة. واجهة الـAPI المتخصصة عندنا تتفوّق على حلول الذكاء الاصطناعي العامة بسرعات استجابة أسرع بـ10 إلى 90 مرة، وبدقة أعلى بنسبة 9% إلى 34%.
ليش تختار Gender-API بدل الذكاء الاصطناعي العام؟
- مصمّم خصيصًا متخصص في تحديد gender، وليس ذكاءً اصطناعيًا عامًا متعدد الاستخدامات
- سرعة البرق : أوقات استجابة أقل من 100 ملّي ثانية مقابل ثوانٍ مع الذكاء الاصطناعي العام
- أكثر دقة دقّة 99.5% مع ذكاء ثقافي وإقليمي
- Larger Database : 9+ million names, 37% more than typical AI training data
- Reliable : 99.9% uptime SLA with predictable performance
Key Features
- Easy integration with just a few lines of code
- Batch processing for high-volume applications
- Country-specific accuracy for regional name variations
- Smart normalization handling typos and variants
- GDPR compliant and enterprise-ready
ابدأ مجانًا اليوم
Get 100 free API calls per month with no credit card required. Scale as you grow with flexible pricing for every use case.