9 ms·
Thanks! -- It is in the backlog under "pending". If this thing takes off and becomes a thing then adding those will be fairly straight forward.
by simplecto 2y ago
Thanks! -- It is in the backlog under "pending".
If this thing takes off and becomes a thing then adding those will be fairly straight forward.
- avipars 2y agoIs the backend open source? I wanted to implement my own WHOIS service and it is more complex than it seems.
- simplecto 2y agoIt is not (I'm not sure where it is going. But here is a gist of that file. This is in my requirements.txt git+https://github.com/richardpenman/whois.git@master#egg=python-whois https://github.com/richardpenman/whois.git@master#egg=python... And the meat of the file: import whois """Get WHOIS information for a domain.""" try: domain_info = whois.whois(domain) except whois.parser.PywhoisError as e: return Response({"message": "Bad request", "details": str(e)}, status=400) if domain_info["domain_name"] is None and domain_info["registrar"] is None: return Response({"message": "Bad request", "details": f"{domain} not found or registered"}, status=400) return {"result": domain_info}