From e9ff25387fc5089e85a6c1f0ddb146a9cc64b899 Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Thu, 18 Oct 2018 16:03:32 +0300 Subject: [PATCH 01/13] Update GetResponseAPI3.class.php enterprise domain --- src/GetResponseAPI3.class.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/GetResponseAPI3.class.php b/src/GetResponseAPI3.class.php index 2782e2f..f17e6ac 100644 --- a/src/GetResponseAPI3.class.php +++ b/src/GetResponseAPI3.class.php @@ -34,10 +34,14 @@ class GetResponse * @param $api_key * @param null $api_url */ - public function __construct($api_key, $api_url = null) + public function __construct($api_key, $api_url = null, $enterprise_domain = null) { $this->api_key = $api_key; + if (!empty($enterprise_domain)) { + $this->enterprise_domain = $enterprise_domain; + } + if (!empty($api_url)) { $this->api_url = $api_url; } @@ -403,4 +407,4 @@ private function setParams($params = array()) return http_build_query($result); } -} \ No newline at end of file +} From c0b3701be63986c4bfea29b125533ce72be3318b Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Thu, 18 Oct 2018 16:10:42 +0300 Subject: [PATCH 02/13] Update composer.json --- composer.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/composer.json b/composer.json index 3bd66e2..21f09c1 100644 --- a/composer.json +++ b/composer.json @@ -1,5 +1,5 @@ { - "name": "getresponse/getresponse", + "name": "funnyfox777/getresponse-api-php", "description": "GetResponse API v3 client library.", "version": "0.0.2", "homepage": "https://github.com/GetResponse/getresponse-api-php", @@ -23,4 +23,4 @@ "autoload": { "files": ["src/GetResponseAPI3.class.php"] } -} \ No newline at end of file +} From bf400816af960906c504baa34b34c6714567bf63 Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Thu, 18 Oct 2018 16:19:28 +0300 Subject: [PATCH 03/13] Update composer.json --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 21f09c1..4a343dd 100644 --- a/composer.json +++ b/composer.json @@ -2,7 +2,7 @@ "name": "funnyfox777/getresponse-api-php", "description": "GetResponse API v3 client library.", "version": "0.0.2", - "homepage": "https://github.com/GetResponse/getresponse-api-php", + "homepage": "https://github.com/funnyfox777/getresponse-api-php", "keywords": ["GetResponse", "api", "email"], "type": "library", "license": "MIT", From 09e054b3c66b530807f1294e191a6822d3365492 Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Thu, 18 Oct 2018 16:25:38 +0300 Subject: [PATCH 04/13] Update composer.json --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 4a343dd..f4eefa4 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "funnyfox777/getresponse-api-php", "description": "GetResponse API v3 client library.", - "version": "0.0.2", + "version": "1.0.0", "homepage": "https://github.com/funnyfox777/getresponse-api-php", "keywords": ["GetResponse", "api", "email"], "type": "library", From 2bc44851d94c4e06b980151eac385df200d102b8 Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Thu, 18 Oct 2018 16:26:40 +0300 Subject: [PATCH 05/13] Update composer.json --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index f4eefa4..69842c5 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "funnyfox777/getresponse-api-php", "description": "GetResponse API v3 client library.", - "version": "1.0.0", + "version": "1.0.1", "homepage": "https://github.com/funnyfox777/getresponse-api-php", "keywords": ["GetResponse", "api", "email"], "type": "library", From 8b89dba77bf256c21bb2fa790f7345ab8e3b78b2 Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Thu, 18 Oct 2018 16:48:39 +0300 Subject: [PATCH 06/13] Update GetResponseAPI3.class.php --- src/GetResponseAPI3.class.php | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/GetResponseAPI3.class.php b/src/GetResponseAPI3.class.php index f17e6ac..2a5d5de 100644 --- a/src/GetResponseAPI3.class.php +++ b/src/GetResponseAPI3.class.php @@ -14,6 +14,7 @@ class GetResponse private $api_key; private $api_url = 'https://api.getresponse.com/v3'; + private $api_url_enterprise = 'https://api3.getresponse360.com/v3'; private $timeout = 8; public $http_status; @@ -37,14 +38,14 @@ class GetResponse public function __construct($api_key, $api_url = null, $enterprise_domain = null) { $this->api_key = $api_key; - - if (!empty($enterprise_domain)) { - $this->enterprise_domain = $enterprise_domain; - } if (!empty($api_url)) { $this->api_url = $api_url; } + + if (!empty($enterprise_domain)) { + $this->enterprise_domain = $enterprise_domain; + } } /** @@ -352,7 +353,7 @@ private function call($api_method = null, $http_method = 'GET', $params = array( } $params = json_encode($params); - $url = $this->api_url . '/' . $api_method; + $url = ($this->enterprise_domain ? $this->api_url_enterprise : $this->api_url) . '/' . $api_method; $options = array( CURLOPT_URL => $url, @@ -367,6 +368,7 @@ private function call($api_method = null, $http_method = 'GET', $params = array( if (!empty($this->enterprise_domain)) { $options[CURLOPT_HTTPHEADER][] = 'X-Domain: ' . $this->enterprise_domain; + } if (!empty($this->app_id)) { From 128acdb21856f7ced3883c7703aa0d0f1fd2ee5d Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Thu, 18 Oct 2018 16:51:19 +0300 Subject: [PATCH 07/13] Update composer.json --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 69842c5..d481b5f 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "funnyfox777/getresponse-api-php", "description": "GetResponse API v3 client library.", - "version": "1.0.1", + "version": "1.0.3", "homepage": "https://github.com/funnyfox777/getresponse-api-php", "keywords": ["GetResponse", "api", "email"], "type": "library", From 4726285a9469a8f0aaad5cd098f06010b046c4fb Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Tue, 23 Oct 2018 11:44:43 +0300 Subject: [PATCH 08/13] change api url enterprise change api url enterprise --- src/GetResponseAPI3.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/GetResponseAPI3.class.php b/src/GetResponseAPI3.class.php index 2a5d5de..bec0ba5 100644 --- a/src/GetResponseAPI3.class.php +++ b/src/GetResponseAPI3.class.php @@ -14,7 +14,7 @@ class GetResponse private $api_key; private $api_url = 'https://api.getresponse.com/v3'; - private $api_url_enterprise = 'https://api3.getresponse360.com/v3'; + private $api_url_enterprise = 'https://api3.getresponse360.pl/v3'; private $timeout = 8; public $http_status; From 8079ac351b49ab5da9dc7f1993ba9c0f21390b96 Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Tue, 23 Oct 2018 12:01:37 +0300 Subject: [PATCH 09/13] Update composer.json --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index d481b5f..964d25f 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "funnyfox777/getresponse-api-php", "description": "GetResponse API v3 client library.", - "version": "1.0.3", + "version": "1.0.4", "homepage": "https://github.com/funnyfox777/getresponse-api-php", "keywords": ["GetResponse", "api", "email"], "type": "library", From a2f03346395e0b3a60f3b4c4c5488632f312da59 Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Tue, 23 Oct 2018 12:04:09 +0300 Subject: [PATCH 10/13] change api url enterprise change api url enterprise --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 964d25f..df48ebb 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "funnyfox777/getresponse-api-php", "description": "GetResponse API v3 client library.", - "version": "1.0.4", + "version": "1.0.5" "homepage": "https://github.com/funnyfox777/getresponse-api-php", "keywords": ["GetResponse", "api", "email"], "type": "library", From 94458c3800120f585e1ffc1a7f8c4a0a319948b8 Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Tue, 23 Oct 2018 12:07:12 +0300 Subject: [PATCH 11/13] syntax --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index df48ebb..6bdd7da 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "funnyfox777/getresponse-api-php", "description": "GetResponse API v3 client library.", - "version": "1.0.5" + "version": "1.0.5", "homepage": "https://github.com/funnyfox777/getresponse-api-php", "keywords": ["GetResponse", "api", "email"], "type": "library", From 3dbe29d5b073b7aa47cc28ec0004d3c8c955048e Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Tue, 23 Oct 2018 14:00:11 +0300 Subject: [PATCH 12/13] Update GetResponseAPI3.class.php --- src/GetResponseAPI3.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/GetResponseAPI3.class.php b/src/GetResponseAPI3.class.php index bec0ba5..98bde28 100644 --- a/src/GetResponseAPI3.class.php +++ b/src/GetResponseAPI3.class.php @@ -1,6 +1,6 @@ From 95555beb4227c9cf06446cedad4dc1b24a40e6b0 Mon Sep 17 00:00:00 2001 From: funnyfox777 <30665468+funnyfox777@users.noreply.github.com> Date: Tue, 23 Oct 2018 14:27:14 +0300 Subject: [PATCH 13/13] Update GetResponseAPI3.class.php --- src/GetResponseAPI3.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/GetResponseAPI3.class.php b/src/GetResponseAPI3.class.php index 98bde28..bec0ba5 100644 --- a/src/GetResponseAPI3.class.php +++ b/src/GetResponseAPI3.class.php @@ -1,6 +1,6 @@