mcaptcha-api-rs

Crates.iomcaptcha-api-rs
lib.rsmcaptcha-api-rs
version0.1.0
sourcesrc
created_at2024-01-02 19:54:35.91739
updated_at2024-01-02 19:54:35.91739
descriptionHTTP Library to interact with mCaptcha API
homepagehttps://mcaptcha.org
repositoryhttps://git.batsense.net/mCaptcha/mcaptcha-api-rs
max_upload_size
id1086592
size27,389
Aravinth Manivannan (realaravinth)

documentation

https://docs.rs/mcaptcha-api-rs

README

status-badge


mcaptcha-api-rs: Library to interact with with mCaptcha API

This library provides a convenient interface to validate mCaptcha authorization tokens presented by Visitors against your mCaptcha instances. It uses reqwest, and native-tls under the hood to communicate with the API.

Install

cargo add mcaptcha-api-rs

Example

use url::Url;
use mcaptcha_api_rs::MCaptcha;

let mcaptcha = MCaptcha::new("sitekeyfromdashboard", "secretfromdashboadr", Url::parse("https://mcaptcha.example.com").unwrap());
assert!(mcaptcha.verify("authorizationtokenfromvisitor").await.unwrap());
Commit count: 0

cargo fmt