Extract Email Address By URL

A Specrom News API endpoint for extracting email address from a webpage using a fast regex

Extract email addresses found in any webpage by inputting a URL. This is an excellent way to build a journalist email database.

Once you have email addresses, use our email address to name endpoint to query our database and get full names and a spam score.


import requests

url = "https://specrom-news-api.p.rapidapi.com/"

payload = {
  "api_type": "email_extraction",
  "url": "https://www.wsj.com/articles/a-powerful-force-teslas-momentum-leads-stock-market-surge-11595151001"
}

headers = {
  "content-type": "application/json",
  "X-RapidAPI-Key": "API_Key",
  "X-RapidAPI-Host": "specrom-news-api.p.rapidapi.com"
}

response = requests.request("POST", url, json=payload, headers=headers)

print(response.text)
	
	POST / HTTP/1.1
Content-Type: application/json
X-Rapidapi-Key: API_Key
X-Rapidapi-Host: specrom-news-api.p.rapidapi.com
Host: specrom-news-api.p.rapidapi.com
Content-Length: 192

{
    "api_type": "email_extraction",
    "url": "https://www.wsj.com/articles/a-powerful-force-teslas-momentum-leads-stock-market-surge-11595151001"
}
	
	
Parameter Description
api_type email_extraction
url URL of the webpage where you want to extract email address

Output


["amrith.ramkumar@wsj.com"]