Give up the paid backup slots
curl --request DELETE \
--url https://rdp.sh/api/v1/servers/{server}/backups/slots \
--header 'Authorization: <api-key>'import requests
url = "https://rdp.sh/api/v1/servers/{server}/backups/slots"
headers = {"Authorization": "<api-key>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: '<api-key>'}};
fetch('https://rdp.sh/api/v1/servers/{server}/backups/slots', 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/servers/{server}/backups/slots",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://rdp.sh/api/v1/servers/{server}/backups/slots"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://rdp.sh/api/v1/servers/{server}/backups/slots")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://rdp.sh/api/v1/servers/{server}/backups/slots")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"enabled": true,
"slots": {
"total": 1,
"free": 1,
"paid": false,
"paid_total": 5
},
"status": true,
"message": "Backups continue on the free slot. There is no refund for the current period.",
"schedule": {
"frequency": "daily",
"hour": 3,
"weekday": 123,
"retention": 1
}
}{
"status": false,
"error": "Delete backups until only 1 remains, then switch back to the free slot."
}Backups
Remove Backup Slots
Goes back to the free slot. Nothing is refunded and nothing is deleted: delete backups until only one is left first. Renewals no longer include the surcharge.
DELETE
/
servers
/
{server}
/
backups
/
slots
Give up the paid backup slots
curl --request DELETE \
--url https://rdp.sh/api/v1/servers/{server}/backups/slots \
--header 'Authorization: <api-key>'import requests
url = "https://rdp.sh/api/v1/servers/{server}/backups/slots"
headers = {"Authorization": "<api-key>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: '<api-key>'}};
fetch('https://rdp.sh/api/v1/servers/{server}/backups/slots', 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/servers/{server}/backups/slots",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://rdp.sh/api/v1/servers/{server}/backups/slots"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://rdp.sh/api/v1/servers/{server}/backups/slots")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://rdp.sh/api/v1/servers/{server}/backups/slots")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"enabled": true,
"slots": {
"total": 1,
"free": 1,
"paid": false,
"paid_total": 5
},
"status": true,
"message": "Backups continue on the free slot. There is no refund for the current period.",
"schedule": {
"frequency": "daily",
"hour": 3,
"weekday": 123,
"retention": 1
}
}{
"status": false,
"error": "Delete backups until only 1 remains, then switch back to the free slot."
}Authorizations
Your API key as it is, without Bearer. API access is off for new
accounts: until it is turned on under Settings > API, every request
answers 403 with API access is turned off for this account. Turn it on under Settings > API. If the account lists allowed IPs, a request
from any other address answers 403 with This API key is not allowed from <address>.
Response
The server is back on the free slot.
Whether a server's backups are enabled, its slots and its schedule.