Implementation of a client to freenom.com for obtaining information on registered domains, as well as managing DNS records of these domains.
- Get list zones (domains) with information registered in account
- Get dns records from zone
- Remove dns record from zone
- Add dns record to zone
For use client you only needed install package:
Install-Package Skidbladnir.Client.Freenom.Dns
Creating client, authenticate and get list zones:
public async Task Main(){
var dnsClient = FreenomClientFactory.Create();
if(!(await dnsClient.IsAuthenticated()))
await dnsClient.SignIn(Email, Password);
var zones = await dnsClient.GetZones();
Console.WriteLine("===========Zones============");
foreach (var zone in zones)
{
Console.WriteLine(
$"Zone: {zone.ZoneId} \t {zone.Name} \t {zone.ExpireDate} \t {zone.RegistrationDate} \t {zone.Status} \t {zone.Type}\n");
}
}