import requests
url = "https://platform.ankra.app/org/credentials/upcloud/{credential_id}/capacity"
headers = {"cookie": "ankra_session="}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {cookie: 'ankra_session='}};
fetch('https://platform.ankra.app/org/credentials/upcloud/{credential_id}/capacity', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://platform.ankra.app/org/credentials/upcloud/{credential_id}/capacity \
--cookie ankra_session={
"provider": "azure",
"measurement_version": 1,
"hetzner": {
"servers": {
"count": 123,
"running": 123,
"cores": 123,
"memory_gb": 123,
"disk_gb": 123
},
"volumes": {
"count": 123,
"total_gb": 123
},
"load_balancers": 123,
"floating_ips": 123,
"primary_ips": 123,
"networks": 123,
"firewalls": 123,
"ssh_keys": 123
},
"proxmox": {
"nodes": [
{
"node": "<string>",
"status": "<string>",
"cpu_cores": 123,
"cpu_used_fraction": 123,
"memory_total_bytes": 123,
"memory_used_bytes": 123,
"root_disk_total_bytes": 123,
"root_disk_used_bytes": 123,
"uptime_seconds": 123
}
],
"storages": [
{
"storage": "<string>",
"type": "<string>",
"shared": true,
"total_bytes": 123,
"used_bytes": 123,
"node": "<string>"
}
],
"guests": {
"count": 123,
"running": 123,
"templates": 123,
"allocated_cpu_cores": 123,
"allocated_memory_bytes": 123
},
"totals": {
"nodes": 123,
"online_nodes": 123,
"cpu_cores": 123,
"memory_total_bytes": 123,
"memory_used_bytes": 123,
"storage_total_bytes": 123,
"storage_used_bytes": 123
}
},
"upcloud": {
"credits": 123,
"limits": {
"cores": 123,
"memory_mb": 123,
"storage_ssd_gb": 123,
"storage_hdd_gb": 123,
"public_ipv4": 123,
"public_ipv6": 123,
"networks": 123,
"load_balancers": 123,
"detached_floating_ips": 123
},
"servers": {
"count": 123,
"running": 123,
"cores": 123,
"memory_mb": 123
},
"storages": {
"count": 123,
"total_gb": 123
}
},
"digitalocean": {
"account_status": "<string>",
"limits": {
"droplets": 123,
"floating_ips": 123,
"reserved_ips": 123
},
"droplets": {
"count": 123,
"running": 123,
"vcpus": 123,
"memory_mb": 123,
"disk_gb": 123
},
"volumes": {
"count": 123,
"total_gb": 123
},
"load_balancers": 123,
"floating_ips": 123
},
"ovh": {
"regions": [
{
"region": "<string>",
"instances_used": 123,
"instances_limit": 123,
"cores_used": 123,
"cores_limit": 123,
"ram_used_mb": 123,
"ram_limit_mb": 123,
"volume_used_gb": 123,
"volume_limit_gb": 123,
"volume_count": 123,
"load_balancers_used": 123,
"load_balancers_limit": 123
}
],
"totals": {
"instances_used": 123,
"instances_limit": 123,
"cores_used": 123,
"cores_limit": 123,
"ram_used_mb": 123,
"ram_limit_mb": 123,
"volume_used_gb": 123,
"volume_limit_gb": 123
}
},
"scaleway": {
"zones": [
{
"zone": "<string>",
"servers": 123,
"running": 123,
"cores": 123,
"ram_bytes": 123
}
],
"servers": 123,
"running": 123,
"cores": 123,
"ram_bytes": 123,
"storage_gb": 123,
"load_balancers": 123
},
"morpheus": {
"clouds": [
{
"id": 123,
"name": "<string>",
"memory_used_bytes": 123,
"memory_total_bytes": 123,
"storage_used_bytes": 123,
"storage_total_bytes": 123,
"cpu_used_percent": 123
}
],
"totals": {
"memory_used_bytes": 123,
"memory_total_bytes": 123,
"storage_used_bytes": 123,
"storage_total_bytes": 123
},
"instances": 123,
"hosts": 123
},
"azure": {
"virtual_machines": 123,
"aks_clusters": 123,
"regions": [
{
"location": "<string>",
"virtual_machines": 123,
"cores_used": 123,
"cores_limit": 123,
"virtual_machines_used": 123,
"virtual_machines_limit": 123
}
]
}
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}Get UpCloud credential capacity (browser session)
Browser session authentication; any member of the organisation that owns the credential. Reads the capacity and usage the UpCloud API exposes for this credential, live from the provider. Pass measurement_version=1 to receive the versioned contract, which keeps measurements the provider did not report as null; without it the response omits measurement_version and projects unknown OVH and HPE Morpheus measurements as 0 for older clients. Any other measurement_version answers 400. A credential of another provider or organisation answers 404; a provider API that refuses the read answers 400 with the provider’s detail.
import requests
url = "https://platform.ankra.app/org/credentials/upcloud/{credential_id}/capacity"
headers = {"cookie": "ankra_session="}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {cookie: 'ankra_session='}};
fetch('https://platform.ankra.app/org/credentials/upcloud/{credential_id}/capacity', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://platform.ankra.app/org/credentials/upcloud/{credential_id}/capacity \
--cookie ankra_session={
"provider": "azure",
"measurement_version": 1,
"hetzner": {
"servers": {
"count": 123,
"running": 123,
"cores": 123,
"memory_gb": 123,
"disk_gb": 123
},
"volumes": {
"count": 123,
"total_gb": 123
},
"load_balancers": 123,
"floating_ips": 123,
"primary_ips": 123,
"networks": 123,
"firewalls": 123,
"ssh_keys": 123
},
"proxmox": {
"nodes": [
{
"node": "<string>",
"status": "<string>",
"cpu_cores": 123,
"cpu_used_fraction": 123,
"memory_total_bytes": 123,
"memory_used_bytes": 123,
"root_disk_total_bytes": 123,
"root_disk_used_bytes": 123,
"uptime_seconds": 123
}
],
"storages": [
{
"storage": "<string>",
"type": "<string>",
"shared": true,
"total_bytes": 123,
"used_bytes": 123,
"node": "<string>"
}
],
"guests": {
"count": 123,
"running": 123,
"templates": 123,
"allocated_cpu_cores": 123,
"allocated_memory_bytes": 123
},
"totals": {
"nodes": 123,
"online_nodes": 123,
"cpu_cores": 123,
"memory_total_bytes": 123,
"memory_used_bytes": 123,
"storage_total_bytes": 123,
"storage_used_bytes": 123
}
},
"upcloud": {
"credits": 123,
"limits": {
"cores": 123,
"memory_mb": 123,
"storage_ssd_gb": 123,
"storage_hdd_gb": 123,
"public_ipv4": 123,
"public_ipv6": 123,
"networks": 123,
"load_balancers": 123,
"detached_floating_ips": 123
},
"servers": {
"count": 123,
"running": 123,
"cores": 123,
"memory_mb": 123
},
"storages": {
"count": 123,
"total_gb": 123
}
},
"digitalocean": {
"account_status": "<string>",
"limits": {
"droplets": 123,
"floating_ips": 123,
"reserved_ips": 123
},
"droplets": {
"count": 123,
"running": 123,
"vcpus": 123,
"memory_mb": 123,
"disk_gb": 123
},
"volumes": {
"count": 123,
"total_gb": 123
},
"load_balancers": 123,
"floating_ips": 123
},
"ovh": {
"regions": [
{
"region": "<string>",
"instances_used": 123,
"instances_limit": 123,
"cores_used": 123,
"cores_limit": 123,
"ram_used_mb": 123,
"ram_limit_mb": 123,
"volume_used_gb": 123,
"volume_limit_gb": 123,
"volume_count": 123,
"load_balancers_used": 123,
"load_balancers_limit": 123
}
],
"totals": {
"instances_used": 123,
"instances_limit": 123,
"cores_used": 123,
"cores_limit": 123,
"ram_used_mb": 123,
"ram_limit_mb": 123,
"volume_used_gb": 123,
"volume_limit_gb": 123
}
},
"scaleway": {
"zones": [
{
"zone": "<string>",
"servers": 123,
"running": 123,
"cores": 123,
"ram_bytes": 123
}
],
"servers": 123,
"running": 123,
"cores": 123,
"ram_bytes": 123,
"storage_gb": 123,
"load_balancers": 123
},
"morpheus": {
"clouds": [
{
"id": 123,
"name": "<string>",
"memory_used_bytes": 123,
"memory_total_bytes": 123,
"storage_used_bytes": 123,
"storage_total_bytes": 123,
"cpu_used_percent": 123
}
],
"totals": {
"memory_used_bytes": 123,
"memory_total_bytes": 123,
"storage_used_bytes": 123,
"storage_total_bytes": 123
},
"instances": 123,
"hosts": 123
},
"azure": {
"virtual_machines": 123,
"aks_clusters": 123,
"regions": [
{
"location": "<string>",
"virtual_machines": 123,
"cores_used": 123,
"cores_limit": 123,
"virtual_machines_used": 123,
"virtual_machines_limit": 123
}
]
}
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}Authorizations
Browser session. Mutations also require X-Ankra-CSRF.
Path Parameters
Query Parameters
Set to 1 to keep unreported measurements as null instead of 0. measurement_version on provider credential capacity responses. Version 1 preserves missing OVH and Morpheus measurements as null. Older responses cannot distinguish missing readings from zero.
Response
Capacity and usage report
The provider-tagged capacity and usage report of a cloud credential (GET /org/credentials/{provider}/{credential_id}/capacity). Exactly one provider member is set, named by provider. Each provider reports what its API exposes: Hetzner and Scaleway report usage only, Proxmox VE reports the cluster's node and storage totals, UpCloud and DigitalOcean report account limits next to usage, OVH and HPE Morpheus report measurements that may be unknown. measurement_version is present only on responses requested with measurement_version=1; unversioned responses omit it and project unknown OVH and Morpheus measurements as 0.
azure, digitalocean, hetzner, morpheus, ovh, proxmox, scaleway, upcloud measurement_version on provider credential capacity responses. Version 1 preserves missing OVH and Morpheus measurements as null. Older responses cannot distinguish missing readings from zero.
Project usage behind a Hetzner credential. Hetzner exposes no project-limit read, so limits only surface as resource_limit_exceeded create failures.
Show child attributes
Show child attributes
The Proxmox VE cluster's total and used node resources, storage pools and guests behind a credential.
Show child attributes
Show child attributes
Account credits, resource limits and usage behind an UpCloud credential.
Show child attributes
Show child attributes
Account status, limits and usage behind a DigitalOcean credential.
Show child attributes
Show child attributes
Per-region quotas and their totals behind an OVH Public Cloud credential. A region OVH returns without quota sections stays in the list with unknown readings.
Show child attributes
Show child attributes
Project usage behind a Scaleway credential, per zone and in total. Scaleway exposes no limit read.
Show child attributes
Show child attributes
Per-cloud capacity and its totals behind an HPE Morpheus credential, with the instance and host counts.
Show child attributes
Show child attributes
Virtual machines, AKS clusters and per-location compute quotas behind an Azure credential.
Show child attributes
Show child attributes