curl --request GET \
--url https://api.enokilabs.ai/api/v1/categoryimport requests
url = "https://api.enokilabs.ai/api/v1/category"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.enokilabs.ai/api/v1/category', 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.enokilabs.ai/api/v1/category",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.enokilabs.ai/api/v1/category"
req, _ := http.NewRequest("GET", url, nil)
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.enokilabs.ai/api/v1/category")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.enokilabs.ai/api/v1/category")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"categories": [
{
"key": "<string>",
"display_name": "<string>",
"description": "<string>"
}
],
"lens": "security"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}List taxonomy categories
List the security categories an assessment run can be focused on, with the display name and description of each. The ‘key’ of each entry is exactly what the ‘categories’ field of POST /api/v1/run accepts; a key this endpoint did not return is rejected there with a 400. Use the descriptions to pick the categories relevant to a change instead of running the full taxonomy on every deploy.
Responses are static platform metadata, so a polling caller can cache one for an hour.
curl --request GET \
--url https://api.enokilabs.ai/api/v1/categoryimport requests
url = "https://api.enokilabs.ai/api/v1/category"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.enokilabs.ai/api/v1/category', 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.enokilabs.ai/api/v1/category",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.enokilabs.ai/api/v1/category"
req, _ := http.NewRequest("GET", url, nil)
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.enokilabs.ai/api/v1/category")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.enokilabs.ai/api/v1/category")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"categories": [
{
"key": "<string>",
"display_name": "<string>",
"description": "<string>"
}
],
"lens": "security"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Headers
Bearer token with API key
Query Parameters
Optional. Which part of the taxonomy to list; defaults to 'security', the only lens a run can be focused on. The other values list categories Enoki covers elsewhere — passing one of their keys to POST /api/v1/run is rejected with a 400.
security, safety, compliance Response
Successful Response