Skip to content

WebNinjaDeveloper.com

Programming Tutorials




Menu
  • Home
  • Youtube Channel
  • Official Blog
  • Nearby Places Finder
  • Direction Route Finder
  • Distance & Time Calculator
Menu

Python 3 Email Validation API Example to Check Whether Input Email Address Exists or Not in Terminal

Posted on January 16, 2023

 

 

SOURCE CODE

 

 

app.py

 

 

Python
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
import requests
 
api_key = 'your_api_key'
email = 'example@email.com'
 
url = 'https://api.emailvalidation.com/v1/validate?api_key=' + api_key + '&email=' + email
 
response = requests.get(url)
 
if response.status_code == 200:
    data = response.json()
    if data['is_valid']:
        print(email + ' is a valid email')
    else:
        print(email + ' is not a valid email')
else:
    print('Error while validating the email')

 

 

As you can see in the above code we are importing the requests module and after that you need to copy paste the api_key and after that you need to validate the given email address and after that we are printing the status of the validity of the email.

 

Recent Posts

  • Android Java Project to Download Multiple Images From URL With Progressbar & Save it inside Gallery
  • Android Java Project to Capture Image From Camera & Save it inside Gallery
  • Android Java Project to Crop,Scale & Rotate Images Selected From Gallery and Save it inside SD Card
  • Android Kotlin Project to Load Image From URL into ImageView Widget
  • Android Java Project to Make HTTP Call to JSONPlaceholder API and Display Data in RecyclerView Using GSON & Volley Library
  • Angular
  • Bunjs
  • C#
  • Deno
  • django
  • Electronjs
  • java
  • javascript
  • Koajs
  • kotlin
  • Laravel
  • meteorjs
  • Nestjs
  • Nextjs
  • Nodejs
  • PHP
  • Python
  • React
  • ReactNative
  • Svelte
  • Tutorials
  • Vuejs




©2023 WebNinjaDeveloper.com | Design: Newspaperly WordPress Theme