Package: buildlink
buildlinkbuildlink is a python program which helps you to shorten link with a single command without any registration or using any API Key. Its is capable of expanding any link available on internet. with support of wide range of domain names.FeaturesLink Shorteningbuildlink has ability to shorten any long url into short url using 5 different service providers along with custom alias for shorten linkNote :aliasfor link shortening must be less than 30 characters.i.e.shorten("url", alias="less than 30 char")Link Expandingwith the help ofexpand(), you can expand any shorten link available on internet to their long form without visiting really to that link.This is helpful when you get malicious short link and you want to know actual URL behind the shorten one, without clicking on the Link.Functionsexpand(url)This function takes one input as a parameter and return the Long URL associated with the short link.Return Type :stringexpand("https://tinyurl.com/yuxh3b37")# Output : https://github.com/TechUX/buildlinkSee Examplesshorten(url, service, alias)This function takes three parameters as a input, url, service for shortening, and alias .Return Type :list - list of shortened URL ,if no service is prividedshorten("https://github.com/TechUX/buildlink",service="tinyurl")# Output : https://tinyurl.com/yuxh3b37See Exampleshelp()This function display a basic help page of the package.OptionsThere are 5 options which is available forservice.These are as follow :ServiceDomaintinyurltinyurl.comisgdis.gdclckruclck.ruchilpitchilp.itdagada.gdNote :length ofaliasmust be less than 30 characters.ExamplesLink shorteningimportbuildlinkaslinklong_url="https://github.com/TechUX/buildlink/blob/main/README.md"shorten_url=link.shorten(long_url)print(shorten_url)# Output : ['https://tinyurl.com/2mksjsq7', 'https://is.gd/e8tsIB', 'https://clck.ru/33GnAf', 'http://chilp.it/6c70182\n', 'https://da.gd/tsttQ\n']Shortening with service specifiedfor this, just add theservice="<service_value>parameter.importbuildlinkaslinklong_url="https://github.com/TechUX/buildlink/blob/main/README.md"shorten_url=link.shorten(long_url,service="tinyurl")print(shorten_url)# Output : https://tinyurl.com/2mksjsq7Shortening with aliasimportbuildlinkaslinklong_url="https://github.com/TechUX/buildlink/blob/main/README.md"shorten_url=link.shorten(long_url,alias="pylink")print(shorten_url)# Output : https://is.gd/pylinkLink Expandingimportbuildlinkaslinkshort_url="https://is.gd/pylink"long_url=link.expand(short_url)print(longurl)# Output : https://github.com/TechUX/buildlink/blob/main/README.mdSupported Domain for link shorteningthis package is currently using 5 domains to short link :
These are as followTinyurlis.gdclck.ruchilp.itda.gdSupported Domain for link expandingAlmost all the shorten domains are supported for expansion.
buildlink supports a wide range of URL shortening services, including t.co, goo.gl, bit.ly, amzn.to, tinyurl.com, ow.ly, youtu.be, rg.gy, adf.ly and many others.Issues & Pull RequestsIf you find any issue or bug in the package, kindly post it onIssue page.Go to Issue pageNew Ideas and Innovations are always welcomed.Create a pull requestif you want to add something new or have a fix of any bug.Click here for Pull RequestAboutA simple , lghtweight python package which have ability of shortening and expanding links.You can shorten a long URL with 5 different services and also expand any shorten URL of internet to its original Long form in a single Click.Try this package now.Its available on pypi.Author & LicenseAuthor: Devesh Singh [GitHub: @TechUX| Instagram :@devesh92744:@code.radius]LicenseThis project is under MIT License.Click Here for detailed License