public final class WebServiceClient extends Object implements Closeable
Modifier and Type | Class and Description |
---|---|
static class |
WebServiceClient.Builder
Builder creates instances of WebServiceClient
from values set by the methods. |
Modifier and Type | Method and Description |
---|---|
void |
close()
Close any open connections and return resources to the system.
|
FactorsResponse |
factors(Transaction transaction)
Make a minFraud Factors request to the web service using the transaction
request object passed to the method.
|
InsightsResponse |
insights(Transaction transaction)
Make a minFraud Insights request to the web service using the transaction
request object passed to the method.
|
ScoreResponse |
score(Transaction transaction)
Make a minFraud Score request to the web service using the transaction
request object passed to the method.
|
String |
toString() |
public FactorsResponse factors(Transaction transaction) throws IOException, MinFraudException, InsufficientFundsException, InvalidRequestException, AuthenticationException, PermissionRequiredException, HttpException
transaction
- A transaction request object.InsufficientFundsException
- when there are insufficient funds on
the account.AuthenticationException
- when there is a problem authenticating.InvalidRequestException
- when the request is invalid for some
other reason.PermissionRequiredException
- when permission is required to use the
service.MinFraudException
- when the web service returns unexpected
content.HttpException
- when the web service returns an unexpected
response.IOException
- when some other IO error occurs.public InsightsResponse insights(Transaction transaction) throws IOException, MinFraudException, InsufficientFundsException, InvalidRequestException, AuthenticationException, PermissionRequiredException, HttpException
transaction
- A transaction request object.InsufficientFundsException
- when there are insufficient funds on
the account.AuthenticationException
- when there is a problem authenticating.InvalidRequestException
- when the request is invalid for some
other reason.PermissionRequiredException
- when permission is required to use the
service.MinFraudException
- when the web service returns unexpected
content.HttpException
- when the web service returns an unexpected
response.IOException
- when some other IO error occurs.public ScoreResponse score(Transaction transaction) throws IOException, MinFraudException, InsufficientFundsException, InvalidRequestException, AuthenticationException, PermissionRequiredException, HttpException
transaction
- A transaction request object.InsufficientFundsException
- when there are insufficient funds on
the account.AuthenticationException
- when there is a problem authenticating.InvalidRequestException
- when the request is invalid for some
other reason.PermissionRequiredException
- when permission is required to use the
service.MinFraudException
- when the web service returns unexpected
content.HttpException
- when the web service returns an unexpected
response.IOException
- when some other IO error occurs.public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
Copyright © 2016 MaxMind, Inc.. All rights reserved.