import datetime import json import urllib.parse def domains(domains): html = '' for domain in domains: owner = domain['owner'] if 'index' in owner: if owner['index'] == 0: continue expires = domain['stats'] if 'daysUntilExpire' in expires: expires = expires['daysUntilExpire'] paid = domain['value'] paid = paid / 1000000 html += f'
Returns: {returns}
' html += f'{output}
' html += f'