public function sendData($data)
{
$url = sprintf('%s?%s', $this->getEndpoint(), http_build_query($this->getData()));
$result = $this->httpClient->get($url)->send()->getBody();
$xml = simplexml_load_string($result);
$json = json_encode($xml);
$data = json_decode($json, true);
return $this->response = new LegacyQueryResponse($this, $data);
}