DNS Records

A DNSRecord is a custom DNS configuration record for a Site.

They represent the records you will need to configure in your DNS hosting provider to allow custom domains to work with Files.com.

Show Site DNS Configuration

SDK Function

DnsRecord.list()

Return Object

ListIterator<DnsRecord>

Authorization Requirement

Requires either a Site-Wide API key or User API key or session from a User with Site Admin permissions.

Additional Arguments

Example Request

import com.files.ListIterator;
import com.files.exceptions.*;
import com.files.exceptions.ApiErrorException.*;
import com.files.models.DnsRecord;

try {
  HashMap<String, Object> parameters = new HashMap<>();
  ListIterator<DnsRecord> dnsRecords = DnsRecord.list(parameters);
  for (DnsRecord dnsRecord : dnsRecords.listAutoPaging()) {
    // Operate on dnsRecord
  }
} catch (NotAuthenticatedException e) {
  System.out.println("Authentication Error Occurred (" + e.getClass().getName() + "): " + e.getMessage());
} catch (SdkException e) {
  System.out.println("Unknown Error Occurred (" + e.getClass().getName() + "): " + e.getMessage());
}

The DnsRecord Object

Some of the functions above return a DnsRecord object. The attributes of this object are listed below.

AttributeDescription
id
string
Unique label for DNS record; used by Zapier and other integrations.
domain
string
DNS record domain name
rrtype
string
DNS record type
value
string
DNS record value