libresolver/src/types.ts

32 lines
471 B
TypeScript
Raw Normal View History

2022-08-18 14:49:10 +00:00
export interface ResolverOptions {
type: any;
customType?: string;
2022-08-18 15:11:53 +00:00
options?: any;
2022-08-18 14:49:10 +00:00
}
export interface DNSResult {
records: any[];
error?: Error;
}
export interface DNSRecord {
type: string;
customType?: string;
value: string;
}
const DNS_RECORD_TYPE = {
2022-08-18 15:04:41 +00:00
DEFAULT: "DEFAULT",
2022-08-18 14:49:10 +00:00
A: "A",
CNAME: "CNAME",
NS: "NS",
CONTENT: "CONTENT",
TEXT: "TEXT",
ALL: "ALL",
CUSTOM: "CUSTOM",
};
Object.freeze(DNS_RECORD_TYPE);
export { DNS_RECORD_TYPE };