// public string DnsRecordName { get; set; }
// public string DnsRecordType { get; set; }
// public string DnsRecordValue { get; set; }
/// <summary>
/// Returns all records up to 100 at a time, starting with the
/// one with the optional name and/or type, sorted in lexical
/// order by name (with labels reversed) then by type.
/// </summary>
public async Task <ListResourceRecordSetsResponse> GetRecords(
string startingDnsName, string startingDnsType = null)
{
#pragma warning disable 618 // "'StoredProfileCredentials' is obsolete..."
var crd = StoredProfileCredentials.GetProfile(AwsProfileName);
#pragma warning restore 618
var cfg = new AmazonRoute53Config
{
RegionEndpoint = RegionEndpoint.USEast1,
};
var reg = RegionEndpoint.GetBySystemName(AwsRegion);
using (var r53 = new Amazon.Route53.AmazonRoute53Client(crd, cfg))
{
var rrRequ = new Amazon.Route53.Model.ListResourceRecordSetsRequest
{
HostedZoneId = HostedZoneId,
StartRecordName = startingDnsName,
StartRecordType = startingDnsType,
};
var rrResp = await r53.ListResourceRecordSetsAsync(rrRequ);
return(rrResp);
}
}