An url shortener backend server built with Golang and Fiber v3 framework. With Cloudflare and Cloudflare Turnstile supported.
All the environmental variables are optional.
CLOUDFLARE_TURNSTILE_SECRET_KEYSecret Key of/for Cloudflare Turnstile captcha verification.CORS_DOMAINSDomain/s to be included in CORS list. Example:https://example.com, https://www.exmaple.com, https://sub.example.com, https://*.example.com.TLS_CERTTLS/SSL Certificate.TLS_KEYTLS/SSL Certificate Private/Secret Key.
Example:
CLOUDFLARE_TURNSTILE_SECRET_KEY=
CORS_DOMAINS=
TLS_CERT=
TLS_KEY=/{hash}To get the original URL.
/To submit/save URL to the server and return a hash.
Requireurlin query.
Andcaptcha_tokenif Cloudflare Turnstile is enabled.