Stream chat responses for cluster troubleshooting
import requests
url = "https://platform.ankra.app/api/v1/org/clusters/{cluster_id}/kubernetes/chat"
payload = {
"query": "<string>",
"addon_name": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({query: '<string>', addon_name: '<string>'})
};
fetch('https://platform.ankra.app/api/v1/org/clusters/{cluster_id}/kubernetes/chat', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://platform.ankra.app/api/v1/org/clusters/{cluster_id}/kubernetes/chat \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"query": "<string>",
"addon_name": "<string>"
}
'{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Chat
Stream chat responses for cluster troubleshooting
Runs one AI chat turn about the cluster and streams the reply as server-sent events. Answers 404 when the cluster is not a live cluster of the organisation. Deprecated: responses carry Deprecation and Sunset headers, and durable chat sessions (/api/v1/chat/sessions) are the successor.
POST
/
api
/
v1
/
org
/
clusters
/
{cluster_id}
/
kubernetes
/
chat
Stream chat responses for cluster troubleshooting
import requests
url = "https://platform.ankra.app/api/v1/org/clusters/{cluster_id}/kubernetes/chat"
payload = {
"query": "<string>",
"addon_name": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({query: '<string>', addon_name: '<string>'})
};
fetch('https://platform.ankra.app/api/v1/org/clusters/{cluster_id}/kubernetes/chat', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://platform.ankra.app/api/v1/org/clusters/{cluster_id}/kubernetes/chat \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"query": "<string>",
"addon_name": "<string>"
}
'{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
Body
application/json
The plan-level Launch Plan approval this turn acts under. A confirmation-gated write the approval covers is claimed under it and runs instead of asking for confirmation; anything it does not cover, and any call after the approval expired, was revoked or the plan changed, asks for confirmation as usual. Only the person who approved can act under it.
Response
Streaming chat response