WEDOS REST API is still in development. Access and features may change without notice.
This article partially covers the Domains endpoint of WEDOS REST API. Domains and Domain contacts have their own articles. For WEDOS API (WAPI) see WAPI – WEDOS Domains.
For basic information anbout WEDOS REST API, consult the WEDOS REST API Manual.
In this article, you will find the following information:
- DNS Endpoint access
- DNS Endpoint details:
- Notes
NSSETs Endpoint Access
An NSSET is a named set of DNS servers that can be managed on its own and assigned to several domains at once (used mainly for .cz domains). This API covers NSSET management under the /v2/nssets URL prefix.
Base URL and Authentication
The base URL for the NSSETs endpoints is: https://api.wedos.com/v2
All communication runs over HTTPS, and authentication uses only OAuth2: send the header Authorization: Bearer <TOKEN> with every request. The token must have the domains scope (one shared scope for domains, contacts and NSSETs). Without valid authentication the API returns an error.
Data requests (POST/PATCH) are sent as JSON (Content-Type: application/json).
You can add the parameter example=1 to any endpoint (e.g. ?example=1, or &example=1 if the URL already contains other query parameters). Instead of executing the request, the API then returns a sample curl command for that call. Valid authentication is required even in this mode.
Endpoint Overview
| Method | Endpoint | Description |
|---|---|---|
| GET | /nssets/check | Check availability/existence of an NSSET |
| GET | /nssets/{name} | NSSET information |
| POST | /nssets | Create an NSSET |
| POST | /nssets/{name}/transfer | Transfer an NSSET |
| POST | /nssets/{name}/auth-info/send | Send the NSSET’s authorization code |
| PATCH | /nssets/{name} | Modify an NSSET |
Response format
The API response is always a JSON object with the keys code (return code), msg (text description), request_id (request identifier) and, where applicable, data (returned data on success).
Besides the specific (business) return codes listed for each call below, all endpoints may also return these general REST-layer codes:
1000– the request was executed successfully2000– authentication (OAuth2 Bearer token) missing or invalid2004– maximum allowed request size exceeded (URL or request body)4000– unknown/unsupported API method or action4001– input data validation failed4005– no example defined for the current URL form inexample=1mode6000– internal error initializing request processing
GET /nssets/check
Checks whether an NSSET handle is free to use and what its status is at the registry.
Parameters:
tld– required, query, string – TLD for which the NSSET is checkedname– required, query, string – NSSET handlereg_key– optional, query, string – identifier of a specific registry
Return codes:
1000– the NSSET is available for registration2100– required parameter missing2101– invalid input parameters2201– invalid TLD2247– unsupported NSSET format3242– the NSSET is unavailable3245– the NSSET is already registered3248– NSSET unavailable – quarantine3249– NSSET unavailable – reserved3250– NSSET unavailable – blocked3251– the NSSET is already registered with us4218– check failed – communication error5001– internal authentication error
Response data: None – the result is carried directly by the response’s code/msg.
Example:
curl -X GET -H 'Authorization: Bearer <TOKEN>' \
'https://api.wedos.com/v2/nssets/check?tld=cz&name=NSSET'
{
"code": 1000,
"msg": "OK",
"request_id": "a1b2c3g1"
}
GET /nssets/{name}
Returns detailed information about an NSSET, including its DNS servers.
Parameters:
name– required, path – NSSET handletld– required, query, string – TLDreg_key– optional, query, string – identifier of a specific registry
Return codes:
1000– OK2100– required parameter missing2101– invalid input parameters2201– invalid TLD2209– syntax error2247– unsupported NSSET format3214– failed to load the NSSET3242– the NSSET is unavailable4204– connection error
Response data:
nsset– object with NSSET details:name– NSSET handlestatus– NSSET status at the registryreg_owner,reg_creator,reg_update– registrar identifierscreated_date,updated_date,transfer_date– creation/update/transfer datestech_c– technical contact identifierdns.server– array of the NSSET’s DNS servers (name,addr_ipv4,addr_ipv6)
Example:
curl -X GET -H 'Authorization: Bearer <TOKEN>' \
'https://api.wedos.com/v2/nssets/NSSET?tld=cz'
{
"code": 1000,
"msg": "OK",
"request_id": "a1b2c3g2",
"data": {
"nsset": {
"name": "NSSET",
"status": "ok",
"tech_c": "CONTACT",
"created_date": "2024-01-10",
"dns": {
"server": [
{ "name": "ns.wedos.com", "addr_ipv4": null, "addr_ipv6": null },
{ "name": "ns.wedos.org", "addr_ipv4": null, "addr_ipv6": null }
]
}
}
}
}
POST /nssets
Creates a new NSSET.
Parameters:
tld– required, string – TLD for which the NSSET is createdname– optional, string – requested NSSET handle; if not given, it is generated automaticallydns– required, array – array of DNS servers in the form[{"name":"ns1.example.com","addr_ipv4":"1.2.3.4","addr_ipv6":"..."},...](addr_ipv4/addr_ipv6are optional for each server; same form as in POST /domains/create)tech_c– optional, string – technical contact identifier; if not given, the default is usedreg_key– optional, string – identifier of a specific registry
Return codes:
1000– OK, NSSET created2100– required parameter missing2101– invalid input parameter format2201– incorrectly specified TLD2210– invalid DNS server array format2211– too many DNS servers2216– invalid contact syntax2247– unsupported NSSET format3228– the registry does not support contacts3229– error loading the contact3242– the NSSET is unavailable3244– NSSET creation failed3245– the NSSET is already registered4212– connection error4218,4219– check/creation failed – communication error
Response data:
nsset– handle of the created NSSET
Example:
curl -X POST -H 'Authorization: Bearer <TOKEN>' -H 'Content-Type: application/json' \
'https://api.wedos.com/v2/nssets' \
--data '{
"tld": "cz",
"dns": [
{ "name": "ns.wedos.com" },
{ "name": "ns.wedos.org" }
]
}'
{
"code": 1000,
"msg": "OK",
"request_id": "a1b2c3g3",
"data": {
"nsset": "NSSET"
}
}
POST /nssets/{name}/transfer
Transfers an NSSET to us from another registrar.
Parameters:
name– required, path – NSSET handletld– required, string – TLDauth_info– required, string – the NSSET’s authorization codereg_key– optional, string – identifier of a specific registry
Return codes:
1000– OK2100– required parameter missing2101– invalid input parameters2201– unsupported TLD2215–auth_infomissing2247– invalid NSSET name2249– NSSET transfer is not allowed for this TLD3214– failed to load the NSSET3242– NSSET not supported3251– the NSSET is already registered with the target registrar3255– authorization error3256– NSSET transfer failed4221– transfer failed – connection error
Response data: None – the result is carried directly by the response’s code/msg.
Example:
curl -X POST -H 'Authorization: Bearer <TOKEN>' -H 'Content-Type: application/json' \
'https://api.wedos.com/v2/nssets/NSSET/transfer' \
--data '{"tld": "cz", "auth_info": "AUTHCODE123"}'
{
"code": 1000,
"msg": "OK",
"request_id": "a1b2c3g4"
}
POST /nssets/{name}/auth-info/send
Sends the NSSET’s authorization code to the technical contact’s e-mail.
Parameters:
name– required, path – NSSET handletld– required, string – TLDreg_key– optional, string – identifier of a specific registry
Return codes:
1000– OK, authorization code sent to the contact e-mail2100– required parameter missing2101– invalid input parameters2201– unsupported TLD2243– sending the authorization code is not allowed for this NSSET3214– failed to load the NSSET3217– sending the authorization code failed3242– the NSSET is unavailable4222– sending failed – connection error5001– internal authorization error
Response data: None – the result is carried directly by the response’s code/msg.
Example:
curl -X POST -H 'Authorization: Bearer <TOKEN>' -H 'Content-Type: application/json' \
'https://api.wedos.com/v2/nssets/NSSET/auth-info/send' \
--data '{"tld": "cz"}'
{
"code": 1000,
"msg": "OK",
"request_id": "a1b2c3g5"
}
PATCH /nssets/{name}
Modifies an existing NSSET – its DNS servers, technical contact, or test scope.
Parameters:
name– required, path – NSSET handletld– required, string – TLDdns– required, array – array of DNS servers in the same form as in POST /nssetsauth_info– required, string – the NSSET’s authorization codetech_c– optional, string – technical contact identifier; if not given, it stays unchangedreg_key– optional, string – identifier of a specific registryreport_level– optional – scope of the tests the registry performs during the modification
Return codes:
1000– OK2100– required parameter missing2101– invalid input parameters2201– incorrectly specified TLD2209– syntax error2210– invalid DNS server array format2211– too many DNS servers2216– invalid contact syntax2247– invalid NSSET3214– failed to load the NSSET3242– the NSSET is not supported by this domain/registry3252– authorization error3254– NSSET modification failed4204,4220– NSSET unavailable/modification failed – connection error4212– contact unavailable – connection error
Response data: None – the result is carried directly by the response’s code/msg.
Example:
curl -X PATCH -H 'Authorization: Bearer <TOKEN>' -H 'Content-Type: application/json' \
'https://api.wedos.com/v2/nssets/NSSET-1' \
--data '{
"tld": "cz",
"auth_info": "AUTHCODE123",
"dns": [
{ "name": "ns.wedos.com" },
{ "name": "ns.wedos.org" }
]
}'
{
"code": 1000,
"msg": "OK",
"request_id": "a1b2c3g6"
}
Notes
- The endpoints under
/v2/domains,/v2/contactsand/v2/nssetsare handled by one shared server class and all share one OAuth2 scope,domains. From the client’s point of view, they are three logically separate but administratively unified APIs. - The
dnsparameter is given as a plain array of objects{"name": "...", "addr_ipv4": "...", "addr_ipv6": "..."}. Internally, it is converted to the legacy format used by older API versions before the WAPI call. Theaddr_ipv4andaddr_ipv6items are optional for each server. - For NSSETs,
tldis always a required parameter, because the same handle (name) may in theory exist at several registries, and the validation/format of the data differs by TLD/registry.
