Skip to main content
POST
/
v1
/
parentdomains
/
{parentDomain}
/
buy
Purchases and sets up a parent domain for use with ens subdomains
curl --request POST \
  --url https://api.superlink.me/v1/parentdomains/{parentDomain}/buy \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "domainContactDetails": {
    "address1": "15 Church St",
    "address2": "Door 25, The building",
    "city": "New York",
    "country": "US",
    "email": "nora.miller@gmail.com",
    "nameFirst": "Nora",
    "nameLast": "Miller",
    "phoneCountryCode": "+1",
    "phoneNumber": "1234123412",
    "postalCode": "12345",
    "state": "CA"
  }
}
'
import requests

url = "https://api.superlink.me/v1/parentdomains/{parentDomain}/buy"

payload = { "domainContactDetails": {
"address1": "15 Church St",
"address2": "Door 25, The building",
"city": "New York",
"country": "US",
"email": "nora.miller@gmail.com",
"nameFirst": "Nora",
"nameLast": "Miller",
"phoneCountryCode": "+1",
"phoneNumber": "1234123412",
"postalCode": "12345",
"state": "CA"
} }
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
domainContactDetails: {
address1: '15 Church St',
address2: 'Door 25, The building',
city: 'New York',
country: 'US',
email: 'nora.miller@gmail.com',
nameFirst: 'Nora',
nameLast: 'Miller',
phoneCountryCode: '+1',
phoneNumber: '1234123412',
postalCode: '12345',
state: 'CA'
}
})
};

fetch('https://api.superlink.me/v1/parentdomains/{parentDomain}/buy', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.superlink.me/v1/parentdomains/{parentDomain}/buy",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'domainContactDetails' => [
'address1' => '15 Church St',
'address2' => 'Door 25, The building',
'city' => 'New York',
'country' => 'US',
'email' => 'nora.miller@gmail.com',
'nameFirst' => 'Nora',
'nameLast' => 'Miller',
'phoneCountryCode' => '+1',
'phoneNumber' => '1234123412',
'postalCode' => '12345',
'state' => 'CA'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://api.superlink.me/v1/parentdomains/{parentDomain}/buy"

payload := strings.NewReader("{\n \"domainContactDetails\": {\n \"address1\": \"15 Church St\",\n \"address2\": \"Door 25, The building\",\n \"city\": \"New York\",\n \"country\": \"US\",\n \"email\": \"nora.miller@gmail.com\",\n \"nameFirst\": \"Nora\",\n \"nameLast\": \"Miller\",\n \"phoneCountryCode\": \"+1\",\n \"phoneNumber\": \"1234123412\",\n \"postalCode\": \"12345\",\n \"state\": \"CA\"\n }\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("Authorization", "<api-key>")
req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://api.superlink.me/v1/parentdomains/{parentDomain}/buy")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"domainContactDetails\": {\n \"address1\": \"15 Church St\",\n \"address2\": \"Door 25, The building\",\n \"city\": \"New York\",\n \"country\": \"US\",\n \"email\": \"nora.miller@gmail.com\",\n \"nameFirst\": \"Nora\",\n \"nameLast\": \"Miller\",\n \"phoneCountryCode\": \"+1\",\n \"phoneNumber\": \"1234123412\",\n \"postalCode\": \"12345\",\n \"state\": \"CA\"\n }\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.superlink.me/v1/parentdomains/{parentDomain}/buy")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"domainContactDetails\": {\n \"address1\": \"15 Church St\",\n \"address2\": \"Door 25, The building\",\n \"city\": \"New York\",\n \"country\": \"US\",\n \"email\": \"nora.miller@gmail.com\",\n \"nameFirst\": \"Nora\",\n \"nameLast\": \"Miller\",\n \"phoneCountryCode\": \"+1\",\n \"phoneNumber\": \"1234123412\",\n \"postalCode\": \"12345\",\n \"state\": \"CA\"\n }\n}"

response = http.request(request)
puts response.read_body
This response has no body data.
{
"errors": [
{
"field": "field",
"info": "error message"
}
]
}
{
"errors": [
{
"field": "field",
"info": "error message"
}
]
}
{
"message": "Internal server error"
}

Authorizations

Authorization
string
header
required

Type "Bearer" followed by a space and the JWT token.

Path Parameters

parentDomain
string
required

superlink.me

Body

application/json

purchase parent domain

domainContactDetails
object

Response