Changes an RDB export schedule's cron expression, retention, or enables or disables it
curl --request PATCH \
--url http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName} \
--header 'Content-Type: application/json' \
--cookie token= \
--data '
{
"schedule": "<string>",
"enabled": true,
"retention": 50
}
'import requests
url = "http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName}"
payload = {
"schedule": "<string>",
"enabled": True,
"retention": 50
}
headers = {
"cookie": "token=",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {cookie: 'token=', 'Content-Type': 'application/json'},
body: JSON.stringify({schedule: '<string>', enabled: true, retention: 50})
};
fetch('http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "3001",
CURLOPT_URL => "http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'schedule' => '<string>',
'enabled' => true,
'retention' => 50
]),
CURLOPT_COOKIE => "token=",
CURLOPT_HTTPHEADER => [
"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 := "http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName}"
payload := strings.NewReader("{\n \"schedule\": \"<string>\",\n \"enabled\": true,\n \"retention\": 50\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("cookie", "token=")
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.patch("http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName}")
.header("cookie", "token=")
.header("Content-Type", "application/json")
.body("{\n \"schedule\": \"<string>\",\n \"enabled\": true,\n \"retention\": 50\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName}")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Patch.new(url)
request["cookie"] = 'token='
request["Content-Type"] = 'application/json'
request.body = "{\n \"schedule\": \"<string>\",\n \"enabled\": true,\n \"retention\": 50\n}"
response = http.request(request)
puts response.read_body{
"name": "<string>",
"namespace": "<string>",
"clusterName": "<string>",
"schedule": "<string>",
"enabled": true,
"retention": 123,
"repository": "<string>",
"node": "replica",
"createdAt": "<string>",
"filters": {
"databases": [
7
],
"keyPatterns": [
"<string>"
]
},
"createdBy": "<string>",
"lastScheduleTime": "<string>",
"lastSuccessfulTime": "<string>"
}{
"error": "<string>",
"statusCode": 123,
"message": "<string>"
}{
"error": "<string>",
"statusCode": 123,
"message": "<string>"
}{
"error": "<string>",
"statusCode": 123,
"message": "<string>"
}RDB Transfers
Changes an RDB export schedule's cron expression, retention, or enables or disables it
PATCH
/
api
/
clusters
/
{clusterName}
/
transfers
/
schedules
/
{scheduleName}
Changes an RDB export schedule's cron expression, retention, or enables or disables it
curl --request PATCH \
--url http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName} \
--header 'Content-Type: application/json' \
--cookie token= \
--data '
{
"schedule": "<string>",
"enabled": true,
"retention": 50
}
'import requests
url = "http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName}"
payload = {
"schedule": "<string>",
"enabled": True,
"retention": 50
}
headers = {
"cookie": "token=",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {cookie: 'token=', 'Content-Type': 'application/json'},
body: JSON.stringify({schedule: '<string>', enabled: true, retention: 50})
};
fetch('http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "3001",
CURLOPT_URL => "http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'schedule' => '<string>',
'enabled' => true,
'retention' => 50
]),
CURLOPT_COOKIE => "token=",
CURLOPT_HTTPHEADER => [
"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 := "http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName}"
payload := strings.NewReader("{\n \"schedule\": \"<string>\",\n \"enabled\": true,\n \"retention\": 50\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("cookie", "token=")
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.patch("http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName}")
.header("cookie", "token=")
.header("Content-Type", "application/json")
.body("{\n \"schedule\": \"<string>\",\n \"enabled\": true,\n \"retention\": 50\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:3001/api/clusters/{clusterName}/transfers/schedules/{scheduleName}")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Patch.new(url)
request["cookie"] = 'token='
request["Content-Type"] = 'application/json'
request.body = "{\n \"schedule\": \"<string>\",\n \"enabled\": true,\n \"retention\": 50\n}"
response = http.request(request)
puts response.read_body{
"name": "<string>",
"namespace": "<string>",
"clusterName": "<string>",
"schedule": "<string>",
"enabled": true,
"retention": 123,
"repository": "<string>",
"node": "replica",
"createdAt": "<string>",
"filters": {
"databases": [
7
],
"keyPatterns": [
"<string>"
]
},
"createdBy": "<string>",
"lastScheduleTime": "<string>",
"lastSuccessfulTime": "<string>"
}{
"error": "<string>",
"statusCode": 123,
"message": "<string>"
}{
"error": "<string>",
"statusCode": 123,
"message": "<string>"
}{
"error": "<string>",
"statusCode": 123,
"message": "<string>"
}Authorizations
JWT token stored in HTTP-only cookie
Query Parameters
Minimum string length:
1Body
application/json
Response
Default Response
Read from a replica when the shard has one (default), or always from the primary.
Available options:
replica Show child attributes
Show child attributes
Was this page helpful?