Reverse MX API use case.


Very often for Webmasters or SEO professionals it is needed to check Reverse MX information for given mail server or even automate the process and there is a very useful online service "WhoisXML API" that provides RESTful APIs that we will use.

Using it's APIs you can perform many handy data requests, in our example will get get Reverse MX details - don't forget to get your API KEY. With one API call you will obtain ready to use parsed JSON file with check results which domains link back to a mail server to avoid hosts with a dubious reputation, improve email delivery, and other purposes.

Reverse MX.


This Python script below will use information from "WhoisXML API" and provide you a result in a JSON format without the need to use web a browser.
The process of getting Reverse MX detais can be easily automated now !



Python code to obtain Reverse MX data using API:



# Reverse MX API USE

import requests


MX = 'mx.mail.ru'


APIKEY ='at_ZUVkrukr4UHznQq2j6dyv2VhhhhYV'
   

ReverseMXURL = f'https://reverse-mx.whoisxmlapi.com/api/v1?apiKey={APIKEY}&mx={MX}&outputFormat=JSON'

r = requests.get(ReverseMXURL)

ReverseMX = r.json()

print(f'Reverse MX info for {MX} .\n')
ReverseMX

Reverse MX data output:



Reverse MX info for mx.mail.ru .

{'current_page': '0',
 'size': 27,
 'result': [{'name': '28484.ru',
   'first_seen': 1654732800,
   'last_visit': 1662336000},
  {'name': 'aleksin-ask.ru',
   'first_seen': 1637280000,
   'last_visit': 1662076800},
  {'name': 'alimel.com', 'first_seen': 1653436800, 'last_visit': 1661126400},
  {'name': 'antonsheff.ru',
   'first_seen': 1637280000,
   'last_visit': 1662076800},
  {'name': 'arta-marketing.ru',
   'first_seen': 1655251200,
   'last_visit': 1661126400},
  {'name': 'beautylect.es',
   'first_seen': 1658966400,
   'last_visit': 1661299200},
  {'name': 'cortexx.space',
   'first_seen': 1654560000,
   'last_visit': 1662249600},
  {'name': 'dementalization.com',
   'first_seen': 1661904000,
   'last_visit': 1661904000},
  {'name': 'edeniza.com', 'first_seen': 1637280000, 'last_visit': 1661299200},
  {'name': 'edeniza.ru', 'first_seen': 1637280000, 'last_visit': 1661299200},
  {'name': 'endlesswar.ru',
   'first_seen': 1655251200,
   'last_visit': 1661817600},
  {'name': 'fasadus.kz', 'first_seen': 1637280000, 'last_visit': 1661731200},
  {'name': 'fawnit.com', 'first_seen': 1654387200, 'last_visit': 1661126400},
  {'name': 'glasshome.kz', 'first_seen': 1637280000, 'last_visit': 1662076800},
  {'name': 'konsalt-pravo.ru',
   'first_seen': 1637280000,
   'last_visit': 1659744000},
  {'name': 'kostiuk.ru', 'first_seen': 1655164800, 'last_visit': 1661126400},
  {'name': 'kover-russia.ru',
   'first_seen': 1654300800,
   'last_visit': 1661126400},
  {'name': 'lukilevsha.ru',
   'first_seen': 1637280000,
   'last_visit': 1660348800},
  {'name': 'miadev.com', 'first_seen': 1655164800, 'last_visit': 1661040000},
  {'name': 'poly-clip.ru', 'first_seen': 1637280000, 'last_visit': 1662076800},
  {'name': 'santbitli.com',
   'first_seen': 1643932800,
   'last_visit': 1661904000},
  {'name': 'toksatlebensmittel.de',
   'first_seen': 1654646400,
   'last_visit': 1662940800},
  {'name': 'tolkynzabirova.kz',
   'first_seen': 1637280000,
   'last_visit': 1662076800},
  {'name': 'tylerwilson.co.uk',
   'first_seen': 1653782400,
   'last_visit': 1661126400},
  {'name': 'xdiff.su', 'first_seen': 1637280000, 'last_visit': 1659916800},
  {'name': 'xn--80aag2clhc.xn--90ais',
   'first_seen': 1637280000,
   'last_visit': 1659657600},
  {'name': 'zividolgo.ru',
   'first_seen': 1661212800,
   'last_visit': 1661212800}]}



See also related topics: