src/AbstractHttpClient.php
private function request($method, $path)
    {
        $modifiedClient = $this->applyModifiers([
            'method'      => $method,
            'path'        => $path,
            'form_params' => $this->getFormParameters(),
            'multiplart'  => $this->getMultipart(),
            'query'       => $this->getQuery(),
            'json'        => $this->getJson(),
            'headers'     => $this->getHeaders(),
        ]);

        $modifiedClient->setHeaders($this->getHeaders());

        $client = $modifiedClient->getHttpClient();

        $request = new Request(
            $method,
            $this->buildRequestUri($modifiedClient->options['base_uri'], $path),
            $modifiedClient->headers
        );

        try {
            $response = $client->send($request, $modifiedClient->body);
        } catch (ClientException $e) {
            return $this->requestErrorHandler->handle($e);
        }

        return $modifiedClient->handleResponse($response->getBody());
    }
private function request($method, $path)
    {
        $modifiedClient = $this->applyModifiers([
            'method'      => $method,
            'path'        => $path,
            'form_params' => $this->getFormParameters(),
            'multiplart'  => $this->getMultipart(),
            'query'       => $this->getQuery(),
            'json'        => $this->getJson(),
            'headers'     => $this->getHeaders(),
        ]);

        $modifiedClient->setHeaders($this->getHeaders());

        $client = $modifiedClient->getHttpClient();

        $request = new Request(
            $method,
            $this->buildRequestUri($modifiedClient->options['base_uri'], $path),
            $modifiedClient->headers
        );

        try {
            $response = $client->send($request, $modifiedClient->body);
        } catch (ClientException $e) {
            return $this->requestErrorHandler->handle($e);
        }

        return $modifiedClient->handleResponse($response->getBody());
    }
@param $method
@param $path

@return mixed