use of com.ingenico.connect.gateway.sdk.java.CommunicatorConfiguration in project connect-sdk-java by Ingenico-ePayments.
the class ItTest method getCommunicatorConfiguration.
private CommunicatorConfiguration getCommunicatorConfiguration(URL propertiesUrl) throws URISyntaxException {
CommunicatorConfiguration configuration = Factory.createConfiguration(propertiesUrl.toURI(), API_KEY_ID, SECRET_API_KEY);
String host = System.getProperty("connect.api.endpoint.host");
if (host != null) {
String scheme = System.getProperty("connect.api.endpoint.scheme", "https");
int port = Integer.parseInt(System.getProperty("connect.api.endpoint.port", "-1"));
URI apiEndpoint = new URI(scheme, null, host, port, null, null, null);
configuration = configuration.withApiEndpoint(apiEndpoint);
}
return configuration;
}
use of com.ingenico.connect.gateway.sdk.java.CommunicatorConfiguration in project connect-sdk-java by Ingenico-ePayments.
the class BlockMandateExample method getClient.
private Client getClient() throws URISyntaxException {
String apiKeyId = System.getProperty("connect.api.apiKeyId", "someKey");
String secretApiKey = System.getProperty("connect.api.secretApiKey", "someSecret");
URL propertiesUrl = getClass().getResource("/example-configuration.properties");
CommunicatorConfiguration configuration = Factory.createConfiguration(propertiesUrl.toURI(), apiKeyId, secretApiKey);
return Factory.createClient(configuration);
}
use of com.ingenico.connect.gateway.sdk.java.CommunicatorConfiguration in project connect-sdk-java by Ingenico-ePayments.
the class CreateMandateExample method getClient.
private Client getClient() throws URISyntaxException {
String apiKeyId = System.getProperty("connect.api.apiKeyId", "someKey");
String secretApiKey = System.getProperty("connect.api.secretApiKey", "someSecret");
URL propertiesUrl = getClass().getResource("/example-configuration.properties");
CommunicatorConfiguration configuration = Factory.createConfiguration(propertiesUrl.toURI(), apiKeyId, secretApiKey);
return Factory.createClient(configuration);
}
use of com.ingenico.connect.gateway.sdk.java.CommunicatorConfiguration in project connect-sdk-java by Ingenico-ePayments.
the class CreateMandateWithReferenceExample method getClient.
private Client getClient() throws URISyntaxException {
String apiKeyId = System.getProperty("connect.api.apiKeyId", "someKey");
String secretApiKey = System.getProperty("connect.api.secretApiKey", "someSecret");
URL propertiesUrl = getClass().getResource("/example-configuration.properties");
CommunicatorConfiguration configuration = Factory.createConfiguration(propertiesUrl.toURI(), apiKeyId, secretApiKey);
return Factory.createClient(configuration);
}
use of com.ingenico.connect.gateway.sdk.java.CommunicatorConfiguration in project connect-sdk-java by Ingenico-ePayments.
the class ApprovePaymentExample method getClient.
private Client getClient() throws URISyntaxException {
String apiKeyId = System.getProperty("connect.api.apiKeyId", "someKey");
String secretApiKey = System.getProperty("connect.api.secretApiKey", "someSecret");
URL propertiesUrl = getClass().getResource("/example-configuration.properties");
CommunicatorConfiguration configuration = Factory.createConfiguration(propertiesUrl.toURI(), apiKeyId, secretApiKey);
return Factory.createClient(configuration);
}
Aggregations