Is there any disposable email service that allow us to send veriifcation mail at temparory address and verify them?

Surendranath Birudala's picture

I need to automate a process where each time I need to register with a different email and need to verify the user on a specific email. Is there any such email service that allows testers to automate the process?

2 Answers

Manish Mehta's picture

You can simply create test automation script linking your application, email service page and verifications steps.

Sudhey Sharma's picture

Yes, at present there are so many disposable email service providers available in the market. they provide free public and private inbox for a temporary email address. Recently I found few very good disposable email service providers and one of them is ‘mail7.io’ (Email workflow testing tool with instant disposable emails)

To automate this, you can write the code something like the below mentioned:

import org.apcahe.commons.lang3.RandomStringUtils;

public class mail7{

private static final String EMAIL-DOMAIN = ‘Mailio’;

private static final String EMAIL_APIKEY = ‘mail7_api_key’;

private static final String EMAIL_APISecret = ‘mail7_api_secret’;

private String emailid;

public usernameGenerator(){

String username = RandomStringUtils.randomAlphanumeric(8).toLowerCase();

System.out. println(“Random Username is ” + username);

return username;

}

public getInbox(String username){

HttpResponse <String> httpResponse = Unirest.get(“"https://api.mail7.io/inbox?apikey=" + EMAIL_APIKEY + "&apisecret=" + EMAIL_APISecret + "&to=" + username”).asString();

System.out.println( httpResponse.getHeaders().get("Content-Type"));

System.out.println(httpResponse.getBody());

return httpResponse.getBody();

}

please refer to this doc to get a better idea and solution for your problem.

Registration And Login Automation Using Selenium With Disposable Email

StickyMinds is a TechWell community.

Through conferences, training, consulting, and online resources, TechWell helps you develop and deliver great software every day.