Skip to content

mariyabytes/LinkShortner

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ln-K - A minimalist link shortner

A simple no-frills link shortner, made using the django web framework. Visit Ln-k.cf to test it out now !

API

In order to generate a short url, send a POST request to https://ln-k.cf/api with the url parameter.

CURL

$ curl "https://ln-k.cf/api/" -d "url=https://google.com"

{"status_code": 200, "shorturl": "https://ln-k.cf/bndrc", "message": "Short URL Created Successfully !"}

Python

import requests

longurl = "https://google.com"
r = requests.post("http://ln-k.cf/api/", data={"url":longurl})

shorturl = r.json()['shorturl']
print(shorturl)

About

Self-hostable Link shortner written in Django

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published