Skip to content

aburra12/Emailage_Java

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Emailage

The Emailage™ API is organized around REST (Representational State Transfer). The API was built to help companies integrate with our highly efficient fraud risk and scoring system. By calling our API endpoints and simply passing us an email and/or IP Address, companies will be provided with real-time risk scoring assessments based around machine learning and proprietary algorithms that evolve with new fraud trends.

Getting Started

Requirements

  • JVM 1.8 and above
  • Maven 3+
    • Maven is used to maintain all dependencies

Installation

Emailage can be installed directly from the source code:

$ git clone https://github.com/emailage/Emailage_Java.git

Or you can use the Maven dependency:

<dependency>
  <groupId>com.emailage</groupId>
  <artifactId>classic-api-client</artifactId>
  <version>1.2.0</version>
</dependency>

Usage

Please refer to the below class for for full code example.

com.emailage.javawrapper.test.TestClient.java

Settings

Before using the API, you will need to populate the configuration parameters:

ConfigurationParameters configuration = new ConfigurationParameters();
parameters.setUserEmail(/*Email associated with the emailage user making the request*/);
parameters.setAcccountToken(/*Emailage authentication token*/);
parameters.setAccountSecret(/*Emailage account secret*/);
parameters.setEnvironment(/*Environment for the Requetst Production/Sandbox*/);
parameters.setHashAlgorithm(/*Signature Hashing algorithm*/);
parameters.setResultFormat(/*Xml or JSON*/);

Email Validation

String validResult = EmailageClient.QueryEmail("test@test.com", configuration);

Email and IP Validation

String validResult = EmailageClient.QueryEmailAndIP("test@test.com", "147.12.12.13", configuration);

Email and IP Validation with extra input parameters

ExtraInputParameter extraArgs = new ExtraInputParameter();
		extraArgs.setBillPostal("85225");
		extraArgs.setBillCity("Chandler");
String validResult = EmailageClient.QueryEmailAndIPPlusExtraArgs("test@test.com", "147.12.12.13", extraArgs,
					configuration);

Mark email as fraud/good.

String validResult = EmailageClient.MarkEmailAsFraud("test@test.com", Enums.FraudFlag.Fraud, Enums.FraudType.Good,
					configuration);

Frequent asked integration problems.

  1. Using the wrong AccountSID/AUTHToken for different environments. Sandbox and Production have different AccountSID and AUTHToken.
  2. Using a wrong JVM version. JVM 1.8 and above is required for the client.

About

Java wrapper for Emailage API

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 100.0%