Mythic Beasts

Primary domain name servers

All customers with domains hosted with Mythic Beasts can use our DNS servers to act as the primary DNS servers for their domain.

Control panel interface

The primary DNS service can be configured using the Customer Control Panel. The Primary DNS configuration is in the "Domains" section under "Manage DNS" for each of the domains. Here you can view the zone file and add, remove or update any of the records you require.

Automation interface

For users with a large number of domains, we also provide a simple HTTP-based API, allowing you to script addition and removal of dns entries. To use the API, you must set a password in the control panel interface for your domain that will be used to authenticate your requests, using the "DNS Password" option.

Request to the API take the form of HTTP POST requests containing a number of HTTP parameters. These are documented below. HTTP requests should be made to https://secure.mythic-beasts.com/control/fcgi/customer/primarydnsapi.

HTTP parameters

domain (required) The domain name you are updating the zonefile for, e.g. mythic-beasts.com

password (required) The password set in the control panel for the domain.

command (required) An API command. Commands take the form of a verb followed by a zone file entry as appropriate.

Commands

ADD This requests that an entry be added to the zone file, valid syntax for this command is


ADD host ttl type data
ADD host ttl MX mx_priority data
ADD host ttl SRV srv_priority srv_weight srv_port data
				

For example :


ADD www 86400 A 93.93.130.49
				

If successful, the response will contain ADD followed by the entry. Otherwise, the response will contain NADD followed by the entry and a reason that the update didn't succeed. For example:


NADD www 86400 A 93.93.130.49; Can't have multiple identical records
                

DELETE This requests that an entry be removed from the zone. Valid syntax for this command is


DELETE host ttl type data
DELETE host ttl MX mx_priority data
DELETE host ttl SRV srv_priority srv_weight srv_port data
                

For example :


DELETE www 86400 A 93.93.130.49
                

The response will contain DELETE followed by the entry in the event of success, and NDELETE followed by the entry and a reason in the event of failure.

LIST This command takes no arguments, and requests a list of all the entries in the zone. For example :


@ 86400 NS ns0.mythic-beasts.com. 
@ 86400 MX 10 mx2.mythic-beasts.com. 
@ 86400 A 93.93.130.44 
@ 86400 NS ns0.beasts.org. 
@ 86400 NS ns1.mythic-beasts.com. 
                

Sample API code


#!/usr/bin/perl -w

use WWW::Mechanize;

my $domain = 'mythic-beasts.com';
my $password = 'this-is-actually-a-secret';
my $url = 'https://secure.mythic-beasts.com/control/fcgi/customer/primarydnsapi';

my $mech = new WWW::Mechanize;
print "Zone\n\n";

my $zone = $mech->post($url,
        { domain => $domain, password => $password, command => 'LIST'
});
print $zone->content();

Copyright © 2000-2012 Mythic Beasts Ltd. All Rights Reserved.