Partial Update for CAPTCHA Configuration
curl --request PATCH \
--url https://{tenantDomain}/api/v2/attack-protection/captcha \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"simple_captcha": {}
}
'import requests
url = "https://{tenantDomain}/api/v2/attack-protection/captcha"
payload = { "simple_captcha": {} }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({simple_captcha: {}})
};
fetch('https://{tenantDomain}/api/v2/attack-protection/captcha', 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://{tenantDomain}/api/v2/attack-protection/captcha",
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([
'simple_captcha' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://{tenantDomain}/api/v2/attack-protection/captcha"
payload := strings.NewReader("{\n \"simple_captcha\": {}\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <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("https://{tenantDomain}/api/v2/attack-protection/captcha")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"simple_captcha\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{tenantDomain}/api/v2/attack-protection/captcha")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"simple_captcha\": {}\n}"
response = http.request(request)
puts response.read_body{
"active_provider_id": "<string>",
"arkose": {
"site_key": "<string>",
"fail_open": true,
"client_subdomain": "<string>",
"verify_subdomain": "<string>"
},
"auth_challenge": {
"fail_open": true
},
"hcaptcha": {
"site_key": "<string>"
},
"friendly_captcha": {
"site_key": "<string>"
},
"recaptcha_enterprise": {
"site_key": "<string>",
"project_id": "<string>"
},
"recaptcha_v2": {
"site_key": "<string>"
},
"simple_captcha": {}
}Partial Update for CAPTCHA Configuration
Update existing CAPTCHA configuration for your client.
PATCH
https://{tenantDomain}/api/v2
/
attack-protection
/
captcha
Partial Update for CAPTCHA Configuration
curl --request PATCH \
--url https://{tenantDomain}/api/v2/attack-protection/captcha \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"simple_captcha": {}
}
'import requests
url = "https://{tenantDomain}/api/v2/attack-protection/captcha"
payload = { "simple_captcha": {} }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({simple_captcha: {}})
};
fetch('https://{tenantDomain}/api/v2/attack-protection/captcha', 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://{tenantDomain}/api/v2/attack-protection/captcha",
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([
'simple_captcha' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://{tenantDomain}/api/v2/attack-protection/captcha"
payload := strings.NewReader("{\n \"simple_captcha\": {}\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <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("https://{tenantDomain}/api/v2/attack-protection/captcha")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"simple_captcha\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{tenantDomain}/api/v2/attack-protection/captcha")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"simple_captcha\": {}\n}"
response = http.request(request)
puts response.read_body{
"active_provider_id": "<string>",
"arkose": {
"site_key": "<string>",
"fail_open": true,
"client_subdomain": "<string>",
"verify_subdomain": "<string>"
},
"auth_challenge": {
"fail_open": true
},
"hcaptcha": {
"site_key": "<string>"
},
"friendly_captcha": {
"site_key": "<string>"
},
"recaptcha_enterprise": {
"site_key": "<string>",
"project_id": "<string>"
},
"recaptcha_v2": {
"site_key": "<string>"
},
"simple_captcha": {}
}Autorisations
bearerAuthoAuth2ClientCredentials
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Corps
application/jsonapplication/x-www-form-urlencoded
The id of the active provider for the CAPTCHA.
Options disponibles:
arkose, auth_challenge, friendly_captcha, hcaptcha, recaptcha_v2, recaptcha_enterprise, simple_captcha Maximum string length:
36Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Réponse
Captcha configuration successfully retrieved.
⌘I