public static function auth($params = array()) { $params['api'] = 'checkout'; $request = new Twocheckout_Api_Requester(); $result = $request->doCall('/checkout/api/1/' . self::$sid . '/rs/authService', $params); return Twocheckout_Util::returnResponse($result); }
public static function delete($params = array()) { $request = new Twocheckout_Api_Requester(); $urlSuffix = '/api/products/delete_option'; $result = $request->doCall($urlSuffix, $params); return Twocheckout_Util::returnResponse($result); }
public static function delete($params = array(), $format = 'json') { $request = new Twocheckout_Api_Requester(); $urlSuffix = 'products/delete_coupon'; $result = $request->do_call($urlSuffix, $params); return Twocheckout_Util::return_resp($result, $format); }
public static function retrieve() { $request = new Twocheckout_Api_Requester(); $urlSuffix = '/api/acct/detail_contact_info'; $result = $request->doCall($urlSuffix); return Twocheckout_Util::returnResponse($result); }
public static function retrieve($format = 'json') { $request = new Twocheckout_Api_Requester(); $urlSuffix = 'acct/detail_contact_info'; $result = $request->do_call($urlSuffix); return Twocheckout_Util::return_resp($result, $format); }
public static function pending() { $request = new Twocheckout_Api_Requester(); $urlSuffix = '/api/acct/detail_pending_payment'; $result = $request->doCall($urlSuffix); $response = Twocheckout_Util::returnResponse($result); return $response; }
public static function pending($format = 'json') { $request = new Twocheckout_Api_Requester(); $urlSuffix = 'acct/detail_pending_payment'; $result = $request->do_call($urlSuffix); $response = Twocheckout_Util::return_resp($result, $format); return $response; }
public function check($insMessage, $secretWord, $format = 'json') { $hashSid = $insMessage['vendor_id']; $hashOrder = $insMessage['sale_id']; $hashInvoice = $insMessage['invoice_id']; $StringToHash = strtoupper(md5($hashOrder . $hashSid . $hashInvoice . $secretWord)); if ($StringToHash != $insMessage['md5_hash']) { $result = Twocheckout_Message::message('Fail', 'Hash Mismatch'); } else { $result = Twocheckout_Message::message('Success', 'Hash Matched'); } return Twocheckout_Util::return_resp($result, $format); }
public static function check($params = array(), $secretWord, $format = 'json') { $hashSecretWord = $secretWord; $hashSid = $params['sid']; $hashTotal = $params['total']; $hashOrder = $params['order_number']; $StringToHash = strtoupper(md5($hashSecretWord . $hashSid . $hashOrder . $hashTotal)); if ($StringToHash != $params['key']) { $result = Twocheckout_Message::message('Fail', 'Hash Mismatch'); } else { $result = Twocheckout_Message::message('Success', 'Hash Matched'); } return Twocheckout_Util::return_resp($result, $format); }
public static function check($params = array(), $secretWord) { $hashSecretWord = $secretWord; $hashSid = $params['sid']; $hashTotal = $params['total']; //Two checkout uses order number as 1 in test orders for generating hash $hashOrder = 'Y' == $params['demo'] ? 1 : $params['order_number']; $StringToHash = strtoupper(md5($hashSecretWord . $hashSid . $hashOrder . $hashTotal)); if ($StringToHash != $params['key']) { $result = Twocheckout_Message::message('Fail', 'Hash Mismatch'); } else { $result = Twocheckout_Message::message('Success', 'Hash Matched'); } return Twocheckout_Util::returnResponse($result); }
public static function reauth($params = array(), $format = 'json') { $request = new Twocheckout_Api_Requester(); $urlSuffix = 'sales/reauth'; $result = $request->do_call($urlSuffix, $params); return Twocheckout_Util::return_resp($result, $format); }
function tcheckout_is_subscription_cancel($profile_id) { $this->set_gateway_param(); $result = $this->tcheckout_get_profile_detail($profile_id); $lineitems = Twocheckout_Util::getRecurringLineitems($result); if ($result['response_code'] == 'OK' && empty($lineitems)) { return true; } return false; }
public static function reauth($params = array()) { $request = new Twocheckout_Api_Requester(); $urlSuffix = '/api/sales/reauth'; $result = $request->doCall($urlSuffix, $params); return Twocheckout_Util::returnResponse($result); }
public static function auth($params = array()) { $request = new Twocheckout_Requester(); $result = $request->do_call($params); return Twocheckout_Util::return_resp($result); }