/** * create a new payment object * @param string $apikey your API key * @param int $projectId your project id */ public function __construct($configKey = '') { list($userId, $projectId, $apiKey) = explode(':', $configKey); $apiUrl = getenv('sofortApiUrl') != '' ? getenv('sofortApiUrl') : 'https://api.sofort.com/api/xml'; parent::__construct($userId, $apiKey, $apiUrl); $this->_parameters['project_id'] = $projectId; }
/** * Constructor for SofortLibIDealBanks * * @param string $configKey * @param string $apiUrl (optional) * @return \SofortLibIdealBanks */ public function __construct($configKey, $apiUrl = '') { $this->_rootTag = 'ideal'; if ($apiUrl == '') { $apiUrl = getenv('idealApiUrl') != '' ? getenv('idealApiUrl') . '/banks' : self::IDEAL_BANKS_URL; } parent::__construct($configKey, $apiUrl); }
/** * * Constructor for SofortLibDebit * @param string $configKey */ public function __construct($configKey = '') { list($userId, $projectId, $apiKey) = explode(':', $configKey); $apiUrl = getenv('debitApiUrl') != '' ? getenv('debitApiUrl') : 'https://www.sofort.com/payment/debitpay/xml'; parent::__construct($userId, $apiKey, $apiUrl); $this->setProjectId($projectId); $this->setDate(); //set date to today }
/** * * Constructor for SofortLibRefund * @param string $configKey */ public function __construct($configKey = '') { list($userId, $projectId, $apiKey) = explode(':', $configKey); $apiUrl = getenv('refundApiUrl') != '' ? getenv('refundApiUrl') : 'https://www.sofort.com/payment/refunds'; parent::__construct($userId, $apiKey, $apiUrl); }
/** * Constructor for SofortLibNotification */ public function __construct() { parent::__construct('', '', ''); }