Get cluster action
curl --request GET \
--url https://api.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id} \
--header 'Authorization: <api-key>'import requests
url = "https://api.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id}"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id}', 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.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
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://api.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id}"
req, _ := http.NewRequest("GET", 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.get("https://api.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id}")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"cluster_id": "<string>",
"account_id": "<string>",
"action_type": "terminate_pod",
"status": "Pending",
"target_pod_name": "<string>",
"target_namespace": "<string>",
"parameters": {},
"result": "<string>",
"created_by": "<string>",
"created_at": "<string>",
"updated_at": "<string>",
"deleted_at": "<string>"
}{
"status": 123,
"code": "<string>",
"request_id": "<string>",
"validation_details": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}Cluster Actions
Get cluster action
Get a single cluster isolation action by ID.
GET
/
accounts
/
{account_id}
/
clusters
/
{cluster_id}
/
actions
/
{action_id}
Get cluster action
curl --request GET \
--url https://api.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id} \
--header 'Authorization: <api-key>'import requests
url = "https://api.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id}"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id}', 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.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
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://api.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id}"
req, _ := http.NewRequest("GET", 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.get("https://api.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id}")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.prd.rad.security/accounts/{account_id}/clusters/{cluster_id}/actions/{action_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"cluster_id": "<string>",
"account_id": "<string>",
"action_type": "terminate_pod",
"status": "Pending",
"target_pod_name": "<string>",
"target_namespace": "<string>",
"parameters": {},
"result": "<string>",
"created_by": "<string>",
"created_at": "<string>",
"updated_at": "<string>",
"deleted_at": "<string>"
}{
"status": 123,
"code": "<string>",
"request_id": "<string>",
"validation_details": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>",
"param": "<string>"
}
]
}Authorizations
Path Parameters
Account ID
Cluster ID
Action ID
Response
OK
Action ID, prefixed with ca-
Available options:
terminate_pod, disable_outbound, label_pod Example:
"terminate_pod"
Execution status of the action
Available options:
Pending, Executed, Failed Example:
"Pending"
Action parameters. labels for label_pod, quarantine_id for disable_outbound.
Message reported by rad-sync after execution; the Kubernetes error when the action failed.
Identity that created the action
⌘I