public function createRecord(Zone $zone, ParameterBag $parameters)
 {
     $res = false;
     $domain = $zone->getDomain();
     $info = Transip_DomainService::getInfo($domain);
     $recList = $info->dnsEntries;
     $tmpRec = $this->formatRecord($parameters);
     $recList[] = new Transip_DnsEntry($tmpRec['name'], $tmpRec['ttl'], $tmpRec['type'], $tmpRec['data']);
     Transip_DomainService::setDnsEntries($domain, $recList);
     $res = true;
     return $res;
 }
 public function getRecord(Zone $zone, $recordId)
 {
     try {
         $recordId = explode(':', $recordId);
         $response = $this->httpClient->get("domains/{$zone->getDomain()}/records/{$recordId[1]}/{$recordId[0]}");
         if ($response->getStatusCode() == 200) {
             return $this->toRecord(json_decode($response->getBody(), true)[0], $zone);
         }
     } catch (\Exception $e) {
     }
 }