$ pip install yourls>>> from yourls import YOURLSClient
>>> yourls = YOURLSClient('http://example.com/yourls-api.php', signature='6f344c2a8p')
>>> yourls.shorten('http://google.com')
ShortenedURL(
shorturl='http://example.com/abcde',
url='http://google.com',
title='Google',
date=datetime.datetime(2015, 10, 31, 14, 31, 4),
ip='203.0.113.0',
clicks=0,
keyword='abcde')For in-depth information, visit the documentation!