import requests
url = "https://platform.ankra.app/api/v1/clusters/{cluster_id}/ai-insights"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://platform.ankra.app/api/v1/clusters/{cluster_id}/ai-insights', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://platform.ankra.app/api/v1/clusters/{cluster_id}/ai-insights \
--header 'Authorization: Bearer <token>'{
"items": [
{}
],
"page": 123,
"page_size": 123,
"total": 123,
"total_pages": 123
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}{
"detail": "Cluster not found"
}List cluster AI insights
Lists the AI insights Ankra recorded for a cluster: the diagnoses of recurring or ongoing issues, each with its severity, status, affected resource and when it was first and last seen. The same listing the portal’s Insights page reads, with the same filters and paging. Requires clusters.read on the cluster.
import requests
url = "https://platform.ankra.app/api/v1/clusters/{cluster_id}/ai-insights"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://platform.ankra.app/api/v1/clusters/{cluster_id}/ai-insights', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://platform.ankra.app/api/v1/clusters/{cluster_id}/ai-insights \
--header 'Authorization: Bearer <token>'{
"items": [
{}
],
"page": 123,
"page_size": 123,
"total": 123,
"total_pages": 123
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}{
"detail": "Cluster not found"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Headers
PAT organisation override.
Path Parameters
Query Parameters
Only insights in this status (for example open).
Only insights of this severity.
Free-text search over the insight.
Only insights in this namespace.
Only insights of this category.
Only insights about the resource of this name.
The namespace of resource.
The order of the listing.
Only insights seen from this time.
Only insights seen up to this time.
The page to return, from 1.
x >= 1How many insights a page holds.
1 <= x <= 100