VeliTurnstile
Cloudflare Turnstile validator module for Veli.
Installation
the package can be installed by adding veli_turnstile to your list of dependencies in mix.exs:
def deps do
[
{:veli_turnstile, "~> 0.1.0"}
]
endDocumentation
Documentation is avaible at HexDocs.
Example
First, you need to add validator to Veli:
Veli.add_validator(:turnstile, VeliTurnstile)Now you can use the validator:
rule = [type: :string, turnstile: "secret key"]
Veli.valid("turnstile response", rule) |> Veli.error()License
Released under the MIT License.