The client library for Bulk Whois API in Python language.
The minimum Python version is 3.7.
pip install bulk-whois-apiFull API documentation available here
from bulkwhoisapi import *
client = Client('Your API key')domains = [
'example.com',
'example.org'
]
result = client.create_request(domains=domains)
# Used for further requests
request_id = result.request_idresult = client.get_records(
request_id=request_id,
max_records=len(domains)
)
# Finished once result.records_left == 0
print(result)result = client.get_requests()client.download(filename='records.csv', request_id=request_id)# Paginate over processed records and get results in XML
result = client.get_records_raw(
request_id=request_id,
max_records=1,
start_index=2,
output_format=Client.XML_FORMAT
)ResponseCreate:
- request_id: str
- invalid_domains: [str]
ResponseRecords:
- no_data_available: bool
- request_id: str
- total_records: int
- records_left: int
- records_processed: int
- domain_list: [str]
- whois_records: [BulkWhoisRecord]
ResponseRequests:
- user_requests: [BulkRequest]