You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I keep getting this message on every email.
For reference, I used a express node app
importexpressfrom'express';import{PingEmail}from'ping-email';// Create an Express applicationconstapp=express();constport=3000;// Configure the PingEmail instanceconstpingEmail=newPingEmail({port: 267,// SMTP porttimeout: 15000,// Time in milliseconds to wait for a response from the SMTP serverattempts: 5,// Number of attempts to verify the email address});// Middleware to parse JSON request bodiesapp.use(express.json());// Endpoint to validate an email addressapp.post('/validate-email',async(req,res)=>{const{ email }=req.body;if(!email){returnres.status(400).json({error: 'Email is required'});}try{console.log("Validating Email:",email);const{email: verifiedEmail, valid, message }=awaitpingEmail.ping(email);console.log("Validation Result:",{ verifiedEmail, valid, message });constresult={email: verifiedEmail,valid: valid,reason: message};res.json(result);}catch(error){console.error('Error during email validation:',error);res.status(500).json({error: 'Internal Server Error'});}});// Start the serverapp.listen(port,()=>{console.log(`Email validation service is running on port ${port}`);});
I keep getting this message on every email.
For reference, I used a express node app
Here is the response I get on running
npm start
The text was updated successfully, but these errors were encountered: