The DNS API allows you to manage your DNS zones and records.
A domain name is an identification string that defines a realm of administrative autonomy, authority or control within the Internet. Domain names are formed by the rules and procedures of the Domain Name System (DNS). Any name registered in the DNS is a domain name.
Domains are further divided into sub-domains, each becoming a DNS zone itself with its own set of administrators and DNS servers.
The term domain is used in the business functions of the entity assigned to it and the term zone is usually used for configuration of DNS services.
example.com is the domain
and has only one owner who can manage it.
By default, the domain only has a root zone (no sub domain).
example.com zone
allows the configuration of records such as:
If we add a DNS zone to the sub domain dev.example.com, we get:
In the simplest case you will only need the root zone.
But multiple zones (i.e. sub-domains) allow:
templates
Remark: to be RFC compliant, each zone will automatically have NS records added.
An internationalized domain name (IDN) is an Internet domain name that contains at least one label that is displayed in software applications, which is in whole or in part in a language-specific script or alphabet, such as Arabic, Chinese, Cyrillic, Tamil, Hebrew or the Latin alphabet-based characters with diacritics or ligatures, such as French. These writing systems are encoded by computers in multi-byte Unicode. Internationalized domain names are stored in the Domain Name System as ASCII strings using Punycode transcription.
Example: allélua.com
converted in IDN is xn--alllua-dva.com
.
To simplify its use, the DNS API uses unicode
(UTF-8
) for name and data fields.
Login to your Scaleway account and create a token from the credentials
page. A secret_key
and an access_key
will be displayed on your screen, the
secret_key
will be used as X-Auth-Token
.
Reference: https://www.scaleway.com/docs/generate-an-api-token/
The organization id is required to get the permissions. You will need to query:
To get your organization id:
Reference: https://www.scaleway.com/docs/retrieve-my-organization-id-throught-the-api/
To use Scaleway DNS to manage your Domain, you need to register your Domain with:
You will then have 48h to set up a TXT record to confirm the ownership of the Domain:
_scaleway-challenge
Upon validation you will receive a confirmation email and the Domain will be available on the API.
You will then have to update your DNS nameservers to Scaleway DNS servers: ns0.dom.scw.cloud
and ns1.dom.scw.cloud
.
Your domain's DNSSEC needs to be set up on the registry by your registrar and on the DNS server with the same information. If need: remove your DNSSEC settings on your registrar before migrating to our service. You will be able to re-setup if after.
To set up the DNSSEC:
EnableDomainDNSSEC
to generate the setup on the DNS serversexample.com
, name test.example.com.
will be converted to test
Remarks:
clear
operation clears all the records (thus allows to restart from scratch)For external domain:
You will have to set in your registrar the DS
returned in the result:
Call the API with the right settings:
We provide the classic record types (A
, AAAA
, CNAME
...) along with some dynamic records. At the moment the following dynamic records are supported: http(s) health checks and views.
This will test if a (http/https) service is up on a provided list of IPs.
An IP is considered healthy if the query response contains the text specified in must_contain
.
The Record Type can be one of:
View will give responses depending on the requester (or resolver) IP.
Record Type can be:
Returns a list of manageable DNS zones. You can filter the DNS zones by domain name.
domain_asc
, domain_desc
, subdomain_asc
and subdomain_desc
. The default value is domain_asc
.Create a new DNS zone.
Update the name and/or the organizations for a DNS zone.
Delete a DNS zone and all it's records.
Clone an existed DNS zone with all its records into a new one.
Refresh SOA DNS zone. You can recreate the given DNS zone and its sub DNS zone if needed.
Get the DNS zone TSIG Key to allow AXFR request.
Returns a list of Nameservers and their optional glue records for a DNS zone.
Update DNS zone nameservers and set optional glue records.
Returns a list of DNS records of a DNS zone with default NS. You can filter the records by type and name.
name_asc
and name_desc
. The default value is name_asc
.unknown
, A
, AAAA
, CNAME
, TXT
, SRV
, TLSA
, MX
, NS
, PTR
, CAA
, ALIAS
, LOC
, SSHFP
, HINFO
, RP
, URI
, DS
, NAPTR
and DNAME
. The default value is unknown
.Only available with default NS.
Send a list of actions and records.
Action can be:
All edits will be versioned.
Only available with default NS.
Delete all the records from a DNS zone.
All edits will be versioned.
Get a list of DNS zone versions.
The maximum version count is 100.
If the count reaches this limit, the oldest version will be deleted after each new modification.
Get a list of records from a previous DNS zone version.
Get all differences from a previous DNS zone version.
Restore and activate a previous DNS zone version.
Import and replace records from a given provider format with default NS.
Get a DNS zone in a given format with default NS.
Import and replace records from a given provider format with default NS.
unknown_raw_format
and bind
. The default value is unknown_raw_format
.