Renew domain
curl --request POST \
--url https://rdp.sh/api/v1/domains/{domain}/renew \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '{
"years": 1
}'import requests
url = "https://rdp.sh/api/v1/domains/{domain}/renew"
payload = { "years": 1 }
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({years: 1})
};
fetch('https://rdp.sh/api/v1/domains/{domain}/renew', 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://rdp.sh/api/v1/domains/{domain}/renew",
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([
'years' => 1
]),
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://rdp.sh/api/v1/domains/{domain}/renew"
payload := strings.NewReader("{\n \"years\": 1\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://rdp.sh/api/v1/domains/{domain}/renew")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"years\": 1\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://rdp.sh/api/v1/domains/{domain}/renew")
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 \"years\": 1\n}"
response = http.request(request)
puts response.read_body{
"status": true,
"message": "Domain renewed",
"invoice_id": 8232,
"amount_charged": 14.28,
"years": 1,
"domain": {
"id": 1,
"domain_name": "example.com",
"status": "active",
"provider": "internetbs",
"auto_renew": true,
"whois_privacy": true,
"lock_status": true,
"use_rdp_nameservers": true,
"nameservers": "ns1.rdp.sh",
"registration_date": "2025-01-01T00:00:00.000000Z",
"expiry_date": "2027-01-01T00:00:00.000000Z",
"days_until_expiry": 180,
"is_expiring_soon": true,
"dns_records_count": 2,
"created_at": "2025-01-01T00:00:00.000000Z"
}
}{
"status": false,
"error": "Insufficient balance",
"required": 14.28,
"available": 5
}Domains
Renew Domain
Extend a domain’s registration and pay for it from the account balance.
Priced at renewal_price * years from the RDP.sh price list, plus 19%
VAT unless the account is VAT exempt. Extensions that are no longer in
the price list — and so never appear in GET /domains/pricing — fall
back to EUR 19.99 per year. The new expiry date is the old one plus
years, so renewing early never loses the remaining term.
POST
/
domains
/
{domain}
/
renew
Renew domain
curl --request POST \
--url https://rdp.sh/api/v1/domains/{domain}/renew \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '{
"years": 1
}'import requests
url = "https://rdp.sh/api/v1/domains/{domain}/renew"
payload = { "years": 1 }
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({years: 1})
};
fetch('https://rdp.sh/api/v1/domains/{domain}/renew', 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://rdp.sh/api/v1/domains/{domain}/renew",
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([
'years' => 1
]),
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://rdp.sh/api/v1/domains/{domain}/renew"
payload := strings.NewReader("{\n \"years\": 1\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://rdp.sh/api/v1/domains/{domain}/renew")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"years\": 1\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://rdp.sh/api/v1/domains/{domain}/renew")
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 \"years\": 1\n}"
response = http.request(request)
puts response.read_body{
"status": true,
"message": "Domain renewed",
"invoice_id": 8232,
"amount_charged": 14.28,
"years": 1,
"domain": {
"id": 1,
"domain_name": "example.com",
"status": "active",
"provider": "internetbs",
"auto_renew": true,
"whois_privacy": true,
"lock_status": true,
"use_rdp_nameservers": true,
"nameservers": "ns1.rdp.sh",
"registration_date": "2025-01-01T00:00:00.000000Z",
"expiry_date": "2027-01-01T00:00:00.000000Z",
"days_until_expiry": 180,
"is_expiring_soon": true,
"dns_records_count": 2,
"created_at": "2025-01-01T00:00:00.000000Z"
}
}{
"status": false,
"error": "Insufficient balance",
"required": 14.28,
"available": 5
}Authorizations
Path Parameters
Domain ID
Body
application/json
Number of years to extend the registration by.
Required range:
1 <= x <= 10Response
The domain was renewed and the account balance was charged.
Example:
true
Example:
"Domain renewed"
ID of the balance invoice created for this renewal.
Example:
8232
Gross amount deducted from the account balance, VAT included.
Example:
14.28
Example:
1
Domain object.
Show child attributes
Show child attributes