mirror of
				https://github.com/StackExchange/dnscontrol.git
				synced 2025-10-27 22:48:27 +08:00 
			
		
		
		
	
		
			
				
	
	
		
			32 lines
		
	
	
	
		
			732 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
			
		
		
	
	
			32 lines
		
	
	
	
		
			732 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
| interface Domain {
 | |
|     name: string;
 | |
|     subdomain: string;
 | |
|     registrar: unknown;
 | |
|     meta: Record<string, unknown>;
 | |
|     records: DNSRecord[];
 | |
|     dnsProviders: Record<string, unknown>;
 | |
|     defaultTTL: number;
 | |
|     nameservers: unknown[];
 | |
|     ignored_names: unknown[];
 | |
|     ignored_targets: unknown[];
 | |
|     [key: string]: unknown;
 | |
| }
 | |
| 
 | |
| interface DNSRecord {
 | |
|     type: string;
 | |
|     meta: Record<string, unknown>;
 | |
|     ttl: number;
 | |
| }
 | |
| 
 | |
| type DomainModifier =
 | |
|     | ((domain: Domain) => void)
 | |
|     | Partial<Domain>
 | |
|     | DomainModifier[];
 | |
| 
 | |
| type RecordModifier =
 | |
|     | ((record: DNSRecord) => void)
 | |
|     | Partial<DNSRecord['meta']>;
 | |
| 
 | |
| type Duration =
 | |
|     | `${number}${'s' | 'm' | 'h' | 'd' | 'w' | 'n' | 'y' | ''}`
 | |
|     | number /* seconds */;
 |