import requests
url = "https://platform.ankra.app/api/v1/org/cloud-cost/waste"
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/org/cloud-cost/waste', 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/org/cloud-cost/waste \
--header 'Authorization: Bearer <token>'{
"credential_errors": [
{
"credential_name": "<string>",
"error": "<string>",
"provider": "<string>",
"scanned_at": "2023-11-07T05:31:56Z"
}
],
"currency": "<string>",
"findings": [
{
"cluster_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cluster_name": "<string>",
"credential_name": "<string>",
"details": {},
"external_id": "<string>",
"first_seen_at": "2023-11-07T05:31:56Z",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"kind": "<string>",
"last_seen_at": "2023-11-07T05:31:56Z",
"monthly_cost_cents": 123,
"provider": "<string>",
"region": "<string>",
"resource_name": "<string>",
"origin_namespace": "<string>",
"shared_with_org_count": 123,
"counts_toward_savings": true
}
],
"has_data": true,
"scanned_at": "2023-11-07T05:31:56Z",
"total_monthly_cost_cents": 123,
"unpriced_finding_count": 123,
"shared_not_counted_monthly_cost_cents": 123,
"shared_not_counted_finding_count": 123,
"consent": {
"kinds": [
"<string>"
],
"min_unattached_days": 123
}
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}{
"detail": "Cluster not found"
}List open cloud waste findings
The organisation’s open waste findings from the latest scan, with the credentials whose sweep failed so an incomplete scan never reads as zero waste. Bearer-PAT twin of the browser route of the same name under /org; the console’s session cookie is not accepted here and the browser route answers a token with a login redirect.
import requests
url = "https://platform.ankra.app/api/v1/org/cloud-cost/waste"
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/org/cloud-cost/waste', 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/org/cloud-cost/waste \
--header 'Authorization: Bearer <token>'{
"credential_errors": [
{
"credential_name": "<string>",
"error": "<string>",
"provider": "<string>",
"scanned_at": "2023-11-07T05:31:56Z"
}
],
"currency": "<string>",
"findings": [
{
"cluster_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cluster_name": "<string>",
"credential_name": "<string>",
"details": {},
"external_id": "<string>",
"first_seen_at": "2023-11-07T05:31:56Z",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"kind": "<string>",
"last_seen_at": "2023-11-07T05:31:56Z",
"monthly_cost_cents": 123,
"provider": "<string>",
"region": "<string>",
"resource_name": "<string>",
"origin_namespace": "<string>",
"shared_with_org_count": 123,
"counts_toward_savings": true
}
],
"has_data": true,
"scanned_at": "2023-11-07T05:31:56Z",
"total_monthly_cost_cents": 123,
"unpriced_finding_count": 123,
"shared_not_counted_monthly_cost_cents": 123,
"shared_not_counted_finding_count": 123,
"consent": {
"kinds": [
"<string>"
],
"min_unattached_days": 123
}
}{
"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.
Query Parameters
Narrow the findings to one cluster.
Response
Successful response
Show child attributes
Show child attributes
Show child attributes
Show child attributes
The priced monthly cost of the listed findings whose cost counts in another organisation or in none (counts_toward_savings false); it is not in total_monthly_cost_cents.
How many listed findings have counts_toward_savings false, priced or not; none of them is in unpriced_finding_count.
The kinds this platform deletes only with written consent (no snapshot exists), and the minimum age a finding must have been seen before it may be deleted.
Show child attributes
Show child attributes