How to make URL Shoretner using Python

Pyshorteners is a A simple URL Shorter API wrapper Python library. Which will help you short and expand urls using the most famous URL Shorteners availables.
With pyshorteners , generate a short url or expand another one is as easy as typing

Library Installation

pip install pyshorteners

Source Code

#import library
import pyshortners

#create a instance
s = pyshortners.Shortner()

#using tinyurl for sorting
print(s.tinyurl.short('https://techcvr.net'))

Output

https://tinyurl.com/y2enatq8

Leave a Comment

Your email address will not be published. Required fields are marked *