ccbikai / Sink

⚡ A Simple / Speedy / Secure Link Shortener with Analytics, 100% run on Cloudflare.
https://Sink.Cool
GNU Affero General Public License v3.0
2.98k stars 1.59k forks source link

4 digits slug via API? #26

Open Root-FTW opened 4 months ago

Root-FTW commented 4 months ago

I have been using this project with my domain and it works perfect, it allows me to create shortened links and it's great, just one question, in cloudflare configure the slug to be 4 digits maximum, when using it via UI it works and generates the 4 digits slug, but via API is not like that, is there a way to specify via API that I want the slug to be 4 digits?

ccbikai commented 4 months ago

You can directly pass a 4-digit slug when calling the API, and if it is duplicated, the creation will fail.