public class PayConfiguration extends Object
| Constructor and Description |
|---|
PayConfiguration() |
| Modifier and Type | Method and Description |
|---|---|
Environment |
getEnvironment() |
int |
getMaxRetries() |
String |
getOverrideServiceURL() |
PrivateKey |
getPrivateKey() |
String |
getPublicKeyId() |
Region |
getRegion() |
boolean |
isUserAgentRedaction()
Returns true if the merchant wants to set the Java and OS version segment in
the User-Agent header to 'Redacted'.
|
PayConfiguration |
setEnvironment(Environment environment) |
PayConfiguration |
setMaxRetries(int maxRetries) |
PayConfiguration |
setOverrideServiceURL(String overrideServiceURL) |
PayConfiguration |
setPrivateKey(PrivateKey privateKey) |
PayConfiguration |
setPrivateKey(String privateKey) |
PayConfiguration |
setPublicKeyId(String publicKeyId) |
PayConfiguration |
setRegion(Region region) |
PayConfiguration |
setUserAgentRedaction(boolean userAgentRedaction)
Sets userAgentRedaction in PayConfiguration
If this flag is set to true, the Java and OS version segment in the User-Agent header is
'Redacted'.
|
public Region getRegion()
public PayConfiguration setRegion(Region region)
region - Identifies region associated with Amazon Pay API operations.public String getPublicKeyId()
public PayConfiguration setPublicKeyId(String publicKeyId)
publicKeyId - The public key id of the merchantpublic PrivateKey getPrivateKey()
public PayConfiguration setPrivateKey(String privateKey) throws AmazonPayClientException
privateKey - The private key stringAmazonPayClientException - When an error response is returned by Amazon Pay due to bad request or other issuepublic PayConfiguration setPrivateKey(PrivateKey privateKey)
privateKey - the PrivateKey objectpublic Environment getEnvironment()
public PayConfiguration setEnvironment(Environment environment)
environment - the environment,i.e, Sandbox or Livepublic int getMaxRetries()
public PayConfiguration setMaxRetries(int maxRetries)
maxRetries - Sets the maximum number of retries to be made in case of internal server
errors or throttling errors, in PayConfigurationpublic boolean isUserAgentRedaction()
public PayConfiguration setUserAgentRedaction(boolean userAgentRedaction)
userAgentRedaction - - argument that sets userAgentRedaction in PayConfigurationpublic String getOverrideServiceURL()
public PayConfiguration setOverrideServiceURL(String overrideServiceURL)
overrideServiceURL - Sets CV2 Service URL override in PayConfiguration
This should only be used if you need to programmatically override the default service endpoint
provided by the SDK's endpointMappingsMap in com.amazon.pay.types.ServiceConstants.Copyright © 2020. All rights reserved.