diff --git a/src/FusionDirectory/Rest/WebServiceCall.php b/src/FusionDirectory/Rest/WebServiceCall.php index dcd6d512147bf821224cf84e2cd1ba636562e261..232e8553a3b9bf07fcd0330f1d29079c337885d0 100644 --- a/src/FusionDirectory/Rest/WebServiceCall.php +++ b/src/FusionDirectory/Rest/WebServiceCall.php @@ -198,5 +198,22 @@ class WebServiceCall curl_close($this->ch); return $response; } + + /** + * @return array + * @throws Exception + */ +public function execute(): array +{ + $this->setCurlSettings(); + $response = curl_exec($this->ch); + $this->handleCurlError($this->ch); + + $decoded = json_decode($response, true); + curl_close($this->ch); + + return $decoded; +} + }